changed "http" to "https" in URLs
[rocksndiamonds.git] / src / libgame / sdl.c
index 41af967e18a1e583c3212c3877ba1e503a458d30..990054de955f965cab82e6c66936b1aaf63ac17f 100644 (file)
@@ -4,7 +4,7 @@
 // (c) 1995-2014 by Artsoft Entertainment
 //                         Holger Schemel
 //                 info@artsoft.org
-//                 http://www.artsoft.org/
+//                 https://www.artsoft.org/
 // ----------------------------------------------------------------------------
 // sdl.c
 // ============================================================================
@@ -330,6 +330,15 @@ static void SDLSetAlpha(SDL_Surface *surface, boolean set, int alpha)
   SDL_SetSurfaceAlphaMod(surface, alpha);
 }
 
+const char *SDLGetRendererName(void)
+{
+  static SDL_RendererInfo renderer_info;
+
+  SDL_GetRendererInfo(sdl_renderer, &renderer_info);
+
+  return renderer_info.name;
+}
+
 SDL_Surface *SDLGetNativeSurface(SDL_Surface *surface)
 {
   SDL_PixelFormat format;
@@ -2557,6 +2566,9 @@ static void setJoystickButton(int nr, int button_id_raw, int button_state)
 
 void HandleJoystickEvent(Event *event)
 {
+  // when using joystick, disable overlay touch buttons
+  runtime.uses_touch_device = FALSE;
+
   switch (event->type)
   {
     case SDL_CONTROLLERDEVICEADDED: