From 6ffe400e53f9dc7f66b8f2588cc766f4254a39da Mon Sep 17 00:00:00 2001 From: Daniel Stone Date: Thu, 12 Sep 2013 16:58:00 -0400 Subject: [PATCH 30/38] XWayland: Don't commit empty surfaces Instead of attaching, damaging and then committing a new buffer as soon as we allocate a pixmap, just attach and damage the entire buffer. When the buffer is changed, we'll commit the changes. This avoids an ugly black (on SHM) flash when a window is mapped or resized. Signed-off-by: Daniel Stone --- hw/xfree86/xwayland/xwayland-window.c | 1 - 1 file changed, 1 deletion(-) diff --git a/hw/xfree86/xwayland/xwayland-window.c b/hw/xfree86/xwayland/xwayland-window.c index 3c85630..fb9c64a 100644 --- a/hw/xfree86/xwayland/xwayland-window.c +++ b/hw/xfree86/xwayland/xwayland-window.c @@ -80,7 +80,6 @@ xwl_window_attach(struct xwl_window *xwl_window, PixmapPtr pixmap) wl_surface_damage(xwl_window->surface, 0, 0, pixmap->drawable.width, pixmap->drawable.height); - wl_surface_commit(xwl_window->surface); callback = wl_display_sync(xwl_screen->display); wl_callback_add_listener(callback, &free_pixmap_listener, pixmap); -- 1.8.3.1