summaryrefslogtreecommitdiffstats
path: root/src/core/hid
diff options
context:
space:
mode:
authorgerman77 <juangerman-13@hotmail.com>2023-06-25 02:48:45 +0200
committergerman77 <juangerman-13@hotmail.com>2023-06-25 02:59:55 +0200
commit5aa208e26417a455abced9c067f75e1b81f2cb80 (patch)
treeeff9bb064170291d8724fdc59ff2540f17b49b01 /src/core/hid
parentMerge pull request #10891 from german77/sdl28v2 (diff)
downloadyuzu-5aa208e26417a455abced9c067f75e1b81f2cb80.tar
yuzu-5aa208e26417a455abced9c067f75e1b81f2cb80.tar.gz
yuzu-5aa208e26417a455abced9c067f75e1b81f2cb80.tar.bz2
yuzu-5aa208e26417a455abced9c067f75e1b81f2cb80.tar.lz
yuzu-5aa208e26417a455abced9c067f75e1b81f2cb80.tar.xz
yuzu-5aa208e26417a455abced9c067f75e1b81f2cb80.tar.zst
yuzu-5aa208e26417a455abced9c067f75e1b81f2cb80.zip
Diffstat (limited to '')
-rw-r--r--src/core/hid/emulated_controller.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/core/hid/emulated_controller.cpp b/src/core/hid/emulated_controller.cpp
index c937495f9..190f7c906 100644
--- a/src/core/hid/emulated_controller.cpp
+++ b/src/core/hid/emulated_controller.cpp
@@ -1250,6 +1250,11 @@ Common::Input::DriverResult EmulatedController::SetPollingMode(
const auto virtual_nfc_result = nfc_output_device->SetPollingMode(polling_mode);
const auto mapped_nfc_result = right_output_device->SetPollingMode(polling_mode);
+ // Restore previous state
+ if (mapped_nfc_result != Common::Input::DriverResult::Success) {
+ right_output_device->SetPollingMode(Common::Input::PollingMode::Active);
+ }
+
if (virtual_nfc_result == Common::Input::DriverResult::Success) {
return virtual_nfc_result;
}