rename old symbol PANORAMIX to XINERAMA

PANORAMIX was the original working title of the extension, before it became
official standard. Just nobody cared about fixing the symbols to the official
naming.

For backwards compatibility with drivers, the old PANORAMIX symbol will
still be set.

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
Part-of: <https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/1258>
This commit is contained in:
Enrico Weigelt, metux IT consult 2024-01-24 20:04:37 +01:00 committed by Marge Bot
parent a0326994cc
commit fb696a7d7b
48 changed files with 278 additions and 273 deletions

View File

@ -52,10 +52,10 @@ in this Software without prior written authorization from the X Consortium.
#include "colormapst.h"
#include "xace.h"
#include "inputstr.h"
#ifdef PANORAMIX
#ifdef XINERAMA
#include "panoramiX.h"
#include "panoramiXsrv.h"
#endif
#endif /* XINERAMA */
#ifdef DPMSExtension
#include <X11/extensions/dpmsconst.h>
#include "dpmsproc.h"
@ -588,9 +588,9 @@ ScreenSaverHandle(ScreenPtr pScreen, int xstate, Bool force)
ret = TRUE;
}
#ifdef PANORAMIX
#ifdef XINERAMA
if (noPanoramiXExtension || !pScreen->myNum)
#endif
#endif /* XINERAMA */
SendScreenSaverNotify(pScreen, state, force);
return ret;
}
@ -1078,7 +1078,7 @@ ScreenSaverUnsetAttributes(ClientPtr client)
static int
ProcScreenSaverSetAttributes(ClientPtr client)
{
#ifdef PANORAMIX
#ifdef XINERAMA
if (!noPanoramiXExtension) {
REQUEST(xScreenSaverSetAttributesReq);
PanoramiXRes *draw;
@ -1157,7 +1157,7 @@ ProcScreenSaverSetAttributes(ClientPtr client)
return status;
}
#endif
#endif /* XINERAMA */
return ScreenSaverSetAttributes(client);
}
@ -1165,7 +1165,7 @@ ProcScreenSaverSetAttributes(ClientPtr client)
static int
ProcScreenSaverUnsetAttributes(ClientPtr client)
{
#ifdef PANORAMIX
#ifdef XINERAMA
if (!noPanoramiXExtension) {
REQUEST(xScreenSaverUnsetAttributesReq);
PanoramiXRes *draw;
@ -1185,7 +1185,7 @@ ProcScreenSaverUnsetAttributes(ClientPtr client)
stuff->drawable = draw->info[0].id;
}
#endif
#endif /* XINERAMA */
return ScreenSaverUnsetAttributes(client);
}

View File

@ -65,10 +65,10 @@ static void SShapeNotifyEvent(xShapeNotifyEvent * /* from */ ,
* externally by the Xfixes extension and are now defined in window.h
*/
#ifdef PANORAMIX
#ifdef XINERAMA
#include "panoramiX.h"
#include "panoramiXsrv.h"
#endif
#endif /* XINERAMA */
static int ShapeEventBase = 0;
static RESTYPE ClientType, ShapeEventType; /* resource types for event masks */
@ -297,7 +297,7 @@ ProcShapeRectangles(ClientPtr client)
stuff->xOff, stuff->yOff, createDefault);
}
#ifdef PANORAMIX
#ifdef XINERAMA
static int
ProcPanoramiXShapeRectangles(ClientPtr client)
{
@ -320,7 +320,7 @@ ProcPanoramiXShapeRectangles(ClientPtr client)
}
return result;
}
#endif
#endif /* XINERAMA */
/**************
* ProcShapeMask
@ -395,7 +395,7 @@ ProcShapeMask(ClientPtr client)
stuff->xOff, stuff->yOff, createDefault);
}
#ifdef PANORAMIX
#ifdef XINERAMA
static int
ProcPanoramiXShapeMask(ClientPtr client)
{
@ -429,7 +429,7 @@ ProcPanoramiXShapeMask(ClientPtr client)
}
return result;
}
#endif
#endif /* XINERAMA */
/************
* ProcShapeCombine
@ -523,7 +523,7 @@ ProcShapeCombine(ClientPtr client)
stuff->xOff, stuff->yOff, createDefault);
}
#ifdef PANORAMIX
#ifdef XINERAMA
static int
ProcPanoramiXShapeCombine(ClientPtr client)
{
@ -552,7 +552,7 @@ ProcPanoramiXShapeCombine(ClientPtr client)
}
return result;
}
#endif
#endif /* XINERAMA */
/*************
* ProcShapeOffset
@ -594,7 +594,7 @@ ProcShapeOffset(ClientPtr client)
return Success;
}
#ifdef PANORAMIX
#ifdef XINERAMA
static int
ProcPanoramiXShapeOffset(ClientPtr client)
{
@ -617,7 +617,7 @@ ProcPanoramiXShapeOffset(ClientPtr client)
}
return result;
}
#endif
#endif /* XINERAMA */
static int
ProcShapeQueryExtents(ClientPtr client)
@ -1035,32 +1035,32 @@ ProcShapeDispatch(ClientPtr client)
case X_ShapeQueryVersion:
return ProcShapeQueryVersion(client);
case X_ShapeRectangles:
#ifdef PANORAMIX
#ifdef XINERAMA
if (!noPanoramiXExtension)
return ProcPanoramiXShapeRectangles(client);
else
#endif
#endif /* XINERAMA */
return ProcShapeRectangles(client);
case X_ShapeMask:
#ifdef PANORAMIX
#ifdef XINERAMA
if (!noPanoramiXExtension)
return ProcPanoramiXShapeMask(client);
else
#endif
#endif /* XINERAMA */
return ProcShapeMask(client);
case X_ShapeCombine:
#ifdef PANORAMIX
#ifdef XINERAMA
if (!noPanoramiXExtension)
return ProcPanoramiXShapeCombine(client);
else
#endif
#endif /* XINERAMA */
return ProcShapeCombine(client);
case X_ShapeOffset:
#ifdef PANORAMIX
#ifdef XINERAMA
if (!noPanoramiXExtension)
return ProcPanoramiXShapeOffset(client);
else
#endif
#endif /* XINERAMA */
return ProcShapeOffset(client);
case X_ShapeQueryExtents:
return ProcShapeQueryExtents(client);

View File

@ -89,10 +89,10 @@ in this Software without prior written authorization from The Open Group.
#define SHMPERM_MODE(p) p->mode
#endif
#ifdef PANORAMIX
#ifdef XINERAMA
#include "panoramiX.h"
#include "panoramiXsrv.h"
#endif
#endif /* XINERAMA */
typedef struct _ShmScrPrivateRec {
CloseScreenProcPtr CloseScreen;
@ -730,7 +730,7 @@ ProcShmGetImage(ClientPtr client)
return Success;
}
#ifdef PANORAMIX
#ifdef XINERAMA
static int
ProcPanoramiXShmPutImage(ClientPtr client)
{
@ -1026,7 +1026,7 @@ ProcPanoramiXShmCreatePixmap(ClientPtr client)
return result;
}
#endif
#endif /* XINERAMA */
static PixmapPtr
fbShmCreatePixmap(ScreenPtr pScreen,
@ -1346,22 +1346,22 @@ ProcShmDispatch(ClientPtr client)
case X_ShmDetach:
return ProcShmDetach(client);
case X_ShmPutImage:
#ifdef PANORAMIX
#ifdef XINERAMA
if (!noPanoramiXExtension)
return ProcPanoramiXShmPutImage(client);
#endif
#endif /* XINERAMA */
return ProcShmPutImage(client);
case X_ShmGetImage:
#ifdef PANORAMIX
#ifdef XINERAMA
if (!noPanoramiXExtension)
return ProcPanoramiXShmGetImage(client);
#endif
#endif /* XINERAMA */
return ProcShmGetImage(client);
case X_ShmCreatePixmap:
#ifdef PANORAMIX
#ifdef XINERAMA
if (!noPanoramiXExtension)
return ProcPanoramiXShmCreatePixmap(client);
#endif
#endif /* XINERAMA */
return ProcShmCreatePixmap(client);
#ifdef SHM_FD_PASSING
case X_ShmAttachFd:

View File

@ -78,10 +78,10 @@ static InternalEvent *xtest_evlist;
*/
DeviceIntPtr xtestpointer, xtestkeyboard;
#ifdef PANORAMIX
#ifdef XINERAMA
#include "panoramiX.h"
#include "panoramiXsrv.h"
#endif
#endif /* XINERAMA */
static int XTestSwapFakeInput(ClientPtr /* client */ ,
xReq * /* req */

View File

@ -48,12 +48,12 @@ SOFTWARE.
#include "xvdisp.h"
#ifdef PANORAMIX
#ifdef XINERAMA
#include "panoramiX.h"
#include "panoramiXsrv.h"
unsigned long XvXRTPort;
#endif
#endif /* XINERAMA */
static int
SWriteQueryExtensionReply(ClientPtr client, xvQueryExtensionReply * rep)
@ -1433,7 +1433,7 @@ SProcXvDispatch(ClientPtr client)
return SXvProcVector[stuff->data] (client);
}
#ifdef PANORAMIX
#ifdef XINERAMA
static int
XineramaXvStopVideo(ClientPtr client)
{
@ -1541,7 +1541,7 @@ XineramaXvShmPutImage(ClientPtr client)
}
#else
#define XineramaXvShmPutImage ProcXvShmPutImage
#endif
#endif /* MITSHM */
static int
XineramaXvPutImage(ClientPtr client)
@ -1796,17 +1796,17 @@ XineramifyXv(void)
XvProcVector[xv_PutImage] = XineramaXvPutImage;
XvProcVector[xv_ShmPutImage] = XineramaXvShmPutImage;
}
#endif /* PANORAMIX */
#endif /* XINERAMA */
void
XvResetProcVector(void)
{
#ifdef PANORAMIX
#ifdef XINERAMA
XvProcVector[xv_PutVideo] = ProcXvPutVideo;
XvProcVector[xv_PutStill] = ProcXvPutStill;
XvProcVector[xv_StopVideo] = ProcXvStopVideo;
XvProcVector[xv_SetPortAttribute] = ProcXvSetPortAttribute;
XvProcVector[xv_PutImage] = ProcXvPutImage;
XvProcVector[xv_ShmPutImage] = ProcXvShmPutImage;
#endif
#endif /* XINERAMA */
}

View File

@ -96,10 +96,10 @@ SOFTWARE.
#include "opaque.h"
#include "input.h"
#ifdef PANORAMIX
#ifdef XINERAMA
#include "panoramiX.h"
#include "panoramiXsrv.h"
#endif
#endif /* XINERAMA */
#include "xvdisp.h"
#define SCREEN_PROLOGUE(pScreen, field) ((pScreen)->field = ((XvScreenPtr) \
@ -174,9 +174,9 @@ XvExtensionInit(void)
ErrorF("XvExtensionInit: Unable to allocate resource types\n");
return;
}
#ifdef PANORAMIX
#ifdef XINERAMA
XineramaRegisterConnectionBlockCallback(XineramifyXv);
#endif
#endif /* XINERAMA */
XvScreenGeneration = serverGeneration;
}
@ -267,9 +267,9 @@ XvScreenInit(ScreenPtr pScreen)
ErrorF("XvScreenInit: Unable to allocate resource types\n");
return BadAlloc;
}
#ifdef PANORAMIX
#ifdef XINERAMA
XineramaRegisterConnectionBlockCallback(XineramifyXv);
#endif
#endif /* XINERAMA */
XvScreenGeneration = serverGeneration;
}

View File

@ -48,9 +48,9 @@
#include "scrnintstr.h"
#include "xkbsrv.h"
#ifdef PANORAMIX
#ifdef XINERAMA
#include "panoramiXsrv.h"
#endif
#endif /* XINERAMA */
#include "inpututils.h"
#include "xiquerypointer.h"
@ -184,7 +184,7 @@ ProcXIQueryPointer(ClientPtr client)
rep.win_y = 0;
}
#ifdef PANORAMIX
#ifdef XINERAMA
if (!noPanoramiXExtension) {
rep.root_x += double_to_fp1616(screenInfo.screens[0]->x);
rep.root_y += double_to_fp1616(screenInfo.screens[0]->y);
@ -193,7 +193,7 @@ ProcXIQueryPointer(ClientPtr client)
rep.win_y += double_to_fp1616(screenInfo.screens[0]->y);
}
}
#endif
#endif /* XINERAMA */
WriteReplyToClient(client, sizeof(xXIQueryPointerReply), &rep);
if (buttons)

View File

@ -587,7 +587,7 @@ CompositeExtensionInit(void)
noCompositeExtension = FALSE;
}
#ifdef PANORAMIX
#ifdef XINERAMA
#include "panoramiXsrv.h"
int (*PanoramiXSaveCompositeVector[CompositeNumberRequests]) (ClientPtr);
@ -940,4 +940,4 @@ PanoramiXCompositeReset(void)
ProcCompositeVector[i] = PanoramiXSaveCompositeVector[i];
}
#endif
#endif /* XINERAMA */

View File

@ -46,9 +46,9 @@
#include "compint.h"
#include "xace.h"
#ifdef PANORAMIX
#ifdef XINERAMA
#include "panoramiXsrv.h"
#endif
#endif /* XINERAMA */
/*
* Delete the given overlay client list element from its screen list.
@ -133,14 +133,14 @@ compCreateOverlayWindow(ScreenPtr pScreen)
int h = pScreen->height;
int x = 0, y = 0;
#ifdef PANORAMIX
#ifdef XINERAMA
if (!noPanoramiXExtension) {
x = -pScreen->x;
y = -pScreen->y;
w = PanoramiXPixWidth;
h = PanoramiXPixHeight;
}
#endif
#endif /* XINERAMA */
pWin = cs->pOverlayWin =
CreateWindow(cs->overlayWid, pRoot, x, y, w, h, 0,

View File

@ -49,9 +49,9 @@
#include "compint.h"
#include "compositeext_priv.h"
#ifdef PANORAMIX
#ifdef XINERAMA
#include "panoramiXsrv.h"
#endif
#endif /* XINERAMA */
#ifdef COMPOSITE_DEBUG
static int
@ -201,12 +201,12 @@ updateOverlayWindow(ScreenPtr pScreen)
int w = pScreen->width;
int h = pScreen->height;
#ifdef PANORAMIX
#ifdef XINERAMA
if (!noPanoramiXExtension) {
w = PanoramiXPixWidth;
h = PanoramiXPixHeight;
}
#endif
#endif /* XINERAMA */
cs = GetCompScreen(pScreen);
if ((pWin = cs->pOverlayWin) != NULL) {

View File

@ -31,7 +31,7 @@
#include "extinit_priv.h"
#include "dixstruct_priv.h"
#ifdef PANORAMIX
#ifdef XINERAMA
#include "panoramiX.h"
#include "panoramiXsrv.h"
@ -43,7 +43,7 @@ typedef struct {
static RESTYPE XRT_DAMAGE;
static int (*PanoramiXSaveDamageCreate) (ClientPtr);
#endif
#endif /* XINERAMA */
static unsigned char DamageReqCode;
static int DamageEventBase;
@ -68,7 +68,7 @@ DamageNoteCritical(ClientPtr pClient)
static void
damageGetGeometry(DrawablePtr draw, int *x, int *y, int *w, int *h)
{
#ifdef PANORAMIX
#ifdef XINERAMA
if (!noPanoramiXExtension && draw->type == DRAWABLE_WINDOW) {
WindowPtr win = (WindowPtr)draw;
@ -80,7 +80,7 @@ damageGetGeometry(DrawablePtr draw, int *x, int *y, int *w, int *h)
return;
}
}
#endif
#endif /* XINERAMA */
*x = draw->x;
*y = draw->y;
@ -319,7 +319,7 @@ ProcDamageDestroy(ClientPtr client)
return Success;
}
#ifdef PANORAMIX
#ifdef XINERAMA
static RegionPtr
DamageExtSubtractWindowClip(DamageExtPtr pDamageExt)
{
@ -367,7 +367,7 @@ DamageExtFreeWindowClip(RegionPtr reg)
if (reg != &PanoramiXScreenRegion)
RegionDestroy(reg);
}
#endif
#endif /* XINERAMA */
/*
* DamageSubtract intersects with borderClip, so we must reconstruct the
@ -378,7 +378,7 @@ DamageExtSubtract(DamageExtPtr pDamageExt, const RegionPtr pRegion)
{
DamagePtr pDamage = pDamageExt->pDamage;
#ifdef PANORAMIX
#ifdef XINERAMA
if (!noPanoramiXExtension) {
RegionPtr damage = DamageRegion(pDamage);
RegionSubtract(damage, damage, pRegion);
@ -396,7 +396,7 @@ DamageExtSubtract(DamageExtPtr pDamageExt, const RegionPtr pRegion)
return RegionNotEmpty(damage);
}
#endif
#endif /* XINERAMA */
return DamageSubtract(pDamage, pRegion);
}
@ -604,7 +604,7 @@ SDamageNotifyEvent(xDamageNotifyEvent * from, xDamageNotifyEvent * to)
cpswaps(from->geometry.height, to->geometry.height);
}
#ifdef PANORAMIX
#ifdef XINERAMA
static void
PanoramiXDamageReport(DamagePtr pDamage, RegionPtr pRegion, void *closure)
@ -723,7 +723,7 @@ PanoramiXDamageReset(void)
ProcDamageVector[X_DamageCreate] = PanoramiXSaveDamageCreate;
}
#endif /* PANORAMIX */
#endif /* XINERAMA */
void
DamageExtensionInit(void)
@ -752,10 +752,10 @@ DamageExtensionInit(void)
(EventSwapPtr) SDamageNotifyEvent;
SetResourceTypeErrorValue(DamageExtType,
extEntry->errorBase + BadDamage);
#ifdef PANORAMIX
#ifdef XINERAMA
if (XRT_DAMAGE)
SetResourceTypeErrorValue(XRT_DAMAGE,
extEntry->errorBase + BadDamage);
#endif
#endif /* XINERAMA */
}
}

View File

@ -1367,10 +1367,10 @@ DbeExtensionInit(void)
int nStubbedScreens = 0;
Bool ddxInitSuccess;
#ifdef PANORAMIX
#ifdef XINERAMA
if (!noPanoramiXExtension)
return;
#endif
#endif /* XINERAMA */
/* Create the resource types. */
dbeDrawableResType =

View File

@ -471,9 +471,9 @@ TellNoMap(WindowPtr pwin, Colormap * pmid)
.u.colormap.state = ColormapUninstalled
};
xE.u.u.type = ColormapNotify;
#ifdef PANORAMIX
#ifdef XINERAMA
if (noPanoramiXExtension || !pwin->drawable.pScreen->myNum)
#endif
#endif /* XINERAMA */
DeliverEvents(pwin, &xE, 1, (WindowPtr) NULL);
if (pwin->optional) {
pwin->optional->colormap = None;
@ -490,10 +490,10 @@ TellLostMap(WindowPtr pwin, void *value)
{
Colormap *pmid = (Colormap *) value;
#ifdef PANORAMIX
#ifdef XINERAMA
if (!noPanoramiXExtension && pwin->drawable.pScreen->myNum)
return WT_STOPWALKING;
#endif
#endif /* XINERAMA */
if (wColormap(pwin) == *pmid) {
/* This should be call to DeliverEvent */
xEvent xE = {
@ -515,10 +515,10 @@ TellGainedMap(WindowPtr pwin, void *value)
{
Colormap *pmid = (Colormap *) value;
#ifdef PANORAMIX
#ifdef XINERAMA
if (!noPanoramiXExtension && pwin->drawable.pScreen->myNum)
return WT_STOPWALKING;
#endif
#endif /* XINERAMA */
if (wColormap(pwin) == *pmid) {
/* This should be call to DeliverEvent */
xEvent xE = {

View File

@ -2631,9 +2631,9 @@ ProcAllocColor(ClientPtr client)
if ((rc = AllocColor(pmap, &acr.red, &acr.green, &acr.blue,
&acr.pixel, client->index)))
return rc;
#ifdef PANORAMIX
#ifdef XINERAMA
if (noPanoramiXExtension || !pmap->pScreen->myNum)
#endif
#endif /* XINERAMA */
WriteReplyToClient(client, sizeof(xAllocColorReply), &acr);
return Success;
@ -2672,9 +2672,9 @@ ProcAllocNamedColor(ClientPtr client)
&ancr.screenRed, &ancr.screenGreen,
&ancr.screenBlue, &ancr.pixel, client->index)))
return rc;
#ifdef PANORAMIX
#ifdef XINERAMA
if (noPanoramiXExtension || !pcmp->pScreen->myNum)
#endif
#endif /* XINERAMA */
WriteReplyToClient(client, sizeof(xAllocNamedColorReply),
&ancr);
return Success;
@ -2726,9 +2726,9 @@ ProcAllocColorCells(ClientPtr client)
free(ppixels);
return rc;
}
#ifdef PANORAMIX
#ifdef XINERAMA
if (noPanoramiXExtension || !pcmp->pScreen->myNum)
#endif
#endif /* XINERAMA */
{
xAllocColorCellsReply accr = {
.type = X_Reply,
@ -2795,9 +2795,9 @@ ProcAllocColorPlanes(ClientPtr client)
return rc;
}
acpr.length = bytes_to_int32(length);
#ifdef PANORAMIX
#ifdef XINERAMA
if (noPanoramiXExtension || !pcmp->pScreen->myNum)
#endif
#endif /* XINERAMA */
{
WriteReplyToClient(client, sizeof(xAllocColorPlanesReply), &acpr);
client->pSwapReplyFunc = (ReplySwapPtr) Swap32Write;
@ -3737,12 +3737,12 @@ SendConnSetup(ClientPtr client, const char *reason)
#endif
/* fill in the "currentInputMask" */
root = (xWindowRoot *) (lConnectionInfo + connBlockScreenStart);
#ifdef PANORAMIX
#ifdef XINERAMA
if (noPanoramiXExtension)
numScreens = screenInfo.numScreens;
else
numScreens = ((xConnSetup *) ConnectionInfo)->numRoots;
#endif
#endif /* XINERAMA */
for (i = 0; i < numScreens; i++) {
unsigned int j;

View File

@ -1333,9 +1333,9 @@ doPolyText(ClientPtr client, PTclosurePtr c)
if (c->err != Success)
err = c->err;
if (err != Success && c->client != serverClient) {
#ifdef PANORAMIX
#ifdef XINERAMA
if (noPanoramiXExtension || !c->pGC->pScreen->myNum)
#endif
#endif /* XINERAMA */
SendErrorToClient(c->client, c->reqType, 0, 0, err);
}
if (ClientIsAsleep(client)) {

View File

@ -1251,10 +1251,10 @@ CoreFocusPointerRootNoneSwitch(DeviceIntPtr dev,
int i;
int nscreens = screenInfo.numScreens;
#ifdef PANORAMIX
#ifdef XINERAMA
if (!noPanoramiXExtension)
nscreens = 1;
#endif
#endif /* XINERAMA */
for (i = 0; i < nscreens; i++) {
root = screenInfo.screens[i]->root;
@ -1295,10 +1295,10 @@ CoreFocusToPointerRootOrNone(DeviceIntPtr dev, WindowPtr A,
int i;
int nscreens = screenInfo.numScreens;
#ifdef PANORAMIX
#ifdef XINERAMA
if (!noPanoramiXExtension)
nscreens = 1;
#endif
#endif /* XINERAMA */
if (!HasFocus(A)) {
WindowPtr child = FirstFocusChild(A);
@ -1342,10 +1342,10 @@ CoreFocusFromPointerRootOrNone(DeviceIntPtr dev,
int i;
int nscreens = screenInfo.numScreens;
#ifdef PANORAMIX
#ifdef XINERAMA
if (!noPanoramiXExtension)
nscreens = 1;
#endif
#endif /* XINERAMA */
for (i = 0; i < nscreens; i++) {
root = screenInfo.screens[i]->root;
@ -1432,10 +1432,10 @@ DeviceFocusEvents(DeviceIntPtr dev, WindowPtr from, WindowPtr to, int mode)
in = (to == NoneWin) ? NotifyDetailNone : NotifyPointerRoot;
/* wrong values if neither, but then not referenced */
#ifdef PANORAMIX
#ifdef XINERAMA
if (!noPanoramiXExtension)
nscreens = 1;
#endif
#endif /* XINERAMA */
if ((to == NullWindow) || (to == PointerRootWin)) {
if ((from == NullWindow) || (from == PointerRootWin)) {

View File

@ -134,10 +134,10 @@ Equipment Corporation.
#include "scrnintstr.h"
#include "cursorstr.h"
#include "dixstruct.h"
#ifdef PANORAMIX
#ifdef XINERAMA
#include "panoramiX.h"
#include "panoramiXsrv.h"
#endif
#endif /* XINERAMA */
#include "globals.h"
#include "xace.h"
#include "probes.h"
@ -512,17 +512,17 @@ SyntheticMotion(DeviceIntPtr dev, int x, int y)
{
int screenno = 0;
#ifdef PANORAMIX
#ifdef XINERAMA
if (!noPanoramiXExtension)
screenno = dev->spriteInfo->sprite->screen->myNum;
#endif
#endif /* XINERAMA */
PostSyntheticMotion(dev, x, y, screenno,
(syncEvents.playingEvents) ? syncEvents.time.
milliseconds : currentTime.milliseconds);
}
#ifdef PANORAMIX
#ifdef XINERAMA
static void PostNewCursor(DeviceIntPtr pDev);
static Bool
@ -657,7 +657,7 @@ XineramaConfineCursorToWindow(DeviceIntPtr pDev,
CheckPhysLimits(pDev, pSprite->current, generateEvents, FALSE, NULL);
}
#endif /* PANORAMIX */
#endif /* XINERAMA */
/**
* Modifies the filter for the given protocol event type to the given masks.
@ -733,12 +733,12 @@ CheckPhysLimits(DeviceIntPtr pDev, CursorPtr cursor, Bool generateEvents,
if (!cursor)
return;
new = pSprite->hotPhys;
#ifdef PANORAMIX
#ifdef XINERAMA
if (!noPanoramiXExtension)
/* I don't care what the DDX has to say about it */
pSprite->physLimits = pSprite->hotLimits;
else
#endif
#endif /* XINERAMA */
{
if (pScreen)
new.pScreen = pScreen;
@ -762,16 +762,16 @@ CheckPhysLimits(DeviceIntPtr pDev, CursorPtr cursor, Bool generateEvents,
if (pSprite->hotShape)
ConfineToShape(pDev, pSprite->hotShape, &new.x, &new.y);
if ((
#ifdef PANORAMIX
#ifdef XINERAMA
noPanoramiXExtension &&
#endif
#endif /* XINERAMA */
(pScreen != pSprite->hotPhys.pScreen)) ||
(new.x != pSprite->hotPhys.x) || (new.y != pSprite->hotPhys.y)) {
#ifdef PANORAMIX
#ifdef XINERAMA
if (!noPanoramiXExtension)
XineramaSetCursorPosition(pDev, new.x, new.y, generateEvents);
else
#endif
#endif /* XINERAMA */
{
if (pScreen != pSprite->hotPhys.pScreen)
pSprite->hotPhys = new;
@ -782,11 +782,11 @@ CheckPhysLimits(DeviceIntPtr pDev, CursorPtr cursor, Bool generateEvents,
SyntheticMotion(pDev, new.x, new.y);
}
#ifdef PANORAMIX
#ifdef XINERAMA
/* Tell DDX what the limits are */
if (!noPanoramiXExtension)
XineramaConstrainCursor(pDev);
#endif
#endif /* XINERAMA */
}
static void
@ -820,7 +820,7 @@ CheckVirtualMotion(DeviceIntPtr pDev, QdEventPtr qe, WindowPtr pWin)
if (pWin) {
BoxRec lims;
#ifdef PANORAMIX
#ifdef XINERAMA
if (!noPanoramiXExtension) {
int x, y, off_x, off_y, i;
@ -848,7 +848,7 @@ CheckVirtualMotion(DeviceIntPtr pDev, QdEventPtr qe, WindowPtr pWin)
}
}
else
#endif
#endif /* XINERAMA */
{
if (pSprite->hot.pScreen != pWin->drawable.pScreen) {
pSprite->hot.pScreen = pWin->drawable.pScreen;
@ -866,14 +866,14 @@ CheckVirtualMotion(DeviceIntPtr pDev, QdEventPtr qe, WindowPtr pWin)
else if (pSprite->hot.y >= lims.y2)
pSprite->hot.y = lims.y2 - 1;
#ifdef PANORAMIX
#ifdef XINERAMA
if (!noPanoramiXExtension) {
if (RegionNumRects(&pSprite->Reg2) > 1)
reg = &pSprite->Reg2;
}
else
#endif
#endif /* XINERAMA */
{
if (wBoundingShape(pWin))
reg = &pWin->borderSize;
@ -888,9 +888,9 @@ CheckVirtualMotion(DeviceIntPtr pDev, QdEventPtr qe, WindowPtr pWin)
ev->root_y = pSprite->hot.y;
}
}
#ifdef PANORAMIX
#ifdef XINERAMA
if (noPanoramiXExtension) /* No typo. Only set the root win if disabled */
#endif
#endif /* XINERAMA */
RootWindow(pDev->spriteInfo->sprite) = pSprite->hot.pScreen->root;
}
@ -907,12 +907,12 @@ ConfineCursorToWindow(DeviceIntPtr pDev, WindowPtr pWin, Bool generateEvents,
else {
ScreenPtr pScreen = pWin->drawable.pScreen;
#ifdef PANORAMIX
#ifdef XINERAMA
if (!noPanoramiXExtension) {
XineramaConfineCursorToWindow(pDev, pWin, generateEvents);
return;
}
#endif
#endif /* XINERAMA */
pSprite->hotLimits = *RegionExtents(&pWin->borderSize);
pSprite->hotShape = wBoundingShape(pWin) ? &pWin->borderSize
: NullRegion;
@ -948,12 +948,12 @@ ChangeToCursor(DeviceIntPtr pDev, CursorPtr cursor)
(pSprite->current->bits->yhot != cursor->bits->yhot))
CheckPhysLimits(pDev, cursor, FALSE, pSprite->confined,
(ScreenPtr) NULL);
#ifdef PANORAMIX
#ifdef XINERAMA
/* XXX: is this really necessary?? (whot) */
if (!noPanoramiXExtension)
pScreen = pSprite->screen;
else
#endif
#endif /* XINERAMA */
pScreen = pSprite->hotPhys.pScreen;
(*pScreen->DisplayCursor) (pDev, pScreen, cursor);
@ -1176,12 +1176,12 @@ EnqueueEvent(InternalEvent *ev, DeviceIntPtr device)
}
if (event->type == ET_Motion) {
#ifdef PANORAMIX
#ifdef XINERAMA
if (!noPanoramiXExtension) {
event->root_x += pSprite->screen->x - screenInfo.screens[0]->x;
event->root_y += pSprite->screen->y - screenInfo.screens[0]->y;
}
#endif
#endif /* XINERAMA */
pSprite->hotPhys.x = event->root_x;
pSprite->hotPhys.y = event->root_y;
/* do motion compression, but not if from different devices */
@ -1239,7 +1239,7 @@ PlayReleasedEvents(void)
CheckVirtualMotion(pDev, qe, NullWindow);
syncEvents.time.months = qe->months;
syncEvents.time.milliseconds = qe->event->any.time;
#ifdef PANORAMIX
#ifdef XINERAMA
/* Translate back to the sprite screen since processInputProc
will translate from sprite screen to screen 0 upon reentry
to the DIX layer */
@ -1267,7 +1267,7 @@ PlayReleasedEvents(void)
}
}
#endif
#endif /* XINERAMA */
(*qe->device->public.processInputProc) (qe->event, qe->device);
free(qe);
for (dev = inputInfo.devices; dev && dev->deviceGrab.sync.frozen;
@ -2486,7 +2486,7 @@ DeliverRawEvent(RawDeviceEvent *ev, DeviceIntPtr device)
Only works for core events.
*/
#ifdef PANORAMIX
#ifdef XINERAMA
static int
XineramaTryClientEventsResult(ClientPtr client,
GrabPtr grab, Mask mask, Mask filter)
@ -2500,7 +2500,7 @@ XineramaTryClientEventsResult(ClientPtr client,
}
return 0;
}
#endif
#endif /* XINERAMA */
/**
* Try to deliver events to the interested parties.
@ -2520,11 +2520,11 @@ MaybeDeliverEventsToClient(WindowPtr pWin, xEvent *pEvents,
if (pWin->eventMask & filter) {
if (wClient(pWin) == dontClient)
return 0;
#ifdef PANORAMIX
#ifdef XINERAMA
if (!noPanoramiXExtension && pWin->drawable.pScreen->myNum)
return XineramaTryClientEventsResult(wClient(pWin), NullGrab,
pWin->eventMask, filter);
#endif
#endif /* XINERAMA */
if (XaceHookReceiveAccess(wClient(pWin), pWin, pEvents, count))
return 1; /* don't send, but pretend we did */
return TryClientEvents(wClient(pWin), NULL, pEvents, count,
@ -2534,11 +2534,11 @@ MaybeDeliverEventsToClient(WindowPtr pWin, xEvent *pEvents,
if (other->mask & filter) {
if (SameClient(other, dontClient))
return 0;
#ifdef PANORAMIX
#ifdef XINERAMA
if (!noPanoramiXExtension && pWin->drawable.pScreen->myNum)
return XineramaTryClientEventsResult(rClient(other), NullGrab,
other->mask, filter);
#endif
#endif /* XINERAMA */
if (XaceHookReceiveAccess(rClient(other), pWin, pEvents,
count))
return 1; /* don't send, but pretend we did */
@ -2911,10 +2911,10 @@ DeliverEvents(WindowPtr pWin, xEvent *xE, int count, WindowPtr otherParent)
DeviceIntRec dummy;
int deliveries;
#ifdef PANORAMIX
#ifdef XINERAMA
if (!noPanoramiXExtension && pWin->drawable.pScreen->myNum)
return count;
#endif
#endif /* XINERAMA */
if (!count)
return 0;
@ -2979,7 +2979,7 @@ PointInBorderSize(WindowPtr pWin, int x, int y)
if (RegionContainsPoint(&pWin->borderSize, x, y, &box))
return TRUE;
#ifdef PANORAMIX
#ifdef XINERAMA
if (!noPanoramiXExtension &&
XineramaSetWindowPntrs(inputInfo.pointer, pWin)) {
SpritePtr pSprite = inputInfo.pointer->spriteInfo->sprite;
@ -2994,7 +2994,7 @@ PointInBorderSize(WindowPtr pWin, int x, int y)
return TRUE;
}
}
#endif
#endif /* XINERAMA */
return FALSE;
}
@ -3134,7 +3134,7 @@ CheckMotion(DeviceEvent *ev, DeviceIntPtr pDev)
return FALSE;
}
#ifdef PANORAMIX
#ifdef XINERAMA
if (!noPanoramiXExtension) {
/* Motion events entering DIX get translated to Screen 0
coordinates. Replayed events have already been
@ -3143,7 +3143,7 @@ CheckMotion(DeviceEvent *ev, DeviceIntPtr pDev)
ev->root_y += pSprite->screen->y - screenInfo.screens[0]->y;
}
else
#endif
#endif /* XINERAMA */
{
if (pSprite->hot.pScreen != pSprite->hotPhys.pScreen) {
pSprite->hot.pScreen = pSprite->hotPhys.pScreen;
@ -3169,13 +3169,13 @@ CheckMotion(DeviceEvent *ev, DeviceIntPtr pDev)
if ((pSprite->hotPhys.x != ev->root_x) ||
(pSprite->hotPhys.y != ev->root_y)) {
#ifdef PANORAMIX
#ifdef XINERAMA
if (!noPanoramiXExtension) {
XineramaSetCursorPosition(pDev, pSprite->hotPhys.x,
pSprite->hotPhys.y, FALSE);
}
else
#endif
#endif /* XINERAMA */
{
(*pSprite->hotPhys.pScreen->SetCursorPosition) (pDev,
pSprite->
@ -3332,7 +3332,7 @@ InitializeSprite(DeviceIntPtr pDev, WindowPtr pWin)
pSprite->hot.y, FALSE);
(*pScreen->DisplayCursor) (pDev, pScreen, pSprite->current);
}
#ifdef PANORAMIX
#ifdef XINERAMA
if (!noPanoramiXExtension) {
pSprite->hotLimits.x1 = -screenInfo.screens[0]->x;
pSprite->hotLimits.y1 = -screenInfo.screens[0]->y;
@ -3346,7 +3346,7 @@ InitializeSprite(DeviceIntPtr pDev, WindowPtr pWin)
RegionNull(&pSprite->Reg1);
RegionNull(&pSprite->Reg2);
}
#endif
#endif /* XINERAMA */
}
void FreeSprite(DeviceIntPtr dev)
@ -3412,7 +3412,7 @@ UpdateSpriteForScreen(DeviceIntPtr pDev, ScreenPtr pScreen)
(*pScreen->ConstrainCursor) (pDev, pScreen, &pSprite->physLimits);
(*pScreen->DisplayCursor) (pDev, pScreen, pSprite->current);
#ifdef PANORAMIX
#ifdef XINERAMA
if (!noPanoramiXExtension) {
pSprite->hotLimits.x1 = -screenInfo.screens[0]->x;
pSprite->hotLimits.y1 = -screenInfo.screens[0]->y;
@ -3421,7 +3421,7 @@ UpdateSpriteForScreen(DeviceIntPtr pDev, ScreenPtr pScreen)
pSprite->physLimits = pSprite->hotLimits;
pSprite->screen = pScreen;
}
#endif
#endif /* XINERAMA */
}
/*
@ -3454,7 +3454,7 @@ NewCurrentScreen(DeviceIntPtr pDev, ScreenPtr newScreen, int x, int y)
pSprite->hotPhys.x = x;
pSprite->hotPhys.y = y;
#ifdef PANORAMIX
#ifdef XINERAMA
if (!noPanoramiXExtension) {
pSprite->hotPhys.x += newScreen->x - screenInfo.screens[0]->x;
pSprite->hotPhys.y += newScreen->y - screenInfo.screens[0]->y;
@ -3481,12 +3481,12 @@ NewCurrentScreen(DeviceIntPtr pDev, ScreenPtr newScreen, int x, int y)
}
}
else
#endif
#endif /* XINERAMA */
if (newScreen != pSprite->hotPhys.pScreen)
ConfineCursorToWindow(ptr, newScreen->root, TRUE, FALSE);
}
#ifdef PANORAMIX
#ifdef XINERAMA
static Bool
XineramaPointInWindowIsVisible(WindowPtr pWin, int x, int y)
@ -3593,7 +3593,7 @@ XineramaWarpPointer(ClientPtr client)
return Success;
}
#endif
#endif /* XINERAMA */
/**
* Server-side protocol handling for WarpPointer request.
@ -3625,10 +3625,10 @@ ProcWarpPointer(ClientPtr client)
dev = dev->lastSlave;
pSprite = dev->spriteInfo->sprite;
#ifdef PANORAMIX
#ifdef XINERAMA
if (!noPanoramiXExtension)
return XineramaWarpPointer(client);
#endif
#endif /* XINERAMA */
if (stuff->dstWid != None) {
rc = dixLookupWindow(&dest, stuff->dstWid, client, DixGetAttrAccess);
@ -3707,7 +3707,7 @@ BorderSizeNotEmpty(DeviceIntPtr pDev, WindowPtr pWin)
if (RegionNotEmpty(&pWin->borderSize))
return TRUE;
#ifdef PANORAMIX
#ifdef XINERAMA
if (!noPanoramiXExtension && XineramaSetWindowPntrs(pDev, pWin)) {
int i;
@ -3717,7 +3717,7 @@ BorderSizeNotEmpty(DeviceIntPtr pDev, WindowPtr pWin)
return TRUE;
}
}
#endif
#endif /* XINERAMA */
return FALSE;
}
@ -5352,7 +5352,7 @@ ProcQueryPointer(ClientPtr client)
rep.winY = 0;
}
#ifdef PANORAMIX
#ifdef XINERAMA
if (!noPanoramiXExtension) {
rep.rootX += screenInfo.screens[0]->x;
rep.rootY += screenInfo.screens[0]->y;
@ -5361,7 +5361,7 @@ ProcQueryPointer(ClientPtr client)
rep.winY += screenInfo.screens[0]->y;
}
}
#endif
#endif /* XINERAMA */
if (rc == BadAccess) {
rep.mask = 0;
@ -5910,10 +5910,10 @@ CheckCursorConfinement(WindowPtr pWin)
WindowPtr confineTo;
DeviceIntPtr pDev;
#ifdef PANORAMIX
#ifdef XINERAMA
if (!noPanoramiXExtension && pWin->drawable.pScreen->myNum)
return;
#endif
#endif /* XINERMA */
for (pDev = inputInfo.devices; pDev; pDev = pDev->next) {
if (DevHasCursor(pDev)) {
@ -5974,11 +5974,11 @@ ProcRecolorCursor(ClientPtr client)
for (nscr = 0; nscr < screenInfo.numScreens; nscr++) {
pscr = screenInfo.screens[nscr];
#ifdef PANORAMIX
#ifdef XINERAMA
if (!noPanoramiXExtension)
displayed = (pscr == pSprite->screen);
else
#endif
#endif /* XINERAMA */
displayed = (pscr == pSprite->hotPhys.pScreen);
(*pscr->RecolorCursor) (PickPointer(client), pscr, pCursor,
(pCursor == pSprite->current) && displayed);
@ -6003,9 +6003,9 @@ ProcRecolorCursor(ClientPtr client)
void
WriteEventsToClient(ClientPtr pClient, int count, xEvent *events)
{
#ifdef PANORAMIX
#ifdef XINERAMA
xEvent eventCopy;
#endif
#endif /* XINERAMA */
xEvent *eventTo, *eventFrom;
int i, eventlength = sizeof(xEvent);
@ -6019,7 +6019,7 @@ WriteEventsToClient(ClientPtr pClient, int count, xEvent *events)
/* Let XKB rewrite the state, as it depends on client preferences. */
XkbFilterEvents(pClient, count, events);
#ifdef PANORAMIX
#ifdef XINERAMA
if (!noPanoramiXExtension &&
(screenInfo.screens[0]->x || screenInfo.screens[0]->y)) {
switch (events->u.u.type) {
@ -6050,7 +6050,7 @@ WriteEventsToClient(ClientPtr pClient, int count, xEvent *events)
break;
}
}
#endif
#endif /* XINERAMA */
if (EventCallback) {
EventInfoRec eventinfo;

View File

@ -60,10 +60,10 @@
#include "xkbsrv.h"
#ifdef PANORAMIX
#ifdef XINERAMA
#include "panoramiX.h"
#include "panoramiXsrv.h"
#endif
#endif /* XINERAMA */
#include "exglobals.h"
#include "exevents.h"
@ -2140,7 +2140,7 @@ PostSyntheticMotion(DeviceIntPtr pDev,
{
DeviceEvent ev;
#ifdef PANORAMIX
#ifdef XINERAMA
/* Translate back to the sprite screen since processInputProc
will translate from sprite screen to screen 0 upon reentry
to the DIX layer. */
@ -2148,7 +2148,7 @@ PostSyntheticMotion(DeviceIntPtr pDev,
x += screenInfo.screens[0]->x - screenInfo.screens[screen]->x;
y += screenInfo.screens[0]->y - screenInfo.screens[screen]->y;
}
#endif
#endif /* XINERAMA */
memset(&ev, 0, sizeof(DeviceEvent));
init_device_event(&ev, pDev, time, EVENT_SOURCE_NORMAL);

View File

@ -116,11 +116,11 @@ Equipment Corporation.
#include "extnsionst.h"
#include "privates.h"
#include "exevents.h"
#ifdef PANORAMIX
#ifdef XINERAMA
#include "panoramiXsrv.h"
#else
#include "dixevents.h" /* InitEvents() */
#endif
#endif /* XINERAMA */
#ifdef DPMSExtension
#include <X11/extensions/dpmsconst.h>
@ -241,13 +241,13 @@ dix_main(int argc, char *argv[], char *envp[])
FatalError("could not open default cursor font");
}
#ifdef PANORAMIX
#ifdef XINERAMA
/*
* Consolidate window and colourmap information for each screen
*/
if (!noPanoramiXExtension)
PanoramiXConsolidate();
#endif
#endif /* XINERAMA */
for (i = 0; i < screenInfo.numScreens; i++)
InitRootWindow(screenInfo.screens[i]->root);
@ -261,14 +261,14 @@ dix_main(int argc, char *argv[], char *envp[])
dixCloseRegistry();
#ifdef PANORAMIX
#ifdef XINERAMA
if (!noPanoramiXExtension) {
if (!PanoramiXCreateConnectionBlock()) {
FatalError("could not create connection block info");
}
}
else
#endif
#endif /* XINERAMA */
{
if (!CreateConnectionBlock()) {
FatalError("could not create connection block info");
@ -290,7 +290,7 @@ dix_main(int argc, char *argv[], char *envp[])
FreeScreenSaverTimer();
CloseDownExtensions();
#ifdef PANORAMIX
#ifdef XINERAMA
{
Bool remember_it = noPanoramiXExtension;
@ -300,7 +300,7 @@ dix_main(int argc, char *argv[], char *envp[])
}
#else
FreeAllResources();
#endif
#endif /* XINERAMA */
CloseInput();

View File

@ -137,10 +137,10 @@ Equipment Corporation.
#include "colormap.h"
#include "inputstr.h"
#include "cursor.h"
#ifdef PANORAMIX
#ifdef XINERAMA
#include "panoramiX.h"
#include "panoramiXsrv.h"
#endif
#endif /* XINERAMA */
#include "xace.h"
#include <assert.h>
#include "gcstruct.h"
@ -1178,7 +1178,7 @@ LegalNewID(XID id, ClientPtr client)
void *val;
int rc;
#ifdef PANORAMIX
#ifdef XINERAMA
XID minid, maxid;
if (!noPanoramiXExtension) {
@ -1188,7 +1188,7 @@ LegalNewID(XID id, ClientPtr client)
if ((id >= minid) && (id <= maxid))
return TRUE;
}
#endif /* PANORAMIX */
#endif /* XINERAMA */
if (client->clientAsMask == (id & ~RESOURCE_ID_MASK)) {
rc = dixLookupResourceByClass(&val, id, RC_ANY, serverClient,
DixGetAttrAccess);

View File

@ -124,10 +124,10 @@ Equipment Corporation.
#include "gcstruct.h"
#include "servermd.h"
#include "mivalidate.h"
#ifdef PANORAMIX
#ifdef XINERAMA
#include "panoramiX.h"
#include "panoramiXsrv.h"
#endif
#endif /* XINERAMA */
#include "dixevents.h"
#include "globals.h"
#ifdef COMPOSITE
@ -2303,12 +2303,12 @@ ConfigureWindow(WindowPtr pWin, Mask mask, XID *vlist, ClientPtr client)
};
event.u.u.type = ConfigureRequest;
event.u.u.detail = (mask & CWStackMode) ? smode : Above;
#ifdef PANORAMIX
#ifdef XINERAMA
if (!noPanoramiXExtension && (!pParent || !pParent->parent)) {
event.u.configureRequest.x += screenInfo.screens[0]->x;
event.u.configureRequest.y += screenInfo.screens[0]->y;
}
#endif
#endif /* XINERAMA */
if (MaybeDeliverEventsToClient(pParent, &event, 1,
SubstructureRedirectMask, client) == 1)
return Success;
@ -2386,12 +2386,12 @@ ConfigureWindow(WindowPtr pWin, Mask mask, XID *vlist, ClientPtr client)
.u.configureNotify.override = pWin->overrideRedirect
};
event.u.u.type = ConfigureNotify;
#ifdef PANORAMIX
#ifdef XINERAMA
if (!noPanoramiXExtension && (!pParent || !pParent->parent)) {
event.u.configureNotify.x += screenInfo.screens[0]->x;
event.u.configureNotify.y += screenInfo.screens[0]->y;
}
#endif
#endif /* XINERAMA */
DeliverEvents(pWin, &event, 1, NullWindow);
}
if (mask & CWBorderWidth) {
@ -2531,12 +2531,12 @@ ReparentWindow(WindowPtr pWin, WindowPtr pParent,
.u.reparent.override = pWin->overrideRedirect
};
event.u.u.type = ReparentNotify;
#ifdef PANORAMIX
#ifdef XINERAMA
if (!noPanoramiXExtension && !pParent->parent) {
event.u.reparent.x += screenInfo.screens[0]->x;
event.u.reparent.y += screenInfo.screens[0]->y;
}
#endif
#endif /* XINERAMA */
DeliverEvents(pWin, &event, 1, pParent);
/* take out of sibling chain */
@ -2795,7 +2795,7 @@ UnrealizeTree(WindowPtr pWin, Bool fromConfigure)
if (pChild->realized) {
pChild->realized = FALSE;
pChild->visibility = VisibilityNotViewable;
#ifdef PANORAMIX
#ifdef XINERAMA
if (!noPanoramiXExtension && !pChild->drawable.pScreen->myNum) {
PanoramiXRes *win;
int rc = dixLookupResourceByType((void **) &win,
@ -2806,7 +2806,7 @@ UnrealizeTree(WindowPtr pWin, Bool fromConfigure)
if (rc == Success)
win->u.win.visibility = VisibilityNotViewable;
}
#endif
#endif /* XINERAMA */
(*Unrealize) (pChild);
DeleteWindowFromAnyEvents(pChild, FALSE);
if (pChild->viewable) {
@ -3023,7 +3023,7 @@ SendVisibilityNotify(WindowPtr pWin)
xEvent event;
unsigned int visibility = pWin->visibility;
#ifdef PANORAMIX
#ifdef XINERAMA
/* This is not quite correct yet, but it's close */
if (!noPanoramiXExtension) {
PanoramiXRes *win;
@ -3084,7 +3084,7 @@ SendVisibilityNotify(WindowPtr pWin)
win->u.win.visibility = visibility;
}
#endif
#endif /* XINERAMA */
event = (xEvent) {
.u.visibility.window = pWin->drawable.id,

View File

@ -85,10 +85,10 @@ dri3_extension_init(void)
if (dri3_screen_generation != serverGeneration)
return;
#ifdef PANORAMIX
#ifdef XINERAMA
if (!noPanoramiXExtension)
return;
#endif
#endif /* XINERAMA */
extension = AddExtension(DRI3_NAME, DRI3NumberEvents, DRI3NumberErrors,
proc_dri3_dispatch, sproc_dri3_dispatch,

View File

@ -939,7 +939,7 @@ configServerFlags(XF86ConfFlagsPtr flagsconf, XF86OptionPtr layoutopts)
i, MAX_TIME_IN_MIN);
#endif
#ifdef PANORAMIX
#ifdef XINERAMA
from = X_DEFAULT;
if (!noPanoramiXExtension)
from = X_CMDLINE;
@ -949,7 +949,7 @@ configServerFlags(XF86ConfFlagsPtr flagsconf, XF86OptionPtr layoutopts)
}
if (!noPanoramiXExtension)
xf86Msg(from, "Xinerama: enabled\n");
#endif
#endif /* XINERAMA */
#ifdef DRI2
xf86Info.dri2 = FALSE;

View File

@ -176,11 +176,11 @@ DGAInit(ScreenPtr pScreen, DGAFunctionPtr funcs, DGAModePtr modes, int num)
for (i = 0; i < num; i++)
modes[i].num = i + 1;
#ifdef PANORAMIX
#ifdef XINERAMA
if (!noPanoramiXExtension)
for (i = 0; i < num; i++)
modes[i].flags &= ~DGA_PIXMAP_AVAILABLE;
#endif
#endif /* XINERAMA */
return TRUE;
}
@ -225,11 +225,11 @@ DGAReInitModes(ScreenPtr pScreen, DGAModePtr modes, int num)
for (i = 0; i < num; i++)
modes[i].num = i + 1;
#ifdef PANORAMIX
#ifdef XINERAMA
if (!noPanoramiXExtension)
for (i = 0; i < num; i++)
modes[i].flags &= ~DGA_PIXMAP_AVAILABLE;
#endif
#endif /* XINERAMA */
return TRUE;
}

View File

@ -1627,10 +1627,10 @@ xf86ValidateModes(ScrnInfoPtr scrp, DisplayModePtr availModes,
}
/* Lookup each mode */
#ifdef PANORAMIX
#ifdef XINERAMA
if (noPanoramiXExtension)
validateAllDefaultModes = TRUE;
#endif
#endif /* XINERAMA */
for (p = scrp->modes;; p = p->next) {
Bool repeat;

View File

@ -409,11 +409,11 @@ xf86RandRInit(ScreenPtr pScreen)
XF86RandRInfoPtr randrp;
ScrnInfoPtr scrp = xf86ScreenToScrn(pScreen);
#ifdef PANORAMIX
#ifdef XINERAMA
/* XXX disable RandR when using Xinerama */
if (!noPanoramiXExtension)
return TRUE;
#endif
#endif /* XINERAMA */
xf86RandRKey = &xf86RandRKeyRec;

View File

@ -382,7 +382,7 @@ DRIScreenInit(ScreenPtr pScreen, DRIInfoPtr pDRIInfo, int *pDRMFD)
return FALSE;
}
#ifdef PANORAMIX
#ifdef XINERAMA
/*
* If Xinerama is on, don't allow DRI to initialise. It won't be usable
* anyway.
@ -392,7 +392,7 @@ DRIScreenInit(ScreenPtr pScreen, DRIInfoPtr pDRIInfo, int *pDRMFD)
"Direct rendering is not supported when Xinerama is enabled\n");
return FALSE;
}
#endif
#endif /* XINERAMA */
if (drm_server_inited == FALSE) {
drmSetServerInfo(&DRIDRMServerInfo);
drm_server_inited = TRUE;

View File

@ -686,10 +686,10 @@ DRI2ExtensionInit(void)
{
ExtensionEntry *dri2Extension;
#ifdef PANORAMIX
#ifdef XINERAMA
if (!noPanoramiXExtension)
return;
#endif
#endif /* XINERAMA */
dri2Extension = AddExtension(DRI2_NAME,
DRI2NumberEvents,

View File

@ -759,11 +759,11 @@ xf86RandR12CreateScreenResources(ScreenPtr pScreen)
int width, height;
int mmWidth, mmHeight;
#ifdef PANORAMIX
#ifdef XINERAMA
/* XXX disable RandR when using Xinerama */
if (!noPanoramiXExtension)
return TRUE;
#endif
#endif /* XINERAMA */
config = XF86_CRTC_CONFIG_PTR(pScrn);
randrp = XF86RANDRINFO(pScreen);
@ -849,7 +849,7 @@ xf86RandR12Init(ScreenPtr pScreen)
rrScrPrivPtr rp;
XF86RandRInfoPtr randrp;
#ifdef PANORAMIX
#ifdef XINERAMA
/* XXX disable RandR when using Xinerama */
if (!noPanoramiXExtension) {
if (xf86NumScreens == 1)
@ -857,7 +857,7 @@ xf86RandR12Init(ScreenPtr pScreen)
else
return TRUE;
}
#endif
#endif /* XINERAMA */
if (xf86RandR12Generation != serverGeneration)
xf86RandR12Generation = serverGeneration;

View File

@ -73,9 +73,9 @@ extern _X_EXPORT Bool noDPMSExtension;
extern _X_EXPORT Bool noGlxExtension;
#endif
#ifdef PANORAMIX
#ifdef XINERAMA
extern _X_EXPORT Bool noPanoramiXExtension;
#endif
#endif /* XINERAMA */
#ifdef RANDR
extern _X_EXPORT Bool noRRExtension;

View File

@ -30,8 +30,8 @@ extern _X_EXPORT char *SeatId;
extern _X_EXPORT char *ConnectionInfo;
extern _X_EXPORT sig_atomic_t inSignalContext;
#ifdef PANORAMIX
#ifdef XINERAMA
extern _X_EXPORT Bool PanoramiXExtensionDisabledHack;
#endif
#endif /* XINERAMA */
#endif /* !_XSERV_GLOBAL_H_ */

View File

@ -223,13 +223,13 @@ typedef struct _SpriteRec {
WindowPtr win; /* window of logical position */
HotSpot hot; /* logical pointer position */
HotSpot hotPhys; /* physical pointer position */
#ifdef PANORAMIX
#ifdef XINERAMA
ScreenPtr screen; /* all others are in Screen 0 coordinates */
RegionRec Reg1; /* Region 1 for confining motion */
RegionRec Reg2; /* Region 2 for confining virtual motion */
WindowPtr windows[MAXSCREENS];
WindowPtr confineWin; /* confine window */
#endif
#endif /* XINERAMA */
/* The window trace information is used at dix/events.c to avoid having
* to compute all the windows between the root and the current pointer
* window each time a button or key goes down. The grabs on each of those

View File

@ -216,7 +216,11 @@ if build_glx
conf_data.set_quoted('DRI_DRIVER_PATH', dri_dep.get_variable(pkgconfig : 'dridriverdir'))
endif
conf_data.set('MITSHM', build_mitshm ? '1' : false)
# for backwards compat with drivers, still setting the old PANORAMIX symbol
conf_data.set('PANORAMIX', build_xinerama ? '1' : false)
conf_data.set('XINERAMA', build_xinerama ? '1' : false)
conf_data.set('PRESENT', '1')
conf_data.set('RANDR', '1')
conf_data.set('RES', build_res ? '1' : false)

View File

@ -70,6 +70,7 @@
/* Internal define for Xinerama */
#mesondefine PANORAMIX
#mesondefine XINERAMA
/* Support Present extension */
#mesondefine PRESENT

View File

@ -91,10 +91,10 @@ Equipment Corporation.
#include "dixstruct.h"
#include "globals.h"
#ifdef PANORAMIX
#ifdef XINERAMA
#include "panoramiX.h"
#include "panoramiXsrv.h"
#endif
#endif /* XINERAMA */
/*
machine-independent graphics exposure code. any device that uses
@ -321,7 +321,7 @@ miSendExposures(WindowPtr pWin, RegionPtr pRgn, int dx, int dy)
pe->u.expose.count = i;
}
#ifdef PANORAMIX
#ifdef XINERAMA
if (!noPanoramiXExtension) {
int scrnum = pWin->drawable.pScreen->myNum;
int x = 0, y = 0;
@ -352,7 +352,7 @@ miSendExposures(WindowPtr pWin, RegionPtr pRgn, int dx, int dy)
pEvent[i].u.expose.y += y;
}
}
#endif
#endif /* XINERAMA */
DeliverEvents(pWin, pEvent, numRects, NullWindow);

View File

@ -111,9 +111,9 @@ static const ExtensionModule staticExtensions[] = {
#ifdef XCSECURITY
{SecurityExtensionInit, "SECURITY", &noSecurityExtension},
#endif
#ifdef PANORAMIX
#ifdef XINERAMA
{PanoramiXExtensionInit, "XINERAMA", &noPanoramiXExtension},
#endif
#endif /* XINERAMA */
/* must be before Render to layer DisplayCursor correctly */
{XFixesExtensionInit, "XFIXES", &noXFixesExtension},
#ifdef XF86BIGFONT

View File

@ -402,9 +402,9 @@ miPointerWarpCursor(DeviceIntPtr pDev, ScreenPtr pScreen, int x, int y)
* updated to the second screen, and we never receive any events.
* (FDO bug #18668) */
if (changedScreen
#ifdef PANORAMIX
#ifdef XINERAMA
&& noPanoramiXExtension
#endif
#endif /* XINERAMA */
) {
DeviceIntPtr master = GetMaster(pDev, MASTER_POINTER);
/* Hack for CVE-2023-5380: if we're moving

View File

@ -168,10 +168,10 @@ Bool noXFree86DRIExtension = FALSE;
Bool noXFree86VidModeExtension = FALSE;
#endif
Bool noXFixesExtension = FALSE;
#ifdef PANORAMIX
#ifdef XINERAMA
/* Xinerama is disabled by default unless enabled via +xinerama */
Bool noPanoramiXExtension = TRUE;
#endif
#endif /* XINERAMA */
#ifdef DRI2
Bool noDRI2Extension = FALSE;
#endif
@ -189,9 +189,9 @@ Bool enableIndirectGLX = FALSE;
Bool AllowByteSwappedClients = FALSE;
#ifdef PANORAMIX
#ifdef XINERAMA
Bool PanoramiXExtensionDisabledHack = FALSE;
#endif
#endif /* XINERAMA */
char *SeatId = NULL;
@ -391,10 +391,10 @@ UseMsg(void)
ErrorF("-v screen-saver without video blanking\n");
ErrorF("-wr create root window with white background\n");
ErrorF("-maxbigreqsize set maximal bigrequest size \n");
#ifdef PANORAMIX
#ifdef XINERAMA
ErrorF("+xinerama Enable XINERAMA extension\n");
ErrorF("-xinerama Disable XINERAMA extension\n");
#endif
#endif /* XINERAMA */
ErrorF("-dumbSched Disable smart scheduling and threaded input, enable old behavior\n");
ErrorF("-schedInterval int Set scheduler interval in msec\n");
ErrorF("-sigstop Enable SIGSTOP based startup\n");
@ -790,7 +790,7 @@ ProcessCommandLine(int argc, char *argv[])
UseMsg();
}
}
#ifdef PANORAMIX
#ifdef XINERAMA
else if (strcmp(argv[i], "+xinerama") == 0) {
noPanoramiXExtension = FALSE;
}
@ -800,7 +800,7 @@ ProcessCommandLine(int argc, char *argv[])
else if (strcmp(argv[i], "-disablexineramaextension") == 0) {
PanoramiXExtensionDisabledHack = TRUE;
}
#endif
#endif /* XINERAMA */
else if (strcmp(argv[i], "-I") == 0) {
/* ignore all remaining arguments */
break;

View File

@ -244,10 +244,10 @@ present_extension_init(void)
ExtensionEntry *extension;
int i;
#ifdef PANORAMIX
#ifdef XINERAMA
if (!noPanoramiXExtension)
return;
#endif
#endif /* XINERAMA */
extension = AddExtension(PRESENT_NAME, PresentNumberEvents, PresentNumberErrors,
proc_present_dispatch, sproc_present_dispatch,

View File

@ -444,9 +444,9 @@ RRExtensionInit(void)
RRCrtcInitErrorValue();
RROutputInitErrorValue();
RRProviderInitErrorValue();
#ifdef PANORAMIX
#ifdef XINERAMA
RRXineramaExtensionInit();
#endif
#endif /* XINERAMA */
}
void

View File

@ -419,10 +419,10 @@ SProcRRXineramaDispatch(ClientPtr client)
void
RRXineramaExtensionInit(void)
{
#ifdef PANORAMIX
#ifdef XINERAMA
if (!noPanoramiXExtension)
return;
#endif
#endif /* XINERAMA */
if (noRRXineramaExtension)
return;

View File

@ -49,12 +49,12 @@ and Jim Haggerty of Metheus.
#include <stdio.h>
#include <assert.h>
#ifdef PANORAMIX
#ifdef XINERAMA
#include "globals.h"
#include "panoramiX.h"
#include "panoramiXsrv.h"
#include "cursor.h"
#endif
#endif /* XINERAMA */
#include "protocol-versions.h"
@ -713,7 +713,7 @@ RecordSendProtocolEvents(RecordClientsAndProtocolPtr pRCAP,
xEvent swappedEvent;
xEvent *pEvToRecord = pev;
#ifdef PANORAMIX
#ifdef XINERAMA
xEvent shiftedEvent;
if (!noPanoramiXExtension &&
@ -730,7 +730,7 @@ RecordSendProtocolEvents(RecordClientsAndProtocolPtr pRCAP,
screenInfo.screens[scr]->y - screenInfo.screens[0]->y;
pEvToRecord = &shiftedEvent;
}
#endif /* PANORAMIX */
#endif /* XINERAMA */
if (pContext->pRecordingClient->swapped) {
(*EventSwapVector[pEvToRecord->u.u.type & 0177])

View File

@ -43,9 +43,9 @@
#include "picturestr_priv.h"
#include "glyphstr_priv.h"
#include "xace.h"
#ifdef PANORAMIX
#ifdef XINERAMA
#include "panoramiXsrv.h"
#endif
#endif /* XINERAMA */
DevPrivateKeyRec PictureScreenPrivateKeyRec;
DevPrivateKeyRec PictureWindowPrivateKeyRec;
@ -1006,7 +1006,7 @@ CreateConicalGradientPicture(Picture pid, xPointFixed * center, xFixed angle,
static int
cpAlphaMap(void **result, XID id, ScreenPtr screen, ClientPtr client, Mask mode)
{
#ifdef PANORAMIX
#ifdef XINERAMA
if (!noPanoramiXExtension) {
PanoramiXRes *res;
int err = dixLookupResourceByType((void **)&res, id, XRT_PICTURE,
@ -1015,14 +1015,14 @@ cpAlphaMap(void **result, XID id, ScreenPtr screen, ClientPtr client, Mask mode)
return err;
id = res->info[screen->myNum].id;
}
#endif
#endif /* XINERAMA */
return dixLookupResourceByType(result, id, PictureType, client, mode);
}
static int
cpClipMask(void **result, XID id, ScreenPtr screen, ClientPtr client, Mask mode)
{
#ifdef PANORAMIX
#ifdef XINERAMA
if (!noPanoramiXExtension) {
PanoramiXRes *res;
int err = dixLookupResourceByType((void **)&res, id, XRT_PIXMAP,
@ -1031,7 +1031,7 @@ cpClipMask(void **result, XID id, ScreenPtr screen, ClientPtr client, Mask mode)
return err;
id = res->info[screen->myNum].id;
}
#endif
#endif /* XINERAMA */
return dixLookupResourceByType(result, id, X11_RESTYPE_PIXMAP, client, mode);
}

View File

@ -38,9 +38,9 @@ Bool AnimCurInit(ScreenPtr pScreen);
int AnimCursorCreate(CursorPtr *cursors, CARD32 *deltas, int ncursor,
CursorPtr *ppCursor, ClientPtr client, XID cid);
#ifdef PANORAMIX
#ifdef XINERAMA
void PanoramiXRenderInit(void);
void PanoramiXRenderReset(void);
#endif /* PANORAMIX */
#endif /* XINERAMA */
#endif /* _XSERVER_PICTURESTR_PRIV_H_ */

View File

@ -52,10 +52,10 @@
#include "xace.h"
#include "protocol-versions.h"
#ifdef PANORAMIX
#ifdef XINERAMA
#include "panoramiX.h"
#include "panoramiXsrv.h"
#endif
#endif /* XINERAMA */
static int ProcRenderQueryVersion(ClientPtr pClient);
static int ProcRenderQueryPictFormats(ClientPtr pClient);
@ -221,9 +221,9 @@ typedef struct _RenderClient {
#define GetRenderClient(pClient) ((RenderClientPtr)dixLookupPrivate(&(pClient)->devPrivates, RenderClientPrivateKey))
#ifdef PANORAMIX
#ifdef XINERAMA
RESTYPE XRT_PICTURE;
#endif
#endif /* XINERAMA */
void
RenderExtensionInit(void)
@ -244,10 +244,10 @@ RenderExtensionInit(void)
if (!extEntry)
return;
RenderErrBase = extEntry->errorBase;
#ifdef PANORAMIX
#ifdef XINERAMA
if (XRT_PICTURE)
SetResourceTypeErrorValue(XRT_PICTURE, RenderErrBase + BadPicture);
#endif
#endif /* XINERAMA */
SetResourceTypeErrorValue(PictureType, RenderErrBase + BadPicture);
SetResourceTypeErrorValue(PictFormatType, RenderErrBase + BadPictFormat);
SetResourceTypeErrorValue(GlyphSetType, RenderErrBase + BadGlyphSet);
@ -332,14 +332,14 @@ ProcRenderQueryPictFormats(ClientPtr client)
REQUEST_SIZE_MATCH(xRenderQueryPictFormatsReq);
#ifdef PANORAMIX
#ifdef XINERAMA
if (noPanoramiXExtension)
numScreens = screenInfo.numScreens;
else
numScreens = ((xConnSetup *) ConnectionInfo)->numRoots;
#else
numScreens = screenInfo.numScreens;
#endif
#endif /* XINERAMA */
ndepth = nformat = nvisual = 0;
for (s = 0; s < numScreens; s++) {
pScreen = screenInfo.screens[s];
@ -2582,7 +2582,7 @@ SProcRenderDispatch(ClientPtr client)
return BadRequest;
}
#ifdef PANORAMIX
#ifdef XINERAMA
#define VERIFY_XIN_PICTURE(pPicture, pid, client, mode) {\
int rc = dixLookupResourceByType((void **)&(pPicture), pid,\
XRT_PICTURE, client, mode);\
@ -3330,4 +3330,4 @@ PanoramiXRenderReset(void)
RenderErrBase = 0;
}
#endif /* PANORAMIX */
#endif /* XINERAMA */

View File

@ -815,7 +815,7 @@ SProcXFixesExpandRegion(ClientPtr client)
return (*ProcXFixesVector[stuff->xfixesReqType]) (client);
}
#ifdef PANORAMIX
#ifdef XINERAMA
#include "panoramiX.h"
#include "panoramiXsrv.h"
@ -925,4 +925,4 @@ PanoramiXFixesSetPictureClipRegion(ClientPtr client)
return result;
}
#endif
#endif /* XINERAMA */

View File

@ -252,7 +252,7 @@ XFixesExtensionInit(void)
}
}
#ifdef PANORAMIX
#ifdef XINERAMA
int (*PanoramiXSaveXFixesVector[XFixesNumberRequests]) (ClientPtr);
@ -282,4 +282,4 @@ PanoramiXFixesReset(void)
ProcXFixesVector[i] = PanoramiXSaveXFixesVector[i];
}
#endif
#endif /* XINERAMA */

View File

@ -310,10 +310,10 @@ Bool
XFixesShouldDisconnectClient(ClientPtr client);
/* Xinerama */
#ifdef PANORAMIX
#ifdef XINERAMA
extern int (*PanoramiXSaveXFixesVector[XFixesNumberRequests]) (ClientPtr);
void PanoramiXFixesInit(void);
void PanoramiXFixesReset(void);
#endif
#endif /* XINERAMA */
#endif /* _XFIXESINT_H_ */