diff --git a/pcsx2/DebugTools/DebugInterface.cpp b/pcsx2/DebugTools/DebugInterface.cpp index 2efd70d1f1..b1e715552b 100644 --- a/pcsx2/DebugTools/DebugInterface.cpp +++ b/pcsx2/DebugTools/DebugInterface.cpp @@ -18,7 +18,6 @@ #include "DebugInterface.h" #include "Memory.h" #include "R5900.h" -#include "gui/AppCoreThread.h" #include "Debug.h" #include "VU.h" #include "GS.h" // Required for gsNonMirroredRead() @@ -28,8 +27,6 @@ #include "IopMem.h" #include "SymbolMap.h" -extern AppCoreThread CoreThread; - R5900DebugInterface r5900Debug; R3000DebugInterface r3000Debug; diff --git a/pcsx2/IPC.cpp b/pcsx2/IPC.cpp index ca126ba221..63a6f947e4 100644 --- a/pcsx2/IPC.cpp +++ b/pcsx2/IPC.cpp @@ -469,7 +469,7 @@ SocketIPC::IPCBuffer SocketIPC::ParseCommand(char* buf, char* ret_buffer, u32 bu switch (m_vm->HasActiveMachine()) { case true: - if (CoreThread.IsClosing()) + if (GetCoreThread().IsClosing()) status = Paused; else status = Running; diff --git a/pcsx2/Recording/InputRecording.cpp b/pcsx2/Recording/InputRecording.cpp index 65a86bbee8..ff34c095b5 100644 --- a/pcsx2/Recording/InputRecording.cpp +++ b/pcsx2/Recording/InputRecording.cpp @@ -374,7 +374,7 @@ bool InputRecording::Play(wxWindow* parent, wxString filename) // Either load the savestate, or restart the game if (inputRecordingData.FromSaveState()) { - if (!CoreThread.IsOpen()) + if (!GetCoreThread().IsOpen()) { inputRec::consoleLog("Game is not open, aborting playing input recording which starts on a save-state."); inputRecordingData.Close(); diff --git a/pcsx2/Recording/InputRecordingControls.cpp b/pcsx2/Recording/InputRecordingControls.cpp index 5b33b18700..9667bf5f5c 100644 --- a/pcsx2/Recording/InputRecordingControls.cpp +++ b/pcsx2/Recording/InputRecordingControls.cpp @@ -20,7 +20,6 @@ #include "Counters.h" #include "DebugTools/Debug.h" #include "MemoryTypes.h" -#include "gui/App.h" #include "gui/MainFrame.h" #include "InputRecording.h" @@ -68,24 +67,24 @@ void InputRecordingControls::HandlePausingAndLocking() frameLock = false; Resume(); } - else if (!emulationCurrentlyPaused && CoreThread.IsOpen() && CoreThread.IsRunning()) + else if (!emulationCurrentlyPaused && GetCoreThread().IsOpen() && GetCoreThread().IsRunning()) { emulationCurrentlyPaused = true; - CoreThread.PauseSelf(); + GetCoreThread().PauseSelf(); } } - else if (pauseEmulation && CoreThread.IsOpen() && CoreThread.IsRunning()) + else if (pauseEmulation && GetCoreThread().IsOpen() && GetCoreThread().IsRunning()) { emulationCurrentlyPaused = true; - CoreThread.PauseSelf(); + GetCoreThread().PauseSelf(); } } void InputRecordingControls::ResumeCoreThreadIfStarted() { - if (resumeEmulation && CoreThread.IsOpen()) + if (resumeEmulation && GetCoreThread().IsOpen()) { - CoreThread.Resume(); + GetCoreThread().Resume(); resumeEmulation = false; emulationCurrentlyPaused = false; } @@ -115,7 +114,7 @@ bool InputRecordingControls::IsFrameAdvancing() bool InputRecordingControls::IsPaused() { - return emulationCurrentlyPaused && CoreThread.IsOpen() && CoreThread.IsPaused(); + return emulationCurrentlyPaused && GetCoreThread().IsOpen() && GetCoreThread().IsPaused(); } void InputRecordingControls::Pause() @@ -126,13 +125,13 @@ void InputRecordingControls::Pause() void InputRecordingControls::PauseImmediately() { - if (!CoreThread.IsPaused()) + if (!GetCoreThread().IsPaused()) { Pause(); - if (CoreThread.IsOpen() && CoreThread.IsRunning()) + if (GetCoreThread().IsOpen() && GetCoreThread().IsRunning()) { emulationCurrentlyPaused = true; - CoreThread.PauseSelf(); + GetCoreThread().PauseSelf(); } } } @@ -150,13 +149,13 @@ void InputRecordingControls::Resume() void InputRecordingControls::ResumeImmediately() { - if (CoreThread.IsPaused()) + if (GetCoreThread().IsPaused()) { Resume(); - if (CoreThread.IsRunning()) + if (GetCoreThread().IsRunning()) { emulationCurrentlyPaused = false; - CoreThread.Resume(); + GetCoreThread().Resume(); } } }