From c8472a74441838e16d0d3414db1fa7fe996868a9 Mon Sep 17 00:00:00 2001 From: Michael Vogt Date: Tue, 25 Nov 2008 19:35:17 +0200 Subject: [PATCH] Do not send VisibilityNotify events when MapUnmapEvents are disabled This prevents a protocol visible side-effect (XVisibilityEvent) on XCompositeRedirectWindow() followed by a XCompositeUnredirectWindow(). The problem shows up in gnome-screensaver with compiz and "unredirect fullscreen windows" enable. A VisibilityNotify event is generated (first with obscured and than with unobscured) when the window swithces from redirected to unredirected. https://bugs.freedesktop.org/show_bug.cgi?id=18133 http://launchpad.net/bugs/278112 --- dix/window.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/dix/window.c b/dix/window.c index ff5ba4acc..c31fa875b 100644 --- a/dix/window.c +++ b/dix/window.c @@ -3091,6 +3091,8 @@ void SendVisibilityNotify(WindowPtr pWin) { xEvent event; + if (!MapUnmapEventsEnabled(pWin)) + return; #ifndef NO_XINERAMA_PORT unsigned int visibility = pWin->visibility; #endif