mirror of
https://github.com/X11Libre/xserver.git
synced 2026-09-29 21:46:40 +00:00
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
28 changed files with 321 additions and 333 deletions
|
|
@ -296,8 +296,8 @@ QuartzWarpCursor(DeviceIntPtr pDev, ScreenPtr pScreen, int x, int y)
|
|||
{
|
||||
int sx, sy;
|
||||
|
||||
sx = dixScreenOrigins[pScreen->myNum].x + darwinMainScreenX;
|
||||
sy = dixScreenOrigins[pScreen->myNum].y + darwinMainScreenY;
|
||||
sx = pScreen->x + darwinMainScreenX;
|
||||
sy = pScreen->y + darwinMainScreenY;
|
||||
|
||||
CGWarpMouseCursorPosition(CGPointMake(sx + x, sy + y));
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue