Make MainForm.RebootCore return bool, read in MainForm.StartNewMovie
resolves #2147
This commit is contained in:
parent
5229d664c4
commit
c57cd97f56
|
@ -71,7 +71,7 @@ namespace BizHawk.Client.Common
|
||||||
void PauseEmulator();
|
void PauseEmulator();
|
||||||
|
|
||||||
/// <remarks>only referenced from <c>EmuClientApi</c></remarks>
|
/// <remarks>only referenced from <c>EmuClientApi</c></remarks>
|
||||||
void RebootCore();
|
bool RebootCore();
|
||||||
|
|
||||||
/// <remarks>only referenced from <c>EmuClientApi</c></remarks>
|
/// <remarks>only referenced from <c>EmuClientApi</c></remarks>
|
||||||
void Render();
|
void Render();
|
||||||
|
|
|
@ -32,7 +32,8 @@ namespace BizHawk.Client.EmuHawk
|
||||||
|
|
||||||
if (!_isLoadingRom)
|
if (!_isLoadingRom)
|
||||||
{
|
{
|
||||||
RebootCore();
|
var rebootSucceeded = RebootCore();
|
||||||
|
if (!rebootSucceeded) return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
Config.RecentMovies.Add(movie.Filename);
|
Config.RecentMovies.Add(movie.Filename);
|
||||||
|
|
|
@ -1103,20 +1103,17 @@ namespace BizHawk.Client.EmuHawk
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public void RebootCore()
|
public bool RebootCore()
|
||||||
{
|
{
|
||||||
if (IsSlave && Master.WantsToControlReboot)
|
if (IsSlave && Master.WantsToControlReboot)
|
||||||
{
|
{
|
||||||
Master.RebootCore();
|
Master.RebootCore();
|
||||||
|
return true;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
if (CurrentlyOpenRomArgs == null)
|
if (CurrentlyOpenRomArgs == null) return true;
|
||||||
{
|
return LoadRom(CurrentlyOpenRomArgs.OpenAdvanced.SimplePath, CurrentlyOpenRomArgs);
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
LoadRom(CurrentlyOpenRomArgs.OpenAdvanced.SimplePath, CurrentlyOpenRomArgs);
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue