mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2026-04-25 16:21:11 -05:00
WiimoteReal: Immediately disconnect balance boards when disabled rather than placing them in the temporary pool.
This commit is contained in:
parent
74c5ca79e2
commit
918a419131
|
|
@ -1052,7 +1052,13 @@ void HandleWiimoteSourceChange(unsigned int index)
|
|||
|
||||
{
|
||||
const Core::CPUThreadGuard guard(Core::System::GetInstance());
|
||||
if (auto removed_wiimote = std::move(g_wiimotes[index]))
|
||||
auto removed_wiimote = std::move(g_wiimotes[index]);
|
||||
|
||||
// The Wiimote pool isn't currently designed to handle Balance Boards.
|
||||
// Refactoring will be needed to differentiate between remotes/boards.
|
||||
const bool is_balance_board = index == WIIMOTE_BALANCE_BOARD;
|
||||
|
||||
if (removed_wiimote != nullptr && !is_balance_board)
|
||||
AddWiimoteToPool(std::move(removed_wiimote));
|
||||
}
|
||||
g_controller_interface.PlatformPopulateDevices([] { ProcessWiimotePool(); });
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user