summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJamey Sharp <jamey@minilop.net>2010-05-23 11:05:01 -0700
committerJamey Sharp <jamey@minilop.net>2010-06-03 14:03:23 -0700
commit217ccaa5a341018457f468a774c035c0df47d918 (patch)
tree667fcf3549fc14234feab415d060c4ac94f96572
parente7fae9ecc42ab5e73b89117722dbf4117d928f9a (diff)
Delete panoramiXdataPtr: it's redundant.
This eliminates a dynamically-allocated MAXSCREENS-sized array. Signed-off-by: Jamey Sharp <jamey@minilop.net> Reviewed-by: Tiago Vignatti <tiago.vignatti@nokia.com> Tested-by: Tiago Vignatti <tiago.vignatti@nokia.com> (i686 GNU/Linux)
-rw-r--r--Xext/panoramiX.c59
-rw-r--r--Xext/panoramiX.h7
-rw-r--r--Xext/panoramiXprocs.c106
-rw-r--r--Xext/panoramiXsrv.h1
-rw-r--r--Xext/shm.c12
-rw-r--r--Xext/xvdisp.c16
-rw-r--r--Xi/xiquerypointer.c8
-rw-r--r--dix/events.c138
-rw-r--r--dix/getevents.c4
-rw-r--r--dix/window.c12
-rw-r--r--hw/dmx/doc/dmx.xml9
-rw-r--r--hw/xquartz/pseudoramiX.c4
-rw-r--r--mi/miexpose.c4
-rw-r--r--record/record.c8
-rw-r--r--render/render.c44
15 files changed, 204 insertions, 228 deletions
diff --git a/Xext/panoramiX.c b/Xext/panoramiX.c
index e1cef87a5..5f0e97efc 100644
--- a/Xext/panoramiX.c
+++ b/Xext/panoramiX.c
@@ -70,7 +70,6 @@ int PanoramiXPixWidth = 0;
int PanoramiXPixHeight = 0;
int PanoramiXNumScreens = 0;
-PanoramiXData *panoramiXdataPtr = NULL;
static RegionRec PanoramiXScreenRegion = {{0, 0, 0, 0}, NULL};
static int PanoramiXNumDepths;
@@ -199,8 +198,8 @@ XineramaValidateGC(
if((pDraw->type == DRAWABLE_WINDOW) && !(((WindowPtr)pDraw)->parent)) {
/* the root window */
- int x_off = panoramiXdataPtr[pGC->pScreen->myNum].x;
- int y_off = panoramiXdataPtr[pGC->pScreen->myNum].y;
+ int x_off = dixScreenOrigins[pGC->pScreen->myNum].x;
+ int y_off = dixScreenOrigins[pGC->pScreen->myNum].y;
int new_val;
new_val = pGCPriv->clipOrg.x - x_off;
@@ -396,27 +395,23 @@ static void XineramaInitData(ScreenPtr pScreen)
pScreen = screenInfo.screens[i];
- panoramiXdataPtr[i].x = dixScreenOrigins[i].x;
- panoramiXdataPtr[i].y = dixScreenOrigins[i].y;
- panoramiXdataPtr[i].width = pScreen->width;
- panoramiXdataPtr[i].height = pScreen->height;
-
- TheBox.x1 = panoramiXdataPtr[i].x;
- TheBox.x2 = TheBox.x1 + panoramiXdataPtr[i].width;
- TheBox.y1 = panoramiXdataPtr[i].y;
- TheBox.y2 = TheBox.y1 + panoramiXdataPtr[i].height;
+ TheBox.x1 = dixScreenOrigins[i].x;
+ TheBox.x2 = TheBox.x1 + pScreen->width;
+ TheBox.y1 = dixScreenOrigins[i].y;
+ TheBox.y2 = TheBox.y1 + pScreen->height;
REGION_INIT(pScreen, &XineramaScreenRegions[i], &TheBox, 1);
REGION_UNION(pScreen, &PanoramiXScreenRegion, &PanoramiXScreenRegion,
&XineramaScreenRegions[i]);
}
- PanoramiXPixWidth = panoramiXdataPtr[0].x + panoramiXdataPtr[0].width;
- PanoramiXPixHeight = panoramiXdataPtr[0].y + panoramiXdataPtr[0].height;
+ PanoramiXPixWidth = dixScreenOrigins[0].x + screenInfo.screens[0]->width;
+ PanoramiXPixHeight = dixScreenOrigins[0].y + screenInfo.screens[0]->height;
for (i = 1; i < PanoramiXNumScreens; i++) {
- w = panoramiXdataPtr[i].x + panoramiXdataPtr[i].width;
- h = panoramiXdataPtr[i].y + panoramiXdataPtr[i].height;
+ pScreen = screenInfo.screens[i];
+ w = dixScreenOrigins[i].x + pScreen->width;
+ h = dixScreenOrigins[i].y + pScreen->height;
if (PanoramiXPixWidth < w)
PanoramiXPixWidth = w;
@@ -473,12 +468,6 @@ void PanoramiXExtensionInit(int argc, char *argv[])
* run in non-PanoramiXeen mode.
*/
- panoramiXdataPtr = (PanoramiXData *)
- calloc(PanoramiXNumScreens, sizeof(PanoramiXData));
-
- if (!panoramiXdataPtr)
- break;
-
if (!dixRequestPrivate(PanoramiXGCKey, sizeof(PanoramiXGCRec))) {
noPanoramiXExtension = TRUE;
return;
@@ -897,8 +886,6 @@ static void PanoramiXResetProc(ExtensionEntry* extEntry)
screenInfo.numScreens = PanoramiXNumScreens;
for (i = 256; i--; )
ProcVector[i] = SavedProcVector[i];
-
- free(panoramiXdataPtr);
}
@@ -1000,8 +987,8 @@ ProcPanoramiXGetScreenSize(ClientPtr client)
rep.length = 0;
rep.sequenceNumber = client->sequence;
/* screen dimensions */
- rep.width = panoramiXdataPtr[stuff->screen].width;
- rep.height = panoramiXdataPtr[stuff->screen].height;
+ rep.width = screenInfo.screens[stuff->screen]->width;
+ rep.height = screenInfo.screens[stuff->screen]->height;
rep.window = stuff->window;
rep.screen = stuff->screen;
if (client->swapped) {
@@ -1073,10 +1060,10 @@ ProcXineramaQueryScreens(ClientPtr client)
int i;
for(i = 0; i < PanoramiXNumScreens; i++) {
- scratch.x_org = panoramiXdataPtr[i].x;
- scratch.y_org = panoramiXdataPtr[i].y;
- scratch.width = panoramiXdataPtr[i].width;
- scratch.height = panoramiXdataPtr[i].height;
+ scratch.x_org = dixScreenOrigins[i].x;
+ scratch.y_org = dixScreenOrigins[i].y;
+ scratch.width = screenInfo.screens[i]->width;
+ scratch.height = screenInfo.screens[i]->height;
if(client->swapped) {
int n;
@@ -1166,8 +1153,8 @@ XineramaGetImageData(
SrcBox.x1 = left;
SrcBox.y1 = top;
if(!isRoot) {
- SrcBox.x1 += pDraw->x + panoramiXdataPtr[0].x;
- SrcBox.y1 += pDraw->y + panoramiXdataPtr[0].y;
+ SrcBox.x1 += pDraw->x + dixScreenOrigins[0].x;
+ SrcBox.y1 += pDraw->y + dixScreenOrigins[0].y;
}
SrcBox.x2 = SrcBox.x1 + width;
SrcBox.y2 = SrcBox.y1 + height;
@@ -1184,8 +1171,8 @@ XineramaGetImageData(
if(inOut == rgnIN) {
(*pDraw->pScreen->GetImage)(pDraw,
- SrcBox.x1 - pDraw->x - panoramiXdataPtr[i].x,
- SrcBox.y1 - pDraw->y - panoramiXdataPtr[i].y,
+ SrcBox.x1 - pDraw->x - dixScreenOrigins[i].x,
+ SrcBox.y1 - pDraw->y - dixScreenOrigins[i].y,
width, height, format, planemask, data);
break;
} else if (inOut == rgnOUT)
@@ -1216,8 +1203,8 @@ XineramaGetImageData(
}
}
- x = pbox->x1 - pDraw->x - panoramiXdataPtr[i].x;
- y = pbox->y1 - pDraw->y - panoramiXdataPtr[i].y;
+ x = pbox->x1 - pDraw->x - dixScreenOrigins[i].x;
+ y = pbox->y1 - pDraw->y - dixScreenOrigins[i].y;
(*pDraw->pScreen->GetImage)(pDraw, x, y, w, h,
format, planemask, ScratchMem);
diff --git a/Xext/panoramiX.h b/Xext/panoramiX.h
index 35de17951..a8684f0d2 100644
--- a/Xext/panoramiX.h
+++ b/Xext/panoramiX.h
@@ -46,13 +46,6 @@ Equipment Corporation.
#include "gcstruct.h"
-typedef struct _PanoramiXData {
- int x;
- int y;
- int width;
- int height;
-} PanoramiXData;
-
typedef struct _PanoramiXInfo {
XID id ;
} PanoramiXInfo;
diff --git a/Xext/panoramiXprocs.c b/Xext/panoramiXprocs.c
index 6b199cf7b..ccd721687 100644
--- a/Xext/panoramiXprocs.c
+++ b/Xext/panoramiXprocs.c
@@ -135,8 +135,8 @@ int PanoramiXCreateWindow(ClientPtr client)
stuff->wid = newWin->info[j].id;
stuff->parent = parent->info[j].id;
if (parentIsRoot) {
- stuff->x = orig_x - panoramiXdataPtr[j].x;
- stuff->y = orig_y - panoramiXdataPtr[j].y;
+ stuff->x = orig_x - dixScreenOrigins[j].x;
+ stuff->y = orig_y - dixScreenOrigins[j].y;
}
if (backPix)
*((CARD32 *) &stuff[1] + pback_offset) = backPix->info[j].id;
@@ -334,8 +334,8 @@ int PanoramiXReparentWindow(ClientPtr client)
stuff->window = win->info[j].id;
stuff->parent = parent->info[j].id;
if(parentIsRoot) {
- stuff->x = x - panoramiXdataPtr[j].x;
- stuff->y = y - panoramiXdataPtr[j].y;
+ stuff->x = x - dixScreenOrigins[j].x;
+ stuff->y = y - dixScreenOrigins[j].y;
}
result = (*SavedProcVector[X_ReparentWindow])(client);
if(result != Success) break;
@@ -495,9 +495,9 @@ int PanoramiXConfigureWindow(ClientPtr client)
if(sib)
*((CARD32 *) &stuff[1] + sib_offset) = sib->info[j].id;
if(x_offset >= 0)
- *((CARD32 *) &stuff[1] + x_offset) = x - panoramiXdataPtr[j].x;
+ *((CARD32 *) &stuff[1] + x_offset) = x - dixScreenOrigins[j].x;
if(y_offset >= 0)
- *((CARD32 *) &stuff[1] + y_offset) = y - panoramiXdataPtr[j].y;
+ *((CARD32 *) &stuff[1] + y_offset) = y - dixScreenOrigins[j].y;
result = (*SavedProcVector[X_ConfigureWindow])(client);
if(result != Success) break;
}
@@ -565,8 +565,8 @@ int PanoramiXGetGeometry(ClientPtr client)
if((pWin->parent == screenInfo.screens[0]->root) ||
(pWin->parent->drawable.id == screenInfo.screens[0]->screensaver.wid))
{
- rep.x += panoramiXdataPtr[0].x;
- rep.y += panoramiXdataPtr[0].y;
+ rep.x += dixScreenOrigins[0].x;
+ rep.y += dixScreenOrigins[0].y;
}
rep.borderWidth = pWin->borderWidth;
}
@@ -599,8 +599,8 @@ int PanoramiXTranslateCoords(ClientPtr client)
if((pWin == screenInfo.screens[0]->root) ||
(pWin->drawable.id == screenInfo.screens[0]->screensaver.wid))
{
- x = stuff->srcX - panoramiXdataPtr[0].x;
- y = stuff->srcY - panoramiXdataPtr[0].y;
+ x = stuff->srcX - dixScreenOrigins[0].x;
+ y = stuff->srcY - dixScreenOrigins[0].y;
} else {
x = pWin->drawable.x + stuff->srcX;
y = pWin->drawable.y + stuff->srcY;
@@ -637,8 +637,8 @@ int PanoramiXTranslateCoords(ClientPtr client)
if((pDst == screenInfo.screens[0]->root) ||
(pWin->drawable.id == screenInfo.screens[0]->screensaver.wid))
{
- rep.dstX += panoramiXdataPtr[0].x;
- rep.dstY += panoramiXdataPtr[0].y;
+ rep.dstX += dixScreenOrigins[0].x;
+ rep.dstY += dixScreenOrigins[0].y;
}
WriteReplyToClient(client, sizeof(xTranslateCoordsReply), &rep);
@@ -981,8 +981,8 @@ int PanoramiXClearToBackground(ClientPtr client)
FOR_NSCREENS_BACKWARD(j) {
stuff->window = win->info[j].id;
if(isRoot) {
- stuff->x = x - panoramiXdataPtr[j].x;
- stuff->y = y - panoramiXdataPtr[j].y;
+ stuff->x = x - dixScreenOrigins[j].x;
+ stuff->y = y - dixScreenOrigins[j].y;
}
result = (*SavedProcVector[X_ClearArea])(client);
if(result != Success) break;
@@ -1092,12 +1092,12 @@ int PanoramiXCopyArea(ClientPtr client)
stuff->srcDrawable = src->info[j].id;
stuff->gc = gc->info[j].id;
if (srcIsRoot) {
- stuff->srcX = srcx - panoramiXdataPtr[j].x;
- stuff->srcY = srcy - panoramiXdataPtr[j].y;
+ stuff->srcX = srcx - dixScreenOrigins[j].x;
+ stuff->srcY = srcy - dixScreenOrigins[j].y;
}
if (dstIsRoot) {
- stuff->dstX = dstx - panoramiXdataPtr[j].x;
- stuff->dstY = dsty - panoramiXdataPtr[j].y;
+ stuff->dstX = dstx - dixScreenOrigins[j].x;
+ stuff->dstY = dsty - dixScreenOrigins[j].y;
}
VALIDATE_DRAWABLE_AND_GC(stuff->dstDrawable, pDst, DixWriteAccess);
@@ -1137,7 +1137,7 @@ int PanoramiXCopyArea(ClientPtr client)
if(pRgn[j]) {
if(srcIsRoot) {
REGION_TRANSLATE(pScreen, pRgn[j],
- panoramiXdataPtr[j].x, panoramiXdataPtr[j].y);
+ dixScreenOrigins[j].x, dixScreenOrigins[j].y);
}
REGION_APPEND(pScreen, &totalReg, pRgn[j]);
REGION_DESTROY(pScreen, pRgn[j]);
@@ -1203,12 +1203,12 @@ int PanoramiXCopyPlane(ClientPtr client)
stuff->srcDrawable = src->info[j].id;
stuff->gc = gc->info[j].id;
if (srcIsRoot) {
- stuff->srcX = srcx - panoramiXdataPtr[j].x;
- stuff->srcY = srcy - panoramiXdataPtr[j].y;
+ stuff->srcX = srcx - dixScreenOrigins[j].x;
+ stuff->srcY = srcy - dixScreenOrigins[j].y;
}
if (dstIsRoot) {
- stuff->dstX = dstx - panoramiXdataPtr[j].x;
- stuff->dstY = dsty - panoramiXdataPtr[j].y;
+ stuff->dstX = dstx - dixScreenOrigins[j].x;
+ stuff->dstY = dsty - dixScreenOrigins[j].y;
}
VALIDATE_DRAWABLE_AND_GC(stuff->dstDrawable, pdstDraw, DixWriteAccess);
@@ -1297,8 +1297,8 @@ int PanoramiXPolyPoint(ClientPtr client)
if(j) memcpy(&stuff[1], origPts, npoint * sizeof(xPoint));
if (isRoot) {
- int x_off = panoramiXdataPtr[j].x;
- int y_off = panoramiXdataPtr[j].y;
+ int x_off = dixScreenOrigins[j].x;
+ int y_off = dixScreenOrigins[j].y;
if(x_off || y_off) {
xPoint *pnts = (xPoint*)&stuff[1];
@@ -1357,8 +1357,8 @@ int PanoramiXPolyLine(ClientPtr client)
if(j) memcpy(&stuff[1], origPts, npoint * sizeof(xPoint));
if (isRoot) {
- int x_off = panoramiXdataPtr[j].x;
- int y_off = panoramiXdataPtr[j].y;
+ int x_off = dixScreenOrigins[j].x;
+ int y_off = dixScreenOrigins[j].y;
if(x_off || y_off) {
xPoint *pnts = (xPoint*)&stuff[1];
@@ -1420,8 +1420,8 @@ int PanoramiXPolySegment(ClientPtr client)
if(j) memcpy(&stuff[1], origSegs, nsegs * sizeof(xSegment));
if (isRoot) {
- int x_off = panoramiXdataPtr[j].x;
- int y_off = panoramiXdataPtr[j].y;
+ int x_off = dixScreenOrigins[j].x;
+ int y_off = dixScreenOrigins[j].y;
if(x_off || y_off) {
xSegment *segs = (xSegment*)&stuff[1];
@@ -1483,8 +1483,8 @@ int PanoramiXPolyRectangle(ClientPtr client)
if(j) memcpy(&stuff[1], origRecs, nrects * sizeof(xRectangle));
if (isRoot) {
- int x_off = panoramiXdataPtr[j].x;
- int y_off = panoramiXdataPtr[j].y;
+ int x_off = dixScreenOrigins[j].x;
+ int y_off = dixScreenOrigins[j].y;
if(x_off || y_off) {
@@ -1545,8 +1545,8 @@ int PanoramiXPolyArc(ClientPtr client)
if(j) memcpy(&stuff[1], origArcs, narcs * sizeof(xArc));
if (isRoot) {
- int x_off = panoramiXdataPtr[j].x;
- int y_off = panoramiXdataPtr[j].y;
+ int x_off = dixScreenOrigins[j].x;
+ int y_off = dixScreenOrigins[j].y;
if(x_off || y_off) {
xArc *arcs = (xArc *) &stuff[1];
@@ -1603,8 +1603,8 @@ int PanoramiXFillPoly(ClientPtr client)
if(j) memcpy(&stuff[1], locPts, count * sizeof(DDXPointRec));
if (isRoot) {
- int x_off = panoramiXdataPtr[j].x;
- int y_off = panoramiXdataPtr[j].y;
+ int x_off = dixScreenOrigins[j].x;
+ int y_off = dixScreenOrigins[j].y;
if(x_off || y_off) {
DDXPointPtr pnts = (DDXPointPtr)&stuff[1];
@@ -1666,8 +1666,8 @@ int PanoramiXPolyFillRectangle(ClientPtr client)
if(j) memcpy(&stuff[1], origRects, things * sizeof(xRectangle));
if (isRoot) {
- int x_off = panoramiXdataPtr[j].x;
- int y_off = panoramiXdataPtr[j].y;
+ int x_off = dixScreenOrigins[j].x;
+ int y_off = dixScreenOrigins[j].y;
if(x_off || y_off) {
xRectangle *rects = (xRectangle *) &stuff[1];
@@ -1727,8 +1727,8 @@ int PanoramiXPolyFillArc(ClientPtr client)
if(j) memcpy(&stuff[1], origArcs, narcs * sizeof(xArc));
if (isRoot) {
- int x_off = panoramiXdataPtr[j].x;
- int y_off = panoramiXdataPtr[j].y;
+ int x_off = dixScreenOrigins[j].x;
+ int y_off = dixScreenOrigins[j].y;
if(x_off || y_off) {
xArc *arcs = (xArc *) &stuff[1];
@@ -1780,8 +1780,8 @@ int PanoramiXPutImage(ClientPtr client)
orig_y = stuff->dstY;
FOR_NSCREENS_BACKWARD(j){
if (isRoot) {
- stuff->dstX = orig_x - panoramiXdataPtr[j].x;
- stuff->dstY = orig_y - panoramiXdataPtr[j].y;
+ stuff->dstX = orig_x - dixScreenOrigins[j].x;
+ stuff->dstY = orig_y - dixScreenOrigins[j].y;
}
stuff->drawable = draw->info[j].id;
stuff->gc = gc->info[j].id;
@@ -1846,10 +1846,10 @@ int PanoramiXGetImage(ClientPtr client)
return(BadMatch);
} else {
if( /* check for being onscreen */
- panoramiXdataPtr[0].x + pDraw->x + x < 0 ||
- panoramiXdataPtr[0].x + pDraw->x + x + w > PanoramiXPixWidth ||
- panoramiXdataPtr[0].y + pDraw->y + y < 0 ||
- panoramiXdataPtr[0].y + pDraw->y + y + h > PanoramiXPixHeight ||
+ dixScreenOrigins[0].x + pDraw->x + x < 0 ||
+ dixScreenOrigins[0].x + pDraw->x + x + w > PanoramiXPixWidth ||
+ dixScreenOrigins[0].y + pDraw->y + y < 0 ||
+ dixScreenOrigins[0].y + pDraw->y + y + h > PanoramiXPixHeight ||
/* check for being inside of border */
x < - wBorderWidth((WindowPtr)pDraw) ||
x + w > wBorderWidth((WindowPtr)pDraw) + (int)pDraw->width ||
@@ -1983,8 +1983,8 @@ PanoramiXPolyText8(ClientPtr client)
stuff->drawable = draw->info[j].id;
stuff->gc = gc->info[j].id;
if (isRoot) {
- stuff->x = orig_x - panoramiXdataPtr[j].x;
- stuff->y = orig_y - panoramiXdataPtr[j].y;
+ stuff->x = orig_x - dixScreenOrigins[j].x;
+ stuff->y = orig_y - dixScreenOrigins[j].y;
}
result = (*SavedProcVector[X_PolyText8])(client);
if(result != Success) break;
@@ -2024,8 +2024,8 @@ PanoramiXPolyText16(ClientPtr client)
stuff->drawable = draw->info[j].id;
stuff->gc = gc->info[j].id;
if (isRoot) {
- stuff->x = orig_x - panoramiXdataPtr[j].x;
- stuff->y = orig_y - panoramiXdataPtr[j].y;
+ stuff->x = orig_x - dixScreenOrigins[j].x;
+ stuff->y = orig_y - dixScreenOrigins[j].y;
}
result = (*SavedProcVector[X_PolyText16])(client);
if(result != Success) break;
@@ -2065,8 +2065,8 @@ int PanoramiXImageText8(ClientPtr client)
stuff->drawable = draw->info[j].id;
stuff->gc = gc->info[j].id;
if (isRoot) {
- stuff->x = orig_x - panoramiXdataPtr[j].x;
- stuff->y = orig_y - panoramiXdataPtr[j].y;
+ stuff->x = orig_x - dixScreenOrigins[j].x;
+ stuff->y = orig_y - dixScreenOrigins[j].y;
}
result = (*SavedProcVector[X_ImageText8])(client);
if(result != Success) break;
@@ -2106,8 +2106,8 @@ int PanoramiXImageText16(ClientPtr client)
stuff->drawable = draw->info[j].id;
stuff->gc = gc->info[j].id;
if (isRoot) {
- stuff->x = orig_x - panoramiXdataPtr[j].x;
- stuff->y = orig_y - panoramiXdataPtr[j].y;
+ stuff->x = orig_x - dixScreenOrigins[j].x;
+ stuff->y = orig_y - dixScreenOrigins[j].y;
}
result = (*SavedProcVector[X_ImageText16])(client);
if(result != Success) break;
diff --git a/Xext/panoramiXsrv.h b/Xext/panoramiXsrv.h
index c77b11927..af0017d85 100644
--- a/Xext/panoramiXsrv.h
+++ b/Xext/panoramiXsrv.h
@@ -9,7 +9,6 @@
#include "panoramiX.h"
extern _X_EXPORT int PanoramiXNumScreens;
-extern _X_EXPORT PanoramiXData *panoramiXdataPtr;
extern _X_EXPORT int PanoramiXPixWidth;
extern _X_EXPORT int PanoramiXPixHeight;
diff --git a/Xext/shm.c b/Xext/shm.c
index 3d9c63352..99cd39ed3 100644
--- a/Xext/shm.c
+++ b/Xext/shm.c
@@ -598,8 +598,8 @@ ProcPanoramiXShmPutImage(ClientPtr client)
stuff->drawable = draw->info[j].id;
stuff->gc = gc->info[j].id;
if (isRoot) {
- stuff->dstX = orig_x - panoramiXdataPtr[j].x;
- stuff->dstY = orig_y - panoramiXdataPtr[j].y;
+ stuff->dstX = orig_x - dixScreenOrigins[j].x;
+ stuff->dstY = orig_y - dixScreenOrigins[j].y;
}
result = ProcShmPutImage(client);
if(result != Success) break;
@@ -660,10 +660,10 @@ ProcPanoramiXShmGetImage(ClientPtr client)
return(BadMatch);
} else {
if( /* check for being onscreen */
- panoramiXdataPtr[0].x + pDraw->x + x < 0 ||
- panoramiXdataPtr[0].x + pDraw->x + x + w > PanoramiXPixWidth ||
- panoramiXdataPtr[0].y + pDraw->y + y < 0 ||
- panoramiXdataPtr[0].y + pDraw->y + y + h > PanoramiXPixHeight ||
+ dixScreenOrigins[0].x + pDraw->x + x < 0 ||
+ dixScreenOrigins[0].x + pDraw->x + x + w > PanoramiXPixWidth ||
+ dixScreenOrigins[0].y + pDraw->y + y < 0 ||
+ dixScreenOrigins[0].y + pDraw->y + y + h > PanoramiXPixHeight ||
/* check for being inside of border */
x < - wBorderWidth((WindowPtr)pDraw) ||
x + w > wBorderWidth((WindowPtr)pDraw) + (int)pDraw->width ||
diff --git a/Xext/xvdisp.c b/Xext/xvdisp.c
index d7338ad87..efbe9738d 100644
--- a/Xext/xvdisp.c
+++ b/Xext/xvdisp.c
@@ -1690,8 +1690,8 @@ XineramaXvShmPutImage(ClientPtr client)
stuff->drw_x = x;
stuff->drw_y = y;
if(isRoot) {
- stuff->drw_x -= panoramiXdataPtr[i].x;
- stuff->drw_y -= panoramiXdataPtr[i].y;
+ stuff->drw_x -= dixScreenOrigins[i].x;
+ stuff->drw_y -= dixScreenOrigins[i].y;
}
stuff->send_event = (send_event && !i) ? 1 : 0;
@@ -1742,8 +1742,8 @@ XineramaXvPutImage(ClientPtr client)
stuff->drw_x = x;
stuff->drw_y = y;
if(isRoot) {
- stuff->drw_x -= panoramiXdataPtr[i].x;
- stuff->drw_y -= panoramiXdataPtr[i].y;
+ stuff->drw_x -= dixScreenOrigins[i].x;
+ stuff->drw_y -= dixScreenOrigins[i].y;
}
result = ProcXvPutImage(client);
@@ -1790,8 +1790,8 @@ XineramaXvPutVideo(ClientPtr client)
stuff->drw_x = x;
stuff->drw_y = y;
if(isRoot) {
- stuff->drw_x -= panoramiXdataPtr[i].x;
- stuff->drw_y -= panoramiXdataPtr[i].y;
+ stuff->drw_x -= dixScreenOrigins[i].x;
+ stuff->drw_y -= dixScreenOrigins[i].y;
}
result = ProcXvPutVideo(client);
@@ -1838,8 +1838,8 @@ XineramaXvPutStill(ClientPtr client)
stuff->drw_x = x;
stuff->drw_y = y;
if(isRoot) {
- stuff->drw_x -= panoramiXdataPtr[i].x;
- stuff->drw_y -= panoramiXdataPtr[i].y;
+ stuff->drw_x -= dixScreenOrigins[i].x;
+ stuff->drw_y -= dixScreenOrigins[i].y;
}
result = ProcXvPutStill(client);
diff --git a/Xi/xiquerypointer.c b/Xi/xiquerypointer.c
index 41253fb18..a0c26ba99 100644
--- a/Xi/xiquerypointer.c
+++ b/Xi/xiquerypointer.c
@@ -181,12 +181,12 @@ ProcXIQueryPointer(ClientPtr client)
#ifdef PANORAMIX
if(!noPanoramiXExtension) {
- rep.root_x += FP1616(panoramiXdataPtr[0].x, 0);
- rep.root_y += FP1616(panoramiXdataPtr[0].y, 0);
+ rep.root_x += FP1616(dixScreenOrigins[0].x, 0);
+ rep.root_y += FP1616(dixScreenOrigins[0].y, 0);
if (stuff->win == rep.root)
{
- rep.win_x += FP1616(panoramiXdataPtr[0].x, 0);
- rep.win_y += FP1616(panoramiXdataPtr[0].y, 0);
+ rep.win_x += FP1616(dixScreenOrigins[0].x, 0);
+ rep.win_y += FP1616(dixScreenOrigins[0].y, 0);
}
}
#endif
diff --git a/dix/events.c b/dix/events.c
index 01865969b..21ee85ef8 100644
--- a/dix/events.c
+++ b/dix/events.c
@@ -502,8 +502,8 @@ XineramaSetCursorPosition(
that screen are. */
pScreen = pSprite->screen;
- x += panoramiXdataPtr[0].x;
- y += panoramiXdataPtr[0].y;
+ x += dixScreenOrigins[0].x;
+ y += dixScreenOrigins[0].y;
if(!POINT_IN_REGION(pScreen, &XineramaScreenRegions[pScreen->myNum],
x, y, &box))
@@ -521,10 +521,10 @@ XineramaSetCursorPosition(
}
pSprite->screen = pScreen;
- pSprite->hotPhys.x = x - panoramiXdataPtr[0].x;
- pSprite->hotPhys.y = y - panoramiXdataPtr[0].y;
- x -= panoramiXdataPtr[pScreen->myNum].x;
- y -= panoramiXdataPtr[pScreen->myNum].y;
+ pSprite->hotPhys.x = x - dixScreenOrigins[0].x;
+ pSprite->hotPhys.y = y - dixScreenOrigins[0].y;
+ x -= dixScreenOrigins[pScreen->myNum].x;
+ y -= dixScreenOrigins[pScreen->myNum].y;
return (*pScreen->SetCursorPosition)(pDev, pScreen, x, y, generateEvent);
}
@@ -542,10 +542,10 @@ XineramaConstrainCursor(DeviceIntPtr pDev)
/* Translate the constraining box to the screen
the sprite is actually on */
- newBox.x1 += panoramiXdataPtr[0].x - panoramiXdataPtr[pScreen->myNum].x;
- newBox.x2 += panoramiXdataPtr[0].x - panoramiXdataPtr[pScreen->myNum].x;
- newBox.y1 += panoramiXdataPtr[0].y - panoramiXdataPtr[pScreen->myNum].y;
- newBox.y2 += panoramiXdataPtr[0].y - panoramiXdataPtr[pScreen->myNum].y;
+ newBox.x1 += dixScreenOrigins[0].x - dixScreenOrigins[pScreen->myNum].x;
+ newBox.x2 += dixScreenOrigins[0].x - dixScreenOrigins[pScreen->myNum].x;
+ newBox.y1 += dixScreenOrigins[0].y - dixScreenOrigins[pScreen->myNum].y;
+ newBox.y2 += dixScreenOrigins[0].y - dixScreenOrigins[pScreen->myNum].y;
(* pScreen->ConstrainCursor)(pDev, pScreen, &newBox);
}
@@ -595,12 +595,12 @@ XineramaConfineCursorToWindow(DeviceIntPtr pDev,
REGION_COPY(pSprite->screen, &pSprite->Reg1,
&pSprite->windows[i]->borderSize);
- off_x = panoramiXdataPtr[i].x;
- off_y = panoramiXdataPtr[i].y;
+ off_x = dixScreenOrigins[i].x;
+ off_y = dixScreenOrigins[i].y;
while(i--) {
- x = off_x - panoramiXdataPtr[i].x;
- y = off_y - panoramiXdataPtr[i].y;
+ x = off_x - dixScreenOrigins[i].x;
+ y = off_y - dixScreenOrigins[i].y;
if(x || y)
REGION_TRANSLATE(pSprite->screen, &pSprite->Reg1, x, y);
@@ -608,8 +608,8 @@ XineramaConfineCursorToWindow(DeviceIntPtr pDev,
REGION_UNION(pSprite->screen, &pSprite->Reg1, &pSprite->Reg1,
&pSprite->windows[i]->borderSize);
- off_x = panoramiXdataPtr[i].x;
- off_y = panoramiXdataPtr[i].y;
+ off_x = dixScreenOrigins[i].x;
+ off_y = dixScreenOrigins[i].y;
}
pSprite->hotLimits = *REGION_EXTENTS(pSprite->screen, &pSprite->Reg1);
@@ -814,12 +814,12 @@ CheckVirtualMotion(
REGION_COPY(pSprite->screen, &pSprite->Reg2,
&pSprite->windows[i]->borderSize);
- off_x = panoramiXdataPtr[i].x;
- off_y = panoramiXdataPtr[i].y;
+ off_x = dixScreenOrigins[i].x;
+ off_y = dixScreenOrigins[i].y;
while(i--) {
- x = off_x - panoramiXdataPtr[i].x;
- y = off_y - panoramiXdataPtr[i].y;
+ x = off_x - dixScreenOrigins[i].x;
+ y = off_y - dixScreenOrigins[i].y;
if(x || y)
REGION_TRANSLATE(pSprite->screen, &pSprite->Reg2, x, y);
@@ -827,8 +827,8 @@ CheckVirtualMotion(
REGION_UNION(pSprite->screen, &pSprite->Reg2, &pSprite->Reg2,
&pSprite->windows[i]->borderSize);
- off_x = panoramiXdataPtr[i].x;
- off_y = panoramiXdataPtr[i].y;
+ off_x = dixScreenOrigins[i].x;
+ off_y = dixScreenOrigins[i].y;
}
} else
#endif
@@ -1135,10 +1135,10 @@ EnqueueEvent(InternalEvent *ev, DeviceIntPtr device)
{
#ifdef PANORAMIX
if(!noPanoramiXExtension) {
- event->root_x += panoramiXdataPtr[pSprite->screen->myNum].x -
- panoramiXdataPtr[0].x;
- event->root_y += panoramiXdataPtr[pSprite->screen->myNum].y -
- panoramiXdataPtr[0].y;
+ event->root_x += dixScreenOrigins[pSprite->screen->myNum].x -
+ dixScreenOrigins[0].x;
+ event->root_y += dixScreenOrigins[pSprite->screen->myNum].y -
+ dixScreenOrigins[0].y;
}
#endif
pSprite->hotPhys.x = event->root_x;
@@ -1218,10 +1218,10 @@ PlayReleasedEvents(void)
case ET_KeyRelease:
case ET_ProximityIn:
case ET_ProximityOut:
- ev->root_x += panoramiXdataPtr[0].x -
- panoramiXdataPtr[pDev->spriteInfo->sprite->screen->myNum].x;
- ev->root_y += panoramiXdataPtr[0].y -
- panoramiXdataPtr[pDev->spriteInfo->sprite->screen->myNum].y;
+ ev->root_x += dixScreenOrigins[0].x -
+ dixScreenOrigins[pDev->spriteInfo->sprite->screen->myNum].x;
+ ev->root_y += dixScreenOrigins[0].y -
+ dixScreenOrigins[pDev->spriteInfo->sprite->screen->myNum].y;
break;
default:
break;
@@ -2561,8 +2561,8 @@ PointInBorderSize(WindowPtr pWin, int x, int y)
for(i = 1; i < PanoramiXNumScreens; i++) {
if(POINT_IN_REGION(pSprite->screen,
&pSprite->windows[i]->borderSize,
- x + panoramiXdataPtr[0].x - panoramiXdataPtr[i].x,
- y + panoramiXdataPtr[0].y - panoramiXdataPtr[i].y,
+ x + dixScreenOrigins[0].x - dixScreenOrigins[i].x,
+ y + dixScreenOrigins[0].y - dixScreenOrigins[i].y,
&box))
return TRUE;
}
@@ -2757,10 +2757,10 @@ CheckMotion(DeviceEvent *ev, DeviceIntPtr pDev)
/* Motion events entering DIX get translated to Screen 0
coordinates. Replayed events have already been
translated since they've entered DIX before */
- ev->root_x += panoramiXdataPtr[pSprite->screen->myNum].x -
- panoramiXdataPtr[0].x;
- ev->root_y += panoramiXdataPtr[pSprite->screen->myNum].y -
- panoramiXdataPtr[0].y;
+ ev->root_x += dixScreenOrigins[pSprite->screen->myNum].x -
+ dixScreenOrigins[0].x;
+ ev->root_y += dixScreenOrigins[pSprite->screen->myNum].y -
+ dixScreenOrigins[0].y;
} else
#endif
{
@@ -3008,10 +3008,10 @@ InitializeSprite(DeviceIntPtr pDev, WindowPtr pWin)
}
#ifdef PANORAMIX
if(!noPanoramiXExtension) {
- pSprite->hotLimits.x1 = -panoramiXdataPtr[0].x;
- pSprite->hotLimits.y1 = -panoramiXdataPtr[0].y;
- pSprite->hotLimits.x2 = PanoramiXPixWidth - panoramiXdataPtr[0].x;
- pSprite->hotLimits.y2 = PanoramiXPixHeight - panoramiXdataPtr[0].y;
+ pSprite->hotLimits.x1 = -dixScreenOrigins[0].x;
+ pSprite->hotLimits.y1 = -dixScreenOrigins[0].y;
+ pSprite->hotLimits.x2 = PanoramiXPixWidth - dixScreenOrigins[0].x;
+ pSprite->hotLimits.y2 = PanoramiXPixHeight - dixScreenOrigins[0].y;
pSprite->physLimits = pSprite->hotLimits;
pSprite->confineWin = NullWindow;
pSprite->hotShape = NullRegion;
@@ -3078,10 +3078,10 @@ UpdateSpriteForScreen(DeviceIntPtr pDev, ScreenPtr pScreen)
#ifdef PANORAMIX
if(!noPanoramiXExtension) {
- pSprite->hotLimits.x1 = -panoramiXdataPtr[0].x;
- pSprite->hotLimits.y1 = -panoramiXdataPtr[0].y;
- pSprite->hotLimits.x2 = PanoramiXPixWidth - panoramiXdataPtr[0].x;
- pSprite->hotLimits.y2 = PanoramiXPixHeight - panoramiXdataPtr[0].y;
+ pSprite->hotLimits.x1 = -dixScreenOrigins[0].x;
+ pSprite->hotLimits.y1 = -dixScreenOrigins[0].y;
+ pSprite->hotLimits.x2 = PanoramiXPixWidth - dixScreenOrigins[0].x;
+ pSprite->hotLimits.y2 = PanoramiXPixHeight - dixScreenOrigins[0].y;
pSprite->physLimits = pSprite->hotLimits;
pSprite->screen = pScreen;
}
@@ -3114,10 +3114,10 @@ NewCurrentScreen(DeviceIntPtr pDev, ScreenPtr newScreen, int x, int y)
pSprite->hotPhys.y = y;
#ifdef PANORAMIX
if(!noPanoramiXExtension) {
- pSprite->hotPhys.x += panoramiXdataPtr[newScreen->myNum].x -
- panoramiXdataPtr[0].x;
- pSprite->hotPhys.y += panoramiXdataPtr[newScreen->myNum].y -
- panoramiXdataPtr[0].y;
+ pSprite->hotPhys.x += dixScreenOrigins[newScreen->myNum].x -
+ dixScreenOrigins[0].x;
+ pSprite->hotPhys.y += dixScreenOrigins[newScreen->myNum].y -
+ dixScreenOrigins[0].y;
if (newScreen != pSprite->screen) {
pSprite->screen = newScreen;
/* Make sure we tell the DDX to update its copy of the screen */
@@ -3132,10 +3132,10 @@ NewCurrentScreen(DeviceIntPtr pDev, ScreenPtr newScreen, int x, int y)
(*pSprite->screen->SetCursorPosition)(
pDev,
pSprite->screen,
- pSprite->hotPhys.x + panoramiXdataPtr[0].x -
- panoramiXdataPtr[pSprite->screen->myNum].x,
- pSprite->hotPhys.y + panoramiXdataPtr[0].y -
- panoramiXdataPtr[pSprite->screen->myNum].y, FALSE);
+ pSprite->hotPhys.x + dixScreenOrigins[0].x -
+ dixScreenOrigins[pSprite->screen->myNum].x,
+ pSprite->hotPhys.y + dixScreenOrigins[0].y -
+ dixScreenOrigins[pSprite->screen->myNum].y, FALSE);
}
} else
#endif
@@ -3163,14 +3163,14 @@ XineramaPointInWindowIsVisible(
if(!XineramaSetWindowPntrs(inputInfo.pointer, pWin)) return FALSE;
- xoff = x + panoramiXdataPtr[0].x;
- yoff = y + panoramiXdataPtr[0].y;
+ xoff = x + dixScreenOrigins[0].x;
+ yoff = y + dixScreenOrigins[0].y;
for(i = 1; i < PanoramiXNumScreens; i++) {
pWin = inputInfo.pointer->spriteInfo->sprite->windows[i];
pScreen = pWin->drawable.pScreen;
- x = xoff - panoramiXdataPtr[i].x;
- y = yoff - panoramiXdataPtr[i].y;
+ x = xoff - dixScreenOrigins[i].x;
+ y = yoff - dixScreenOrigins[i].y;
if(POINT_IN_REGION(pScreen, &pWin->borderClip, x, y, &box)
&& (!wInputShape(pWin) ||
@@ -3216,8 +3216,8 @@ XineramaWarpPointer(ClientPtr client)
winX = source->drawable.x;
winY = source->drawable.y;
if(source == screenInfo.screens[0]->root) {
- winX -= panoramiXdataPtr[0].x;
- winY -= panoramiXdataPtr[0].y;
+ winX -= dixScreenOrigins[0].x;
+ winY -= dixScreenOrigins[0].y;
}
if (x < winX + stuff->srcX ||
y < winY + stuff->srcY ||
@@ -3232,8 +3232,8 @@ XineramaWarpPointer(ClientPtr client)
x = dest->drawable.x;
y = dest->drawable.y;
if(dest == screenInfo.screens[0]->root) {
- x -= panoramiXdataPtr[0].x;
- y -= panoramiXdataPtr[0].y;
+ x -= dixScreenOrigins[0].x;
+ y -= dixScreenOrigins[0].y;
}
}
@@ -4997,11 +4997,11 @@ ProcQueryPointer(ClientPtr client)
#ifdef PANORAMIX
if(!noPanoramiXExtension) {
- rep.rootX += panoramiXdataPtr[0].x;
- rep.rootY += panoramiXdataPtr[0].y;
+ rep.rootX += dixScreenOrigins[0].x;
+ rep.rootY += dixScreenOrigins[0].y;
if(stuff->id == rep.root) {
- rep.winX += panoramiXdataPtr[0].x;
- rep.winY += panoramiXdataPtr[0].y;
+ rep.winX += dixScreenOrigins[0].x;
+ rep.winY += dixScreenOrigins[0].y;
}
}
#endif
@@ -5670,7 +5670,7 @@ WriteEventsToClient(ClientPtr pClient, int count, xEvent *events)
#ifdef PANORAMIX
if(!noPanoramiXExtension &&
- (panoramiXdataPtr[0].x || panoramiXdataPtr[0].y))
+ (dixScreenOrigins[0].x || dixScreenOrigins[0].y))
{
switch(events->u.u.type) {
case MotionNotify:
@@ -5687,13 +5687,13 @@ WriteEventsToClient(ClientPtr pClient, int count, xEvent *events)
*/
count = 1; /* should always be 1 */
memcpy(&eventCopy, events, sizeof(xEvent));
- eventCopy.u.keyButtonPointer.rootX += panoramiXdataPtr[0].x;
- eventCopy.u.keyButtonPointer.rootY += panoramiXdataPtr[0].y;
+ eventCopy.u.keyButtonPointer.rootX += dixScreenOrigins[0].x;
+ eventCopy.u.keyButtonPointer.rootY += dixScreenOrigins[0].y;
if(eventCopy.u.keyButtonPointer.event ==
eventCopy.u.keyButtonPointer.root)
{
- eventCopy.u.keyButtonPointer.eventX += panoramiXdataPtr[0].x;
- eventCopy.u.keyButtonPointer.eventY += panoramiXdataPtr[0].y;
+ eventCopy.u.keyButtonPointer.eventX += dixScreenOrigins[0].x;
+ eventCopy.u.keyButtonPointer.eventY += dixScreenOrigins[0].y;
}
events = &eventCopy;
break;
diff --git a/dix/getevents.c b/dix/getevents.c
index eeef41448..3ca5883d9 100644
--- a/dix/getevents.c
+++ b/dix/getevents.c
@@ -1210,8 +1210,8 @@ PostSyntheticMotion(DeviceIntPtr pDev,
will translate from sprite screen to screen 0 upon reentry
to the DIX layer. */
if (!noPanoramiXExtension) {
- x += panoramiXdataPtr[0].x - panoramiXdataPtr[screen].x;
- y += panoramiXdataPtr[0].y - panoramiXdataPtr[screen].y;
+ x += dixScreenOrigins[0].x - dixScreenOrigins[screen].x;
+ y += dixScreenOrigins[0].y - dixScreenOrigins[screen].y;
}
#endif
diff --git a/dix/window.c b/dix/window.c
index 71edd4681..834552313 100644
--- a/dix/window.c
+++ b/dix/window.c
@@ -2236,8 +2236,8 @@ ConfigureWindow(WindowPtr pWin, Mask mask, XID *vlist, ClientPtr client)
event.u.configureRequest.y = y;
#ifdef PANORAMIX
if(!noPanoramiXExtension && (!pParent || !pParent->parent)) {
- event.u.configureRequest.x += panoramiXdataPtr[0].x;
- event.u.configureRequest.y += panoramiXdataPtr[0].y;
+ event.u.configureRequest.x += dixScreenOrigins[0].x;
+ event.u.configureRequest.y += dixScreenOrigins[0].y;
}
#endif
event.u.configureRequest.width = w;
@@ -2317,8 +2317,8 @@ ActuallyDoSomething:
event.u.configureNotify.y = y;
#ifdef PANORAMIX
if(!noPanoramiXExtension && (!pParent || !pParent->parent)) {
- event.u.configureNotify.x += panoramiXdataPtr[0].x;
- event.u.configureNotify.y += panoramiXdataPtr[0].y;
+ event.u.configureNotify.x += dixScreenOrigins[0].x;
+ event.u.configureNotify.y += dixScreenOrigins[0].y;
}
#endif
event.u.configureNotify.width = w;
@@ -2471,8 +2471,8 @@ ReparentWindow(WindowPtr pWin, WindowPtr pParent,
event.u.reparent.y = y;
#ifdef PANORAMIX
if(!noPanoramiXExtension && !pParent->parent) {
- event.u.reparent.x += panoramiXdataPtr[0].x;
- event.u.reparent.y += panoramiXdataPtr[0].y;
+ event.u.reparent.x += dixScreenOrigins[0].x;
+ event.u.reparent.y += dixScreenOrigins[0].y;
}
#endif
event.u.reparent.override = pWin->overrideRedirect;
diff --git a/hw/dmx/doc/dmx.xml b/hw/dmx/doc/dmx.xml
index 12d7067dc..251e6ac13 100644
--- a/hw/dmx/doc/dmx.xml
+++ b/hw/dmx/doc/dmx.xml
@@ -1497,9 +1497,7 @@ PanoramiX prefix.
<para>The Xinerama extension is registered by calling AddExtension().
</para>
- <para>A local per-screen array of data structures
- (panoramiXdataPtr&lsqb;&rsqb;)
- is allocated for each physical screen, and GC and Screen private
+ <para>GC and Screen private
indexes are allocated, and both GC and Screen private areas are
allocated for each physical screen. These hold Xinerama-specific
per-GC and per-Screen data. Each screen's CreateGC and CloseScreen
@@ -1511,9 +1509,8 @@ PanoramiX prefix.
<para>A region (XineramaScreenRegions&lsqb;i&rsqb;) is initialized for each
physical screen, and single region (PanoramiXScreenRegion) is
- initialized to be the union of the screen regions. The
- panoramiXdataPtr&lsqb;&rsqb; array is also initialized with the size and
- origin of each screen. The relative positioning information for the
+ initialized to be the union of the screen regions.
+ The relative positioning information for the
physical screens is taken from the array
dixScreenOrigins&lsqb;&rsqb;, which
the DDX layer must initialize in InitOutput(). The bounds of the
diff --git a/hw/xquartz/pseudoramiX.c b/hw/xquartz/pseudoramiX.c
index 5868ab129..298ec2be9 100644
--- a/hw/xquartz/pseudoramiX.c
+++ b/hw/xquartz/pseudoramiX.c
@@ -255,9 +255,9 @@ static int ProcPseudoramiXGetScreenSize(ClientPtr client)
rep.sequenceNumber = client->sequence;
/* screen dimensions */
rep.width = pseudoramiXScreens[stuff->screen].w;
- // was panoramiXdataPtr[stuff->screen].width;
+ // was screenInfo.screens[stuff->screen]->width;
rep.height = pseudoramiXScreens[stuff->screen].h;
- // was panoramiXdataPtr[stuff->screen].height;
+ // was screenInfo.screens[stuff->screen]->height;
if (client->swapped) {
swaps (&rep.sequenceNumber, n);
swapl (&rep.length, n);
diff --git a/mi/miexpose.c b/mi/miexpose.c
index 9249ca9f9..ee3ef724a 100644
--- a/mi/miexpose.c
+++ b/mi/miexpose.c
@@ -424,8 +424,8 @@ miSendExposures( WindowPtr pWin, RegionPtr pRgn, int dx, int dy)
XID realWin = 0;
if(!pWin->parent) {
- x = panoramiXdataPtr[scrnum].x;
- y = panoramiXdataPtr[scrnum].y;
+ x = dixScreenOrigins[scrnum].x;
+ y = dixScreenOrigins[scrnum].y;
pWin = screenInfo.screens[0]->root;
realWin = pWin->drawable.id;
} else if (scrnum) {
diff --git a/record/record.c b/record/record.c
index 3724dc7a9..b81b7b2fa 100644
--- a/record/record.c
+++ b/record/record.c
@@ -755,11 +755,11 @@ RecordSendProtocolEvents(RecordClientsAndProtocolPtr pRCAP,
int scr = XineramaGetCursorScreen(inputInfo.pointer);
memcpy(&shiftedEvent, pev, sizeof(xEvent));
shiftedEvent.u.keyButtonPointer.rootX +=
- panoramiXdataPtr[scr].x -
- panoramiXdataPtr[0].x;
+ dixScreenOrigins[scr].x -
+ dixScreenOrigins[0].x;
shiftedEvent.u.keyButtonPointer.rootY +=
- panoramiXdataPtr[scr].y -
- panoramiXdataPtr[0].y;
+ dixScreenOrigins[scr].y -
+ dixScreenOrigins[0].y;
pEvToRecord = &shiftedEvent;
}
#endif /* PANORAMIX */
diff --git a/render/render.c b/render/render.c
index d34250227..11c092776 100644
--- a/render/render.c
+++ b/render/render.c
@@ -2832,22 +2832,22 @@ PanoramiXRenderComposite (ClientPtr client)
stuff->src = src->info[j].id;
if (src->u.pict.root)
{
- stuff->xSrc = orig.xSrc - panoramiXdataPtr[j].x;
- stuff->ySrc = orig.ySrc - panoramiXdataPtr[j].y;
+ stuff->xSrc = orig.xSrc - dixScreenOrigins[j].x;
+ stuff->ySrc = orig.ySrc - dixScreenOrigins[j].y;
}
stuff->dst = dst->info[j].id;
if (dst->u.pict.root)
{
- stuff->xDst = orig.xDst - panoramiXdataPtr[j].x;
- stuff->yDst = orig.yDst - panoramiXdataPtr[j].y;
+ stuff->xDst = orig.xDst - dixScreenOrigins[j].x;
+ stuff->yDst = orig.yDst - dixScreenOrigins[j].y;
}
if (msk)
{
stuff->mask = msk->info[j].id;
if (msk->u.pict.root)
{
- stuff->xMask = orig.xMask - panoramiXdataPtr[j].x;
- stuff->yMask = orig.yMask - panoramiXdataPtr[j].y;
+ stuff->xMask = orig.xMask - dixScreenOrigins[j].x;
+ stuff->yMask = orig.yMask - dixScreenOrigins[j].y;
}
}
result = (*PanoramiXSaveRenderVector[X_RenderComposite]) (client);
@@ -2881,14 +2881,14 @@ PanoramiXRenderCompositeGlyphs (ClientPtr client)
stuff->src = src->info[j].id;
if (src->u.pict.root)
{
- stuff->xSrc = xSrc - panoramiXdataPtr[j].x;
- stuff->ySrc = ySrc - panoramiXdataPtr[j].y;
+ stuff->xSrc = xSrc - dixScreenOrigins[j].x;
+ stuff->ySrc = ySrc - dixScreenOrigins[j].y;
}
stuff->dst = dst->info[j].id;
if (dst->u.pict.root)
{
- elt->deltax = origElt.deltax - panoramiXdataPtr[j].x;
- elt->deltay = origElt.deltay - panoramiXdataPtr[j].y;
+ elt->deltax = origElt.deltax - dixScreenOrigins[j].x;
+ elt->deltay = origElt.deltay - dixScreenOrigins[j].y;
}
result = (*PanoramiXSaveRenderVector[stuff->renderReqType]) (client);
if(result != Success) break;
@@ -2918,8 +2918,8 @@ PanoramiXRenderFillRectangles (ClientPtr client)
if (j) memcpy (stuff + 1, extra, extra_len);
if (dst->u.pict.root)
{
- int x_off = panoramiXdataPtr[j].x;
- int y_off = panoramiXdataPtr[j].y;
+ int x_off = dixScreenOrigins[j].x;
+ int y_off = dixScreenOrigins[j].y;
if(x_off || y_off) {
xRectangle *rects = (xRectangle *) (stuff + 1);
@@ -2966,8 +2966,8 @@ PanoramiXRenderTrapezoids(ClientPtr client)
FOR_NSCREENS_FORWARD(j) {
if (j) memcpy (stuff + 1, extra, extra_len);
if (dst->u.pict.root) {
- int x_off = panoramiXdataPtr[j].x;
- int y_off = panoramiXdataPtr[j].y;
+ int x_off = dixScreenOrigins[j].x;
+ int y_off = dixScreenOrigins[j].y;
if(x_off || y_off) {
xTrapezoid *trap = (xTrapezoid *) (stuff + 1);
@@ -3026,8 +3026,8 @@ PanoramiXRenderTriangles(ClientPtr client)
FOR_NSCREENS_FORWARD(j) {
if (j) memcpy (stuff + 1, extra, extra_len);
if (dst->u.pict.root) {
- int x_off = panoramiXdataPtr[j].x;
- int y_off = panoramiXdataPtr[j].y;
+ int x_off = dixScreenOrigins[j].x;
+ int y_off = dixScreenOrigins[j].y;
if(x_off || y_off) {
xTriangle *tri = (xTriangle *) (stuff + 1);
@@ -3082,8 +3082,8 @@ PanoramiXRenderTriStrip(ClientPtr client)
FOR_NSCREENS_FORWARD(j) {
if (j) memcpy (stuff + 1, extra, extra_len);
if (dst->u.pict.root) {
- int x_off = panoramiXdataPtr[j].x;
- int y_off = panoramiXdataPtr[j].y;
+ int x_off = dixScreenOrigins[j].x;
+ int y_off = dixScreenOrigins[j].y;
if(x_off || y_off) {
xPointFixed *fixed = (xPointFixed *) (stuff + 1);
@@ -3134,8 +3134,8 @@ PanoramiXRenderTriFan(ClientPtr client)
FOR_NSCREENS_FORWARD(j) {
if (j) memcpy (stuff + 1, extra, extra_len);
if (dst->u.pict.root) {
- int x_off = panoramiXdataPtr[j].x;
- int y_off = panoramiXdataPtr[j].y;
+ int x_off = dixScreenOrigins[j].x;
+ int y_off = dixScreenOrigins[j].y;
if(x_off || y_off) {
xPointFixed *fixed = (xPointFixed *) (stuff + 1);
@@ -3188,8 +3188,8 @@ PanoramiXRenderAddTraps (ClientPtr client)
if (picture->u.pict.root)
{
- stuff->xOff = x_off + panoramiXdataPtr[j].x;
- stuff->yOff = y_off + panoramiXdataPtr[j].y;
+ stuff->xOff = x_off + dixScreenOrigins[j].x;
+ stuff->yOff = y_off + dixScreenOrigins[j].y;
}
result = (*PanoramiXSaveRenderVector[X_RenderAddTraps]) (client);
if(result != Success) break;