src/video/x11/SDL_x11modes.c
changeset 6472 d4623b7209db
parent 6468 6af2a8db95d0
child 6475 71d39944810b
--- a/src/video/x11/SDL_x11modes.c	Thu Sep 27 11:13:30 2012 -0700
+++ b/src/video/x11/SDL_x11modes.c	Thu Sep 27 11:29:13 2012 -0700
@@ -22,6 +22,7 @@
 
 #if SDL_VIDEO_DRIVER_X11
 
+#include "SDL_hints.h"
 #include "SDL_x11video.h"
 
 /*#define X11MODES_DEBUG*/
@@ -270,10 +271,10 @@
     *major = *minor = 0;
 
     /* Allow environment override */
-    env = getenv("SDL_VIDEO_X11_XINERAMA");
+    env = SDL_GetHint(SDL_HINT_VIDEO_X11_XINERAMA);
     if (env && !SDL_atoi(env)) {
 #ifdef X11MODES_DEBUG
-        printf("Xinerama disabled due to environment variable\n");
+        printf("Xinerama disabled due to hint\n");
 #endif
         return SDL_FALSE;
     }
@@ -311,10 +312,10 @@
     *major = *minor = 0;
 
     /* Allow environment override */
-    env = getenv("SDL_VIDEO_X11_XRANDR");
+    env = SDL_GetHint(SDL_HINT_VIDEO_X11_XRANDR);
     if (env && !SDL_atoi(env)) {
 #ifdef X11MODES_DEBUG
-        printf("XRandR disabled due to environment variable\n");
+        printf("XRandR disabled due to hint\n");
 #endif
         return SDL_FALSE;
     }
@@ -350,10 +351,10 @@
     *major = *minor = 0;
 
     /* Allow environment override */
-    env = getenv("SDL_VIDEO_X11_XVIDMODE");
+    env = SDL_GetHint(SDL_HINT_VIDEO_X11_XVIDMODE);
     if (env && !SDL_atoi(env)) {
 #ifdef X11MODES_DEBUG
-        printf("XVidMode disabled due to environment variable\n");
+        printf("XVidMode disabled due to hint\n");
 #endif
         return SDL_FALSE;
     }