Commit Graph

2511 Commits

Author SHA1 Message Date
Sam Lantinga
f96c870b57 Fixed bugs 1034 and 1035
zicodxx@gmx.de 2010-07-28 12:59:27 PDT
Again another bug I encountered on Windows 7:

Assuming I hide my mouse cusor with SDL_ShowCursor(SDL_DISABLE).
Now if my app runs on Fullscreen, I tend to "get out" of it using ALT+TAB. This
will minimize the app. However SDL_GetAppState will STILL report SDL_APPACTIVE,
SDL_APPINPUTFOCUS and SDL_APPMOUSEFOCUS.

Also if I check event.active.gain, this *seems* (as much as I could find out)
to be set twice (first 0 then 1 again) while going out of the app with ALT+TAB.
I am not perfectly sure here but even if the app is minimized because of
ALT+TAB (or also CTRL+ESC), event.active.gain is 1.

Alex Volkov 2011-04-28 17:19:26 PDT
This happens with the windib driver. Windows posts the WM_ACTIVATE WA_INACTIVE
event with minimized==false when you Alt+Tab out of a fullscreen app.
Responding to this event, wincommon/SDL_sysevents.c:WinMessage() calls
ShowWindow(,SW_MINIMIZE) via SDL_RestoreDesktopMode, but another WM_ACTIVATE
event is not posted in response to that.
Whatever the case may be, WinMessage() should just treat a fullscreen app
receiving WA_INACTIVE the same as a minimized app. Additionally, it's probably
a good idea to clear SDL_APPMOUSEFOCUS at the same time, and that should take
care of bug #1035.

--HG--
branch : SDL-1.2
2011-12-29 04:29:53 -05:00
Sam Lantinga
9cda593e52 Fixed bug 1032
Matthias Hawran 2010-07-28 03:00:49 PDT
Hi,

I simply want to "forward" this post
(http://forums.libsdl.org/viewtopic.php?t=4123) about absolute mouse events not
being monitored by SDL 1.2 as directfb / tslib generates them.

It's fixed in 1.3 and IMHO it should be backported to 1.2

Included the patch from the post (thanks to Guillaume Chereau)

Cheers,
Matthias

--HG--
branch : SDL-1.2
2011-12-29 04:24:15 -05:00
Sam Lantinga
8217f39758 Hi Sam
In X11_CreateYUVOverlay hwdata->image will be accessed after it has been
freed, causing undefined behavior. Exchanging two lines as shown in this
patch will fix that problem:

Regards, Bodo

--HG--
branch : SDL-1.2
2011-12-02 18:35:04 -05:00
Ryan C. Gordon
d7251c0f4f Quartz: When warping the mouse, update the APPMOUSEFOCUS state.
Fixes cursor being visible in middle of window until the next mousemove event,
 when it has just been grabbed+hidden.

--HG--
branch : SDL-1.2
2011-11-17 03:12:34 -05:00
Ryan C. Gordon
81db8b96df Removed unused static functions.
--HG--
branch : SDL-1.2
2011-11-16 21:13:39 -05:00
Ryan C. Gordon
da55cd8cea Fixed type-punning issue (casting to char* makes GCC strict-aliasing happy).
--HG--
branch : SDL-1.2
2011-11-16 21:12:47 -05:00
Ryan C. Gordon
aba1b745a4 Fix strict-aliasing issue in X11 dynamic loader.
Fixes dozens of compiler warnings on FreeBSD.

--HG--
branch : SDL-1.2
2011-11-16 21:10:03 -05:00
Ryan C. Gordon
66dea2f893 Patched to compile on FreeBSD (1.2 branch).
--HG--
branch : SDL-1.2
2011-11-16 05:20:17 -05:00
Ryan C. Gordon
74ab222f0c Windows: If we don't care about OpenGL accel and FULL fails, try NO accel.
--HG--
branch : SDL-1.2
2011-11-07 16:01:03 -05:00
Ryan C. Gordon
3c1419ba11 Mac OS X: Try to save the GL context between fullscreen/windowed toggles.
--HG--
branch : SDL-1.2
2011-11-06 16:51:51 -05:00
Ryan C. Gordon
d46111b5d0 Always do either FULL or NO acceleration for Windows OpenGL.
Don't ever leave it to the OS to decide, because older ATI drivers apparently
 break in this case, and generally apps want FULL by default anyhow.

--HG--
branch : SDL-1.2
2011-11-06 16:34:32 -05:00
Ryan C. Gordon
2f9d939235 Mac OS X: Try to save the GL context when toggling windowed and fullscreen.
--HG--
branch : SDL-1.2
2011-11-04 17:44:17 -04:00
Ryan C. Gordon
fb93817782 Stop a compiler warning on newer Mac OS X SDKs.
--HG--
branch : SDL-1.2
2011-11-04 17:42:54 -04:00
Ryan C. Gordon
d9fc5c6572 Mac OS X: Try to resize--without destroying--the GL context in SetVideoMode.
--HG--
branch : SDL-1.2
2011-11-04 00:58:24 -04:00
Ryan C. Gordon
8b97dbc771 Fix compiler warning on Mac OS X, when targeting old OS with new SDK.
--HG--
branch : SDL-1.2
2011-11-04 00:56:11 -04:00
Ryan C. Gordon
b25ce86137 Fixed a compiler warning when building with Mac OS X target < 10.7.
--HG--
branch : SDL-1.2
2011-11-03 23:58:24 -04:00
Ryan C. Gordon
8d0b0150b4 Fixed buffer overflow in joystick cleanup. (valgrind ftw!)
--HG--
branch : SDL-1.2
2011-11-03 12:42:23 -04:00
Ryan C. Gordon
393309d210 Fixed a bunch more compiler warnings in the 1.2 branch.
--HG--
branch : SDL-1.2
2011-10-13 16:38:05 -04:00
Ryan C. Gordon
1df4cde7fb Don't warn about multichar characters on BeOS/Haiku.
The system headers use them generously.

--HG--
branch : SDL-1.2
2011-10-13 16:35:25 -04:00
Ryan C. Gordon
a7a476588d Quartz: Only use ShowMenuBar()/HideMenuBar() for legacy OS releases.
--HG--
branch : SDL-1.2
2011-10-13 14:50:47 -04:00
Ryan C. Gordon
bd5b06d050 Cleaned up more compiler warnings in the 1.2 branch.
--HG--
branch : SDL-1.2
2011-10-13 12:29:03 -04:00
Ryan C. Gordon
c04621f934 Fixed unused variable compiler warnings on Mac OS X.
--HG--
branch : SDL-1.2
2011-10-13 12:19:30 -04:00
Ryan C. Gordon
0e3c197de0 Don't bother with Win9x compatibility when building 64-bit binaries.
Fixes Bugzilla #1310.

Thanks to Ozkan Sezer for the patch!

--HG--
branch : SDL-1.2
2011-10-13 01:49:14 -04:00
Ryan C. Gordon
2eb0211190 Enable -Wall by default.
Fixes Bugzilla #1284.

(But probably upsets buildbot.  :)  )
(transplanted from 516c5c4e7beabd27608c67cab5b0259643a9083c)

--HG--
branch : SDL-1.2
2011-10-11 22:04:51 -04:00
Ryan C. Gordon
3ccf66ffe6 Cleaned up fatbuild.sh
--HG--
branch : SDL-1.2
2011-09-19 01:46:55 -04:00
Ryan C. Gordon
bf17281c03 Better test for actual Mac OS X SDK in use.
--HG--
branch : SDL-1.2
2011-09-18 02:43:59 -04:00
Ryan C. Gordon
85814cd2bc I _think_ this fixes the Xcode projects.
--HG--
branch : SDL-1.2
2011-09-18 02:38:12 -04:00
Ryan C. Gordon
ad2f5f3539 Fixed building with a newer Mac OS X SDK and -mmacosx-version-min=10.4.
--HG--
branch : SDL-1.2
2011-09-18 02:00:39 -04:00
Ryan C. Gordon
ffe59e1228 Fixed fullscreen OpenGL on Lion when built with the Mac OS X 10.4u SDK.
--HG--
branch : SDL-1.2
2011-09-16 01:55:46 -04:00
Ryan C. Gordon
b78a10812b Make SDL-1.2 Quartz target to work on Lion when built with the 10.4u SDK.
sigh.

--HG--
branch : SDL-1.2
2011-09-16 01:37:44 -04:00
Ryan C. Gordon
6555c1f7fa Make build-scripts/fatbuild.sh sane for x86-64.
No one targets 10.5 or uses gcc 4.0 with x86-64 Mac OS X.

--HG--
branch : SDL-1.2
2011-09-16 00:46:59 -04:00
Ryan C. Gordon
f2c89a2569 Allow testalpha.c to toggle windowed/fullscreen mode.
This is to help track down bugs in the updated Mac OS X video target.

--HG--
branch : SDL-1.2
2011-09-16 00:11:23 -04:00
Ryan C. Gordon
5b2605cc5f Fixed Quartz UpdateRects failing to draw after a second SDL_SetVideoMode().
--HG--
branch : SDL-1.2
2011-09-15 20:59:57 -04:00
Ryan C. Gordon
9219efef59 Try to include more Lion-specific code, even when building with the 10.4u SDK.
--HG--
branch : SDL-1.2
2011-09-14 13:35:10 -04:00
Ryan C. Gordon
1edae6afeb Mac OS X deprecation cleanup: maybe this SDK test is better...?
--HG--
branch : SDL-1.2
2011-09-14 03:23:35 -04:00
Ryan C. Gordon
e286041a2f Attempt to quiet unavoidable compiler warnings on Mac OS X.
--HG--
branch : SDL-1.2
2011-09-14 03:12:48 -04:00
Ryan C. Gordon
6b26d7ee68 Restored the older Quartz video target code.
The new code happened to (supposedly) work everywhere, but it is way slower
 on older Mac OS X releases that could get away with using the now
 deprecated/removed APIs, so now both implementations are available, and SDL
 should choose the right path based on compile options and OS version at
 runtime.

Fun stuff.

--HG--
branch : SDL-1.2
2011-09-13 20:30:48 -04:00
Ryan C. Gordon
c572dcb8a4 Fixed compiler warnings on Haiku.
--HG--
branch : SDL-1.2
2011-09-13 15:19:28 +00:00
Ryan C. Gordon
83545b9395 Turned off the rest of the MMX code in SDL_blit_A.c.
It also seems to blow up everywhere.

Fixes Bugzilla #1278.

--HG--
branch : SDL-1.2
2011-09-13 14:42:58 -04:00
Ryan C. Gordon
8ccce1fbf5 Removed executable bit from VisualC files.
--HG--
branch : SDL-1.2
2011-09-12 00:29:18 -04:00
Ryan C. Gordon
4b4ee808ff Maybe this will fix the Cygwin compile warning...argh.
--HG--
branch : SDL-1.2
2011-09-11 23:34:33 -04:00
Ryan C. Gordon
4eca3de99f Maybe THIS will fix the Cygwin warnings...
--HG--
branch : SDL-1.2
2011-09-11 23:01:03 -04:00
Ryan C. Gordon
84c071b444 Sigh, fixed typo.
--HG--
branch : SDL-1.2
2011-09-11 22:38:45 -04:00
Ryan C. Gordon
a122a400c5 More Cygwin compiler warnings...
--HG--
branch : SDL-1.2
2011-09-11 22:31:53 -04:00
Ryan C. Gordon
75a74696c4 Still fighting with calling conventions in Cygwin/MingW/VisualC...
--HG--
branch : SDL-1.2
2011-09-11 15:24:44 -04:00
Ryan C. Gordon
a88ed755d0 Unpacked Xcode.tar.gz.
--HG--
branch : SDL-1.2
2011-09-11 14:44:37 -04:00
Ryan C. Gordon
9f35990896 Unpacked VisualCE.zip.
--HG--
branch : SDL-1.2
2011-09-11 14:43:21 -04:00
Ryan C. Gordon
679a09473f Unpacked VisualC.zip.
--HG--
branch : SDL-1.2
2011-09-11 13:29:23 -04:00
Ryan C. Gordon
2132f9c034 Another shot at fixing the compiler warnings under Cygwin/MingW.
--HG--
branch : SDL-1.2
2011-09-11 13:23:36 -04:00
Ryan C. Gordon
2d2e1e9928 Patched to compile on Windows.
--HG--
branch : SDL-1.2
2011-09-11 10:48:36 -04:00