Make EmuClientApi.SystemIdConverter a static instance

This commit is contained in:
YoshiRulz 2020-11-26 14:21:07 +10:00
parent 9fc853d404
commit 87a4f1186e
No known key found for this signature in database
GPG Key ID: C4DE31C245353FB7
2 changed files with 2 additions and 2 deletions

View File

@ -72,7 +72,7 @@ namespace BizHawk.Client.EmuHawk
}
}
internal readonly BizHawkSystemIdToEnumConverter SystemIdConverter = new BizHawkSystemIdToEnumConverter();
internal static readonly BizHawkSystemIdToEnumConverter SystemIdConverter = new BizHawkSystemIdToEnumConverter();
private IVideoProvider VideoProvider { get; set; }

View File

@ -98,7 +98,7 @@ namespace BizHawk.Client.EmuHawk
item.Tag = (externalToolFile.Location, entryPoint.FullName); // Tag set => no errors (show custom icon even when disabled)
if (applicabilityAttrs.Count == 1)
{
var system = GlobalWin.ClientApi.SystemIdConverter.Convert(GlobalWin.Emulator.SystemId);
var system = EmuClientApi.SystemIdConverter.Convert(GlobalWin.Emulator.SystemId);
if (applicabilityAttrs[0].NotApplicableTo(system))
{
item.ToolTipText = system == CoreSystem.Null