From d137057fd13e83ec15ab416c7fe774741da06047 Mon Sep 17 00:00:00 2001 From: marha Date: Tue, 10 Jul 2012 14:56:29 +0200 Subject: fontconfig mesa xserver git update 10 Jul 2012 --- xorg-server/dix/colormap.c | 40 +++++++++++++++++++++------------------- 1 file changed, 21 insertions(+), 19 deletions(-) (limited to 'xorg-server/dix/colormap.c') diff --git a/xorg-server/dix/colormap.c b/xorg-server/dix/colormap.c index 10306285e..a43e2791b 100644 --- a/xorg-server/dix/colormap.c +++ b/xorg-server/dix/colormap.c @@ -450,15 +450,15 @@ FreeColormap(pointer value, XID mid) static int TellNoMap(WindowPtr pwin, Colormap * pmid) { - xEvent xE; - if (wColormap(pwin) == *pmid) { /* This should be call to DeliverEvent */ + xEvent xE = { + .u.colormap.window = pwin->drawable.id, + .u.colormap.colormap = None, + .u.colormap.new = TRUE, + .u.colormap.state = ColormapUninstalled + }; xE.u.u.type = ColormapNotify; - xE.u.colormap.window = pwin->drawable.id; - xE.u.colormap.colormap = None; - xE.u.colormap.new = TRUE; - xE.u.colormap.state = ColormapUninstalled; #ifdef PANORAMIX if (noPanoramiXExtension || !pwin->drawable.pScreen->myNum) #endif @@ -477,7 +477,6 @@ int TellLostMap(WindowPtr pwin, pointer value) { Colormap *pmid = (Colormap *) value; - xEvent xE; #ifdef PANORAMIX if (!noPanoramiXExtension && pwin->drawable.pScreen->myNum) @@ -485,11 +484,13 @@ TellLostMap(WindowPtr pwin, pointer value) #endif if (wColormap(pwin) == *pmid) { /* This should be call to DeliverEvent */ + xEvent xE = { + .u.colormap.window = pwin->drawable.id, + .u.colormap.colormap = *pmid, + .u.colormap.new = FALSE, + .u.colormap.state = ColormapUninstalled + }; xE.u.u.type = ColormapNotify; - xE.u.colormap.window = pwin->drawable.id; - xE.u.colormap.colormap = *pmid; - xE.u.colormap.new = FALSE; - xE.u.colormap.state = ColormapUninstalled; DeliverEvents(pwin, &xE, 1, (WindowPtr) NULL); } @@ -501,7 +502,6 @@ int TellGainedMap(WindowPtr pwin, pointer value) { Colormap *pmid = (Colormap *) value; - xEvent xE; #ifdef PANORAMIX if (!noPanoramiXExtension && pwin->drawable.pScreen->myNum) @@ -509,11 +509,13 @@ TellGainedMap(WindowPtr pwin, pointer value) #endif if (wColormap(pwin) == *pmid) { /* This should be call to DeliverEvent */ + xEvent xE = { + .u.colormap.window = pwin->drawable.id, + .u.colormap.colormap = *pmid, + .u.colormap.new = FALSE, + .u.colormap.state = ColormapInstalled + }; xE.u.u.type = ColormapNotify; - xE.u.colormap.window = pwin->drawable.id; - xE.u.colormap.colormap = *pmid; - xE.u.colormap.new = FALSE; - xE.u.colormap.state = ColormapInstalled; DeliverEvents(pwin, &xE, 1, (WindowPtr) NULL); } @@ -576,7 +578,7 @@ CopyFree(int channel, int client, ColormapPtr pmapSrc, ColormapPtr pmapDst) int nalloc; switch (channel) { - default: /* so compiler can see that everything gets initialized */ + default: /* so compiler can see that everything gets initialized */ case REDMAP: ppix = (pmapSrc->clientPixelsRed)[client]; npix = (pmapSrc->numPixelsRed)[client]; @@ -653,7 +655,7 @@ FreeCell(ColormapPtr pmap, Pixel i, int channel) int *pCount; switch (channel) { - default: /* so compiler can see that everything gets initialized */ + default: /* so compiler can see that everything gets initialized */ case PSEUDOMAP: case REDMAP: pent = (EntryPtr) & pmap->red[i]; @@ -2146,7 +2148,7 @@ FreeCo(ColormapPtr pmap, int client, int color, int npixIn, Pixel * ppixIn, ppixClient = pmap->clientPixelsBlue[client]; npixClient = pmap->numPixelsBlue[client]; break; - default: /* so compiler can see that everything gets initialized */ + default: /* so compiler can see that everything gets initialized */ case PSEUDOMAP: cmask = ~((Pixel) 0); rgbbad = 0; -- cgit v1.2.3