summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorbunnei <bunneidev@gmail.com>2021-04-14 06:53:34 +0200
committerGitHub <noreply@github.com>2021-04-14 06:53:34 +0200
commit62a8505345122ff03c9311a13c40863d9b4f743f (patch)
treec4274086589a2bed1d0873deaa997a14b3b710f3 /src
parentMerge pull request #6185 from ameerj/process-reslimit (diff)
parentapplets/controller: Hook up the "Motion" button functionality (diff)
downloadyuzu-62a8505345122ff03c9311a13c40863d9b4f743f.tar
yuzu-62a8505345122ff03c9311a13c40863d9b4f743f.tar.gz
yuzu-62a8505345122ff03c9311a13c40863d9b4f743f.tar.bz2
yuzu-62a8505345122ff03c9311a13c40863d9b4f743f.tar.lz
yuzu-62a8505345122ff03c9311a13c40863d9b4f743f.tar.xz
yuzu-62a8505345122ff03c9311a13c40863d9b4f743f.tar.zst
yuzu-62a8505345122ff03c9311a13c40863d9b4f743f.zip
Diffstat (limited to 'src')
-rw-r--r--src/yuzu/applets/controller.cpp16
-rw-r--r--src/yuzu/applets/controller.h3
2 files changed, 19 insertions, 0 deletions
diff --git a/src/yuzu/applets/controller.cpp b/src/yuzu/applets/controller.cpp
index b92cd6886..836d90fda 100644
--- a/src/yuzu/applets/controller.cpp
+++ b/src/yuzu/applets/controller.cpp
@@ -16,6 +16,7 @@
#include "yuzu/applets/controller.h"
#include "yuzu/configuration/configure_input.h"
#include "yuzu/configuration/configure_input_profile_dialog.h"
+#include "yuzu/configuration/configure_motion_touch.h"
#include "yuzu/configuration/configure_vibration.h"
#include "yuzu/configuration/input_profiles.h"
#include "yuzu/main.h"
@@ -206,6 +207,9 @@ QtControllerSelectorDialog::QtControllerSelectorDialog(
connect(ui->vibrationButton, &QPushButton::clicked, this,
&QtControllerSelectorDialog::CallConfigureVibrationDialog);
+ connect(ui->motionButton, &QPushButton::clicked, this,
+ &QtControllerSelectorDialog::CallConfigureMotionTouchDialog);
+
connect(ui->inputConfigButton, &QPushButton::clicked, this,
&QtControllerSelectorDialog::CallConfigureInputProfileDialog);
@@ -276,6 +280,18 @@ void QtControllerSelectorDialog::CallConfigureVibrationDialog() {
}
}
+void QtControllerSelectorDialog::CallConfigureMotionTouchDialog() {
+ ConfigureMotionTouch dialog(this, input_subsystem);
+
+ dialog.setWindowFlags(Qt::Dialog | Qt::CustomizeWindowHint | Qt::WindowTitleHint |
+ Qt::WindowSystemMenuHint);
+ dialog.setWindowModality(Qt::WindowModal);
+
+ if (dialog.exec() == QDialog::Accepted) {
+ dialog.ApplyConfiguration();
+ }
+}
+
void QtControllerSelectorDialog::CallConfigureInputProfileDialog() {
ConfigureInputProfileDialog dialog(this, input_subsystem, input_profiles.get());
diff --git a/src/yuzu/applets/controller.h b/src/yuzu/applets/controller.h
index 3518eed56..9b57aea1a 100644
--- a/src/yuzu/applets/controller.h
+++ b/src/yuzu/applets/controller.h
@@ -51,6 +51,9 @@ private:
// Initializes the "Configure Vibration" Dialog.
void CallConfigureVibrationDialog();
+ // Initializes the "Configure Motion / Touch" Dialog.
+ void CallConfigureMotionTouchDialog();
+
// Initializes the "Create Input Profile" Dialog.
void CallConfigureInputProfileDialog();