Blame alleggl-0.4.3-fullscreen-viewport.patch

a805759
diff -up alleggl/src/x.c~ alleggl/src/x.c
a805759
--- alleggl/src/x.c~	2007-09-18 22:36:28.000000000 +0200
a805759
+++ alleggl/src/x.c	2009-09-10 22:09:01.000000000 +0200
a805759
@@ -1005,6 +1005,14 @@ old_choose_visual:
a805759
 #ifdef ALLEGROGL_HAVE_XF86VIDMODE
a805759
 	if (fullscreen) {
a805759
 		setattr.override_redirect = True;
a805759
+
a805759
+		/* Warp the pointer to the upper left corner, this is
a805759
+		   necessary as the: XF86VidModeSetViewPort() call below does
a805759
+		   not seem to do anything on newer Xorg servers, instead the
a805759
+		   viewport is always be centered at the last mouse position */
a805759
+		XWarpPointer(_xwin.display, None,
a805759
+			     XDefaultRootWindow(_xwin.display),
a805759
+			     0, 0, 0, 0, 0, 0);
a805759
 		if (!XF86VidModeSwitchToMode(_xwin.display, _xwin.screen,
a805759
 		                             _xwin.modesinfo[bestmode])) {
a805759