mirror of
https://github.com/zoriya/ComSquare.git
synced 2026-06-09 12:51:01 +00:00
Marge master into PPU
This commit is contained in:
+8
-4
@@ -35,15 +35,19 @@ namespace ComSquare
|
||||
this->apu->update(cycleCount);
|
||||
}
|
||||
|
||||
void SNES::enableCPUDebugging()
|
||||
void SNES::enableCPUDebugging(bool pause)
|
||||
{
|
||||
#ifdef DEBUGGER_ENABLED
|
||||
if (this->cpu->isDebugger())
|
||||
std::static_pointer_cast<Debugger::CPUDebug>(this->cpu)->focus();
|
||||
else
|
||||
if (this->cpu->isDebugger()) {
|
||||
auto cpuDebug = std::static_pointer_cast<Debugger::CPUDebug>(this->cpu);
|
||||
cpuDebug->focus();
|
||||
if (pause)
|
||||
cpuDebug->pause();
|
||||
} else
|
||||
this->cpu = std::make_shared<Debugger::CPUDebug>(*this->cpu, *this);
|
||||
#else
|
||||
std::cerr << "Debugging features are not enabled. You can't enable the debugger." << std::endl;
|
||||
(void)pause;
|
||||
#endif
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user