Move each screen's x/y origin into ScreenRec.
Many references to the dixScreenOrigins array already had the corresponding screen pointer handy, which meant they usually looked like "dixScreenOrigins[pScreen->myNum]". Adding a field to ScreenRec instead of keeping this information in a parallel array simplifies those expressions, and eliminates a MAXSCREENS-sized array. Since dix declared the dixScreenOrigins array, I figure allocating a screen private for these values is overkill. 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)
This commit is contained in:
parent
217ccaa5a3
commit
a83cff9f4d
|
@ -198,8 +198,8 @@ XineramaValidateGC(
|
||||||
|
|
||||||
if((pDraw->type == DRAWABLE_WINDOW) && !(((WindowPtr)pDraw)->parent)) {
|
if((pDraw->type == DRAWABLE_WINDOW) && !(((WindowPtr)pDraw)->parent)) {
|
||||||
/* the root window */
|
/* the root window */
|
||||||
int x_off = dixScreenOrigins[pGC->pScreen->myNum].x;
|
int x_off = pGC->pScreen->x;
|
||||||
int y_off = dixScreenOrigins[pGC->pScreen->myNum].y;
|
int y_off = pGC->pScreen->y;
|
||||||
int new_val;
|
int new_val;
|
||||||
|
|
||||||
new_val = pGCPriv->clipOrg.x - x_off;
|
new_val = pGCPriv->clipOrg.x - x_off;
|
||||||
|
@ -395,9 +395,9 @@ static void XineramaInitData(ScreenPtr pScreen)
|
||||||
|
|
||||||
pScreen = screenInfo.screens[i];
|
pScreen = screenInfo.screens[i];
|
||||||
|
|
||||||
TheBox.x1 = dixScreenOrigins[i].x;
|
TheBox.x1 = pScreen->x;
|
||||||
TheBox.x2 = TheBox.x1 + pScreen->width;
|
TheBox.x2 = TheBox.x1 + pScreen->width;
|
||||||
TheBox.y1 = dixScreenOrigins[i].y;
|
TheBox.y1 = pScreen->y;
|
||||||
TheBox.y2 = TheBox.y1 + pScreen->height;
|
TheBox.y2 = TheBox.y1 + pScreen->height;
|
||||||
|
|
||||||
REGION_INIT(pScreen, &XineramaScreenRegions[i], &TheBox, 1);
|
REGION_INIT(pScreen, &XineramaScreenRegions[i], &TheBox, 1);
|
||||||
|
@ -405,13 +405,13 @@ static void XineramaInitData(ScreenPtr pScreen)
|
||||||
&XineramaScreenRegions[i]);
|
&XineramaScreenRegions[i]);
|
||||||
}
|
}
|
||||||
|
|
||||||
PanoramiXPixWidth = dixScreenOrigins[0].x + screenInfo.screens[0]->width;
|
PanoramiXPixWidth = screenInfo.screens[0]->x + screenInfo.screens[0]->width;
|
||||||
PanoramiXPixHeight = dixScreenOrigins[0].y + screenInfo.screens[0]->height;
|
PanoramiXPixHeight = screenInfo.screens[0]->y + screenInfo.screens[0]->height;
|
||||||
|
|
||||||
for (i = 1; i < PanoramiXNumScreens; i++) {
|
for (i = 1; i < PanoramiXNumScreens; i++) {
|
||||||
pScreen = screenInfo.screens[i];
|
pScreen = screenInfo.screens[i];
|
||||||
w = dixScreenOrigins[i].x + pScreen->width;
|
w = pScreen->x + pScreen->width;
|
||||||
h = dixScreenOrigins[i].y + pScreen->height;
|
h = pScreen->y + pScreen->height;
|
||||||
|
|
||||||
if (PanoramiXPixWidth < w)
|
if (PanoramiXPixWidth < w)
|
||||||
PanoramiXPixWidth = w;
|
PanoramiXPixWidth = w;
|
||||||
|
@ -1060,8 +1060,8 @@ ProcXineramaQueryScreens(ClientPtr client)
|
||||||
int i;
|
int i;
|
||||||
|
|
||||||
for(i = 0; i < PanoramiXNumScreens; i++) {
|
for(i = 0; i < PanoramiXNumScreens; i++) {
|
||||||
scratch.x_org = dixScreenOrigins[i].x;
|
scratch.x_org = screenInfo.screens[i]->x;
|
||||||
scratch.y_org = dixScreenOrigins[i].y;
|
scratch.y_org = screenInfo.screens[i]->y;
|
||||||
scratch.width = screenInfo.screens[i]->width;
|
scratch.width = screenInfo.screens[i]->width;
|
||||||
scratch.height = screenInfo.screens[i]->height;
|
scratch.height = screenInfo.screens[i]->height;
|
||||||
|
|
||||||
|
@ -1153,8 +1153,8 @@ XineramaGetImageData(
|
||||||
SrcBox.x1 = left;
|
SrcBox.x1 = left;
|
||||||
SrcBox.y1 = top;
|
SrcBox.y1 = top;
|
||||||
if(!isRoot) {
|
if(!isRoot) {
|
||||||
SrcBox.x1 += pDraw->x + dixScreenOrigins[0].x;
|
SrcBox.x1 += pDraw->x + screenInfo.screens[0]->x;
|
||||||
SrcBox.y1 += pDraw->y + dixScreenOrigins[0].y;
|
SrcBox.y1 += pDraw->y + screenInfo.screens[0]->y;
|
||||||
}
|
}
|
||||||
SrcBox.x2 = SrcBox.x1 + width;
|
SrcBox.x2 = SrcBox.x1 + width;
|
||||||
SrcBox.y2 = SrcBox.y1 + height;
|
SrcBox.y2 = SrcBox.y1 + height;
|
||||||
|
@ -1171,8 +1171,8 @@ XineramaGetImageData(
|
||||||
|
|
||||||
if(inOut == rgnIN) {
|
if(inOut == rgnIN) {
|
||||||
(*pDraw->pScreen->GetImage)(pDraw,
|
(*pDraw->pScreen->GetImage)(pDraw,
|
||||||
SrcBox.x1 - pDraw->x - dixScreenOrigins[i].x,
|
SrcBox.x1 - pDraw->x - screenInfo.screens[i]->x,
|
||||||
SrcBox.y1 - pDraw->y - dixScreenOrigins[i].y,
|
SrcBox.y1 - pDraw->y - screenInfo.screens[i]->y,
|
||||||
width, height, format, planemask, data);
|
width, height, format, planemask, data);
|
||||||
break;
|
break;
|
||||||
} else if (inOut == rgnOUT)
|
} else if (inOut == rgnOUT)
|
||||||
|
@ -1203,8 +1203,8 @@ XineramaGetImageData(
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
x = pbox->x1 - pDraw->x - dixScreenOrigins[i].x;
|
x = pbox->x1 - pDraw->x - screenInfo.screens[i]->x;
|
||||||
y = pbox->y1 - pDraw->y - dixScreenOrigins[i].y;
|
y = pbox->y1 - pDraw->y - screenInfo.screens[i]->y;
|
||||||
|
|
||||||
(*pDraw->pScreen->GetImage)(pDraw, x, y, w, h,
|
(*pDraw->pScreen->GetImage)(pDraw, x, y, w, h,
|
||||||
format, planemask, ScratchMem);
|
format, planemask, ScratchMem);
|
||||||
|
|
|
@ -135,8 +135,8 @@ int PanoramiXCreateWindow(ClientPtr client)
|
||||||
stuff->wid = newWin->info[j].id;
|
stuff->wid = newWin->info[j].id;
|
||||||
stuff->parent = parent->info[j].id;
|
stuff->parent = parent->info[j].id;
|
||||||
if (parentIsRoot) {
|
if (parentIsRoot) {
|
||||||
stuff->x = orig_x - dixScreenOrigins[j].x;
|
stuff->x = orig_x - screenInfo.screens[j]->x;
|
||||||
stuff->y = orig_y - dixScreenOrigins[j].y;
|
stuff->y = orig_y - screenInfo.screens[j]->y;
|
||||||
}
|
}
|
||||||
if (backPix)
|
if (backPix)
|
||||||
*((CARD32 *) &stuff[1] + pback_offset) = backPix->info[j].id;
|
*((CARD32 *) &stuff[1] + pback_offset) = backPix->info[j].id;
|
||||||
|
@ -334,8 +334,8 @@ int PanoramiXReparentWindow(ClientPtr client)
|
||||||
stuff->window = win->info[j].id;
|
stuff->window = win->info[j].id;
|
||||||
stuff->parent = parent->info[j].id;
|
stuff->parent = parent->info[j].id;
|
||||||
if(parentIsRoot) {
|
if(parentIsRoot) {
|
||||||
stuff->x = x - dixScreenOrigins[j].x;
|
stuff->x = x - screenInfo.screens[j]->x;
|
||||||
stuff->y = y - dixScreenOrigins[j].y;
|
stuff->y = y - screenInfo.screens[j]->y;
|
||||||
}
|
}
|
||||||
result = (*SavedProcVector[X_ReparentWindow])(client);
|
result = (*SavedProcVector[X_ReparentWindow])(client);
|
||||||
if(result != Success) break;
|
if(result != Success) break;
|
||||||
|
@ -495,9 +495,9 @@ int PanoramiXConfigureWindow(ClientPtr client)
|
||||||
if(sib)
|
if(sib)
|
||||||
*((CARD32 *) &stuff[1] + sib_offset) = sib->info[j].id;
|
*((CARD32 *) &stuff[1] + sib_offset) = sib->info[j].id;
|
||||||
if(x_offset >= 0)
|
if(x_offset >= 0)
|
||||||
*((CARD32 *) &stuff[1] + x_offset) = x - dixScreenOrigins[j].x;
|
*((CARD32 *) &stuff[1] + x_offset) = x - screenInfo.screens[j]->x;
|
||||||
if(y_offset >= 0)
|
if(y_offset >= 0)
|
||||||
*((CARD32 *) &stuff[1] + y_offset) = y - dixScreenOrigins[j].y;
|
*((CARD32 *) &stuff[1] + y_offset) = y - screenInfo.screens[j]->y;
|
||||||
result = (*SavedProcVector[X_ConfigureWindow])(client);
|
result = (*SavedProcVector[X_ConfigureWindow])(client);
|
||||||
if(result != Success) break;
|
if(result != Success) break;
|
||||||
}
|
}
|
||||||
|
@ -565,8 +565,8 @@ int PanoramiXGetGeometry(ClientPtr client)
|
||||||
if((pWin->parent == screenInfo.screens[0]->root) ||
|
if((pWin->parent == screenInfo.screens[0]->root) ||
|
||||||
(pWin->parent->drawable.id == screenInfo.screens[0]->screensaver.wid))
|
(pWin->parent->drawable.id == screenInfo.screens[0]->screensaver.wid))
|
||||||
{
|
{
|
||||||
rep.x += dixScreenOrigins[0].x;
|
rep.x += screenInfo.screens[0]->x;
|
||||||
rep.y += dixScreenOrigins[0].y;
|
rep.y += screenInfo.screens[0]->y;
|
||||||
}
|
}
|
||||||
rep.borderWidth = pWin->borderWidth;
|
rep.borderWidth = pWin->borderWidth;
|
||||||
}
|
}
|
||||||
|
@ -599,8 +599,8 @@ int PanoramiXTranslateCoords(ClientPtr client)
|
||||||
if((pWin == screenInfo.screens[0]->root) ||
|
if((pWin == screenInfo.screens[0]->root) ||
|
||||||
(pWin->drawable.id == screenInfo.screens[0]->screensaver.wid))
|
(pWin->drawable.id == screenInfo.screens[0]->screensaver.wid))
|
||||||
{
|
{
|
||||||
x = stuff->srcX - dixScreenOrigins[0].x;
|
x = stuff->srcX - screenInfo.screens[0]->x;
|
||||||
y = stuff->srcY - dixScreenOrigins[0].y;
|
y = stuff->srcY - screenInfo.screens[0]->y;
|
||||||
} else {
|
} else {
|
||||||
x = pWin->drawable.x + stuff->srcX;
|
x = pWin->drawable.x + stuff->srcX;
|
||||||
y = pWin->drawable.y + stuff->srcY;
|
y = pWin->drawable.y + stuff->srcY;
|
||||||
|
@ -637,8 +637,8 @@ int PanoramiXTranslateCoords(ClientPtr client)
|
||||||
if((pDst == screenInfo.screens[0]->root) ||
|
if((pDst == screenInfo.screens[0]->root) ||
|
||||||
(pWin->drawable.id == screenInfo.screens[0]->screensaver.wid))
|
(pWin->drawable.id == screenInfo.screens[0]->screensaver.wid))
|
||||||
{
|
{
|
||||||
rep.dstX += dixScreenOrigins[0].x;
|
rep.dstX += screenInfo.screens[0]->x;
|
||||||
rep.dstY += dixScreenOrigins[0].y;
|
rep.dstY += screenInfo.screens[0]->y;
|
||||||
}
|
}
|
||||||
|
|
||||||
WriteReplyToClient(client, sizeof(xTranslateCoordsReply), &rep);
|
WriteReplyToClient(client, sizeof(xTranslateCoordsReply), &rep);
|
||||||
|
@ -981,8 +981,8 @@ int PanoramiXClearToBackground(ClientPtr client)
|
||||||
FOR_NSCREENS_BACKWARD(j) {
|
FOR_NSCREENS_BACKWARD(j) {
|
||||||
stuff->window = win->info[j].id;
|
stuff->window = win->info[j].id;
|
||||||
if(isRoot) {
|
if(isRoot) {
|
||||||
stuff->x = x - dixScreenOrigins[j].x;
|
stuff->x = x - screenInfo.screens[j]->x;
|
||||||
stuff->y = y - dixScreenOrigins[j].y;
|
stuff->y = y - screenInfo.screens[j]->y;
|
||||||
}
|
}
|
||||||
result = (*SavedProcVector[X_ClearArea])(client);
|
result = (*SavedProcVector[X_ClearArea])(client);
|
||||||
if(result != Success) break;
|
if(result != Success) break;
|
||||||
|
@ -1092,12 +1092,12 @@ int PanoramiXCopyArea(ClientPtr client)
|
||||||
stuff->srcDrawable = src->info[j].id;
|
stuff->srcDrawable = src->info[j].id;
|
||||||
stuff->gc = gc->info[j].id;
|
stuff->gc = gc->info[j].id;
|
||||||
if (srcIsRoot) {
|
if (srcIsRoot) {
|
||||||
stuff->srcX = srcx - dixScreenOrigins[j].x;
|
stuff->srcX = srcx - screenInfo.screens[j]->x;
|
||||||
stuff->srcY = srcy - dixScreenOrigins[j].y;
|
stuff->srcY = srcy - screenInfo.screens[j]->y;
|
||||||
}
|
}
|
||||||
if (dstIsRoot) {
|
if (dstIsRoot) {
|
||||||
stuff->dstX = dstx - dixScreenOrigins[j].x;
|
stuff->dstX = dstx - screenInfo.screens[j]->x;
|
||||||
stuff->dstY = dsty - dixScreenOrigins[j].y;
|
stuff->dstY = dsty - screenInfo.screens[j]->y;
|
||||||
}
|
}
|
||||||
|
|
||||||
VALIDATE_DRAWABLE_AND_GC(stuff->dstDrawable, pDst, DixWriteAccess);
|
VALIDATE_DRAWABLE_AND_GC(stuff->dstDrawable, pDst, DixWriteAccess);
|
||||||
|
@ -1137,7 +1137,7 @@ int PanoramiXCopyArea(ClientPtr client)
|
||||||
if(pRgn[j]) {
|
if(pRgn[j]) {
|
||||||
if(srcIsRoot) {
|
if(srcIsRoot) {
|
||||||
REGION_TRANSLATE(pScreen, pRgn[j],
|
REGION_TRANSLATE(pScreen, pRgn[j],
|
||||||
dixScreenOrigins[j].x, dixScreenOrigins[j].y);
|
screenInfo.screens[j]->x, screenInfo.screens[j]->y);
|
||||||
}
|
}
|
||||||
REGION_APPEND(pScreen, &totalReg, pRgn[j]);
|
REGION_APPEND(pScreen, &totalReg, pRgn[j]);
|
||||||
REGION_DESTROY(pScreen, pRgn[j]);
|
REGION_DESTROY(pScreen, pRgn[j]);
|
||||||
|
@ -1203,12 +1203,12 @@ int PanoramiXCopyPlane(ClientPtr client)
|
||||||
stuff->srcDrawable = src->info[j].id;
|
stuff->srcDrawable = src->info[j].id;
|
||||||
stuff->gc = gc->info[j].id;
|
stuff->gc = gc->info[j].id;
|
||||||
if (srcIsRoot) {
|
if (srcIsRoot) {
|
||||||
stuff->srcX = srcx - dixScreenOrigins[j].x;
|
stuff->srcX = srcx - screenInfo.screens[j]->x;
|
||||||
stuff->srcY = srcy - dixScreenOrigins[j].y;
|
stuff->srcY = srcy - screenInfo.screens[j]->y;
|
||||||
}
|
}
|
||||||
if (dstIsRoot) {
|
if (dstIsRoot) {
|
||||||
stuff->dstX = dstx - dixScreenOrigins[j].x;
|
stuff->dstX = dstx - screenInfo.screens[j]->x;
|
||||||
stuff->dstY = dsty - dixScreenOrigins[j].y;
|
stuff->dstY = dsty - screenInfo.screens[j]->y;
|
||||||
}
|
}
|
||||||
|
|
||||||
VALIDATE_DRAWABLE_AND_GC(stuff->dstDrawable, pdstDraw, DixWriteAccess);
|
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(j) memcpy(&stuff[1], origPts, npoint * sizeof(xPoint));
|
||||||
|
|
||||||
if (isRoot) {
|
if (isRoot) {
|
||||||
int x_off = dixScreenOrigins[j].x;
|
int x_off = screenInfo.screens[j]->x;
|
||||||
int y_off = dixScreenOrigins[j].y;
|
int y_off = screenInfo.screens[j]->y;
|
||||||
|
|
||||||
if(x_off || y_off) {
|
if(x_off || y_off) {
|
||||||
xPoint *pnts = (xPoint*)&stuff[1];
|
xPoint *pnts = (xPoint*)&stuff[1];
|
||||||
|
@ -1357,8 +1357,8 @@ int PanoramiXPolyLine(ClientPtr client)
|
||||||
if(j) memcpy(&stuff[1], origPts, npoint * sizeof(xPoint));
|
if(j) memcpy(&stuff[1], origPts, npoint * sizeof(xPoint));
|
||||||
|
|
||||||
if (isRoot) {
|
if (isRoot) {
|
||||||
int x_off = dixScreenOrigins[j].x;
|
int x_off = screenInfo.screens[j]->x;
|
||||||
int y_off = dixScreenOrigins[j].y;
|
int y_off = screenInfo.screens[j]->y;
|
||||||
|
|
||||||
if(x_off || y_off) {
|
if(x_off || y_off) {
|
||||||
xPoint *pnts = (xPoint*)&stuff[1];
|
xPoint *pnts = (xPoint*)&stuff[1];
|
||||||
|
@ -1420,8 +1420,8 @@ int PanoramiXPolySegment(ClientPtr client)
|
||||||
if(j) memcpy(&stuff[1], origSegs, nsegs * sizeof(xSegment));
|
if(j) memcpy(&stuff[1], origSegs, nsegs * sizeof(xSegment));
|
||||||
|
|
||||||
if (isRoot) {
|
if (isRoot) {
|
||||||
int x_off = dixScreenOrigins[j].x;
|
int x_off = screenInfo.screens[j]->x;
|
||||||
int y_off = dixScreenOrigins[j].y;
|
int y_off = screenInfo.screens[j]->y;
|
||||||
|
|
||||||
if(x_off || y_off) {
|
if(x_off || y_off) {
|
||||||
xSegment *segs = (xSegment*)&stuff[1];
|
xSegment *segs = (xSegment*)&stuff[1];
|
||||||
|
@ -1483,8 +1483,8 @@ int PanoramiXPolyRectangle(ClientPtr client)
|
||||||
if(j) memcpy(&stuff[1], origRecs, nrects * sizeof(xRectangle));
|
if(j) memcpy(&stuff[1], origRecs, nrects * sizeof(xRectangle));
|
||||||
|
|
||||||
if (isRoot) {
|
if (isRoot) {
|
||||||
int x_off = dixScreenOrigins[j].x;
|
int x_off = screenInfo.screens[j]->x;
|
||||||
int y_off = dixScreenOrigins[j].y;
|
int y_off = screenInfo.screens[j]->y;
|
||||||
|
|
||||||
|
|
||||||
if(x_off || y_off) {
|
if(x_off || y_off) {
|
||||||
|
@ -1545,8 +1545,8 @@ int PanoramiXPolyArc(ClientPtr client)
|
||||||
if(j) memcpy(&stuff[1], origArcs, narcs * sizeof(xArc));
|
if(j) memcpy(&stuff[1], origArcs, narcs * sizeof(xArc));
|
||||||
|
|
||||||
if (isRoot) {
|
if (isRoot) {
|
||||||
int x_off = dixScreenOrigins[j].x;
|
int x_off = screenInfo.screens[j]->x;
|
||||||
int y_off = dixScreenOrigins[j].y;
|
int y_off = screenInfo.screens[j]->y;
|
||||||
|
|
||||||
if(x_off || y_off) {
|
if(x_off || y_off) {
|
||||||
xArc *arcs = (xArc *) &stuff[1];
|
xArc *arcs = (xArc *) &stuff[1];
|
||||||
|
@ -1603,8 +1603,8 @@ int PanoramiXFillPoly(ClientPtr client)
|
||||||
if(j) memcpy(&stuff[1], locPts, count * sizeof(DDXPointRec));
|
if(j) memcpy(&stuff[1], locPts, count * sizeof(DDXPointRec));
|
||||||
|
|
||||||
if (isRoot) {
|
if (isRoot) {
|
||||||
int x_off = dixScreenOrigins[j].x;
|
int x_off = screenInfo.screens[j]->x;
|
||||||
int y_off = dixScreenOrigins[j].y;
|
int y_off = screenInfo.screens[j]->y;
|
||||||
|
|
||||||
if(x_off || y_off) {
|
if(x_off || y_off) {
|
||||||
DDXPointPtr pnts = (DDXPointPtr)&stuff[1];
|
DDXPointPtr pnts = (DDXPointPtr)&stuff[1];
|
||||||
|
@ -1666,8 +1666,8 @@ int PanoramiXPolyFillRectangle(ClientPtr client)
|
||||||
if(j) memcpy(&stuff[1], origRects, things * sizeof(xRectangle));
|
if(j) memcpy(&stuff[1], origRects, things * sizeof(xRectangle));
|
||||||
|
|
||||||
if (isRoot) {
|
if (isRoot) {
|
||||||
int x_off = dixScreenOrigins[j].x;
|
int x_off = screenInfo.screens[j]->x;
|
||||||
int y_off = dixScreenOrigins[j].y;
|
int y_off = screenInfo.screens[j]->y;
|
||||||
|
|
||||||
if(x_off || y_off) {
|
if(x_off || y_off) {
|
||||||
xRectangle *rects = (xRectangle *) &stuff[1];
|
xRectangle *rects = (xRectangle *) &stuff[1];
|
||||||
|
@ -1727,8 +1727,8 @@ int PanoramiXPolyFillArc(ClientPtr client)
|
||||||
if(j) memcpy(&stuff[1], origArcs, narcs * sizeof(xArc));
|
if(j) memcpy(&stuff[1], origArcs, narcs * sizeof(xArc));
|
||||||
|
|
||||||
if (isRoot) {
|
if (isRoot) {
|
||||||
int x_off = dixScreenOrigins[j].x;
|
int x_off = screenInfo.screens[j]->x;
|
||||||
int y_off = dixScreenOrigins[j].y;
|
int y_off = screenInfo.screens[j]->y;
|
||||||
|
|
||||||
if(x_off || y_off) {
|
if(x_off || y_off) {
|
||||||
xArc *arcs = (xArc *) &stuff[1];
|
xArc *arcs = (xArc *) &stuff[1];
|
||||||
|
@ -1780,8 +1780,8 @@ int PanoramiXPutImage(ClientPtr client)
|
||||||
orig_y = stuff->dstY;
|
orig_y = stuff->dstY;
|
||||||
FOR_NSCREENS_BACKWARD(j){
|
FOR_NSCREENS_BACKWARD(j){
|
||||||
if (isRoot) {
|
if (isRoot) {
|
||||||
stuff->dstX = orig_x - dixScreenOrigins[j].x;
|
stuff->dstX = orig_x - screenInfo.screens[j]->x;
|
||||||
stuff->dstY = orig_y - dixScreenOrigins[j].y;
|
stuff->dstY = orig_y - screenInfo.screens[j]->y;
|
||||||
}
|
}
|
||||||
stuff->drawable = draw->info[j].id;
|
stuff->drawable = draw->info[j].id;
|
||||||
stuff->gc = gc->info[j].id;
|
stuff->gc = gc->info[j].id;
|
||||||
|
@ -1846,10 +1846,10 @@ int PanoramiXGetImage(ClientPtr client)
|
||||||
return(BadMatch);
|
return(BadMatch);
|
||||||
} else {
|
} else {
|
||||||
if( /* check for being onscreen */
|
if( /* check for being onscreen */
|
||||||
dixScreenOrigins[0].x + pDraw->x + x < 0 ||
|
screenInfo.screens[0]->x + pDraw->x + x < 0 ||
|
||||||
dixScreenOrigins[0].x + pDraw->x + x + w > PanoramiXPixWidth ||
|
screenInfo.screens[0]->x + pDraw->x + x + w > PanoramiXPixWidth ||
|
||||||
dixScreenOrigins[0].y + pDraw->y + y < 0 ||
|
screenInfo.screens[0]->y + pDraw->y + y < 0 ||
|
||||||
dixScreenOrigins[0].y + pDraw->y + y + h > PanoramiXPixHeight ||
|
screenInfo.screens[0]->y + pDraw->y + y + h > PanoramiXPixHeight ||
|
||||||
/* check for being inside of border */
|
/* check for being inside of border */
|
||||||
x < - wBorderWidth((WindowPtr)pDraw) ||
|
x < - wBorderWidth((WindowPtr)pDraw) ||
|
||||||
x + w > wBorderWidth((WindowPtr)pDraw) + (int)pDraw->width ||
|
x + w > wBorderWidth((WindowPtr)pDraw) + (int)pDraw->width ||
|
||||||
|
@ -1983,8 +1983,8 @@ PanoramiXPolyText8(ClientPtr client)
|
||||||
stuff->drawable = draw->info[j].id;
|
stuff->drawable = draw->info[j].id;
|
||||||
stuff->gc = gc->info[j].id;
|
stuff->gc = gc->info[j].id;
|
||||||
if (isRoot) {
|
if (isRoot) {
|
||||||
stuff->x = orig_x - dixScreenOrigins[j].x;
|
stuff->x = orig_x - screenInfo.screens[j]->x;
|
||||||
stuff->y = orig_y - dixScreenOrigins[j].y;
|
stuff->y = orig_y - screenInfo.screens[j]->y;
|
||||||
}
|
}
|
||||||
result = (*SavedProcVector[X_PolyText8])(client);
|
result = (*SavedProcVector[X_PolyText8])(client);
|
||||||
if(result != Success) break;
|
if(result != Success) break;
|
||||||
|
@ -2024,8 +2024,8 @@ PanoramiXPolyText16(ClientPtr client)
|
||||||
stuff->drawable = draw->info[j].id;
|
stuff->drawable = draw->info[j].id;
|
||||||
stuff->gc = gc->info[j].id;
|
stuff->gc = gc->info[j].id;
|
||||||
if (isRoot) {
|
if (isRoot) {
|
||||||
stuff->x = orig_x - dixScreenOrigins[j].x;
|
stuff->x = orig_x - screenInfo.screens[j]->x;
|
||||||
stuff->y = orig_y - dixScreenOrigins[j].y;
|
stuff->y = orig_y - screenInfo.screens[j]->y;
|
||||||
}
|
}
|
||||||
result = (*SavedProcVector[X_PolyText16])(client);
|
result = (*SavedProcVector[X_PolyText16])(client);
|
||||||
if(result != Success) break;
|
if(result != Success) break;
|
||||||
|
@ -2065,8 +2065,8 @@ int PanoramiXImageText8(ClientPtr client)
|
||||||
stuff->drawable = draw->info[j].id;
|
stuff->drawable = draw->info[j].id;
|
||||||
stuff->gc = gc->info[j].id;
|
stuff->gc = gc->info[j].id;
|
||||||
if (isRoot) {
|
if (isRoot) {
|
||||||
stuff->x = orig_x - dixScreenOrigins[j].x;
|
stuff->x = orig_x - screenInfo.screens[j]->x;
|
||||||
stuff->y = orig_y - dixScreenOrigins[j].y;
|
stuff->y = orig_y - screenInfo.screens[j]->y;
|
||||||
}
|
}
|
||||||
result = (*SavedProcVector[X_ImageText8])(client);
|
result = (*SavedProcVector[X_ImageText8])(client);
|
||||||
if(result != Success) break;
|
if(result != Success) break;
|
||||||
|
@ -2106,8 +2106,8 @@ int PanoramiXImageText16(ClientPtr client)
|
||||||
stuff->drawable = draw->info[j].id;
|
stuff->drawable = draw->info[j].id;
|
||||||
stuff->gc = gc->info[j].id;
|
stuff->gc = gc->info[j].id;
|
||||||
if (isRoot) {
|
if (isRoot) {
|
||||||
stuff->x = orig_x - dixScreenOrigins[j].x;
|
stuff->x = orig_x - screenInfo.screens[j]->x;
|
||||||
stuff->y = orig_y - dixScreenOrigins[j].y;
|
stuff->y = orig_y - screenInfo.screens[j]->y;
|
||||||
}
|
}
|
||||||
result = (*SavedProcVector[X_ImageText16])(client);
|
result = (*SavedProcVector[X_ImageText16])(client);
|
||||||
if(result != Success) break;
|
if(result != Success) break;
|
||||||
|
|
12
Xext/shm.c
12
Xext/shm.c
|
@ -598,8 +598,8 @@ ProcPanoramiXShmPutImage(ClientPtr client)
|
||||||
stuff->drawable = draw->info[j].id;
|
stuff->drawable = draw->info[j].id;
|
||||||
stuff->gc = gc->info[j].id;
|
stuff->gc = gc->info[j].id;
|
||||||
if (isRoot) {
|
if (isRoot) {
|
||||||
stuff->dstX = orig_x - dixScreenOrigins[j].x;
|
stuff->dstX = orig_x - screenInfo.screens[j]->x;
|
||||||
stuff->dstY = orig_y - dixScreenOrigins[j].y;
|
stuff->dstY = orig_y - screenInfo.screens[j]->y;
|
||||||
}
|
}
|
||||||
result = ProcShmPutImage(client);
|
result = ProcShmPutImage(client);
|
||||||
if(result != Success) break;
|
if(result != Success) break;
|
||||||
|
@ -660,10 +660,10 @@ ProcPanoramiXShmGetImage(ClientPtr client)
|
||||||
return(BadMatch);
|
return(BadMatch);
|
||||||
} else {
|
} else {
|
||||||
if( /* check for being onscreen */
|
if( /* check for being onscreen */
|
||||||
dixScreenOrigins[0].x + pDraw->x + x < 0 ||
|
screenInfo.screens[0]->x + pDraw->x + x < 0 ||
|
||||||
dixScreenOrigins[0].x + pDraw->x + x + w > PanoramiXPixWidth ||
|
screenInfo.screens[0]->x + pDraw->x + x + w > PanoramiXPixWidth ||
|
||||||
dixScreenOrigins[0].y + pDraw->y + y < 0 ||
|
screenInfo.screens[0]->y + pDraw->y + y < 0 ||
|
||||||
dixScreenOrigins[0].y + pDraw->y + y + h > PanoramiXPixHeight ||
|
screenInfo.screens[0]->y + pDraw->y + y + h > PanoramiXPixHeight ||
|
||||||
/* check for being inside of border */
|
/* check for being inside of border */
|
||||||
x < - wBorderWidth((WindowPtr)pDraw) ||
|
x < - wBorderWidth((WindowPtr)pDraw) ||
|
||||||
x + w > wBorderWidth((WindowPtr)pDraw) + (int)pDraw->width ||
|
x + w > wBorderWidth((WindowPtr)pDraw) + (int)pDraw->width ||
|
||||||
|
|
|
@ -1690,8 +1690,8 @@ XineramaXvShmPutImage(ClientPtr client)
|
||||||
stuff->drw_x = x;
|
stuff->drw_x = x;
|
||||||
stuff->drw_y = y;
|
stuff->drw_y = y;
|
||||||
if(isRoot) {
|
if(isRoot) {
|
||||||
stuff->drw_x -= dixScreenOrigins[i].x;
|
stuff->drw_x -= screenInfo.screens[i]->x;
|
||||||
stuff->drw_y -= dixScreenOrigins[i].y;
|
stuff->drw_y -= screenInfo.screens[i]->y;
|
||||||
}
|
}
|
||||||
stuff->send_event = (send_event && !i) ? 1 : 0;
|
stuff->send_event = (send_event && !i) ? 1 : 0;
|
||||||
|
|
||||||
|
@ -1742,8 +1742,8 @@ XineramaXvPutImage(ClientPtr client)
|
||||||
stuff->drw_x = x;
|
stuff->drw_x = x;
|
||||||
stuff->drw_y = y;
|
stuff->drw_y = y;
|
||||||
if(isRoot) {
|
if(isRoot) {
|
||||||
stuff->drw_x -= dixScreenOrigins[i].x;
|
stuff->drw_x -= screenInfo.screens[i]->x;
|
||||||
stuff->drw_y -= dixScreenOrigins[i].y;
|
stuff->drw_y -= screenInfo.screens[i]->y;
|
||||||
}
|
}
|
||||||
|
|
||||||
result = ProcXvPutImage(client);
|
result = ProcXvPutImage(client);
|
||||||
|
@ -1790,8 +1790,8 @@ XineramaXvPutVideo(ClientPtr client)
|
||||||
stuff->drw_x = x;
|
stuff->drw_x = x;
|
||||||
stuff->drw_y = y;
|
stuff->drw_y = y;
|
||||||
if(isRoot) {
|
if(isRoot) {
|
||||||
stuff->drw_x -= dixScreenOrigins[i].x;
|
stuff->drw_x -= screenInfo.screens[i]->x;
|
||||||
stuff->drw_y -= dixScreenOrigins[i].y;
|
stuff->drw_y -= screenInfo.screens[i]->y;
|
||||||
}
|
}
|
||||||
|
|
||||||
result = ProcXvPutVideo(client);
|
result = ProcXvPutVideo(client);
|
||||||
|
@ -1838,8 +1838,8 @@ XineramaXvPutStill(ClientPtr client)
|
||||||
stuff->drw_x = x;
|
stuff->drw_x = x;
|
||||||
stuff->drw_y = y;
|
stuff->drw_y = y;
|
||||||
if(isRoot) {
|
if(isRoot) {
|
||||||
stuff->drw_x -= dixScreenOrigins[i].x;
|
stuff->drw_x -= screenInfo.screens[i]->x;
|
||||||
stuff->drw_y -= dixScreenOrigins[i].y;
|
stuff->drw_y -= screenInfo.screens[i]->y;
|
||||||
}
|
}
|
||||||
|
|
||||||
result = ProcXvPutStill(client);
|
result = ProcXvPutStill(client);
|
||||||
|
|
|
@ -43,6 +43,7 @@
|
||||||
#include "exevents.h"
|
#include "exevents.h"
|
||||||
#include "exglobals.h"
|
#include "exglobals.h"
|
||||||
#include "eventconvert.h"
|
#include "eventconvert.h"
|
||||||
|
#include "scrnintstr.h"
|
||||||
#include "xkbsrv.h"
|
#include "xkbsrv.h"
|
||||||
|
|
||||||
#ifdef PANORAMIX
|
#ifdef PANORAMIX
|
||||||
|
@ -181,12 +182,12 @@ ProcXIQueryPointer(ClientPtr client)
|
||||||
|
|
||||||
#ifdef PANORAMIX
|
#ifdef PANORAMIX
|
||||||
if(!noPanoramiXExtension) {
|
if(!noPanoramiXExtension) {
|
||||||
rep.root_x += FP1616(dixScreenOrigins[0].x, 0);
|
rep.root_x += FP1616(screenInfo.screens[0]->x, 0);
|
||||||
rep.root_y += FP1616(dixScreenOrigins[0].y, 0);
|
rep.root_y += FP1616(screenInfo.screens[0]->y, 0);
|
||||||
if (stuff->win == rep.root)
|
if (stuff->win == rep.root)
|
||||||
{
|
{
|
||||||
rep.win_x += FP1616(dixScreenOrigins[0].x, 0);
|
rep.win_x += FP1616(screenInfo.screens[0]->x, 0);
|
||||||
rep.win_y += FP1616(dixScreenOrigins[0].y, 0);
|
rep.win_y += FP1616(screenInfo.screens[0]->y, 0);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
132
dix/events.c
132
dix/events.c
|
@ -502,8 +502,8 @@ XineramaSetCursorPosition(
|
||||||
that screen are. */
|
that screen are. */
|
||||||
|
|
||||||
pScreen = pSprite->screen;
|
pScreen = pSprite->screen;
|
||||||
x += dixScreenOrigins[0].x;
|
x += screenInfo.screens[0]->x;
|
||||||
y += dixScreenOrigins[0].y;
|
y += screenInfo.screens[0]->y;
|
||||||
|
|
||||||
if(!POINT_IN_REGION(pScreen, &XineramaScreenRegions[pScreen->myNum],
|
if(!POINT_IN_REGION(pScreen, &XineramaScreenRegions[pScreen->myNum],
|
||||||
x, y, &box))
|
x, y, &box))
|
||||||
|
@ -521,10 +521,10 @@ XineramaSetCursorPosition(
|
||||||
}
|
}
|
||||||
|
|
||||||
pSprite->screen = pScreen;
|
pSprite->screen = pScreen;
|
||||||
pSprite->hotPhys.x = x - dixScreenOrigins[0].x;
|
pSprite->hotPhys.x = x - screenInfo.screens[0]->x;
|
||||||
pSprite->hotPhys.y = y - dixScreenOrigins[0].y;
|
pSprite->hotPhys.y = y - screenInfo.screens[0]->y;
|
||||||
x -= dixScreenOrigins[pScreen->myNum].x;
|
x -= pScreen->x;
|
||||||
y -= dixScreenOrigins[pScreen->myNum].y;
|
y -= pScreen->y;
|
||||||
|
|
||||||
return (*pScreen->SetCursorPosition)(pDev, pScreen, x, y, generateEvent);
|
return (*pScreen->SetCursorPosition)(pDev, pScreen, x, y, generateEvent);
|
||||||
}
|
}
|
||||||
|
@ -542,10 +542,10 @@ XineramaConstrainCursor(DeviceIntPtr pDev)
|
||||||
|
|
||||||
/* Translate the constraining box to the screen
|
/* Translate the constraining box to the screen
|
||||||
the sprite is actually on */
|
the sprite is actually on */
|
||||||
newBox.x1 += dixScreenOrigins[0].x - dixScreenOrigins[pScreen->myNum].x;
|
newBox.x1 += screenInfo.screens[0]->x - pScreen->x;
|
||||||
newBox.x2 += dixScreenOrigins[0].x - dixScreenOrigins[pScreen->myNum].x;
|
newBox.x2 += screenInfo.screens[0]->x - pScreen->x;
|
||||||
newBox.y1 += dixScreenOrigins[0].y - dixScreenOrigins[pScreen->myNum].y;
|
newBox.y1 += screenInfo.screens[0]->y - pScreen->y;
|
||||||
newBox.y2 += dixScreenOrigins[0].y - dixScreenOrigins[pScreen->myNum].y;
|
newBox.y2 += screenInfo.screens[0]->y - pScreen->y;
|
||||||
|
|
||||||
(* pScreen->ConstrainCursor)(pDev, pScreen, &newBox);
|
(* pScreen->ConstrainCursor)(pDev, pScreen, &newBox);
|
||||||
}
|
}
|
||||||
|
@ -595,12 +595,12 @@ XineramaConfineCursorToWindow(DeviceIntPtr pDev,
|
||||||
|
|
||||||
REGION_COPY(pSprite->screen, &pSprite->Reg1,
|
REGION_COPY(pSprite->screen, &pSprite->Reg1,
|
||||||
&pSprite->windows[i]->borderSize);
|
&pSprite->windows[i]->borderSize);
|
||||||
off_x = dixScreenOrigins[i].x;
|
off_x = screenInfo.screens[i]->x;
|
||||||
off_y = dixScreenOrigins[i].y;
|
off_y = screenInfo.screens[i]->y;
|
||||||
|
|
||||||
while(i--) {
|
while(i--) {
|
||||||
x = off_x - dixScreenOrigins[i].x;
|
x = off_x - screenInfo.screens[i]->x;
|
||||||
y = off_y - dixScreenOrigins[i].y;
|
y = off_y - screenInfo.screens[i]->y;
|
||||||
|
|
||||||
if(x || y)
|
if(x || y)
|
||||||
REGION_TRANSLATE(pSprite->screen, &pSprite->Reg1, 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,
|
REGION_UNION(pSprite->screen, &pSprite->Reg1, &pSprite->Reg1,
|
||||||
&pSprite->windows[i]->borderSize);
|
&pSprite->windows[i]->borderSize);
|
||||||
|
|
||||||
off_x = dixScreenOrigins[i].x;
|
off_x = screenInfo.screens[i]->x;
|
||||||
off_y = dixScreenOrigins[i].y;
|
off_y = screenInfo.screens[i]->y;
|
||||||
}
|
}
|
||||||
|
|
||||||
pSprite->hotLimits = *REGION_EXTENTS(pSprite->screen, &pSprite->Reg1);
|
pSprite->hotLimits = *REGION_EXTENTS(pSprite->screen, &pSprite->Reg1);
|
||||||
|
@ -814,12 +814,12 @@ CheckVirtualMotion(
|
||||||
|
|
||||||
REGION_COPY(pSprite->screen, &pSprite->Reg2,
|
REGION_COPY(pSprite->screen, &pSprite->Reg2,
|
||||||
&pSprite->windows[i]->borderSize);
|
&pSprite->windows[i]->borderSize);
|
||||||
off_x = dixScreenOrigins[i].x;
|
off_x = screenInfo.screens[i]->x;
|
||||||
off_y = dixScreenOrigins[i].y;
|
off_y = screenInfo.screens[i]->y;
|
||||||
|
|
||||||
while(i--) {
|
while(i--) {
|
||||||
x = off_x - dixScreenOrigins[i].x;
|
x = off_x - screenInfo.screens[i]->x;
|
||||||
y = off_y - dixScreenOrigins[i].y;
|
y = off_y - screenInfo.screens[i]->y;
|
||||||
|
|
||||||
if(x || y)
|
if(x || y)
|
||||||
REGION_TRANSLATE(pSprite->screen, &pSprite->Reg2, x, y);
|
REGION_TRANSLATE(pSprite->screen, &pSprite->Reg2, x, y);
|
||||||
|
@ -827,8 +827,8 @@ CheckVirtualMotion(
|
||||||
REGION_UNION(pSprite->screen, &pSprite->Reg2, &pSprite->Reg2,
|
REGION_UNION(pSprite->screen, &pSprite->Reg2, &pSprite->Reg2,
|
||||||
&pSprite->windows[i]->borderSize);
|
&pSprite->windows[i]->borderSize);
|
||||||
|
|
||||||
off_x = dixScreenOrigins[i].x;
|
off_x = screenInfo.screens[i]->x;
|
||||||
off_y = dixScreenOrigins[i].y;
|
off_y = screenInfo.screens[i]->y;
|
||||||
}
|
}
|
||||||
} else
|
} else
|
||||||
#endif
|
#endif
|
||||||
|
@ -1135,10 +1135,8 @@ EnqueueEvent(InternalEvent *ev, DeviceIntPtr device)
|
||||||
{
|
{
|
||||||
#ifdef PANORAMIX
|
#ifdef PANORAMIX
|
||||||
if(!noPanoramiXExtension) {
|
if(!noPanoramiXExtension) {
|
||||||
event->root_x += dixScreenOrigins[pSprite->screen->myNum].x -
|
event->root_x += pSprite->screen->x - screenInfo.screens[0]->x;
|
||||||
dixScreenOrigins[0].x;
|
event->root_y += pSprite->screen->y - screenInfo.screens[0]->y;
|
||||||
event->root_y += dixScreenOrigins[pSprite->screen->myNum].y -
|
|
||||||
dixScreenOrigins[0].y;
|
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
pSprite->hotPhys.x = event->root_x;
|
pSprite->hotPhys.x = event->root_x;
|
||||||
|
@ -1218,10 +1216,10 @@ PlayReleasedEvents(void)
|
||||||
case ET_KeyRelease:
|
case ET_KeyRelease:
|
||||||
case ET_ProximityIn:
|
case ET_ProximityIn:
|
||||||
case ET_ProximityOut:
|
case ET_ProximityOut:
|
||||||
ev->root_x += dixScreenOrigins[0].x -
|
ev->root_x += screenInfo.screens[0]->x -
|
||||||
dixScreenOrigins[pDev->spriteInfo->sprite->screen->myNum].x;
|
pDev->spriteInfo->sprite->screen->x;
|
||||||
ev->root_y += dixScreenOrigins[0].y -
|
ev->root_y += screenInfo.screens[0]->y -
|
||||||
dixScreenOrigins[pDev->spriteInfo->sprite->screen->myNum].y;
|
pDev->spriteInfo->sprite->screen->y;
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
break;
|
break;
|
||||||
|
@ -2561,8 +2559,8 @@ PointInBorderSize(WindowPtr pWin, int x, int y)
|
||||||
for(i = 1; i < PanoramiXNumScreens; i++) {
|
for(i = 1; i < PanoramiXNumScreens; i++) {
|
||||||
if(POINT_IN_REGION(pSprite->screen,
|
if(POINT_IN_REGION(pSprite->screen,
|
||||||
&pSprite->windows[i]->borderSize,
|
&pSprite->windows[i]->borderSize,
|
||||||
x + dixScreenOrigins[0].x - dixScreenOrigins[i].x,
|
x + screenInfo.screens[0]->x - screenInfo.screens[i]->x,
|
||||||
y + dixScreenOrigins[0].y - dixScreenOrigins[i].y,
|
y + screenInfo.screens[0]->y - screenInfo.screens[i]->y,
|
||||||
&box))
|
&box))
|
||||||
return TRUE;
|
return TRUE;
|
||||||
}
|
}
|
||||||
|
@ -2757,10 +2755,8 @@ CheckMotion(DeviceEvent *ev, DeviceIntPtr pDev)
|
||||||
/* Motion events entering DIX get translated to Screen 0
|
/* Motion events entering DIX get translated to Screen 0
|
||||||
coordinates. Replayed events have already been
|
coordinates. Replayed events have already been
|
||||||
translated since they've entered DIX before */
|
translated since they've entered DIX before */
|
||||||
ev->root_x += dixScreenOrigins[pSprite->screen->myNum].x -
|
ev->root_x += pSprite->screen->x - screenInfo.screens[0]->x;
|
||||||
dixScreenOrigins[0].x;
|
ev->root_y += pSprite->screen->y - screenInfo.screens[0]->y;
|
||||||
ev->root_y += dixScreenOrigins[pSprite->screen->myNum].y -
|
|
||||||
dixScreenOrigins[0].y;
|
|
||||||
} else
|
} else
|
||||||
#endif
|
#endif
|
||||||
{
|
{
|
||||||
|
@ -3008,10 +3004,10 @@ InitializeSprite(DeviceIntPtr pDev, WindowPtr pWin)
|
||||||
}
|
}
|
||||||
#ifdef PANORAMIX
|
#ifdef PANORAMIX
|
||||||
if(!noPanoramiXExtension) {
|
if(!noPanoramiXExtension) {
|
||||||
pSprite->hotLimits.x1 = -dixScreenOrigins[0].x;
|
pSprite->hotLimits.x1 = -screenInfo.screens[0]->x;
|
||||||
pSprite->hotLimits.y1 = -dixScreenOrigins[0].y;
|
pSprite->hotLimits.y1 = -screenInfo.screens[0]->y;
|
||||||
pSprite->hotLimits.x2 = PanoramiXPixWidth - dixScreenOrigins[0].x;
|
pSprite->hotLimits.x2 = PanoramiXPixWidth - screenInfo.screens[0]->x;
|
||||||
pSprite->hotLimits.y2 = PanoramiXPixHeight - dixScreenOrigins[0].y;
|
pSprite->hotLimits.y2 = PanoramiXPixHeight - screenInfo.screens[0]->y;
|
||||||
pSprite->physLimits = pSprite->hotLimits;
|
pSprite->physLimits = pSprite->hotLimits;
|
||||||
pSprite->confineWin = NullWindow;
|
pSprite->confineWin = NullWindow;
|
||||||
pSprite->hotShape = NullRegion;
|
pSprite->hotShape = NullRegion;
|
||||||
|
@ -3078,10 +3074,10 @@ UpdateSpriteForScreen(DeviceIntPtr pDev, ScreenPtr pScreen)
|
||||||
|
|
||||||
#ifdef PANORAMIX
|
#ifdef PANORAMIX
|
||||||
if(!noPanoramiXExtension) {
|
if(!noPanoramiXExtension) {
|
||||||
pSprite->hotLimits.x1 = -dixScreenOrigins[0].x;
|
pSprite->hotLimits.x1 = -screenInfo.screens[0]->x;
|
||||||
pSprite->hotLimits.y1 = -dixScreenOrigins[0].y;
|
pSprite->hotLimits.y1 = -screenInfo.screens[0]->y;
|
||||||
pSprite->hotLimits.x2 = PanoramiXPixWidth - dixScreenOrigins[0].x;
|
pSprite->hotLimits.x2 = PanoramiXPixWidth - screenInfo.screens[0]->x;
|
||||||
pSprite->hotLimits.y2 = PanoramiXPixHeight - dixScreenOrigins[0].y;
|
pSprite->hotLimits.y2 = PanoramiXPixHeight - screenInfo.screens[0]->y;
|
||||||
pSprite->physLimits = pSprite->hotLimits;
|
pSprite->physLimits = pSprite->hotLimits;
|
||||||
pSprite->screen = pScreen;
|
pSprite->screen = pScreen;
|
||||||
}
|
}
|
||||||
|
@ -3114,10 +3110,8 @@ NewCurrentScreen(DeviceIntPtr pDev, ScreenPtr newScreen, int x, int y)
|
||||||
pSprite->hotPhys.y = y;
|
pSprite->hotPhys.y = y;
|
||||||
#ifdef PANORAMIX
|
#ifdef PANORAMIX
|
||||||
if(!noPanoramiXExtension) {
|
if(!noPanoramiXExtension) {
|
||||||
pSprite->hotPhys.x += dixScreenOrigins[newScreen->myNum].x -
|
pSprite->hotPhys.x += newScreen->x - screenInfo.screens[0]->x;
|
||||||
dixScreenOrigins[0].x;
|
pSprite->hotPhys.y += newScreen->y - screenInfo.screens[0]->y;
|
||||||
pSprite->hotPhys.y += dixScreenOrigins[newScreen->myNum].y -
|
|
||||||
dixScreenOrigins[0].y;
|
|
||||||
if (newScreen != pSprite->screen) {
|
if (newScreen != pSprite->screen) {
|
||||||
pSprite->screen = newScreen;
|
pSprite->screen = newScreen;
|
||||||
/* Make sure we tell the DDX to update its copy of the screen */
|
/* Make sure we tell the DDX to update its copy of the screen */
|
||||||
|
@ -3132,10 +3126,10 @@ NewCurrentScreen(DeviceIntPtr pDev, ScreenPtr newScreen, int x, int y)
|
||||||
(*pSprite->screen->SetCursorPosition)(
|
(*pSprite->screen->SetCursorPosition)(
|
||||||
pDev,
|
pDev,
|
||||||
pSprite->screen,
|
pSprite->screen,
|
||||||
pSprite->hotPhys.x + dixScreenOrigins[0].x -
|
pSprite->hotPhys.x + screenInfo.screens[0]->x -
|
||||||
dixScreenOrigins[pSprite->screen->myNum].x,
|
pSprite->screen->x,
|
||||||
pSprite->hotPhys.y + dixScreenOrigins[0].y -
|
pSprite->hotPhys.y + screenInfo.screens[0]->y -
|
||||||
dixScreenOrigins[pSprite->screen->myNum].y, FALSE);
|
pSprite->screen->y, FALSE);
|
||||||
}
|
}
|
||||||
} else
|
} else
|
||||||
#endif
|
#endif
|
||||||
|
@ -3163,14 +3157,14 @@ XineramaPointInWindowIsVisible(
|
||||||
|
|
||||||
if(!XineramaSetWindowPntrs(inputInfo.pointer, pWin)) return FALSE;
|
if(!XineramaSetWindowPntrs(inputInfo.pointer, pWin)) return FALSE;
|
||||||
|
|
||||||
xoff = x + dixScreenOrigins[0].x;
|
xoff = x + screenInfo.screens[0]->x;
|
||||||
yoff = y + dixScreenOrigins[0].y;
|
yoff = y + screenInfo.screens[0]->y;
|
||||||
|
|
||||||
for(i = 1; i < PanoramiXNumScreens; i++) {
|
for(i = 1; i < PanoramiXNumScreens; i++) {
|
||||||
pWin = inputInfo.pointer->spriteInfo->sprite->windows[i];
|
pWin = inputInfo.pointer->spriteInfo->sprite->windows[i];
|
||||||
pScreen = pWin->drawable.pScreen;
|
pScreen = pWin->drawable.pScreen;
|
||||||
x = xoff - dixScreenOrigins[i].x;
|
x = xoff - screenInfo.screens[i]->x;
|
||||||
y = yoff - dixScreenOrigins[i].y;
|
y = yoff - screenInfo.screens[i]->y;
|
||||||
|
|
||||||
if(POINT_IN_REGION(pScreen, &pWin->borderClip, x, y, &box)
|
if(POINT_IN_REGION(pScreen, &pWin->borderClip, x, y, &box)
|
||||||
&& (!wInputShape(pWin) ||
|
&& (!wInputShape(pWin) ||
|
||||||
|
@ -3216,8 +3210,8 @@ XineramaWarpPointer(ClientPtr client)
|
||||||
winX = source->drawable.x;
|
winX = source->drawable.x;
|
||||||
winY = source->drawable.y;
|
winY = source->drawable.y;
|
||||||
if(source == screenInfo.screens[0]->root) {
|
if(source == screenInfo.screens[0]->root) {
|
||||||
winX -= dixScreenOrigins[0].x;
|
winX -= screenInfo.screens[0]->x;
|
||||||
winY -= dixScreenOrigins[0].y;
|
winY -= screenInfo.screens[0]->y;
|
||||||
}
|
}
|
||||||
if (x < winX + stuff->srcX ||
|
if (x < winX + stuff->srcX ||
|
||||||
y < winY + stuff->srcY ||
|
y < winY + stuff->srcY ||
|
||||||
|
@ -3232,8 +3226,8 @@ XineramaWarpPointer(ClientPtr client)
|
||||||
x = dest->drawable.x;
|
x = dest->drawable.x;
|
||||||
y = dest->drawable.y;
|
y = dest->drawable.y;
|
||||||
if(dest == screenInfo.screens[0]->root) {
|
if(dest == screenInfo.screens[0]->root) {
|
||||||
x -= dixScreenOrigins[0].x;
|
x -= screenInfo.screens[0]->x;
|
||||||
y -= dixScreenOrigins[0].y;
|
y -= screenInfo.screens[0]->y;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -4997,11 +4991,11 @@ ProcQueryPointer(ClientPtr client)
|
||||||
|
|
||||||
#ifdef PANORAMIX
|
#ifdef PANORAMIX
|
||||||
if(!noPanoramiXExtension) {
|
if(!noPanoramiXExtension) {
|
||||||
rep.rootX += dixScreenOrigins[0].x;
|
rep.rootX += screenInfo.screens[0]->x;
|
||||||
rep.rootY += dixScreenOrigins[0].y;
|
rep.rootY += screenInfo.screens[0]->y;
|
||||||
if(stuff->id == rep.root) {
|
if(stuff->id == rep.root) {
|
||||||
rep.winX += dixScreenOrigins[0].x;
|
rep.winX += screenInfo.screens[0]->x;
|
||||||
rep.winY += dixScreenOrigins[0].y;
|
rep.winY += screenInfo.screens[0]->y;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
@ -5670,7 +5664,7 @@ WriteEventsToClient(ClientPtr pClient, int count, xEvent *events)
|
||||||
|
|
||||||
#ifdef PANORAMIX
|
#ifdef PANORAMIX
|
||||||
if(!noPanoramiXExtension &&
|
if(!noPanoramiXExtension &&
|
||||||
(dixScreenOrigins[0].x || dixScreenOrigins[0].y))
|
(screenInfo.screens[0]->x || screenInfo.screens[0]->y))
|
||||||
{
|
{
|
||||||
switch(events->u.u.type) {
|
switch(events->u.u.type) {
|
||||||
case MotionNotify:
|
case MotionNotify:
|
||||||
|
@ -5687,13 +5681,13 @@ WriteEventsToClient(ClientPtr pClient, int count, xEvent *events)
|
||||||
*/
|
*/
|
||||||
count = 1; /* should always be 1 */
|
count = 1; /* should always be 1 */
|
||||||
memcpy(&eventCopy, events, sizeof(xEvent));
|
memcpy(&eventCopy, events, sizeof(xEvent));
|
||||||
eventCopy.u.keyButtonPointer.rootX += dixScreenOrigins[0].x;
|
eventCopy.u.keyButtonPointer.rootX += screenInfo.screens[0]->x;
|
||||||
eventCopy.u.keyButtonPointer.rootY += dixScreenOrigins[0].y;
|
eventCopy.u.keyButtonPointer.rootY += screenInfo.screens[0]->y;
|
||||||
if(eventCopy.u.keyButtonPointer.event ==
|
if(eventCopy.u.keyButtonPointer.event ==
|
||||||
eventCopy.u.keyButtonPointer.root)
|
eventCopy.u.keyButtonPointer.root)
|
||||||
{
|
{
|
||||||
eventCopy.u.keyButtonPointer.eventX += dixScreenOrigins[0].x;
|
eventCopy.u.keyButtonPointer.eventX += screenInfo.screens[0]->x;
|
||||||
eventCopy.u.keyButtonPointer.eventY += dixScreenOrigins[0].y;
|
eventCopy.u.keyButtonPointer.eventY += screenInfo.screens[0]->y;
|
||||||
}
|
}
|
||||||
events = &eventCopy;
|
events = &eventCopy;
|
||||||
break;
|
break;
|
||||||
|
|
|
@ -1210,8 +1210,8 @@ PostSyntheticMotion(DeviceIntPtr pDev,
|
||||||
will translate from sprite screen to screen 0 upon reentry
|
will translate from sprite screen to screen 0 upon reentry
|
||||||
to the DIX layer. */
|
to the DIX layer. */
|
||||||
if (!noPanoramiXExtension) {
|
if (!noPanoramiXExtension) {
|
||||||
x += dixScreenOrigins[0].x - dixScreenOrigins[screen].x;
|
x += screenInfo.screens[0]->x - screenInfo.screens[screen]->x;
|
||||||
y += dixScreenOrigins[0].y - dixScreenOrigins[screen].y;
|
y += screenInfo.screens[0]->y - screenInfo.screens[screen]->y;
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
|
@ -135,5 +135,3 @@ char *display;
|
||||||
char *ConnectionInfo;
|
char *ConnectionInfo;
|
||||||
|
|
||||||
CARD32 TimeOutValue = DEFAULT_TIMEOUT * MILLI_PER_SECOND;
|
CARD32 TimeOutValue = DEFAULT_TIMEOUT * MILLI_PER_SECOND;
|
||||||
|
|
||||||
DDXPointRec dixScreenOrigins[MAXSCREENS];
|
|
||||||
|
|
12
dix/window.c
12
dix/window.c
|
@ -2236,8 +2236,8 @@ ConfigureWindow(WindowPtr pWin, Mask mask, XID *vlist, ClientPtr client)
|
||||||
event.u.configureRequest.y = y;
|
event.u.configureRequest.y = y;
|
||||||
#ifdef PANORAMIX
|
#ifdef PANORAMIX
|
||||||
if(!noPanoramiXExtension && (!pParent || !pParent->parent)) {
|
if(!noPanoramiXExtension && (!pParent || !pParent->parent)) {
|
||||||
event.u.configureRequest.x += dixScreenOrigins[0].x;
|
event.u.configureRequest.x += screenInfo.screens[0]->x;
|
||||||
event.u.configureRequest.y += dixScreenOrigins[0].y;
|
event.u.configureRequest.y += screenInfo.screens[0]->y;
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
event.u.configureRequest.width = w;
|
event.u.configureRequest.width = w;
|
||||||
|
@ -2317,8 +2317,8 @@ ActuallyDoSomething:
|
||||||
event.u.configureNotify.y = y;
|
event.u.configureNotify.y = y;
|
||||||
#ifdef PANORAMIX
|
#ifdef PANORAMIX
|
||||||
if(!noPanoramiXExtension && (!pParent || !pParent->parent)) {
|
if(!noPanoramiXExtension && (!pParent || !pParent->parent)) {
|
||||||
event.u.configureNotify.x += dixScreenOrigins[0].x;
|
event.u.configureNotify.x += screenInfo.screens[0]->x;
|
||||||
event.u.configureNotify.y += dixScreenOrigins[0].y;
|
event.u.configureNotify.y += screenInfo.screens[0]->y;
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
event.u.configureNotify.width = w;
|
event.u.configureNotify.width = w;
|
||||||
|
@ -2471,8 +2471,8 @@ ReparentWindow(WindowPtr pWin, WindowPtr pParent,
|
||||||
event.u.reparent.y = y;
|
event.u.reparent.y = y;
|
||||||
#ifdef PANORAMIX
|
#ifdef PANORAMIX
|
||||||
if(!noPanoramiXExtension && !pParent->parent) {
|
if(!noPanoramiXExtension && !pParent->parent) {
|
||||||
event.u.reparent.x += dixScreenOrigins[0].x;
|
event.u.reparent.x += screenInfo.screens[0]->x;
|
||||||
event.u.reparent.y += dixScreenOrigins[0].y;
|
event.u.reparent.y += screenInfo.screens[0]->y;
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
event.u.reparent.override = pWin->overrideRedirect;
|
event.u.reparent.override = pWin->overrideRedirect;
|
||||||
|
|
|
@ -230,7 +230,7 @@ static int dmxSLFindNext(int *list)
|
||||||
/** Make one pass over all the screens and return the number updated. */
|
/** Make one pass over all the screens and return the number updated. */
|
||||||
static int dmxTryComputeScreenOrigins(int *screensLeft)
|
static int dmxTryComputeScreenOrigins(int *screensLeft)
|
||||||
{
|
{
|
||||||
ScreenPtr pScreen;
|
ScreenPtr pScreen, refScreen;
|
||||||
DMXScreenInfo *screen;
|
DMXScreenInfo *screen;
|
||||||
int i, ref;
|
int i, ref;
|
||||||
int changed = 0;
|
int changed = 0;
|
||||||
|
@ -239,54 +239,56 @@ static int dmxTryComputeScreenOrigins(int *screensLeft)
|
||||||
if (!screensLeft[i])
|
if (!screensLeft[i])
|
||||||
continue;
|
continue;
|
||||||
screen = &dmxScreens[i];
|
screen = &dmxScreens[i];
|
||||||
|
pScreen = screenInfo.screens[i];
|
||||||
switch (screen->where) {
|
switch (screen->where) {
|
||||||
case PosAbsolute:
|
case PosAbsolute:
|
||||||
dixScreenOrigins[i].x = screen->whereX;
|
pScreen->x = screen->whereX;
|
||||||
dixScreenOrigins[i].y = screen->whereY;
|
pScreen->y = screen->whereY;
|
||||||
++changed, screensLeft[i] = 0;
|
++changed, screensLeft[i] = 0;
|
||||||
break;
|
break;
|
||||||
case PosRelative:
|
case PosRelative:
|
||||||
ref = screen->whereRefScreen;
|
ref = screen->whereRefScreen;
|
||||||
if (screensLeft[ref])
|
if (screensLeft[ref])
|
||||||
break;
|
break;
|
||||||
dixScreenOrigins[i].x = dixScreenOrigins[ref].x + screen->whereX;
|
refScreen = screenInfo.screens[ref];
|
||||||
dixScreenOrigins[i].y = dixScreenOrigins[ref].y + screen->whereY;
|
pScreen->x = refScreen->x + screen->whereX;
|
||||||
|
pScreen->y = refScreen->y + screen->whereY;
|
||||||
++changed, screensLeft[i] = 0;
|
++changed, screensLeft[i] = 0;
|
||||||
break;
|
break;
|
||||||
case PosRightOf:
|
case PosRightOf:
|
||||||
ref = screen->whereRefScreen;
|
ref = screen->whereRefScreen;
|
||||||
if (screensLeft[ref])
|
if (screensLeft[ref])
|
||||||
break;
|
break;
|
||||||
pScreen = screenInfo.screens[ref];
|
refScreen = screenInfo.screens[ref];
|
||||||
dixScreenOrigins[i].x = dixScreenOrigins[ref].x + pScreen->width;
|
pScreen->x = refScreen->x + refScreen->width;
|
||||||
dixScreenOrigins[i].y = dixScreenOrigins[ref].y;
|
pScreen->y = refScreen->y;
|
||||||
++changed, screensLeft[i] = 0;
|
++changed, screensLeft[i] = 0;
|
||||||
break;
|
break;
|
||||||
case PosLeftOf:
|
case PosLeftOf:
|
||||||
ref = screen->whereRefScreen;
|
ref = screen->whereRefScreen;
|
||||||
if (screensLeft[ref])
|
if (screensLeft[ref])
|
||||||
break;
|
break;
|
||||||
pScreen = screenInfo.screens[i];
|
refScreen = screenInfo.screens[ref];
|
||||||
dixScreenOrigins[i].x = dixScreenOrigins[ref].x - pScreen->width;
|
pScreen->x = refScreen->x - pScreen->width;
|
||||||
dixScreenOrigins[i].y = dixScreenOrigins[ref].y;
|
pScreen->y = refScreen->y;
|
||||||
++changed, screensLeft[i] = 0;
|
++changed, screensLeft[i] = 0;
|
||||||
break;
|
break;
|
||||||
case PosBelow:
|
case PosBelow:
|
||||||
ref = screen->whereRefScreen;
|
ref = screen->whereRefScreen;
|
||||||
if (screensLeft[ref])
|
if (screensLeft[ref])
|
||||||
break;
|
break;
|
||||||
pScreen = screenInfo.screens[ref];
|
refScreen = screenInfo.screens[ref];
|
||||||
dixScreenOrigins[i].x = dixScreenOrigins[ref].x;
|
pScreen->x = refScreen->x;
|
||||||
dixScreenOrigins[i].y = dixScreenOrigins[ref].y + pScreen->height;
|
pScreen->y = refScreen->y + refScreen->height;
|
||||||
++changed, screensLeft[i] = 0;
|
++changed, screensLeft[i] = 0;
|
||||||
break;
|
break;
|
||||||
case PosAbove:
|
case PosAbove:
|
||||||
ref = screen->whereRefScreen;
|
ref = screen->whereRefScreen;
|
||||||
if (screensLeft[ref])
|
if (screensLeft[ref])
|
||||||
break;
|
break;
|
||||||
pScreen = screenInfo.screens[i];
|
refScreen = screenInfo.screens[ref];
|
||||||
dixScreenOrigins[i].x = dixScreenOrigins[ref].x;
|
pScreen->x = refScreen->x;
|
||||||
dixScreenOrigins[i].y = dixScreenOrigins[ref].y - pScreen->height;
|
pScreen->y = refScreen->y - pScreen->height;
|
||||||
++changed, screensLeft[i] = 0;
|
++changed, screensLeft[i] = 0;
|
||||||
break;
|
break;
|
||||||
case PosNone:
|
case PosNone:
|
||||||
|
@ -298,6 +300,7 @@ static int dmxTryComputeScreenOrigins(int *screensLeft)
|
||||||
|
|
||||||
static void dmxComputeScreenOrigins(void)
|
static void dmxComputeScreenOrigins(void)
|
||||||
{
|
{
|
||||||
|
ScreenPtr pScreen;
|
||||||
int *screensLeft;
|
int *screensLeft;
|
||||||
int i, ref;
|
int i, ref;
|
||||||
int minX, minY;
|
int minX, minY;
|
||||||
|
@ -313,8 +316,9 @@ static void dmxComputeScreenOrigins(void)
|
||||||
* guarantees that we will eventually terminate.
|
* guarantees that we will eventually terminate.
|
||||||
*/
|
*/
|
||||||
ref = dmxScreens[i].whereRefScreen;
|
ref = dmxScreens[i].whereRefScreen;
|
||||||
dixScreenOrigins[ref].x = dixScreenOrigins[ref].y = 0;
|
pScreen = screenInfo.screens[ref];
|
||||||
screensLeft[ref] = 0;
|
pScreen->x = pScreen->y = 0;
|
||||||
|
screensLeft[ref] = 0;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
dmxSLFree(screensLeft);
|
dmxSLFree(screensLeft);
|
||||||
|
@ -322,18 +326,18 @@ static void dmxComputeScreenOrigins(void)
|
||||||
|
|
||||||
/* Justify the topmost and leftmost to
|
/* Justify the topmost and leftmost to
|
||||||
* (0,0). */
|
* (0,0). */
|
||||||
minX = dixScreenOrigins[0].x;
|
minX = screenInfo.screens[0]->x;
|
||||||
minY = dixScreenOrigins[0].y;
|
minY = screenInfo.screens[0]->y;
|
||||||
for (i = 1; i < dmxNumScreens; i++) { /* Compute minX, minY */
|
for (i = 1; i < dmxNumScreens; i++) { /* Compute minX, minY */
|
||||||
if (dixScreenOrigins[i].x < minX)
|
if (screenInfo.screens[i]->x < minX)
|
||||||
minX = dixScreenOrigins[i].x;
|
minX = screenInfo.screens[i]->x;
|
||||||
if (dixScreenOrigins[i].y < minY)
|
if (screenInfo.screens[i]->y < minY)
|
||||||
minY = dixScreenOrigins[i].y;
|
minY = screenInfo.screens[i]->y;
|
||||||
}
|
}
|
||||||
if (minX || minY) {
|
if (minX || minY) {
|
||||||
for (i = 0; i < dmxNumScreens; i++) {
|
for (i = 0; i < dmxNumScreens; i++) {
|
||||||
dixScreenOrigins[i].x -= minX;
|
screenInfo.screens[i]->x -= minX;
|
||||||
dixScreenOrigins[i].y -= minY;
|
screenInfo.screens[i]->y -= minY;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -398,8 +402,8 @@ void dmxInitOrigins(void)
|
||||||
|
|
||||||
for (i = 0; i < dmxNumScreens; i++) {
|
for (i = 0; i < dmxNumScreens; i++) {
|
||||||
DMXScreenInfo *dmxScreen = &dmxScreens[i];
|
DMXScreenInfo *dmxScreen = &dmxScreens[i];
|
||||||
dmxScreen->rootXOrigin = dixScreenOrigins[i].x;
|
dmxScreen->rootXOrigin = screenInfo.screens[i]->x;
|
||||||
dmxScreen->rootYOrigin = dixScreenOrigins[i].y;
|
dmxScreen->rootYOrigin = screenInfo.screens[i]->y;
|
||||||
}
|
}
|
||||||
|
|
||||||
dmxReInitOrigins();
|
dmxReInitOrigins();
|
||||||
|
|
|
@ -447,12 +447,12 @@ static void dmxSetRootWindowOrigin(int idx, int x, int y)
|
||||||
dmxScreen->rootYOrigin = y;
|
dmxScreen->rootYOrigin = y;
|
||||||
|
|
||||||
/* Compute offsets here in case <x,y> has been changed above */
|
/* Compute offsets here in case <x,y> has been changed above */
|
||||||
xoff = x - dixScreenOrigins[idx].x;
|
xoff = x - pScreen->x;
|
||||||
yoff = y - dixScreenOrigins[idx].y;
|
yoff = y - pScreen->y;
|
||||||
|
|
||||||
/* Adjust the root window's position in dixScreenOrigins */
|
/* Adjust the root window's position */
|
||||||
dixScreenOrigins[idx].x = dmxScreen->rootXOrigin;
|
pScreen->x = dmxScreen->rootXOrigin;
|
||||||
dixScreenOrigins[idx].y = dmxScreen->rootYOrigin;
|
pScreen->y = dmxScreen->rootYOrigin;
|
||||||
|
|
||||||
/* Recalculate the Xinerama regions and data structs */
|
/* Recalculate the Xinerama regions and data structs */
|
||||||
XineramaReinitData(pScreen);
|
XineramaReinitData(pScreen);
|
||||||
|
|
|
@ -1511,8 +1511,7 @@ PanoramiX prefix.
|
||||||
physical screen, and single region (PanoramiXScreenRegion) is
|
physical screen, and single region (PanoramiXScreenRegion) is
|
||||||
initialized to be the union of the screen regions.
|
initialized to be the union of the screen regions.
|
||||||
The relative positioning information for the
|
The relative positioning information for the
|
||||||
physical screens is taken from the array
|
physical screens is taken from the ScreenRec x and y members, which
|
||||||
dixScreenOrigins[], which
|
|
||||||
the DDX layer must initialize in InitOutput(). The bounds of the
|
the DDX layer must initialize in InitOutput(). The bounds of the
|
||||||
combined screen is also calculated (PanoramiXPixWidth and
|
combined screen is also calculated (PanoramiXPixWidth and
|
||||||
PanoramiXPixHeight).
|
PanoramiXPixHeight).
|
||||||
|
|
|
@ -526,10 +526,9 @@ int dmxFindPointerScreen(int x, int y)
|
||||||
int i;
|
int i;
|
||||||
|
|
||||||
for (i = 0; i < dmxNumScreens; i++) {
|
for (i = 0; i < dmxNumScreens; i++) {
|
||||||
if (x >= dixScreenOrigins[i].x
|
ScreenPtr pScreen = screenInfo.screens[i];
|
||||||
&& x < dixScreenOrigins[i].x + screenInfo.screens[i]->width
|
if (x >= pScreen->x && x < pScreen->x + pScreen->width &&
|
||||||
&& y >= dixScreenOrigins[i].y
|
y >= pScreen->y && y < pScreen->y + pScreen->height)
|
||||||
&& y < dixScreenOrigins[i].y + screenInfo.screens[i]->height)
|
|
||||||
return i;
|
return i;
|
||||||
}
|
}
|
||||||
return -1;
|
return -1;
|
||||||
|
|
|
@ -204,7 +204,8 @@ static void dmxConsoleDrawWindows(pointer private)
|
||||||
XUnionRectWithRegion(&rect, whole, whole);
|
XUnionRectWithRegion(&rect, whole, whole);
|
||||||
|
|
||||||
for (i = 0; i < dmxNumScreens; i++) {
|
for (i = 0; i < dmxNumScreens; i++) {
|
||||||
WindowPtr pRoot = screenInfo.screens[i]->root;
|
ScreenPtr pScreen = screenInfo.screens[i];
|
||||||
|
WindowPtr pRoot = pScreen->root;
|
||||||
WindowPtr pChild;
|
WindowPtr pChild;
|
||||||
|
|
||||||
#if DMX_WINDOW_DEBUG
|
#if DMX_WINDOW_DEBUG
|
||||||
|
@ -227,10 +228,8 @@ static void dmxConsoleDrawWindows(pointer private)
|
||||||
pChild->overrideRedirect,
|
pChild->overrideRedirect,
|
||||||
REGION_NUM_RECTS(&pChild->clipList));
|
REGION_NUM_RECTS(&pChild->clipList));
|
||||||
#endif
|
#endif
|
||||||
rect.x = scalex(priv, pChild->drawable.x
|
rect.x = scalex(priv, pChild->drawable.x + pScreen->x);
|
||||||
+ dixScreenOrigins[i].x);
|
rect.y = scaley(priv, pChild->drawable.y + pScreen->y);
|
||||||
rect.y = scaley(priv, pChild->drawable.y
|
|
||||||
+ dixScreenOrigins[i].y);
|
|
||||||
rect.width = scalex(priv, pChild->drawable.width);
|
rect.width = scalex(priv, pChild->drawable.width);
|
||||||
rect.height = scaley(priv, pChild->drawable.height);
|
rect.height = scaley(priv, pChild->drawable.height);
|
||||||
XDrawRectangle(dpy, priv->pixmap, priv->gc,
|
XDrawRectangle(dpy, priv->pixmap, priv->gc,
|
||||||
|
@ -263,15 +262,15 @@ static void dmxConsoleDraw(myPrivate *priv, int updateCursor, int update)
|
||||||
DMXScreenInfo *dmxScreen = &dmxScreens[i];
|
DMXScreenInfo *dmxScreen = &dmxScreens[i];
|
||||||
XFillRectangle(dpy, priv->pixmap,
|
XFillRectangle(dpy, priv->pixmap,
|
||||||
dmxScreen->beDisplay ? priv->gcRev : priv->gcDet,
|
dmxScreen->beDisplay ? priv->gcRev : priv->gcDet,
|
||||||
scalex(priv, dixScreenOrigins[i].x),
|
scalex(priv, screenInfo.screens[i]->x),
|
||||||
scaley(priv, dixScreenOrigins[i].y),
|
scaley(priv, screenInfo.screens[i]->y),
|
||||||
scalex(priv, screenInfo.screens[i]->width),
|
scalex(priv, screenInfo.screens[i]->width),
|
||||||
scaley(priv, screenInfo.screens[i]->height));
|
scaley(priv, screenInfo.screens[i]->height));
|
||||||
}
|
}
|
||||||
for (i = 0; i < dmxNumScreens; i++) {
|
for (i = 0; i < dmxNumScreens; i++) {
|
||||||
XDrawRectangle(dpy, priv->pixmap, priv->gc,
|
XDrawRectangle(dpy, priv->pixmap, priv->gc,
|
||||||
scalex(priv, dixScreenOrigins[i].x),
|
scalex(priv, screenInfo.screens[i]->x),
|
||||||
scaley(priv, dixScreenOrigins[i].y),
|
scaley(priv, screenInfo.screens[i]->y),
|
||||||
scalex(priv, screenInfo.screens[i]->width),
|
scalex(priv, screenInfo.screens[i]->width),
|
||||||
scaley(priv, screenInfo.screens[i]->height));
|
scaley(priv, screenInfo.screens[i]->height));
|
||||||
}
|
}
|
||||||
|
@ -671,11 +670,11 @@ static void dmxConsoleComputeWidthHeight(myPrivate *priv,
|
||||||
* possible by computing the visible
|
* possible by computing the visible
|
||||||
* bounding box. */
|
* bounding box. */
|
||||||
for (i = 0; i < dmxNumScreens; i++) {
|
for (i = 0; i < dmxNumScreens; i++) {
|
||||||
if (dixScreenOrigins[i].x+screenInfo.screens[i]->width > *width)
|
if (screenInfo.screens[i]->x+screenInfo.screens[i]->width > *width)
|
||||||
*width = dixScreenOrigins[i].x+screenInfo.screens[i]->width;
|
*width = screenInfo.screens[i]->x+screenInfo.screens[i]->width;
|
||||||
|
|
||||||
if (dixScreenOrigins[i].y+screenInfo.screens[i]->height > *height)
|
if (screenInfo.screens[i]->y+screenInfo.screens[i]->height > *height)
|
||||||
*height = dixScreenOrigins[i].y+screenInfo.screens[i]->height;
|
*height = screenInfo.screens[i]->y+screenInfo.screens[i]->height;
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
|
@ -941,9 +941,8 @@ KdScreenInit(int index, ScreenPtr pScreen, int argc, char **argv)
|
||||||
pScreenPriv->card = card;
|
pScreenPriv->card = card;
|
||||||
pScreenPriv->bytesPerPixel = screen->fb.bitsPerPixel >> 3;
|
pScreenPriv->bytesPerPixel = screen->fb.bitsPerPixel >> 3;
|
||||||
pScreenPriv->dpmsState = KD_DPMS_NORMAL;
|
pScreenPriv->dpmsState = KD_DPMS_NORMAL;
|
||||||
#ifdef PANORAMIX
|
pScreen->x = screen->origin.x;
|
||||||
dixScreenOrigins[pScreen->myNum] = screen->origin;
|
pScreen->y = screen->origin.y;
|
||||||
#endif
|
|
||||||
|
|
||||||
if (!monitorResolution)
|
if (!monitorResolution)
|
||||||
monitorResolution = 75;
|
monitorResolution = 75;
|
||||||
|
|
|
@ -581,7 +581,7 @@ xf86InitOrigins(void)
|
||||||
{
|
{
|
||||||
unsigned long screensLeft, prevScreensLeft, mask;
|
unsigned long screensLeft, prevScreensLeft, mask;
|
||||||
screenLayoutPtr screen;
|
screenLayoutPtr screen;
|
||||||
ScreenPtr pScreen;
|
ScreenPtr pScreen, refScreen;
|
||||||
int x1, x2, y1, y2, left, right, top, bottom;
|
int x1, x2, y1, y2, left, right, top, bottom;
|
||||||
int i, j, ref, minX, minY, min, max;
|
int i, j, ref, minX, minY, min, max;
|
||||||
xf86ScreenLayoutPtr pLayout;
|
xf86ScreenLayoutPtr pLayout;
|
||||||
|
@ -608,6 +608,7 @@ xf86InitOrigins(void)
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
pScreen = xf86Screens[i]->pScreen;
|
||||||
switch(screen->where) {
|
switch(screen->where) {
|
||||||
case PosObsolete:
|
case PosObsolete:
|
||||||
OldStyleConfig = TRUE;
|
OldStyleConfig = TRUE;
|
||||||
|
@ -620,7 +621,7 @@ xf86InitOrigins(void)
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
pLayout->left = AddEdge(pLayout->left,
|
pLayout->left = AddEdge(pLayout->left,
|
||||||
0, xf86Screens[i]->pScreen->height,
|
0, pScreen->height,
|
||||||
xf86Screens[ref]->pScreen->width, 0, ref);
|
xf86Screens[ref]->pScreen->width, 0, ref);
|
||||||
}
|
}
|
||||||
if(screen->right) {
|
if(screen->right) {
|
||||||
|
@ -629,7 +630,6 @@ xf86InitOrigins(void)
|
||||||
ErrorF("Referenced uninitialized screen in Layout!\n");
|
ErrorF("Referenced uninitialized screen in Layout!\n");
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
pScreen = xf86Screens[i]->pScreen;
|
|
||||||
pLayout->right = AddEdge(pLayout->right,
|
pLayout->right = AddEdge(pLayout->right,
|
||||||
0, pScreen->height, -pScreen->width, 0, ref);
|
0, pScreen->height, -pScreen->width, 0, ref);
|
||||||
}
|
}
|
||||||
|
@ -640,7 +640,7 @@ xf86InitOrigins(void)
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
pLayout->up = AddEdge(pLayout->up,
|
pLayout->up = AddEdge(pLayout->up,
|
||||||
0, xf86Screens[i]->pScreen->width,
|
0, pScreen->width,
|
||||||
0, xf86Screens[ref]->pScreen->height, ref);
|
0, xf86Screens[ref]->pScreen->height, ref);
|
||||||
}
|
}
|
||||||
if(screen->bottom) {
|
if(screen->bottom) {
|
||||||
|
@ -649,7 +649,6 @@ xf86InitOrigins(void)
|
||||||
ErrorF("Referenced uninitialized screen in Layout!\n");
|
ErrorF("Referenced uninitialized screen in Layout!\n");
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
pScreen = xf86Screens[i]->pScreen;
|
|
||||||
pLayout->down = AddEdge(pLayout->down,
|
pLayout->down = AddEdge(pLayout->down,
|
||||||
0, pScreen->width, 0, -pScreen->height, ref);
|
0, pScreen->width, 0, -pScreen->height, ref);
|
||||||
}
|
}
|
||||||
|
@ -658,8 +657,8 @@ xf86InitOrigins(void)
|
||||||
screen->x = screen->y = 0;
|
screen->x = screen->y = 0;
|
||||||
/* FALLTHROUGH */
|
/* FALLTHROUGH */
|
||||||
case PosAbsolute:
|
case PosAbsolute:
|
||||||
dixScreenOrigins[i].x = screen->x;
|
pScreen->x = screen->x;
|
||||||
dixScreenOrigins[i].y = screen->y;
|
pScreen->y = screen->y;
|
||||||
screensLeft &= ~(1 << i);
|
screensLeft &= ~(1 << i);
|
||||||
break;
|
break;
|
||||||
case PosRelative:
|
case PosRelative:
|
||||||
|
@ -669,8 +668,9 @@ xf86InitOrigins(void)
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
if(screensLeft & (1 << ref)) break;
|
if(screensLeft & (1 << ref)) break;
|
||||||
dixScreenOrigins[i].x = dixScreenOrigins[ref].x + screen->x;
|
refScreen = xf86Screens[ref]->pScreen;
|
||||||
dixScreenOrigins[i].y = dixScreenOrigins[ref].y + screen->y;
|
pScreen->x = refScreen->x + screen->x;
|
||||||
|
pScreen->y = refScreen->y + screen->y;
|
||||||
screensLeft &= ~(1 << i);
|
screensLeft &= ~(1 << i);
|
||||||
break;
|
break;
|
||||||
case PosRightOf:
|
case PosRightOf:
|
||||||
|
@ -680,10 +680,9 @@ xf86InitOrigins(void)
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
if(screensLeft & (1 << ref)) break;
|
if(screensLeft & (1 << ref)) break;
|
||||||
pScreen = xf86Screens[ref]->pScreen;
|
refScreen = xf86Screens[ref]->pScreen;
|
||||||
dixScreenOrigins[i].x =
|
pScreen->x = refScreen->x + refScreen->width;
|
||||||
dixScreenOrigins[ref].x + pScreen->width;
|
pScreen->y = refScreen->y;
|
||||||
dixScreenOrigins[i].y = dixScreenOrigins[ref].y;
|
|
||||||
screensLeft &= ~(1 << i);
|
screensLeft &= ~(1 << i);
|
||||||
break;
|
break;
|
||||||
case PosLeftOf:
|
case PosLeftOf:
|
||||||
|
@ -693,10 +692,9 @@ xf86InitOrigins(void)
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
if(screensLeft & (1 << ref)) break;
|
if(screensLeft & (1 << ref)) break;
|
||||||
pScreen = xf86Screens[i]->pScreen;
|
refScreen = xf86Screens[ref]->pScreen;
|
||||||
dixScreenOrigins[i].x =
|
pScreen->x = refScreen->x - pScreen->width;
|
||||||
dixScreenOrigins[ref].x - pScreen->width;
|
pScreen->y = refScreen->y;
|
||||||
dixScreenOrigins[i].y = dixScreenOrigins[ref].y;
|
|
||||||
screensLeft &= ~(1 << i);
|
screensLeft &= ~(1 << i);
|
||||||
break;
|
break;
|
||||||
case PosBelow:
|
case PosBelow:
|
||||||
|
@ -706,10 +704,9 @@ xf86InitOrigins(void)
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
if(screensLeft & (1 << ref)) break;
|
if(screensLeft & (1 << ref)) break;
|
||||||
pScreen = xf86Screens[ref]->pScreen;
|
refScreen = xf86Screens[ref]->pScreen;
|
||||||
dixScreenOrigins[i].x = dixScreenOrigins[ref].x;
|
pScreen->x = refScreen->x;
|
||||||
dixScreenOrigins[i].y =
|
pScreen->y = refScreen->y + refScreen->height;
|
||||||
dixScreenOrigins[ref].y + pScreen->height;
|
|
||||||
screensLeft &= ~(1 << i);
|
screensLeft &= ~(1 << i);
|
||||||
break;
|
break;
|
||||||
case PosAbove:
|
case PosAbove:
|
||||||
|
@ -719,10 +716,9 @@ xf86InitOrigins(void)
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
if(screensLeft & (1 << ref)) break;
|
if(screensLeft & (1 << ref)) break;
|
||||||
pScreen = xf86Screens[i]->pScreen;
|
refScreen = xf86Screens[ref]->pScreen;
|
||||||
dixScreenOrigins[i].x = dixScreenOrigins[ref].x;
|
pScreen->x = refScreen->x;
|
||||||
dixScreenOrigins[i].y =
|
pScreen->y = refScreen->y - pScreen->height;
|
||||||
dixScreenOrigins[ref].y - pScreen->height;
|
|
||||||
screensLeft &= ~(1 << i);
|
screensLeft &= ~(1 << i);
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
|
@ -741,7 +737,7 @@ xf86InitOrigins(void)
|
||||||
while(!((1 << i) & screensLeft)){ i++; }
|
while(!((1 << i) & screensLeft)){ i++; }
|
||||||
|
|
||||||
ref = xf86ConfigLayout.screens[i].refscreen->screennum;
|
ref = xf86ConfigLayout.screens[i].refscreen->screennum;
|
||||||
dixScreenOrigins[ref].x = dixScreenOrigins[ref].y = 0;
|
xf86Screens[ref]->pScreen->x = xf86Screens[ref]->pScreen->y = 0;
|
||||||
screensLeft &= ~(1 << ref);
|
screensLeft &= ~(1 << ref);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -749,20 +745,20 @@ xf86InitOrigins(void)
|
||||||
}
|
}
|
||||||
|
|
||||||
/* justify the topmost and leftmost to (0,0) */
|
/* justify the topmost and leftmost to (0,0) */
|
||||||
minX = dixScreenOrigins[0].x;
|
minX = xf86Screens[0]->pScreen->x;
|
||||||
minY = dixScreenOrigins[0].y;
|
minY = xf86Screens[0]->pScreen->y;
|
||||||
|
|
||||||
for(i = 1; i < xf86NumScreens; i++) {
|
for(i = 1; i < xf86NumScreens; i++) {
|
||||||
if(dixScreenOrigins[i].x < minX)
|
if(xf86Screens[i]->pScreen->x < minX)
|
||||||
minX = dixScreenOrigins[i].x;
|
minX = xf86Screens[i]->pScreen->x;
|
||||||
if(dixScreenOrigins[i].y < minY)
|
if(xf86Screens[i]->pScreen->y < minY)
|
||||||
minY = dixScreenOrigins[i].y;
|
minY = xf86Screens[i]->pScreen->y;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (minX || minY) {
|
if (minX || minY) {
|
||||||
for(i = 0; i < xf86NumScreens; i++) {
|
for(i = 0; i < xf86NumScreens; i++) {
|
||||||
dixScreenOrigins[i].x -= minX;
|
xf86Screens[i]->pScreen->x -= minX;
|
||||||
dixScreenOrigins[i].y -= minY;
|
xf86Screens[i]->pScreen->y -= minY;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -775,18 +771,20 @@ xf86InitOrigins(void)
|
||||||
|
|
||||||
pScreen = xf86Screens[i]->pScreen;
|
pScreen = xf86Screens[i]->pScreen;
|
||||||
|
|
||||||
left = dixScreenOrigins[i].x;
|
left = pScreen->x;
|
||||||
right = left + pScreen->width;
|
right = left + pScreen->width;
|
||||||
top = dixScreenOrigins[i].y;
|
top = pScreen->y;
|
||||||
bottom = top + pScreen->height;
|
bottom = top + pScreen->height;
|
||||||
|
|
||||||
for(j = 0; j < xf86NumScreens; j++) {
|
for(j = 0; j < xf86NumScreens; j++) {
|
||||||
if(i == j) continue;
|
if(i == j) continue;
|
||||||
|
|
||||||
x1 = dixScreenOrigins[j].x;
|
refScreen = xf86Screens[j]->pScreen;
|
||||||
x2 = x1 + xf86Screens[j]->pScreen->width;
|
|
||||||
y1 = dixScreenOrigins[j].y;
|
x1 = refScreen->x;
|
||||||
y2 = y1 + xf86Screens[j]->pScreen->height;
|
x2 = x1 + refScreen->width;
|
||||||
|
y1 = refScreen->y;
|
||||||
|
y2 = y1 + refScreen->height;
|
||||||
|
|
||||||
if((bottom > y1) && (top < y2)) {
|
if((bottom > y1) && (top < y2)) {
|
||||||
min = y1 - top;
|
min = y1 - top;
|
||||||
|
@ -796,13 +794,13 @@ xf86InitOrigins(void)
|
||||||
|
|
||||||
if(((left - 1) >= x1) && ((left - 1) < x2))
|
if(((left - 1) >= x1) && ((left - 1) < x2))
|
||||||
pLayout->left = AddEdge(pLayout->left, min, max,
|
pLayout->left = AddEdge(pLayout->left, min, max,
|
||||||
dixScreenOrigins[i].x - dixScreenOrigins[j].x,
|
pScreen->x - refScreen->x,
|
||||||
dixScreenOrigins[i].y - dixScreenOrigins[j].y, j);
|
pScreen->y - refScreen->y, j);
|
||||||
|
|
||||||
if((right >= x1) && (right < x2))
|
if((right >= x1) && (right < x2))
|
||||||
pLayout->right = AddEdge(pLayout->right, min, max,
|
pLayout->right = AddEdge(pLayout->right, min, max,
|
||||||
dixScreenOrigins[i].x - dixScreenOrigins[j].x,
|
pScreen->x - refScreen->x,
|
||||||
dixScreenOrigins[i].y - dixScreenOrigins[j].y, j);
|
pScreen->y - refScreen->y, j);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@ -814,13 +812,13 @@ xf86InitOrigins(void)
|
||||||
|
|
||||||
if(((top - 1) >= y1) && ((top - 1) < y2))
|
if(((top - 1) >= y1) && ((top - 1) < y2))
|
||||||
pLayout->up = AddEdge(pLayout->up, min, max,
|
pLayout->up = AddEdge(pLayout->up, min, max,
|
||||||
dixScreenOrigins[i].x - dixScreenOrigins[j].x,
|
pScreen->x - refScreen->x,
|
||||||
dixScreenOrigins[i].y - dixScreenOrigins[j].y, j);
|
pScreen->y - refScreen->y, j);
|
||||||
|
|
||||||
if((bottom >= y1) && (bottom < y2))
|
if((bottom >= y1) && (bottom < y2))
|
||||||
pLayout->down = AddEdge(pLayout->down, min, max,
|
pLayout->down = AddEdge(pLayout->down, min, max,
|
||||||
dixScreenOrigins[i].x - dixScreenOrigins[j].x,
|
pScreen->x - refScreen->x,
|
||||||
dixScreenOrigins[i].y - dixScreenOrigins[j].y, j);
|
pScreen->y - refScreen->y, j);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -140,10 +140,8 @@ AppleWMSetScreenOrigin(
|
||||||
{
|
{
|
||||||
int32_t data[2];
|
int32_t data[2];
|
||||||
|
|
||||||
data[0] = (dixScreenOrigins[pWin->drawable.pScreen->myNum].x
|
data[0] = pWin->drawable.pScreen->x + darwinMainScreenX;
|
||||||
+ darwinMainScreenX);
|
data[1] = pWin->drawable.pScreen->y + darwinMainScreenY;
|
||||||
data[1] = (dixScreenOrigins[pWin->drawable.pScreen->myNum].y
|
|
||||||
+ darwinMainScreenY);
|
|
||||||
|
|
||||||
dixChangeWindowProperty(serverClient, pWin, xa_native_screen_origin(),
|
dixChangeWindowProperty(serverClient, pWin, xa_native_screen_origin(),
|
||||||
XA_INTEGER, 32, PropModeReplace, 2, data, TRUE);
|
XA_INTEGER, 32, PropModeReplace, 2, data, TRUE);
|
||||||
|
|
|
@ -262,8 +262,8 @@ static Bool DarwinScreenInit(int index, ScreenPtr pScreen, int argc, char **argv
|
||||||
return FALSE;
|
return FALSE;
|
||||||
}
|
}
|
||||||
|
|
||||||
dixScreenOrigins[index].x = dfb->x;
|
pScreen->x = dfb->x;
|
||||||
dixScreenOrigins[index].y = dfb->y;
|
pScreen->y = dfb->y;
|
||||||
|
|
||||||
/* ErrorF("Screen %d added: %dx%d @ (%d,%d)\n",
|
/* ErrorF("Screen %d added: %dx%d @ (%d,%d)\n",
|
||||||
index, dfb->width, dfb->height, dfb->x, dfb->y); */
|
index, dfb->width, dfb->height, dfb->x, dfb->y); */
|
||||||
|
@ -526,16 +526,16 @@ DarwinAdjustScreenOrigins(ScreenInfo *pScreenInfo)
|
||||||
{
|
{
|
||||||
int i, left, top;
|
int i, left, top;
|
||||||
|
|
||||||
left = dixScreenOrigins[0].x;
|
left = pScreenInfo->screens[0]->x;
|
||||||
top = dixScreenOrigins[0].y;
|
top = pScreenInfo->screens[0]->y;
|
||||||
|
|
||||||
/* Find leftmost screen. If there's a tie, take the topmost of the two. */
|
/* Find leftmost screen. If there's a tie, take the topmost of the two. */
|
||||||
for (i = 1; i < pScreenInfo->numScreens; i++) {
|
for (i = 1; i < pScreenInfo->numScreens; i++) {
|
||||||
if (dixScreenOrigins[i].x < left ||
|
if (pScreenInfo->screens[i]->x < left ||
|
||||||
(dixScreenOrigins[i].x == left && dixScreenOrigins[i].y < top))
|
(pScreenInfo->screens[i]->x == left && pScreenInfo->screens[i]->y < top))
|
||||||
{
|
{
|
||||||
left = dixScreenOrigins[i].x;
|
left = pScreenInfo->screens[i]->x;
|
||||||
top = dixScreenOrigins[i].y;
|
top = pScreenInfo->screens[i]->y;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -551,10 +551,10 @@ DarwinAdjustScreenOrigins(ScreenInfo *pScreenInfo)
|
||||||
|
|
||||||
if (darwinMainScreenX != 0 || darwinMainScreenY != 0) {
|
if (darwinMainScreenX != 0 || darwinMainScreenY != 0) {
|
||||||
for (i = 0; i < pScreenInfo->numScreens; i++) {
|
for (i = 0; i < pScreenInfo->numScreens; i++) {
|
||||||
dixScreenOrigins[i].x -= darwinMainScreenX;
|
pScreenInfo->screens[i]->x -= darwinMainScreenX;
|
||||||
dixScreenOrigins[i].y -= darwinMainScreenY;
|
pScreenInfo->screens[i]->y -= darwinMainScreenY;
|
||||||
DEBUG_LOG("Screen %d placed at X11 coordinate (%d,%d).\n",
|
DEBUG_LOG("Screen %d placed at X11 coordinate (%d,%d).\n",
|
||||||
i, dixScreenOrigins[i].x, dixScreenOrigins[i].y);
|
i, pScreenInfo->screens[i]->x, pScreenInfo->screens[i]->y);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -377,8 +377,8 @@ static void DarwinPrepareValuators(DeviceIntPtr pDev, int *valuators, ScreenPtr
|
||||||
float pointer_x, float pointer_y,
|
float pointer_x, float pointer_y,
|
||||||
float pressure, float tilt_x, float tilt_y) {
|
float pressure, float tilt_x, float tilt_y) {
|
||||||
/* Fix offset between darwin and X screens */
|
/* Fix offset between darwin and X screens */
|
||||||
pointer_x -= darwinMainScreenX + dixScreenOrigins[screen->myNum].x;
|
pointer_x -= darwinMainScreenX + screen->x;
|
||||||
pointer_y -= darwinMainScreenY + dixScreenOrigins[screen->myNum].y;
|
pointer_y -= darwinMainScreenY + screen->y;
|
||||||
|
|
||||||
if(pointer_x < 0.0)
|
if(pointer_x < 0.0)
|
||||||
pointer_x = 0.0;
|
pointer_x = 0.0;
|
||||||
|
|
|
@ -259,8 +259,8 @@ void QuartzUpdateScreens(void) {
|
||||||
PseudoramiXResetScreens();
|
PseudoramiXResetScreens();
|
||||||
quartzProcs->AddPseudoramiXScreens(&x, &y, &width, &height);
|
quartzProcs->AddPseudoramiXScreens(&x, &y, &width, &height);
|
||||||
|
|
||||||
dixScreenOrigins[pScreen->myNum].x = x;
|
pScreen->x = x;
|
||||||
dixScreenOrigins[pScreen->myNum].y = y;
|
pScreen->y = y;
|
||||||
pScreen->mmWidth = pScreen->mmWidth * ((double) width / pScreen->width);
|
pScreen->mmWidth = pScreen->mmWidth * ((double) width / pScreen->width);
|
||||||
pScreen->mmHeight = pScreen->mmHeight * ((double) height / pScreen->height);
|
pScreen->mmHeight = pScreen->mmHeight * ((double) height / pScreen->height);
|
||||||
pScreen->width = width;
|
pScreen->width = width;
|
||||||
|
@ -269,11 +269,11 @@ void QuartzUpdateScreens(void) {
|
||||||
DarwinAdjustScreenOrigins(&screenInfo);
|
DarwinAdjustScreenOrigins(&screenInfo);
|
||||||
quartzProcs->UpdateScreen(pScreen);
|
quartzProcs->UpdateScreen(pScreen);
|
||||||
|
|
||||||
/* DarwinAdjustScreenOrigins or UpdateScreen may change dixScreenOrigins,
|
/* DarwinAdjustScreenOrigins or UpdateScreen may change pScreen->x/y,
|
||||||
* so use it rather than x/y
|
* so use it rather than x/y
|
||||||
*/
|
*/
|
||||||
sx = dixScreenOrigins[pScreen->myNum].x + darwinMainScreenX;
|
sx = pScreen->x + darwinMainScreenX;
|
||||||
sy = dixScreenOrigins[pScreen->myNum].y + darwinMainScreenY;
|
sy = pScreen->y + darwinMainScreenY;
|
||||||
|
|
||||||
/* Adjust the root window. */
|
/* Adjust the root window. */
|
||||||
pRoot = pScreen->root;
|
pRoot = pScreen->root;
|
||||||
|
@ -292,7 +292,7 @@ void QuartzUpdateScreens(void) {
|
||||||
inputInfo.pointer->spriteInfo->sprite->physLimits = bounds;
|
inputInfo.pointer->spriteInfo->sprite->physLimits = bounds;
|
||||||
inputInfo.pointer->spriteInfo->sprite->hotLimits = bounds;
|
inputInfo.pointer->spriteInfo->sprite->hotLimits = bounds;
|
||||||
|
|
||||||
DEBUG_LOG("Root Window: %dx%d @ (%d, %d) darwinMainScreen (%d, %d) xy (%d, %d) dixScreenOrigins (%d, %d)\n", width, height, x - sx, y - sy, darwinMainScreenX, darwinMainScreenY, x, y, dixScreenOrigins[pScreen->myNum].x, dixScreenOrigins[pScreen->myNum].y);
|
DEBUG_LOG("Root Window: %dx%d @ (%d, %d) darwinMainScreen (%d, %d) xy (%d, %d) dixScreenOrigins (%d, %d)\n", width, height, x - sx, y - sy, darwinMainScreenX, darwinMainScreenY, x, y, pScreen->x, pScreen->y);
|
||||||
|
|
||||||
/* Send an event for the root reconfigure */
|
/* Send an event for the root reconfigure */
|
||||||
e.u.u.type = ConfigureNotify;
|
e.u.u.type = ConfigureNotify;
|
||||||
|
|
|
@ -296,8 +296,8 @@ QuartzWarpCursor(DeviceIntPtr pDev, ScreenPtr pScreen, int x, int y)
|
||||||
{
|
{
|
||||||
int sx, sy;
|
int sx, sy;
|
||||||
|
|
||||||
sx = dixScreenOrigins[pScreen->myNum].x + darwinMainScreenX;
|
sx = pScreen->x + darwinMainScreenX;
|
||||||
sy = dixScreenOrigins[pScreen->myNum].y + darwinMainScreenY;
|
sy = pScreen->y + darwinMainScreenY;
|
||||||
|
|
||||||
CGWarpMouseCursorPosition(CGPointMake(sx + x, sy + y));
|
CGWarpMouseCursorPosition(CGPointMake(sx + x, sy + y));
|
||||||
}
|
}
|
||||||
|
|
|
@ -243,11 +243,11 @@ winScreenInit (int index,
|
||||||
Note the screen origin in a normalized coordinate space where (0,0) is at the top left
|
Note the screen origin in a normalized coordinate space where (0,0) is at the top left
|
||||||
of the native virtual desktop area
|
of the native virtual desktop area
|
||||||
*/
|
*/
|
||||||
dixScreenOrigins[index].x = pScreenInfo->dwInitialX - GetSystemMetrics(SM_XVIRTUALSCREEN);
|
pScreen->x = pScreenInfo->dwInitialX - GetSystemMetrics(SM_XVIRTUALSCREEN);
|
||||||
dixScreenOrigins[index].y = pScreenInfo->dwInitialY - GetSystemMetrics(SM_YVIRTUALSCREEN);
|
pScreen->y = pScreenInfo->dwInitialY - GetSystemMetrics(SM_YVIRTUALSCREEN);
|
||||||
|
|
||||||
ErrorF("Screen %d added at virtual desktop coordinate (%d,%d).\n",
|
ErrorF("Screen %d added at virtual desktop coordinate (%d,%d).\n",
|
||||||
index, dixScreenOrigins[index].x, dixScreenOrigins[index].y);
|
index, pScreen->x, pScreen->y);
|
||||||
|
|
||||||
#if CYGDEBUG || YES
|
#if CYGDEBUG || YES
|
||||||
winDebug ("winScreenInit - returning\n");
|
winDebug ("winScreenInit - returning\n");
|
||||||
|
|
|
@ -22,8 +22,6 @@ extern _X_EXPORT int defaultColorVisualClass;
|
||||||
extern _X_EXPORT int GrabInProgress;
|
extern _X_EXPORT int GrabInProgress;
|
||||||
extern _X_EXPORT Bool noTestExtensions;
|
extern _X_EXPORT Bool noTestExtensions;
|
||||||
|
|
||||||
extern _X_EXPORT DDXPointRec dixScreenOrigins[MAXSCREENS];
|
|
||||||
|
|
||||||
extern _X_EXPORT char *ConnectionInfo;
|
extern _X_EXPORT char *ConnectionInfo;
|
||||||
|
|
||||||
#ifdef DPMSExtension
|
#ifdef DPMSExtension
|
||||||
|
|
|
@ -456,7 +456,7 @@ typedef void (* DeviceCursorCleanupProcPtr)(
|
||||||
typedef struct _Screen {
|
typedef struct _Screen {
|
||||||
int myNum; /* index of this instance in Screens[] */
|
int myNum; /* index of this instance in Screens[] */
|
||||||
ATOM id;
|
ATOM id;
|
||||||
short width, height;
|
short x, y, width, height;
|
||||||
short mmWidth, mmHeight;
|
short mmWidth, mmHeight;
|
||||||
short numDepths;
|
short numDepths;
|
||||||
unsigned char rootDepth;
|
unsigned char rootDepth;
|
||||||
|
|
|
@ -424,8 +424,8 @@ miSendExposures( WindowPtr pWin, RegionPtr pRgn, int dx, int dy)
|
||||||
XID realWin = 0;
|
XID realWin = 0;
|
||||||
|
|
||||||
if(!pWin->parent) {
|
if(!pWin->parent) {
|
||||||
x = dixScreenOrigins[scrnum].x;
|
x = screenInfo.screens[scrnum]->x;
|
||||||
y = dixScreenOrigins[scrnum].y;
|
y = screenInfo.screens[scrnum]->y;
|
||||||
pWin = screenInfo.screens[0]->root;
|
pWin = screenInfo.screens[0]->root;
|
||||||
realWin = pWin->drawable.id;
|
realWin = pWin->drawable.id;
|
||||||
} else if (scrnum) {
|
} else if (scrnum) {
|
||||||
|
|
|
@ -53,9 +53,9 @@ extern Bool no_configure_window;
|
||||||
|
|
||||||
#ifdef ROOTLESS_GLOBAL_COORDS
|
#ifdef ROOTLESS_GLOBAL_COORDS
|
||||||
#define SCREEN_TO_GLOBAL_X \
|
#define SCREEN_TO_GLOBAL_X \
|
||||||
(dixScreenOrigins[pScreen->myNum].x + rootlessGlobalOffsetX)
|
(pScreen->x + rootlessGlobalOffsetX)
|
||||||
#define SCREEN_TO_GLOBAL_Y \
|
#define SCREEN_TO_GLOBAL_Y \
|
||||||
(dixScreenOrigins[pScreen->myNum].y + rootlessGlobalOffsetY)
|
(pScreen->y + rootlessGlobalOffsetY)
|
||||||
#else
|
#else
|
||||||
#define SCREEN_TO_GLOBAL_X 0
|
#define SCREEN_TO_GLOBAL_X 0
|
||||||
#define SCREEN_TO_GLOBAL_Y 0
|
#define SCREEN_TO_GLOBAL_Y 0
|
||||||
|
@ -109,8 +109,8 @@ void RootlessNativeWindowMoved (WindowPtr pWin) {
|
||||||
|
|
||||||
if (xp_get_window_bounds (MAKE_WINDOW_ID(winRec->wid), &bounds) != Success) return;
|
if (xp_get_window_bounds (MAKE_WINDOW_ID(winRec->wid), &bounds) != Success) return;
|
||||||
|
|
||||||
sx = dixScreenOrigins[pWin->drawable.pScreen->myNum].x + darwinMainScreenX;
|
sx = pWin->drawable.pScreen->x + darwinMainScreenX;
|
||||||
sy = dixScreenOrigins[pWin->drawable.pScreen->myNum].y + darwinMainScreenY;
|
sy = pWin->drawable.pScreen->y + darwinMainScreenY;
|
||||||
|
|
||||||
/* Fake up a ConfigureWindow packet to resize the window to the current bounds. */
|
/* Fake up a ConfigureWindow packet to resize the window to the current bounds. */
|
||||||
vlist[0] = (INT16) bounds.x1 - sx;
|
vlist[0] = (INT16) bounds.x1 - sx;
|
||||||
|
|
|
@ -43,6 +43,7 @@ and Jim Haggerty of Metheus.
|
||||||
#include "swaprep.h"
|
#include "swaprep.h"
|
||||||
#include "inputstr.h"
|
#include "inputstr.h"
|
||||||
#include "eventconvert.h"
|
#include "eventconvert.h"
|
||||||
|
#include "scrnintstr.h"
|
||||||
|
|
||||||
|
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
|
@ -755,11 +756,11 @@ RecordSendProtocolEvents(RecordClientsAndProtocolPtr pRCAP,
|
||||||
int scr = XineramaGetCursorScreen(inputInfo.pointer);
|
int scr = XineramaGetCursorScreen(inputInfo.pointer);
|
||||||
memcpy(&shiftedEvent, pev, sizeof(xEvent));
|
memcpy(&shiftedEvent, pev, sizeof(xEvent));
|
||||||
shiftedEvent.u.keyButtonPointer.rootX +=
|
shiftedEvent.u.keyButtonPointer.rootX +=
|
||||||
dixScreenOrigins[scr].x -
|
screenInfo.screens[scr]->x -
|
||||||
dixScreenOrigins[0].x;
|
screenInfo.screens[0]->x;
|
||||||
shiftedEvent.u.keyButtonPointer.rootY +=
|
shiftedEvent.u.keyButtonPointer.rootY +=
|
||||||
dixScreenOrigins[scr].y -
|
screenInfo.screens[scr]->y -
|
||||||
dixScreenOrigins[0].y;
|
screenInfo.screens[0]->y;
|
||||||
pEvToRecord = &shiftedEvent;
|
pEvToRecord = &shiftedEvent;
|
||||||
}
|
}
|
||||||
#endif /* PANORAMIX */
|
#endif /* PANORAMIX */
|
||||||
|
|
|
@ -2832,22 +2832,22 @@ PanoramiXRenderComposite (ClientPtr client)
|
||||||
stuff->src = src->info[j].id;
|
stuff->src = src->info[j].id;
|
||||||
if (src->u.pict.root)
|
if (src->u.pict.root)
|
||||||
{
|
{
|
||||||
stuff->xSrc = orig.xSrc - dixScreenOrigins[j].x;
|
stuff->xSrc = orig.xSrc - screenInfo.screens[j]->x;
|
||||||
stuff->ySrc = orig.ySrc - dixScreenOrigins[j].y;
|
stuff->ySrc = orig.ySrc - screenInfo.screens[j]->y;
|
||||||
}
|
}
|
||||||
stuff->dst = dst->info[j].id;
|
stuff->dst = dst->info[j].id;
|
||||||
if (dst->u.pict.root)
|
if (dst->u.pict.root)
|
||||||
{
|
{
|
||||||
stuff->xDst = orig.xDst - dixScreenOrigins[j].x;
|
stuff->xDst = orig.xDst - screenInfo.screens[j]->x;
|
||||||
stuff->yDst = orig.yDst - dixScreenOrigins[j].y;
|
stuff->yDst = orig.yDst - screenInfo.screens[j]->y;
|
||||||
}
|
}
|
||||||
if (msk)
|
if (msk)
|
||||||
{
|
{
|
||||||
stuff->mask = msk->info[j].id;
|
stuff->mask = msk->info[j].id;
|
||||||
if (msk->u.pict.root)
|
if (msk->u.pict.root)
|
||||||
{
|
{
|
||||||
stuff->xMask = orig.xMask - dixScreenOrigins[j].x;
|
stuff->xMask = orig.xMask - screenInfo.screens[j]->x;
|
||||||
stuff->yMask = orig.yMask - dixScreenOrigins[j].y;
|
stuff->yMask = orig.yMask - screenInfo.screens[j]->y;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
result = (*PanoramiXSaveRenderVector[X_RenderComposite]) (client);
|
result = (*PanoramiXSaveRenderVector[X_RenderComposite]) (client);
|
||||||
|
@ -2881,14 +2881,14 @@ PanoramiXRenderCompositeGlyphs (ClientPtr client)
|
||||||
stuff->src = src->info[j].id;
|
stuff->src = src->info[j].id;
|
||||||
if (src->u.pict.root)
|
if (src->u.pict.root)
|
||||||
{
|
{
|
||||||
stuff->xSrc = xSrc - dixScreenOrigins[j].x;
|
stuff->xSrc = xSrc - screenInfo.screens[j]->x;
|
||||||
stuff->ySrc = ySrc - dixScreenOrigins[j].y;
|
stuff->ySrc = ySrc - screenInfo.screens[j]->y;
|
||||||
}
|
}
|
||||||
stuff->dst = dst->info[j].id;
|
stuff->dst = dst->info[j].id;
|
||||||
if (dst->u.pict.root)
|
if (dst->u.pict.root)
|
||||||
{
|
{
|
||||||
elt->deltax = origElt.deltax - dixScreenOrigins[j].x;
|
elt->deltax = origElt.deltax - screenInfo.screens[j]->x;
|
||||||
elt->deltay = origElt.deltay - dixScreenOrigins[j].y;
|
elt->deltay = origElt.deltay - screenInfo.screens[j]->y;
|
||||||
}
|
}
|
||||||
result = (*PanoramiXSaveRenderVector[stuff->renderReqType]) (client);
|
result = (*PanoramiXSaveRenderVector[stuff->renderReqType]) (client);
|
||||||
if(result != Success) break;
|
if(result != Success) break;
|
||||||
|
@ -2918,8 +2918,8 @@ PanoramiXRenderFillRectangles (ClientPtr client)
|
||||||
if (j) memcpy (stuff + 1, extra, extra_len);
|
if (j) memcpy (stuff + 1, extra, extra_len);
|
||||||
if (dst->u.pict.root)
|
if (dst->u.pict.root)
|
||||||
{
|
{
|
||||||
int x_off = dixScreenOrigins[j].x;
|
int x_off = screenInfo.screens[j]->x;
|
||||||
int y_off = dixScreenOrigins[j].y;
|
int y_off = screenInfo.screens[j]->y;
|
||||||
|
|
||||||
if(x_off || y_off) {
|
if(x_off || y_off) {
|
||||||
xRectangle *rects = (xRectangle *) (stuff + 1);
|
xRectangle *rects = (xRectangle *) (stuff + 1);
|
||||||
|
@ -2966,8 +2966,8 @@ PanoramiXRenderTrapezoids(ClientPtr client)
|
||||||
FOR_NSCREENS_FORWARD(j) {
|
FOR_NSCREENS_FORWARD(j) {
|
||||||
if (j) memcpy (stuff + 1, extra, extra_len);
|
if (j) memcpy (stuff + 1, extra, extra_len);
|
||||||
if (dst->u.pict.root) {
|
if (dst->u.pict.root) {
|
||||||
int x_off = dixScreenOrigins[j].x;
|
int x_off = screenInfo.screens[j]->x;
|
||||||
int y_off = dixScreenOrigins[j].y;
|
int y_off = screenInfo.screens[j]->y;
|
||||||
|
|
||||||
if(x_off || y_off) {
|
if(x_off || y_off) {
|
||||||
xTrapezoid *trap = (xTrapezoid *) (stuff + 1);
|
xTrapezoid *trap = (xTrapezoid *) (stuff + 1);
|
||||||
|
@ -3026,8 +3026,8 @@ PanoramiXRenderTriangles(ClientPtr client)
|
||||||
FOR_NSCREENS_FORWARD(j) {
|
FOR_NSCREENS_FORWARD(j) {
|
||||||
if (j) memcpy (stuff + 1, extra, extra_len);
|
if (j) memcpy (stuff + 1, extra, extra_len);
|
||||||
if (dst->u.pict.root) {
|
if (dst->u.pict.root) {
|
||||||
int x_off = dixScreenOrigins[j].x;
|
int x_off = screenInfo.screens[j]->x;
|
||||||
int y_off = dixScreenOrigins[j].y;
|
int y_off = screenInfo.screens[j]->y;
|
||||||
|
|
||||||
if(x_off || y_off) {
|
if(x_off || y_off) {
|
||||||
xTriangle *tri = (xTriangle *) (stuff + 1);
|
xTriangle *tri = (xTriangle *) (stuff + 1);
|
||||||
|
@ -3082,8 +3082,8 @@ PanoramiXRenderTriStrip(ClientPtr client)
|
||||||
FOR_NSCREENS_FORWARD(j) {
|
FOR_NSCREENS_FORWARD(j) {
|
||||||
if (j) memcpy (stuff + 1, extra, extra_len);
|
if (j) memcpy (stuff + 1, extra, extra_len);
|
||||||
if (dst->u.pict.root) {
|
if (dst->u.pict.root) {
|
||||||
int x_off = dixScreenOrigins[j].x;
|
int x_off = screenInfo.screens[j]->x;
|
||||||
int y_off = dixScreenOrigins[j].y;
|
int y_off = screenInfo.screens[j]->y;
|
||||||
|
|
||||||
if(x_off || y_off) {
|
if(x_off || y_off) {
|
||||||
xPointFixed *fixed = (xPointFixed *) (stuff + 1);
|
xPointFixed *fixed = (xPointFixed *) (stuff + 1);
|
||||||
|
@ -3134,8 +3134,8 @@ PanoramiXRenderTriFan(ClientPtr client)
|
||||||
FOR_NSCREENS_FORWARD(j) {
|
FOR_NSCREENS_FORWARD(j) {
|
||||||
if (j) memcpy (stuff + 1, extra, extra_len);
|
if (j) memcpy (stuff + 1, extra, extra_len);
|
||||||
if (dst->u.pict.root) {
|
if (dst->u.pict.root) {
|
||||||
int x_off = dixScreenOrigins[j].x;
|
int x_off = screenInfo.screens[j]->x;
|
||||||
int y_off = dixScreenOrigins[j].y;
|
int y_off = screenInfo.screens[j]->y;
|
||||||
|
|
||||||
if(x_off || y_off) {
|
if(x_off || y_off) {
|
||||||
xPointFixed *fixed = (xPointFixed *) (stuff + 1);
|
xPointFixed *fixed = (xPointFixed *) (stuff + 1);
|
||||||
|
@ -3188,8 +3188,8 @@ PanoramiXRenderAddTraps (ClientPtr client)
|
||||||
|
|
||||||
if (picture->u.pict.root)
|
if (picture->u.pict.root)
|
||||||
{
|
{
|
||||||
stuff->xOff = x_off + dixScreenOrigins[j].x;
|
stuff->xOff = x_off + screenInfo.screens[j]->x;
|
||||||
stuff->yOff = y_off + dixScreenOrigins[j].y;
|
stuff->yOff = y_off + screenInfo.screens[j]->y;
|
||||||
}
|
}
|
||||||
result = (*PanoramiXSaveRenderVector[X_RenderAddTraps]) (client);
|
result = (*PanoramiXSaveRenderVector[X_RenderAddTraps]) (client);
|
||||||
if(result != Success) break;
|
if(result != Success) break;
|
||||||
|
|
Loading…
Reference in New Issue