added pre-processor directive to set if platform has touch device
authorHolger Schemel <info@artsoft.org>
Thu, 18 Jun 2020 18:32:11 +0000 (20:32 +0200)
committerHolger Schemel <info@artsoft.org>
Thu, 18 Jun 2020 18:32:11 +0000 (20:32 +0200)
src/libgame/system.c
src/libgame/system.h

index 6dcf54967fb329fe977934382ff90a55ed10c140..af3e053607781e7e1b83ed5dfb911396584f6441 100644 (file)
@@ -117,7 +117,11 @@ void InitNetworkInfo(boolean enabled, boolean connected, boolean serveronly,
 
 void InitRuntimeInfo()
 {
+#if defined(HAS_TOUCH_DEVICE)
+  runtime.uses_touch_device = TRUE;
+#else
   runtime.uses_touch_device = FALSE;
+#endif
 }
 
 void InitScoresInfo(void)
index 29f1c28ed708df72cee6c910c26f234762b67562..221d1eefd0a2e190a554b31c313a6abed15c1b29 100644 (file)
 
 // values for special settings for mobile devices
 #if defined(PLATFORM_ANDROID)
+#define HAS_TOUCH_DEVICE
 #define USE_TOUCH_INPUT_OVERLAY
 #define USE_COMPLETE_DISPLAY
 #define HAS_SCREEN_KEYBOARD