Xnest: fetch BlackPixel and WhitePixel from xcb setup data
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
This commit is contained in:
parent
467ee9eba7
commit
2ec930fc4a
|
@ -48,8 +48,6 @@ int *xnestDepths;
|
||||||
int xnestNumDepths;
|
int xnestNumDepths;
|
||||||
XPixmapFormatValues *xnestPixmapFormats;
|
XPixmapFormatValues *xnestPixmapFormats;
|
||||||
int xnestNumPixmapFormats;
|
int xnestNumPixmapFormats;
|
||||||
Pixel xnestBlackPixel;
|
|
||||||
Pixel xnestWhitePixel;
|
|
||||||
Drawable xnestDefaultDrawables[MAXDEPTH + 1];
|
Drawable xnestDefaultDrawables[MAXDEPTH + 1];
|
||||||
Pixmap xnestIconBitmap;
|
Pixmap xnestIconBitmap;
|
||||||
Pixmap xnestScreenSaverPixmap;
|
Pixmap xnestScreenSaverPixmap;
|
||||||
|
@ -134,9 +132,6 @@ xnestOpenDisplay(int argc, char *argv[])
|
||||||
xnestPixmapFormats = XListPixmapFormats(xnestDisplay,
|
xnestPixmapFormats = XListPixmapFormats(xnestDisplay,
|
||||||
&xnestNumPixmapFormats);
|
&xnestNumPixmapFormats);
|
||||||
|
|
||||||
xnestBlackPixel = BlackPixel(xnestDisplay, xnestUpstreamInfo.screenId);
|
|
||||||
xnestWhitePixel = WhitePixel(xnestDisplay, xnestUpstreamInfo.screenId);
|
|
||||||
|
|
||||||
if (xnestParentWindow != (Window) 0)
|
if (xnestParentWindow != (Window) 0)
|
||||||
xnestEventMask = XCB_EVENT_MASK_STRUCTURE_NOTIFY;
|
xnestEventMask = XCB_EVENT_MASK_STRUCTURE_NOTIFY;
|
||||||
else
|
else
|
||||||
|
@ -184,8 +179,8 @@ xnestOpenDisplay(int argc, char *argv[])
|
||||||
(char *) screensaver_bits,
|
(char *) screensaver_bits,
|
||||||
screensaver_width,
|
screensaver_width,
|
||||||
screensaver_height,
|
screensaver_height,
|
||||||
xnestWhitePixel,
|
xnestUpstreamInfo.screenInfo->white_pixel,
|
||||||
xnestBlackPixel,
|
xnestUpstreamInfo.screenInfo->black_pixel,
|
||||||
DefaultDepth(xnestDisplay, xnestUpstreamInfo.screenId));
|
DefaultDepth(xnestDisplay, xnestUpstreamInfo.screenId));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -32,8 +32,6 @@ extern int *xnestDepths;
|
||||||
extern int xnestNumDepths;
|
extern int xnestNumDepths;
|
||||||
extern XPixmapFormatValues *xnestPixmapFormats;
|
extern XPixmapFormatValues *xnestPixmapFormats;
|
||||||
extern int xnestNumPixmapFormats;
|
extern int xnestNumPixmapFormats;
|
||||||
extern Pixel xnestBlackPixel;
|
|
||||||
extern Pixel xnestWhitePixel;
|
|
||||||
extern Drawable xnestDefaultDrawables[MAXDEPTH + 1];
|
extern Drawable xnestDefaultDrawables[MAXDEPTH + 1];
|
||||||
extern Pixmap xnestIconBitmap;
|
extern Pixmap xnestIconBitmap;
|
||||||
extern Pixmap xnestScreenSaverPixmap;
|
extern Pixmap xnestScreenSaverPixmap;
|
||||||
|
|
|
@ -252,8 +252,8 @@ xnestOpenScreen(ScreenPtr pScreen, int argc, char *argv[])
|
||||||
pScreen->maxInstalledCmaps = MAXCMAPS;
|
pScreen->maxInstalledCmaps = MAXCMAPS;
|
||||||
pScreen->backingStoreSupport = XCB_BACKING_STORE_NOT_USEFUL;
|
pScreen->backingStoreSupport = XCB_BACKING_STORE_NOT_USEFUL;
|
||||||
pScreen->saveUnderSupport = XCB_BACKING_STORE_NOT_USEFUL;
|
pScreen->saveUnderSupport = XCB_BACKING_STORE_NOT_USEFUL;
|
||||||
pScreen->whitePixel = xnestWhitePixel;
|
pScreen->whitePixel = xnestUpstreamInfo.screenInfo->white_pixel;
|
||||||
pScreen->blackPixel = xnestBlackPixel;
|
pScreen->blackPixel = xnestUpstreamInfo.screenInfo->black_pixel;
|
||||||
/* GCperDepth */
|
/* GCperDepth */
|
||||||
/* defaultStipple */
|
/* defaultStipple */
|
||||||
/* WindowPrivateLen */
|
/* WindowPrivateLen */
|
||||||
|
@ -342,7 +342,7 @@ xnestOpenScreen(ScreenPtr pScreen, int argc, char *argv[])
|
||||||
if (xnestDoFullGeneration) {
|
if (xnestDoFullGeneration) {
|
||||||
|
|
||||||
valuemask = XCB_CW_BACK_PIXEL | XCB_CW_EVENT_MASK | XCB_CW_COLORMAP;
|
valuemask = XCB_CW_BACK_PIXEL | XCB_CW_EVENT_MASK | XCB_CW_COLORMAP;
|
||||||
attributes.background_pixel = xnestWhitePixel;
|
attributes.background_pixel = xnestUpstreamInfo.screenInfo->white_pixel;
|
||||||
attributes.event_mask = xnestEventMask;
|
attributes.event_mask = xnestEventMask;
|
||||||
attributes.colormap =
|
attributes.colormap =
|
||||||
xnestDefaultVisualColormap(xnestDefaultVisual(pScreen));
|
xnestDefaultVisualColormap(xnestDefaultVisual(pScreen));
|
||||||
|
|
Loading…
Reference in New Issue