src/video/SDL_video.c
changeset 10690 23a825f341e6
parent 10650 b6ec7005ca15
child 10698 044ef09cda20
equal deleted inserted replaced
10689:69d6c1c7a2bf 10690:23a825f341e6
  3380     } else {
  3380     } else {
  3381         return 0;
  3381         return 0;
  3382     }
  3382     }
  3383 }
  3383 }
  3384 
  3384 
  3385 void
  3385 int
  3386 SDL_GL_SwapWindow(SDL_Window * window)
  3386 SDL_GL_SwapWindow(SDL_Window * window)
  3387 {
  3387 {
  3388     CHECK_WINDOW_MAGIC(window,);
  3388     CHECK_WINDOW_MAGIC(window,-1);
  3389 
  3389 
  3390     if (!(window->flags & SDL_WINDOW_OPENGL)) {
  3390     if (!(window->flags & SDL_WINDOW_OPENGL)) {
  3391         SDL_SetError("The specified window isn't an OpenGL window");
  3391         return SDL_SetError("The specified window isn't an OpenGL window");
  3392         return;
       
  3393     }
  3392     }
  3394 
  3393 
  3395     if (SDL_GL_GetCurrentWindow() != window) {
  3394     if (SDL_GL_GetCurrentWindow() != window) {
  3396         SDL_SetError("The specified window has not been made current");
  3395         return SDL_SetError("The specified window has not been made current");
  3397         return;
  3396     }
  3398     }
  3397 
  3399 
  3398     return _this->GL_SwapWindow(_this, window);
  3400     _this->GL_SwapWindow(_this, window);
       
  3401 }
  3399 }
  3402 
  3400 
  3403 void
  3401 void
  3404 SDL_GL_DeleteContext(SDL_GLContext context)
  3402 SDL_GL_DeleteContext(SDL_GLContext context)
  3405 {
  3403 {