summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichel Dänzer <mdaenzer@redhat.com>2020-02-07 12:15:07 +0100
committerMichel Dänzer <michel@daenzer.net>2020-02-11 16:07:36 +0100
commita542224ea28e2e8ccaf5e0df85bf6c603e97599a (patch)
treef3f9c1ee2f206e3bab2e23bb3aec1f81f72b46a2
parentf88d9b1f779835302e02e255fcd45989db7f488d (diff)
xwayland: Call glamor_block_handler from xwl_screen_post_damage
In between the two phases introduced by the previous change. This makes sure all pending drawing to the new buffers is flushed before they're committed to the Wayland server.
-rw-r--r--hw/xwayland/xwayland-screen.c11
1 files changed, 11 insertions, 0 deletions
diff --git a/hw/xwayland/xwayland-screen.c b/hw/xwayland/xwayland-screen.c
index 428f176d5..74f27d345 100644
--- a/hw/xwayland/xwayland-screen.c
+++ b/hw/xwayland/xwayland-screen.c
@@ -29,6 +29,10 @@
#include <unistd.h>
#include <errno.h>
+#ifdef XWL_HAS_GLAMOR
+#include <glamor.h>
+#endif
+
#include <X11/Xatom.h>
#include <micmap.h>
#include <misyncshm.h>
@@ -300,6 +304,13 @@ xwl_screen_post_damage(struct xwl_screen *xwl_screen)
if (xorg_list_is_empty(&commit_window_list))
return;
+#ifdef XWL_HAS_GLAMOR
+ if (xwl_screen->glamor &&
+ xwl_screen->egl_backend == &xwl_screen->gbm_backend) {
+ glamor_block_handler(xwl_screen->screen);
+ }
+#endif
+
xorg_list_for_each_entry_safe(xwl_window, next_xwl_window,
&commit_window_list, link_damage) {
wl_surface_commit(xwl_window->surface);