aboutsummaryrefslogtreecommitdiff
path: root/xorg-server/composite/compinit.c
diff options
context:
space:
mode:
Diffstat (limited to 'xorg-server/composite/compinit.c')
-rw-r--r--xorg-server/composite/compinit.c22
1 files changed, 9 insertions, 13 deletions
diff --git a/xorg-server/composite/compinit.c b/xorg-server/composite/compinit.c
index 3bf77e0ae..b2a9861ea 100644
--- a/xorg-server/composite/compinit.c
+++ b/xorg-server/composite/compinit.c
@@ -46,9 +46,12 @@
#include "compint.h"
-DevPrivateKey CompScreenPrivateKey = &CompScreenPrivateKey;
-DevPrivateKey CompWindowPrivateKey = &CompWindowPrivateKey;
-DevPrivateKey CompSubwindowsPrivateKey = &CompSubwindowsPrivateKey;
+static int CompScreenPrivateKeyIndex;
+DevPrivateKey CompScreenPrivateKey = &CompScreenPrivateKeyIndex;
+static int CompWindowPrivateKeyIndex;
+DevPrivateKey CompWindowPrivateKey = &CompWindowPrivateKeyIndex;
+static int CompSubwindowsPrivateKeyIndex;
+DevPrivateKey CompSubwindowsPrivateKey = &CompSubwindowsPrivateKeyIndex;
static Bool
@@ -76,14 +79,6 @@ compCloseScreen (int index, ScreenPtr pScreen)
pScreen->CopyWindow = cs->CopyWindow;
pScreen->PositionWindow = cs->PositionWindow;
- deleteCompOverlayClientsForScreen(pScreen);
-
- /*
- ** Note: no need to call DeleteWindow; the server has
- ** already destroyed it.
- */
- cs->pOverlayWin = NULL;
-
xfree (cs);
dixSetPrivate(&pScreen->devPrivates, CompScreenPrivateKey, NULL);
ret = (*pScreen->CloseScreen) (index, pScreen);
@@ -123,11 +118,11 @@ compChangeWindowAttributes(WindowPtr pWin, unsigned long mask)
pScreen->backingStoreSupport != NotUseful) {
if (pWin->backingStore != NotUseful) {
compRedirectWindow(serverClient, pWin, CompositeRedirectAutomatic);
- pWin->backStorage = TRUE;
+ pWin->backStorage = (pointer) (intptr_t) 1;
} else {
compUnredirectWindow(serverClient, pWin,
CompositeRedirectAutomatic);
- pWin->backStorage = FALSE;
+ pWin->backStorage = NULL;
}
}
@@ -381,6 +376,7 @@ compScreenInit (ScreenPtr pScreen)
return FALSE;
cs->damaged = FALSE;
+ cs->overlayWid = FakeClientID(0);
cs->pOverlayWin = NULL;
cs->pOverlayClients = NULL;