summaryrefslogtreecommitdiff
path: root/Source/Core/InputCommon/ControllerEmu.cpp
diff options
context:
space:
mode:
authorLioncash <mathew1800@gmail.com>2014-08-15 13:03:56 -0400
committerLioncash <mathew1800@gmail.com>2014-08-15 13:06:56 -0400
commit7fd5e4300a65b09ba496960746d5e76ffc802035 (patch)
tree1d508719092f02b73b7eef7350d1d40a5f7f9fb4 /Source/Core/InputCommon/ControllerEmu.cpp
parentd5d5580424d92c56f8f3d964e1437c744737c67d (diff)
InputCommon: Don't base default radius of analog sticks off of their name.
Diffstat (limited to 'Source/Core/InputCommon/ControllerEmu.cpp')
-rw-r--r--Source/Core/InputCommon/ControllerEmu.cpp10
1 files changed, 3 insertions, 7 deletions
diff --git a/Source/Core/InputCommon/ControllerEmu.cpp b/Source/Core/InputCommon/ControllerEmu.cpp
index e5822a0e9e..87378f86e0 100644
--- a/Source/Core/InputCommon/ControllerEmu.cpp
+++ b/Source/Core/InputCommon/ControllerEmu.cpp
@@ -137,18 +137,14 @@ void ControllerEmu::SaveConfig(IniFile::Section *sec, const std::string& base)
ctrlGroup->SaveConfig(sec, defdev, base);
}
-ControllerEmu::AnalogStick::AnalogStick(const char* const _name) : ControlGroup(_name, GROUP_TYPE_STICK)
+ControllerEmu::AnalogStick::AnalogStick(const char* const _name, ControlState default_radius)
+ : ControlGroup(_name, GROUP_TYPE_STICK)
{
for (auto& named_direction : named_directions)
controls.emplace_back(new Input(named_direction));
controls.emplace_back(new Input(_trans("Modifier")));
-
- // Default to 100 radius for everything but gcpad.
- if (name == "Stick" || name == "Left Stick" || name == "Right Stick")
- settings.emplace_back(new Setting(_trans("Radius"), 1.0f, 0, 100));
- else
- settings.emplace_back(new Setting(_trans("Radius"), 0.7f, 0, 100));
+ settings.emplace_back(new Setting(_trans("Radius"), default_radius, 0, 100));
settings.emplace_back(new Setting(_trans("Dead Zone"), 0, 0, 50));
}