From f5f3afbeef54b2174622b9dd8274101538ad532c Mon Sep 17 00:00:00 2001 From: "Unknown W. Brackets" Date: Sun, 11 Jun 2023 15:43:21 -0700 Subject: [PATCH] Android: Correct pad name tracking. This is split up in two messages, a bit ugly... --- UI/NativeApp.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/UI/NativeApp.cpp b/UI/NativeApp.cpp index f5f6b0e508..322c9c55d4 100644 --- a/UI/NativeApp.cpp +++ b/UI/NativeApp.cpp @@ -1147,7 +1147,8 @@ void NativeRender(GraphicsContext *graphicsContext) { } void HandleGlobalMessage(const std::string &msg, const std::string &value) { - InputDeviceID nextInputDeviceID = DEVICE_ID_ANY; + // A bit ugly, see InputDeviceState.java. + static InputDeviceID nextInputDeviceID = DEVICE_ID_ANY; if (msg == "inputDeviceConnectedID") { nextInputDeviceID = (InputDeviceID)parseLong(value); }