mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-07-25 07:09:48 -06:00
Merge pull request #8518 from stenzek/more-wiimote-reset-crashes
Core: Reset Wiimotes/rumble/memwatcher on emu thread
This commit is contained in:
@ -289,15 +289,6 @@ void Stop() // - Hammertime!
|
|||||||
|
|
||||||
g_video_backend->Video_ExitLoop();
|
g_video_backend->Video_ExitLoop();
|
||||||
}
|
}
|
||||||
|
|
||||||
if (_CoreParameter.bWii)
|
|
||||||
Wiimote::ResetAllWiimotes();
|
|
||||||
|
|
||||||
ResetRumble();
|
|
||||||
|
|
||||||
#ifdef USE_MEMORYWATCHER
|
|
||||||
s_memory_watcher.reset();
|
|
||||||
#endif
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void DeclareAsCPUThread()
|
void DeclareAsCPUThread()
|
||||||
@ -374,6 +365,10 @@ static void CpuThread(const std::optional<std::string>& savestate_path, bool del
|
|||||||
// Enter CPU run loop. When we leave it - we are done.
|
// Enter CPU run loop. When we leave it - we are done.
|
||||||
CPU::Run();
|
CPU::Run();
|
||||||
|
|
||||||
|
#ifdef USE_MEMORYWATCHER
|
||||||
|
s_memory_watcher.reset();
|
||||||
|
#endif
|
||||||
|
|
||||||
s_is_started = false;
|
s_is_started = false;
|
||||||
|
|
||||||
if (_CoreParameter.bFastmem)
|
if (_CoreParameter.bFastmem)
|
||||||
@ -533,7 +528,12 @@ static void EmuThread(std::unique_ptr<BootParameters> boot, WindowSystemInfo wsi
|
|||||||
return;
|
return;
|
||||||
|
|
||||||
if (init_wiimotes)
|
if (init_wiimotes)
|
||||||
|
{
|
||||||
|
Wiimote::ResetAllWiimotes();
|
||||||
Wiimote::Shutdown();
|
Wiimote::Shutdown();
|
||||||
|
}
|
||||||
|
|
||||||
|
ResetRumble();
|
||||||
|
|
||||||
Keyboard::Shutdown();
|
Keyboard::Shutdown();
|
||||||
Pad::Shutdown();
|
Pad::Shutdown();
|
||||||
|
Reference in New Issue
Block a user