From cc304b8b5e2820f8813ead4923d4b31a73a0439f Mon Sep 17 00:00:00 2001 From: Pere Pujal i Carabantes Date: Wed, 29 Oct 2025 23:43:42 +0100 Subject: [PATCH] Adding back changes for Android by Terrence. --- src/i18n.c | 1 + src/tuxpaint.c | 5 +++-- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/src/i18n.c b/src/i18n.c index f78311739..e38d102d5 100644 --- a/src/i18n.c +++ b/src/i18n.c @@ -52,6 +52,7 @@ #ifdef __ANDROID__ #include "SDL2/SDL.h" +#include "../../../SDL2/src/core/android/SDL_android.h" #include "jni.h" // since setlocale on the Android is not supported well, // setlocale cannot get current default locale of the device. diff --git a/src/tuxpaint.c b/src/tuxpaint.c index ddd5922a6..237b2dc53 100644 --- a/src/tuxpaint.c +++ b/src/tuxpaint.c @@ -358,6 +358,7 @@ extern status_t haiku_trash(const char *f); #define AUTOSAVE_GOING_BACKGROUND #include "android_print.h" #include "android_assets.h" +#include "SDL_mouse_c.h" int entered_background = 0; #else @@ -31869,7 +31870,7 @@ static void convert_motion_to_wheel(SDL_Event event) { while (motion_dy - high > 0) { - SDL_SendMouseWheel(NULL, event.motion.which, 0, 1); + SDL_SendMouseWheel(NULL, event.motion.which, 0.0f, 1.0f, SDL_MOUSEWHEEL_NORMAL); motion_dy -= high; } } @@ -31877,7 +31878,7 @@ static void convert_motion_to_wheel(SDL_Event event) { while (motion_dy + high < 0) { - SDL_SendMouseWheel(NULL, event.motion.which, 0, -1); + SDL_SendMouseWheel(NULL, event.motion.which, 0.0f, -1.0f, SDL_MOUSEWHEEL_NORMAL); motion_dy += high; } }