diff options
author | cpasjuste <cpasjuste@gmail.com> | 2020-04-24 09:59:06 +0200 |
---|---|---|
committer | cpasjuste <cpasjuste@gmail.com> | 2020-04-24 09:59:06 +0200 |
commit | fb95def24c42392fe79b6ab672b5a6edc7210195 (patch) | |
tree | 4802156f54de4e30418b984578b91d22d837d5de /src | |
parent | e124615493f4f84d372a99ea604220a8e850dde1 (diff) | |
download | mv-fb95def24c42392fe79b6ab672b5a6edc7210195.tar.gz mv-fb95def24c42392fe79b6ab672b5a6edc7210195.tar.bz2 mv-fb95def24c42392fe79b6ab672b5a6edc7210195.tar.xz mv-fb95def24c42392fe79b6ab672b5a6edc7210195.zip |
switch: fix joystick directions
Diffstat (limited to 'src')
-rw-r--r-- | src/defaults.cpp | 2 | ||||
-rw-r--r-- | src/input/joystick.cpp | 11 |
2 files changed, 5 insertions, 8 deletions
diff --git a/src/defaults.cpp b/src/defaults.cpp index b566c3206..3ece72195 100644 --- a/src/defaults.cpp +++ b/src/defaults.cpp @@ -185,7 +185,7 @@ void setConfigDefaults(Configuration &cfg) AddDEF("useScreenshotDirectorySuffix", true); AddDEF("screenshotDirectorySuffix", ""); #ifdef __SWITCH__ - AddDEF("joystickEnabled", false); + AddDEF("joystickEnabled", true); #else AddDEF("joystickEnabled", false); #endif diff --git a/src/input/joystick.cpp b/src/input/joystick.cpp index 814affa46..7b2eb7d7b 100644 --- a/src/input/joystick.cpp +++ b/src/input/joystick.cpp @@ -178,14 +178,11 @@ bool Joystick::open() mButtonsNumber = MAX_BUTTONS; #ifdef __SWITCH__ - /* config.setValue("joystick" + toString(mNumber) + "calibrated", true); - config.setValue("leftTolerance" + toString(mNumber), 1000); - config.setValue("rightTolerance" + toString(mNumber), 1000); - config.setValue("upTolerance" + toString(mNumber), 1000); - config.setValue("downTolerance" + toString(mNumber), 1000); - //config.setValue("useInactiveJoystick", true); - */ + config.setValue("leftTolerance" + toString(mNumber), -10000); + config.setValue("rightTolerance" + toString(mNumber), 10000); + config.setValue("upTolerance" + toString(mNumber), -10000); + config.setValue("downTolerance" + toString(mNumber), 10000); #endif mCalibrated = config.getValueBool("joystick" + toString(mNumber) + "calibrated", false); |