diff options
Diffstat (limited to '')
-rw-r--r-- | src/input_common/mouse/mouse_poller.cpp | 2 | ||||
-rw-r--r-- | src/input_common/sdl/sdl_impl.cpp | 4 | ||||
-rw-r--r-- | src/input_common/sdl/sdl_impl.h | 8 |
3 files changed, 3 insertions, 11 deletions
diff --git a/src/input_common/mouse/mouse_poller.cpp b/src/input_common/mouse/mouse_poller.cpp index 45b3d7340..efcdd85d2 100644 --- a/src/input_common/mouse/mouse_poller.cpp +++ b/src/input_common/mouse/mouse_poller.cpp @@ -84,7 +84,7 @@ public: std::lock_guard lock{mutex}; const auto axis_value = static_cast<float>(mouse_input->GetMouseState(button).axis.at(axis)); - const float sensitivity = Settings::values.mouse_panning_sensitivity.GetValue(); + const float sensitivity = Settings::values.mouse_panning_sensitivity.GetValue() * 0.10f; return axis_value * sensitivity / (100.0f * range); } diff --git a/src/input_common/sdl/sdl_impl.cpp b/src/input_common/sdl/sdl_impl.cpp index a49d93f01..7778b3562 100644 --- a/src/input_common/sdl/sdl_impl.cpp +++ b/src/input_common/sdl/sdl_impl.cpp @@ -165,10 +165,10 @@ public: if (sdl_controller) { return SDL_GameControllerRumble(sdl_controller.get(), amp_low, amp_high, - rumble_max_duration_ms) == 0; + rumble_max_duration_ms) != -1; } else if (sdl_joystick) { return SDL_JoystickRumble(sdl_joystick.get(), amp_low, amp_high, - rumble_max_duration_ms) == 0; + rumble_max_duration_ms) != -1; } return false; diff --git a/src/input_common/sdl/sdl_impl.h b/src/input_common/sdl/sdl_impl.h index b77afcbd8..7a9ad6346 100644 --- a/src/input_common/sdl/sdl_impl.h +++ b/src/input_common/sdl/sdl_impl.h @@ -10,15 +10,7 @@ #include <thread> #include <unordered_map> -// Ignore -Wimplicit-fallthrough due to https://github.com/libsdl-org/SDL/issues/4307 -#ifdef __GNUC__ -#pragma GCC diagnostic push -#pragma GCC diagnostic ignored "-Wimplicit-fallthrough" -#endif #include <SDL.h> -#ifdef __GNUC__ -#pragma GCC diagnostic pop -#endif #include "common/common_types.h" #include "common/threadsafe_queue.h" |