Clean up GlobalWin.Tools assignment and usage in MainForm

This commit is contained in:
YoshiRulz 2020-11-26 21:46:41 +10:00
parent 8aab0d00cd
commit 2e428ccc2e
No known key found for this signature in database
GPG Key ID: C4DE31C245353FB7
2 changed files with 4 additions and 3 deletions
src/BizHawk.Client.EmuHawk

View File

@ -101,7 +101,7 @@ namespace BizHawk.Client.EmuHawk
}
}
if (GlobalWin.Tools.IsLoaded<TAStudio>())
if (Tools.IsLoaded<TAStudio>())
{
Tools.TAStudio.LoadMovieFile(filename);
}

View File

@ -311,7 +311,7 @@ namespace BizHawk.Client.EmuHawk
GlobalWin.Game = GameInfo.NullInstance;
_throttle = new Throttle();
Emulator = new NullEmulator();
GlobalWin.Tools = new ToolManager(this, Config, InputManager, Emulator, MovieSession, Game);
GlobalWin.Tools = Tools = new ToolManager(this, Config, InputManager, Emulator, MovieSession, Game);
UpdateStatusSlots();
UpdateKeyPriorityIcon();
@ -847,7 +847,8 @@ namespace BizHawk.Client.EmuHawk
set => GlobalWin.Config = base.Config = value;
}
private ToolManager Tools => GlobalWin.Tools;
private readonly ToolManager Tools;
private DisplayManager DisplayManager => GlobalWin.DisplayManager;
public IMovieSession MovieSession