Marcus von Appen
Trying to build SDL 2.x (HG) on Win32 platforms with either VS.NET or MinGW requires one to have the video subsystem and SDL_VIDEO_DRIVER_WINDOWS flag enabled due to the helper window creation routines.
The attached patch changes the helper window creation behaviour, so that one can build SDL2 without the video subsystem or Windows video drivers on Win32 platforms.
Marcus von Appen
If one wants to disable the SDL render subsystem, the build breaks on several platforms due to an empty render_drivers array in SDL_render.c.
There's a limit of one update every 250ms when warping the mouse, and we
can work around that by disassociating the cursor & the mouse before
issuing our warp, then re-associating them.
This should hopefully fix bug #1612. We now send mousemotion events when
the cursor enters the window as well as when it leaves.
Thanks to Alex Szpakowski for the fix.
Fixes http://bugzilla.libsdl.org/show_bug.cgi?id=1612
makeKeyAndOrderFront: was sending three KVO transitions for isVisible,
for false -> true, true -> false, and then false -> true. This was
causing an infinite recursion.
We now suspend monitoring of the KVO before makeKeyAndOrderFront, then
resume afterwards and send any changes in isVisible's state.
This fixes an issue that would arise when you minimize / order out an
OpenGL window on Mac, where the window would lose it's window device.
Without a window device, you cannot render to the window.
It does so by making two changes:
- Windows are no longer "oneShot" (which caused their window device to
get destroyed when they're minified or ordered out)
- Windows are no longer "deferred" (which caused the OS to defer
window device creation until the window is shown, which meant that
we couldn't properly makeCurrent to it)
Thanks to http://www.mikeash.com/pyblog/nsopenglcontext-and-one-shot.html
This changes the old behavior of having values in the -32768 - 32767
range, like regular joystick axis. Now "button as axis" triggers (like
on Logitech controllers) and regular axis triggers (like on Xbox
controllers) have the same resting value, 0.
This has the benefit of ending the otherwise-bogus complaints that
SDL_GetError() reports "Passed a NULL mutex" if you call it instead of
checking if SDL_CreateWindow() actually succeeded. :)