[SDL] Re: Problem with SDL window (cant click-n-drag it!)

Olivier Fabre off at free.fr.ARGL.invalid
Thu Dec 2 11:36:55 PST 2004


'lo Jonathan,

On 02/12/2004, Jonathan Atkins, you wrote:

> can you try commenting out the (SDL_QuitSubSystem(SDL_INIT_VIDEO)
> and the SDL_InitSubSystem(SDL_INIT_VIDEO)?

> just do the SDL_SetVideoMode() to change to a new mode...

Ok, I tried this. Several changes:

- When switching from fullscreen to windowed, the window IS shown.

But:

- When I switch to fullscreen, the display is blinking like if one
buffer contained my game and the other one Windows' desktop. (this also
happens when I alt-tab from fullscreen and back)

- I have noticed once, after a few switches, the "can't click the
dragbar" bug. (the mouse pointer only appears outside of the window
frame, not when it is on top of it - note that I'm using
SDL_ShowCursor(0), if that matters.)

- I then also noticed a bug where the mouse pointer was constrained
inside the window. I am using SDL_WM_GrabInput(), but only when the RMB
is pressed, and this bug never happened with SDL 1.2.6 AFAIR.

This is in my input handling function (called every frame):

mouseButtons = SDL_GetRelativeMouseState( (int*)&g_MouseDeltaX,
(int*)&g_MouseDeltaY );
if( mouseButtons & SDL_BUTTON_RMASK )
    SDL_WM_GrabInput( SDL_GRAB_ON );
else
    SDL_WM_GrabInput( SDL_GRAB_OFF );

-- 
Please remove ".ARGL.invalid" from my email when replying.
Incoming HTML mails are automatically deleted.




More information about the SDL mailing list