Full-screen application switching problem

I have a full-screen SDL application running on Windows 95, compiled with
MSVC++ 6 and linked with SDL 1.1.3. I do not want a mouse cursor within my
application, so I call SDL_ShowCursor(0). The problem is that when I switch
to another application (either by pressing alt-tab or by spawning the new
application), the mouse cursor does not reappear. Is this a bug, or correct
behavior? In either case, how do I fix it?–
Rainer Deyke (root at rainerdeyke.com)
Shareware action/role-playing games - http://rainerdeyke.com
"In ihren Reihen zu stehen heisst unter Feinden zu kaempfen" - Abigor

“Rainer Deyke” wrote in message
news:8kqj95$nos$1 at ftp.lokigames.com

I have a full-screen SDL application running on Windows 95, compiled with
MSVC++ 6 and linked with SDL 1.1.3. I do not want a mouse cursor within
my
application, so I call SDL_ShowCursor(0). The problem is that when I
switch
to another application (either by pressing alt-tab or by spawning the new
application), the mouse cursor does not reappear. Is this a bug, or
correct
behavior? In either case, how do I fix it?

Update: There are two different problems here: pressing alt-tab leaves the
mouse temporarily invisible. Spawning a new process (through ShellExecute)
leaves a visible mouse cursor on the screen, BUT I CANNOT MOVE THE CURSOR
BY MOVING MY MOUSE
. I tried catching the SDL_ACTIVEEVENT event and calling
SDL_ShowCursor(1) upon losing mouse focus and SDL_ShowCursor(0) upon
regaining it - no effect.–
Rainer Deyke (root at rainerdeyke.com)
Shareware action/role-playing games - http://rainerdeyke.com
"In ihren Reihen zu stehen heisst unter Feinden zu kaempfen" - Abigor

Update: There are two different problems here: pressing alt-tab leaves the
mouse temporarily invisible. Spawning a new process (through ShellExecute)
leaves a visible mouse cursor on the screen, BUT I CANNOT MOVE THE CURSOR
BY MOVING MY MOUSE
.

That’s pretty wierd. :slight_smile:

I tried catching the SDL_ACTIVEEVENT event and calling
SDL_ShowCursor(1) upon losing mouse focus and SDL_ShowCursor(0) upon
regaining it - no effect.

How about when you gain and lose application focus? Keyboard focus?

See ya,
-Sam Lantinga, Lead Programmer, Loki Entertainment Software

I have a full-screen SDL application running on Windows 95, compiled with
MSVC++ 6 and linked with SDL 1.1.3. I do not want a mouse cursor within my
application, so I call SDL_ShowCursor(0). The problem is that when I switch
to another application (either by pressing alt-tab or by spawning the new
application), the mouse cursor does not reappear. Is this a bug, or correct
behavior? In either case, how do I fix it?

I wasn’t able to reproduce this here. Are you grabbing the input as well?
Can you send a simple test case to @slouken? If possible send it
today, since I’m working on Win32 SDL today.

Thanks!
-Sam Lantinga, Lead Programmer, Loki Entertainment Software

“Sam Lantinga” wrote in message
news:E13DgpY-0000ot-00 at roboto.devolution.com

Update: There are two different problems here: pressing alt-tab leaves
the

mouse temporarily invisible. Spawning a new process (through
ShellExecute)

leaves a visible mouse cursor on the screen, *BUT I CANNOT MOVE THE
CURSOR

BY MOVING MY MOUSE*.

That’s pretty wierd. :slight_smile:

I tried catching the SDL_ACTIVEEVENT event and calling
SDL_ShowCursor(1) upon losing mouse focus and SDL_ShowCursor(0) upon
regaining it - no effect.

How about when you gain and lose application focus? Keyboard focus?

No effect.–
Rainer Deyke (root at rainerdeyke.com)
Shareware action/role-playing games - http://rainerdeyke.com
"In ihren Reihen zu stehen heisst unter Feinden zu kaempfen" - Abigor