From 0e2edbb0d2e46311d684c6f77e54db2d1e72815c Mon Sep 17 00:00:00 2001 From: Vitor Kiguchi Date: Mon, 5 Apr 2021 19:38:54 -0300 Subject: [PATCH] Account for analog buttons when checking for used buttons circle mod and analog_from_buttons weren't being accounted for. --- src/citra_qt/configuration/configure_input.cpp | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/src/citra_qt/configuration/configure_input.cpp b/src/citra_qt/configuration/configure_input.cpp index c1ce931d6d..d46ac5c1e0 100644 --- a/src/citra_qt/configuration/configure_input.cpp +++ b/src/citra_qt/configuration/configure_input.cpp @@ -350,6 +350,17 @@ QList ConfigureInput::GetUsedKeyboardKeys() { list << QKeySequence(button_param.Get("code", 0)); } } + + for (int analog_id = 0; analog_id < Settings::NativeAnalog::NumAnalogs; analog_id++) { + auto analog_param = analogs_param[analog_id]; + if (analog_param.Get("engine", "") == "analog_from_button") { + for (int sub_button_id = 0; sub_button_id < ANALOG_SUB_BUTTONS_NUM; sub_button_id++) { + auto sub_button = Common::ParamPackage{analog_param.Get(analog_sub_buttons[sub_button_id], "")}; + list << QKeySequence(sub_button.Get("code", 0)); + } + } + } + return list; }