Replace mouse control with device ID mouse check for threshold.

This commit is contained in:
LunaMoo 2019-07-15 03:47:19 +02:00
parent 3f77bb1da5
commit b87e958693

View file

@ -884,7 +884,7 @@ void EmuScreen::processAxis(const AxisInput &axis, int direction) {
KeyMap::AxisToPspButton(axis.deviceId, axis.axisId, -direction, &resultsOpposite);
int axisState = 0;
float threshold = g_Config.bMouseControl ? AXIS_BIND_THRESHOLD_MOUSE : AXIS_BIND_THRESHOLD;
float threshold = axis.deviceId == DEVICE_ID_MOUSE ? AXIS_BIND_THRESHOLD_MOUSE : AXIS_BIND_THRESHOLD;
if (direction == 1 && axis.value >= threshold) {
axisState = 1;
} else if (direction == -1 && axis.value <= -threshold) {