Add a CpuTracingAvailable flag to CoreOutputComm and set to true for NES, set the Trace Logger menu item to be enabled/disabled based on this flag

This commit is contained in:
adelikat 2012-09-30 02:07:14 +00:00
parent bb995c1472
commit f8c508b1a3
3 changed files with 6 additions and 3 deletions

View File

@ -19,6 +19,7 @@ namespace BizHawk.Emulation.Consoles.Nintendo
public NES(GameInfo game, byte[] rom)
{
CoreOutputComm = new CoreOutputComm();
CoreOutputComm.CpuTraceAvailable = true;
BootGodDB.Initialize();
SetPalette(Palettes.FCEUX_Standard);
videoProvider = new MyVideoProvider(this);

View File

@ -35,5 +35,7 @@
public string RomStatusDetails;
public int ScreenLogicalOffsetX, ScreenLogicalOffsetY;
public bool CpuTraceAvailable = false;
}
}

View File

@ -626,13 +626,13 @@ namespace BizHawk.MultiClient
cheatsToolStripMenuItem.ShortcutKeyDisplayString = Global.Config.Cheats;
tAStudioToolStripMenuItem.ShortcutKeyDisplayString = Global.Config.TASTudio;
if (INTERIM)
if (INTERIM && Global.Emulator.CoreOutputComm.CpuTraceAvailable)
{
traceLoggerToolStripMenuItem.Visible = true;
traceLoggerToolStripMenuItem.Enabled = true;
}
else
{
traceLoggerToolStripMenuItem.Visible = false;
traceLoggerToolStripMenuItem.Enabled = false;
}
}