summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlberts Muktupāvels <[email protected]>2015-09-23 17:15:25 +0300
committerWolfgang Ulbrich <[email protected]>2015-10-26 15:09:54 +0100
commit91e2a28ae80b1840ca01466721a96ba39d871eaf (patch)
tree04242977d8a1eeaba5718e7124f037955ed68981
parentcf0c5b766e2c79e36a596ed0d24c792e534b6d67 (diff)
downloadmarco-91e2a28ae80b1840ca01466721a96ba39d871eaf.tar.bz2
marco-91e2a28ae80b1840ca01466721a96ba39d871eaf.tar.xz
effects: remove hack that made Marco crash in certain situations
fixes https://github.com/mate-desktop/marco/issues/200 ported to Marco from https://github.com/GNOME/metacity/commit/f25b7760b7430b674afdb4de1e2072cd99ea3fbc
-rw-r--r--src/core/effects.c21
1 files changed, 1 insertions, 20 deletions
diff --git a/src/core/effects.c b/src/core/effects.c
index 469184e2..163ec054 100644
--- a/src/core/effects.c
+++ b/src/core/effects.c
@@ -316,23 +316,6 @@ update_wireframe_window (MetaDisplay *display,
}
#endif
-/**
- * A hack to force the X server to synchronize with the
- * graphics hardware.
- */
-static void
-graphics_sync (BoxAnimationContext *context)
-{
- XImage *image;
-
- image = XGetImage (context->screen->display->xdisplay,
- context->screen->xroot,
- 0, 0, 1, 1,
- AllPlanes, ZPixmap);
-
- XDestroyImage (image);
-}
-
static gboolean
effects_draw_box_animation_timeout (BoxAnimationContext *context)
{
@@ -383,8 +366,6 @@ effects_draw_box_animation_timeout (BoxAnimationContext *context)
context->gc);
#endif /* !HAVE_SHAPE */
- graphics_sync (context);
-
context->finished(context->finished_data);
g_free (context);
@@ -425,7 +406,7 @@ effects_draw_box_animation_timeout (BoxAnimationContext *context)
#endif /* !HAVE_SHAPE */
/* kick changes onto the server */
- graphics_sync (context);
+ XFlush (context->screen->display->xdisplay);
return TRUE;
}