summaryrefslogtreecommitdiff
path: root/miext
diff options
context:
space:
mode:
authorJeremy Huddleston <jeremyhu@freedesktop.org>2009-09-27 23:29:37 -0700
committerJeremy Huddleston <jeremyhu@freedesktop.org>2009-09-27 23:29:37 -0700
commit459ae6273a50f9fa110cd48b0bb7fbd83e66c00b (patch)
tree916dd565fe49b892085ab26a04cc7d7ef38dcd77 /miext
parentf7d5ab6cd287f55fadae24c366567b79b257f663 (diff)
XQuartz: Fix a bunch of compilation warnings about style
(cherry picked from commit 54000bdcbca52a2de31f7c1a1147de6d8e9dbbb8)
Diffstat (limited to 'miext')
-rw-r--r--miext/rootless/rootlessWindow.c26
1 files changed, 26 insertions, 0 deletions
diff --git a/miext/rootless/rootlessWindow.c b/miext/rootless/rootlessWindow.c
index 3787e7e9e..2e5e84c2e 100644
--- a/miext/rootless/rootlessWindow.c
+++ b/miext/rootless/rootlessWindow.c
@@ -1692,3 +1692,29 @@ RootlessShowAllWindows (void)
RootlessScreenExpose (pScreen);
}
}
+
+/*
+ * SetPixmapOfAncestors
+ * Set the Pixmaps on all ParentRelative windows up the ancestor chain.
+ */
+void
+RootlessSetPixmapOfAncestors(WindowPtr pWin)
+{
+ ScreenPtr pScreen = pWin->drawable.pScreen;
+ WindowPtr topWin = TopLevelParent(pWin);
+ RootlessWindowRec *topWinRec = WINREC(topWin);
+
+ while (pWin->backgroundState == ParentRelative) {
+ if (pWin == topWin) {
+ // disallow ParentRelative background state on top level
+ XID pixel = 0;
+ ChangeWindowAttributes(pWin, CWBackPixel, &pixel, serverClient);
+ RL_DEBUG_MSG("Cleared ParentRelative on 0x%x.\n", pWin);
+ break;
+ }
+
+ pWin = pWin->parent;
+ pScreen->SetWindowPixmap(pWin, topWinRec->pixmap);
+ }
+}
+