src/video/SDL_video.c
changeset 6266 a4be1e781020
parent 6260 fd494c5f305b
child 6296 b42657486c0d
equal deleted inserted replaced
6265:01bf72bcad1e 6266:a4be1e781020
  1143         if (SDL_VideoInit(NULL) < 0) {
  1143         if (SDL_VideoInit(NULL) < 0) {
  1144             return NULL;
  1144             return NULL;
  1145         }
  1145         }
  1146     }
  1146     }
  1147 
  1147 
       
  1148     /* Some platforms can't create zero-sized windows */
       
  1149     if (w < 1) {
       
  1150         w = 1;
       
  1151     }
       
  1152     if (h < 1) {
       
  1153         h = 1;
       
  1154     }
       
  1155 
  1148     /* Some platforms have OpenGL enabled by default */
  1156     /* Some platforms have OpenGL enabled by default */
  1149 #if (SDL_VIDEO_OPENGL && __MACOSX__) || __IPHONEOS__ || __ANDROID__
  1157 #if (SDL_VIDEO_OPENGL && __MACOSX__) || __IPHONEOS__ || __ANDROID__
  1150     flags |= SDL_WINDOW_OPENGL;
  1158     flags |= SDL_WINDOW_OPENGL;
  1151 #endif
  1159 #endif
  1152     if (flags & SDL_WINDOW_OPENGL) {
  1160     if (flags & SDL_WINDOW_OPENGL) {