summaryrefslogtreecommitdiff
path: root/Source/Core/InputCommon/ControllerEmu/ControlGroup/ControlGroup.cpp
diff options
context:
space:
mode:
authorJordan Woyak <jordan.woyak@gmail.com>2020-11-03 17:10:54 -0600
committerGitHub <noreply@github.com>2020-11-03 17:10:54 -0600
commit3cd4c56645541640f61a761dfde16464b1ef09df (patch)
treeda78e02789930be5be5addf02f4326d673ca0c09 /Source/Core/InputCommon/ControllerEmu/ControlGroup/ControlGroup.cpp
parentd2f80a45954d1c638af44b346223d4f480ce4e82 (diff)
parent55dd3d73376746c4fc46df02d8266269a6e4537e (diff)
Merge pull request #9203 from nick-michael/virtual-notches
Logic & UI for "Virtual Notches"
Diffstat (limited to 'Source/Core/InputCommon/ControllerEmu/ControlGroup/ControlGroup.cpp')
-rw-r--r--Source/Core/InputCommon/ControllerEmu/ControlGroup/ControlGroup.cpp11
1 files changed, 11 insertions, 0 deletions
diff --git a/Source/Core/InputCommon/ControllerEmu/ControlGroup/ControlGroup.cpp b/Source/Core/InputCommon/ControllerEmu/ControlGroup/ControlGroup.cpp
index 70975937c9..ee33e32f0f 100644
--- a/Source/Core/InputCommon/ControllerEmu/ControlGroup/ControlGroup.cpp
+++ b/Source/Core/InputCommon/ControllerEmu/ControlGroup/ControlGroup.cpp
@@ -28,6 +28,17 @@ ControlGroup::ControlGroup(std::string name_, std::string ui_name_, const GroupT
{
}
+void ControlGroup::AddVirtualNotchSetting(SettingValue<double>* value, double max_virtual_notch_deg)
+{
+ AddSetting(value,
+ {_trans("Virtual Notches"),
+ // i18n: The degrees symbol.
+ _trans("°"),
+ // i18n: Snap the thumbstick position to the nearest octagonal axis.
+ _trans("Snap the thumbstick position to the nearest octagonal axis.")},
+ 0, 0, max_virtual_notch_deg);
+}
+
void ControlGroup::AddDeadzoneSetting(SettingValue<double>* value, double maximum_deadzone)
{
AddSetting(value,