Debugger: 'cycles' now shows step-cycle-count (before was abs cumulative cycles) (Fixes #737)

And fixed single-step to only UpdateDisplay() once.
This commit is contained in:
tomcw
2019-12-20 09:15:24 +00:00
parent 82f6bf35a5
commit 418687e3d8
5 changed files with 32 additions and 9 deletions
+8 -1
View File
@@ -3735,6 +3735,7 @@ void DrawVideoScannerValue(int line, int vert, int horz, bool isVisible)
}
//===========================================================================
void DrawVideoScannerInfo (int line)
{
NTSC_VideoGetScannerAddressForDebugger(); // update g_nVideoClockHorz/g_nVideoClockVert
@@ -3755,6 +3756,12 @@ void DrawVideoScannerInfo (int line)
}
}
if (g_nCumulativeCycles != g_videoScannerDisplayInfo.lastCumulativeCycles)
{
g_videoScannerDisplayInfo.cycleDelta = (UINT) (g_nCumulativeCycles - g_videoScannerDisplayInfo.lastCumulativeCycles);
g_videoScannerDisplayInfo.lastCumulativeCycles = g_nCumulativeCycles;
}
DrawVideoScannerValue(line, v, h, NTSC_IsVisible());
line++;
@@ -3778,7 +3785,7 @@ void DrawVideoScannerInfo (int line)
rect.left += nameWidth * nFontWidth;
char sValue[10];
sprintf_s(sValue, sizeof(sValue), "%08X", (UINT32)g_nCumulativeCycles);
sprintf_s(sValue, sizeof(sValue), "%08X", g_videoScannerDisplayInfo.cycleDelta);
PrintText(sValue, rect);
}