changeset 4978:4a7f284a82b2

You can't change the resolution on some devices
author Sam Lantinga <slouken@libsdl.org>
date Wed, 12 Jan 2011 13:46:37 -0800
parents 85969cc5098c
children be4ba07d9867
files src/video/SDL_video.c
diffstat 1 files changed, 4 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/src/video/SDL_video.c	Wed Jan 12 13:38:10 2011 -0800
+++ b/src/video/SDL_video.c	Wed Jan 12 13:46:37 2011 -0800
@@ -694,6 +694,10 @@
     }
 
     /* Actually change the display mode */
+    if (!_this->SetDisplayMode) {
+        SDL_SetError("Video driver doesn't support changing display mode");
+        return -1;
+    }
     if (_this->SetDisplayMode(_this, display, &display_mode) < 0) {
         return -1;
     }