diff --git a/UI/JitCompareScreen.cpp b/UI/JitCompareScreen.cpp index 73b18543e4..3d94797ad6 100644 --- a/UI/JitCompareScreen.cpp +++ b/UI/JitCompareScreen.cpp @@ -69,7 +69,7 @@ void JitCompareScreen::UpdateDisasm() { } char temp[256]; - snprintf(temp, sizeof(temp), "%i/%i", currentBlock_, blockCacheDebug->GetNumBlocks()); + snprintf(temp, sizeof(temp), "%d/%d", currentBlock_, blockCacheDebug->GetNumBlocks()); blockName_->SetText(temp); if (currentBlock_ < 0 || !blockCacheDebug || currentBlock_ >= blockCacheDebug->GetNumBlocks()) { diff --git a/UI/JitCompareScreen.h b/UI/JitCompareScreen.h index 027f3e7bb6..ab92ef7c33 100644 --- a/UI/JitCompareScreen.h +++ b/UI/JitCompareScreen.h @@ -23,7 +23,14 @@ private: UI::EventReturn OnAddressChange(UI::EventParams &e); UI::EventReturn OnShowStats(UI::EventParams &e); - int currentBlock_ = -1; + // To switch, change the below things and call RecreateViews(); + enum ViewMode { + BLOCK_LIST, + DISASM, + }; + ViewMode viewMode_ = DISASM; + int currentBlock_ = -1; // For DISASM mode + std::vector blockList_; // for BLOCK_LIST mode UI::TextView *blockName_; UI::TextEdit *blockAddr_;