window: Make sure override_redirect window have correct monitor info
We need to update window->monitor on override_redirect windows as well, other wise they may end up with an invalid struct which triggers and assert when meta_window_is_monitor_sized is called. https://bugzilla.gnome.org/show_bug.cgi?id=702564
This commit is contained in:
parent
5205821fb9
commit
8ab136b7ea
@ -3039,7 +3039,7 @@ meta_screen_resize (MetaScreen *screen,
|
|||||||
|
|
||||||
/* Fix up monitor for all windows on this screen */
|
/* Fix up monitor for all windows on this screen */
|
||||||
windows = meta_display_list_windows (screen->display,
|
windows = meta_display_list_windows (screen->display,
|
||||||
META_LIST_DEFAULT);
|
META_LIST_INCLUDE_OVERRIDE_REDIRECT);
|
||||||
for (tmp = windows; tmp != NULL; tmp = tmp->next)
|
for (tmp = windows; tmp != NULL; tmp = tmp->next)
|
||||||
{
|
{
|
||||||
MetaWindow *window = tmp->data;
|
MetaWindow *window = tmp->data;
|
||||||
|
@ -145,6 +145,8 @@ static void meta_window_move_between_rects (MetaWindow *window,
|
|||||||
static void unmaximize_window_before_freeing (MetaWindow *window);
|
static void unmaximize_window_before_freeing (MetaWindow *window);
|
||||||
static void unminimize_window_and_all_transient_parents (MetaWindow *window);
|
static void unminimize_window_and_all_transient_parents (MetaWindow *window);
|
||||||
|
|
||||||
|
static void meta_window_update_monitor (MetaWindow *window);
|
||||||
|
|
||||||
/* Idle handlers for the three queues (run with meta_later_add()). The
|
/* Idle handlers for the three queues (run with meta_later_add()). The
|
||||||
* "data" parameter in each case will be a GINT_TO_POINTER of the
|
* "data" parameter in each case will be a GINT_TO_POINTER of the
|
||||||
* index into the queue arrays to use.
|
* index into the queue arrays to use.
|
||||||
@ -4767,6 +4769,12 @@ meta_window_update_for_monitors_changed (MetaWindow *window)
|
|||||||
if (window->type == META_WINDOW_DESKTOP)
|
if (window->type == META_WINDOW_DESKTOP)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
|
if (window->override_redirect)
|
||||||
|
{
|
||||||
|
meta_window_update_monitor (window);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
old = window->monitor;
|
old = window->monitor;
|
||||||
|
|
||||||
/* Start on primary */
|
/* Start on primary */
|
||||||
|
Loading…
Reference in New Issue
Block a user