mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-06-14 00:58:51 +02:00
Core::IsRunning: Avoid Global System Accessor
This commit is contained in:
@ -191,16 +191,16 @@ void GamecubeControllersWidget::SaveSettings()
|
||||
{
|
||||
Config::ConfigChangeCallbackGuard config_guard;
|
||||
|
||||
auto& system = Core::System::GetInstance();
|
||||
for (size_t i = 0; i < m_gc_groups.size(); ++i)
|
||||
{
|
||||
const SerialInterface::SIDevices si_device =
|
||||
FromGCMenuIndex(m_gc_controller_boxes[i]->currentIndex());
|
||||
Config::SetBaseOrCurrent(Config::GetInfoForSIDevice(static_cast<int>(i)), si_device);
|
||||
|
||||
if (Core::IsRunning())
|
||||
if (Core::IsRunning(system))
|
||||
{
|
||||
Core::System::GetInstance().GetSerialInterface().ChangeDevice(si_device,
|
||||
static_cast<s32>(i));
|
||||
system.GetSerialInterface().ChangeDevice(si_device, static_cast<s32>(i));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user