Resize the guard window when the X screen is resized.

Fixes bug #670396. Without this fix the guard window may not
extend over the whole area of the screen after a XRandR
reconfiguration. The effect being that mouse events are
delivered to invisible windows.
This commit is contained in:
Benjamin Berg 2012-10-14 12:16:06 +02:00
parent 027f16b096
commit 472662d099

View File

@ -2878,6 +2878,22 @@ meta_screen_resize (MetaScreen *screen,
reload_monitor_infos (screen);
set_desktop_geometry_hint (screen);
/* Resize the guard window to fill the screen again. */
if (screen->guard_window != None)
{
XWindowChanges changes;
changes.x = 0;
changes.y = 0;
changes.width = width;
changes.height = height;
XConfigureWindow(screen->display->xdisplay,
screen->guard_window,
CWX | CWY | CWWidth | CWHeight,
&changes);
}
if (screen->display->compositor)
meta_compositor_sync_screen_size (screen->display->compositor,
screen, width, height);