diff options
Diffstat (limited to 'xorg-server/composite/compwindow.c')
-rw-r--r-- | xorg-server/composite/compwindow.c | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/xorg-server/composite/compwindow.c b/xorg-server/composite/compwindow.c index 6c2434959..882429414 100644 --- a/xorg-server/composite/compwindow.c +++ b/xorg-server/composite/compwindow.c @@ -336,6 +336,21 @@ compIsAlternateVisual(ScreenPtr pScreen, XID visual) } static Bool +compIsImplicitRedirectException(ScreenPtr pScreen, + XID parentVisual, XID winVisual) +{ + CompScreenPtr cs = GetCompScreen(pScreen); + int i; + + for (i = 0; i < cs->numImplicitRedirectExceptions; i++) + if (cs->implicitRedirectExceptions[i].parentVisual == parentVisual && + cs->implicitRedirectExceptions[i].winVisual == winVisual) + return TRUE; + + return FALSE; +} + +static Bool compImplicitRedirect(WindowPtr pWin, WindowPtr pParent) { if (pParent) { @@ -343,6 +358,9 @@ compImplicitRedirect(WindowPtr pWin, WindowPtr pParent) XID winVisual = wVisual(pWin); XID parentVisual = wVisual(pParent); + if (compIsImplicitRedirectException(pScreen, parentVisual, winVisual)) + return FALSE; + if (winVisual != parentVisual && (compIsAlternateVisual(pScreen, winVisual) || compIsAlternateVisual(pScreen, parentVisual))) |