Rockbox open source high quality audio player as a Music Player Daemon
mpris rockbox mpd libadwaita audio rust zig deno
2
fork

Configure Feed

Select the types of activity you want to include in your feed.

sdl: Explicitly disable the cursor for non-touchscreen devices

...Except for simulators, those always need the cursor

In practice this only affects the RG Nano as it is currently our
only SDL target that lacks a touchscreen.

Change-Id: I292f923848528c233da518b062d9ccd8a03515dd

+8 -7
+8 -7
firmware/target/hosted/sdl/system-sdl.c
··· 99 99 sdl_window_setup(); 100 100 #endif 101 101 102 - #if (CONFIG_PLATFORM & PLATFORM_MAEMO) 103 - SDL_sem *wait_for_maemo_startup; 104 - #endif 105 - 106 - #if (CONFIG_PLATFORM & (PLATFORM_MAEMO|PLATFORM_PANDORA)) || defined(RG_NANO) 102 + #if !defined(SIMULATOR) 103 + #if defined(HAVE_TOUCHSCREEN) 107 104 /* SDL touch screen fix: Work around a SDL assumption that returns 108 105 relative mouse coordinates when you get to the screen edges 109 106 using the touchscreen and a disabled mouse cursor. ··· 113 110 114 111 SDL_ShowCursor(SDL_ENABLE); 115 112 SDL_SetCursor(hiddenCursor); 116 - #endif 113 + #else /* !HAVE_TOUCHSCREEN */ 114 + /* Explicitly disable the cursor on non-touch targets */ 115 + SDL_ShowCursor(SDL_DISABLE); 116 + #endif /* !HAVE_TOUCHSCREEN */ 117 + #endif /* !SIMULATOR */ 117 118 118 119 #if (CONFIG_PLATFORM & PLATFORM_MAEMO) 119 120 /* start maemo thread: Listen to display on/off events and battery monitoring */ 120 - wait_for_maemo_startup = SDL_CreateSemaphore(0); /* 0-count so it blocks */ 121 + SDL_sem *wait_for_maemo_startup = SDL_CreateSemaphore(0); /* 0-count so it blocks */ 121 122 SDL_Thread *maemo_thread = SDL_CreateThread(maemo_thread_func, NULL, wait_for_maemo_startup); 122 123 SDL_SemWait(wait_for_maemo_startup); 123 124 SDL_DestroySemaphore(wait_for_maemo_startup);