aboutsummaryrefslogtreecommitdiff
path: root/src/yuzu/configuration/configure_input_advanced.cpp
diff options
context:
space:
mode:
authorNarr the Reg <juangerman-13@hotmail.com>2023-11-04 14:05:05 -0600
committerNarr the Reg <juangerman-13@hotmail.com>2023-11-04 14:13:18 -0600
commitf07484bc64e6c6f178f4891f1c86ebb23d14dbe7 (patch)
tree70028c9f4a1c3a0a62a873892b023489f56f9eff /src/yuzu/configuration/configure_input_advanced.cpp
parent940618a64dc048790291e240dca6a085a4f1c27c (diff)
core: hid: Signal color updates
Diffstat (limited to 'src/yuzu/configuration/configure_input_advanced.cpp')
-rw-r--r--src/yuzu/configuration/configure_input_advanced.cpp8
1 files changed, 6 insertions, 2 deletions
diff --git a/src/yuzu/configuration/configure_input_advanced.cpp b/src/yuzu/configuration/configure_input_advanced.cpp
index 3cfd5d4394..441cea3f6a 100644
--- a/src/yuzu/configuration/configure_input_advanced.cpp
+++ b/src/yuzu/configuration/configure_input_advanced.cpp
@@ -4,11 +4,13 @@
#include <QColorDialog>
#include "common/settings.h"
#include "core/core.h"
+#include "core/hid/emulated_controller.h"
+#include "core/hid/hid_core.h"
#include "ui_configure_input_advanced.h"
#include "yuzu/configuration/configure_input_advanced.h"
-ConfigureInputAdvanced::ConfigureInputAdvanced(QWidget* parent)
- : QWidget(parent), ui(std::make_unique<Ui::ConfigureInputAdvanced>()) {
+ConfigureInputAdvanced::ConfigureInputAdvanced(Core::HID::HIDCore& hid_core_, QWidget* parent)
+ : QWidget(parent), ui(std::make_unique<Ui::ConfigureInputAdvanced>()), hid_core{hid_core_} {
ui->setupUi(this);
controllers_color_buttons = {{
@@ -123,6 +125,8 @@ void ConfigureInputAdvanced::ApplyConfiguration() {
player.button_color_left = colors[1];
player.body_color_right = colors[2];
player.button_color_right = colors[3];
+
+ hid_core.GetEmulatedControllerByIndex(player_idx)->ReloadColorsFromSettings();
}
Settings::values.debug_pad_enabled = ui->debug_enabled->isChecked();