From 734b0f5dd473cc43089b430699ad0215aebbcb4e Mon Sep 17 00:00:00 2001 From: ayuanx Date: Sat, 16 Jan 2010 22:37:38 +0000 Subject: [PATCH] Fixed a stupid error left by me. git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@4860 8ced0084-cf51-0410-be5f-012b33b47a6e --- Source/Core/VideoCommon/Src/CommandProcessor.cpp | 2 +- Source/Core/VideoCommon/Src/Fifo.cpp | 4 ++++ Source/Plugins/Plugin_Wiimote/Src/main.cpp | 6 +++--- Source/Plugins/Plugin_nJoy_SDL/Src/GUI/ConfigBox.cpp | 1 + 4 files changed, 9 insertions(+), 4 deletions(-) diff --git a/Source/Core/VideoCommon/Src/CommandProcessor.cpp b/Source/Core/VideoCommon/Src/CommandProcessor.cpp index ea153180c3..788a463ce2 100644 --- a/Source/Core/VideoCommon/Src/CommandProcessor.cpp +++ b/Source/Core/VideoCommon/Src/CommandProcessor.cpp @@ -571,7 +571,7 @@ bool AllowIdleSkipping() // if not then lock CPUThread until GP finish a frame. void WaitForFrameFinish() { - while ((fake_GPWatchdogLastToken == fifo.Fake_GPWDToken) && fifo.bFF_GPReadEnable && ((!fifo.bFF_BPEnable && fifo.CPReadWriteDistance) || (fifo.bFF_BPEnable && !fifo.bFF_Breakpoint))); + while ((fake_GPWatchdogLastToken == fifo.Fake_GPWDToken) && fifo.bFF_GPReadEnable && ((!fifo.bFF_BPEnable && fifo.CPReadWriteDistance) || (fifo.bFF_BPEnable && !fifo.bFF_Breakpoint))) { s_fifoIdleEvent.Wait(); } diff --git a/Source/Core/VideoCommon/Src/Fifo.cpp b/Source/Core/VideoCommon/Src/Fifo.cpp index 6ca7c3f259..b097af4644 100644 --- a/Source/Core/VideoCommon/Src/Fifo.cpp +++ b/Source/Core/VideoCommon/Src/Fifo.cpp @@ -97,6 +97,10 @@ void Fifo_ExitLoop() // Created to allow for self shutdown. void Fifo_ExitLoopNonBlocking() { + // This should break the wait loop in CPU thread + CommandProcessor::fifo.bFF_GPReadEnable = false; + CommandProcessor::SetFifoIdleFromVideoPlugin(); + // Terminate GPU thread loop fifoStateRun = false; fifo_run_event.Set(); } diff --git a/Source/Plugins/Plugin_Wiimote/Src/main.cpp b/Source/Plugins/Plugin_Wiimote/Src/main.cpp index 222fb3e532..5d8842ae22 100644 --- a/Source/Plugins/Plugin_Wiimote/Src/main.cpp +++ b/Source/Plugins/Plugin_Wiimote/Src/main.cpp @@ -227,12 +227,12 @@ void Initialize(void *init) WMdisplay = (Display*)g_WiimoteInitialize.hWnd; #endif - // Load IR settings, as this is a per-game setting and the user might have loaded a different game - g_Config.LoadIR(); - g_ISOId = g_WiimoteInitialize.ISOId; DEBUG_LOG(WIIMOTE, "ISOId: %08x %s", g_WiimoteInitialize.ISOId, Hex2Ascii(g_WiimoteInitialize.ISOId).c_str()); + // Load IR settings, as this is a per-game setting and the user might have loaded a different game + g_Config.LoadIR(); + // Run this first so that WiiMoteReal::Initialize() overwrites g_Eeprom WiiMoteEmu::Initialize(); diff --git a/Source/Plugins/Plugin_nJoy_SDL/Src/GUI/ConfigBox.cpp b/Source/Plugins/Plugin_nJoy_SDL/Src/GUI/ConfigBox.cpp index c9766b1764..262744aa38 100644 --- a/Source/Plugins/Plugin_nJoy_SDL/Src/GUI/ConfigBox.cpp +++ b/Source/Plugins/Plugin_nJoy_SDL/Src/GUI/ConfigBox.cpp @@ -791,6 +791,7 @@ void PADConfigDialognJoy::CreateGUIControls() // Create objects for general settings 3 m_gGenSettingsID[i] = new wxStaticBoxSizer( wxVERTICAL, m_Controller[i], wxT("Settings") ); m_CBSaveByID[i] = new wxCheckBox(m_Controller[i], IDC_SAVEBYID, wxT("Save by ID"), wxDefaultPosition, wxDefaultSize, 0, wxDefaultValidator); + m_CBSaveByID[i]->Enable(false); m_CBShowAdvanced[i] = new wxCheckBox(m_Controller[i], IDC_SHOWADVANCED, wxT("Show advanced settings"), wxDefaultPosition, wxDefaultSize, 0, wxDefaultValidator); // Populate general settings 3