DEADSOFTWARE

sdl2: fix building with sdl2
[flatwaifu.git] / src / sdl2 / main.c
index dd5b8d43b2d16947a79291f66e1dc57d9fa9c38f..66b6680aefec37471739a81acd7bf3cd2ef250ae 100644 (file)
@@ -158,6 +158,15 @@ int Y_set_videomode (int w, int h, int flags) {
   }
 }
 
+void Y_get_videomode (int *w, int *h) {
+  if (window != NULL) {
+    SDL_GetWindowSize(window, w, h);
+  } else {
+    *w = 0;
+    *h = 0;
+  }
+}
+
 int Y_videomode_setted (void) {
   return window != NULL;
 }
@@ -178,11 +187,10 @@ void Y_unset_videomode (void) {
   }
 }
 
-int Y_set_fullscreen (int yes) {
+void Y_set_fullscreen (int yes) {
   if (window != NULL) {
     SDL_SetWindowFullscreen(window, yes ? SDL_WINDOW_FULLSCREEN : 0);
   }
-  return yes;
 }
 
 int Y_get_fullscreen (void) {