mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-12-25 01:01:37 -05:00
InputCommon: Make ControllerInterface RegisterDevicesChangedCallback use Common::HookableEvent.
This commit is contained in:
@@ -75,7 +75,7 @@ Settings::Settings()
|
||||
}
|
||||
});
|
||||
|
||||
m_hotplug_callback_handle = g_controller_interface.RegisterDevicesChangedCallback([this] {
|
||||
m_hotplug_event_hook = g_controller_interface.RegisterDevicesChangedCallback("Settings", [this] {
|
||||
if (Core::IsHostThread())
|
||||
{
|
||||
emit DevicesChanged();
|
||||
@@ -101,7 +101,7 @@ Settings::~Settings()
|
||||
|
||||
void Settings::UnregisterDevicesChangedCallback()
|
||||
{
|
||||
g_controller_interface.UnregisterDevicesChangedCallback(m_hotplug_callback_handle);
|
||||
m_hotplug_event_hook.reset();
|
||||
}
|
||||
|
||||
Settings& Settings::Instance()
|
||||
|
||||
Reference in New Issue
Block a user