Implement freezing of updates during resize

Replace the unused meta_compositor_set_updates() with
a reversed-meaning meta_compositor_set_updates_frozen(), and use
it to implement freezing application window updates during
interactive resizing. This avoids drawing new areas of the window
with blank content before the application has a chance to repaint.

https://bugzilla.gnome.org/show_bug.cgi?id=685463
This commit is contained in:
Owen W. Taylor
2011-06-13 17:53:23 -04:00
parent 3abaf506a6
commit c9343e3ee3
6 changed files with 92 additions and 18 deletions

View File

@@ -343,6 +343,9 @@ struct _MetaWindow
/* if TRUE, window is attached to its parent */
guint attached : 1;
/* if TRUE, we are freezing updates during a resize */
guint updates_frozen_for_resize : 1;
/* if non-NULL, the bounds of the window frame */
cairo_region_t *frame_bounds;
@@ -663,4 +666,6 @@ gboolean meta_window_can_tile_side_by_side (MetaWindow *window);
void meta_window_compute_tile_match (MetaWindow *window);
gboolean meta_window_updates_are_frozen (MetaWindow *window);
#endif