diff options
| author | Techjar <tecknojar@gmail.com> | 2018-11-10 22:37:49 -0500 |
|---|---|---|
| committer | Techjar <tecknojar@gmail.com> | 2018-11-12 22:32:18 -0500 |
| commit | ef89e4e70c256989ede03d33145ee05be141dc06 (patch) | |
| tree | 3ead829f6e3470797daa744e31e73234120a5705 /Source/Core/DolphinQt/NetPlay/NetPlayDialog.cpp | |
| parent | 97e3200f5799cb43f508fd6c385321bc778c5ffb (diff) | |
NetPlay: Sync power button event
This fixes the deadlock on shutdown when Wii Remotes are in use.
Diffstat (limited to 'Source/Core/DolphinQt/NetPlay/NetPlayDialog.cpp')
| -rw-r--r-- | Source/Core/DolphinQt/NetPlay/NetPlayDialog.cpp | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/Source/Core/DolphinQt/NetPlay/NetPlayDialog.cpp b/Source/Core/DolphinQt/NetPlay/NetPlayDialog.cpp index 1e47f80bb6..30d6146e52 100644 --- a/Source/Core/DolphinQt/NetPlay/NetPlayDialog.cpp +++ b/Source/Core/DolphinQt/NetPlay/NetPlayDialog.cpp @@ -54,6 +54,7 @@ #include "UICommon/DiscordPresence.h" #include "UICommon/GameFile.h" +#include "UICommon/UICommon.h" #include "VideoCommon/VideoConfig.h" @@ -796,6 +797,13 @@ void NetPlayDialog::OnMsgStopGame() QueueOnObject(this, [this] { UpdateDiscordPresence(); }); } +void NetPlayDialog::OnMsgPowerButton() +{ + if (!Core::IsRunning()) + return; + QueueOnObject(this, [] { UICommon::TriggerSTMPowerEvent(); }); +} + void NetPlayDialog::OnPadBufferChanged(u32 buffer) { QueueOnObject(this, [this, buffer] { |
