forked from pool/xorg-x11-server
529 lines
23 KiB
Diff
529 lines
23 KiB
Diff
|
Index: xorg-server-1.9.2/hw/vnc/rfb.h
|
||
|
===================================================================
|
||
|
--- xorg-server-1.9.2.orig/hw/vnc/rfb.h
|
||
|
+++ xorg-server-1.9.2/hw/vnc/rfb.h
|
||
|
@@ -189,8 +189,8 @@ typedef struct
|
||
|
|
||
|
CloseScreenProcPtr CloseScreen;
|
||
|
CreateGCProcPtr CreateGC;
|
||
|
- PaintWindowBackgroundProcPtr PaintWindowBackground;
|
||
|
- PaintWindowBorderProcPtr PaintWindowBorder;
|
||
|
+// PaintWindowBackgroundProcPtr PaintWindowBackground;
|
||
|
+// PaintWindowBorderProcPtr PaintWindowBorder;
|
||
|
CopyWindowProcPtr CopyWindow;
|
||
|
ClearToBackgroundProcPtr ClearToBackground;
|
||
|
RestoreAreasProcPtr RestoreAreas;
|
||
|
Index: xorg-server-1.9.2/hw/vnc/draw.c
|
||
|
===================================================================
|
||
|
--- xorg-server-1.9.2.orig/hw/vnc/draw.c
|
||
|
+++ xorg-server-1.9.2/hw/vnc/draw.c
|
||
|
@@ -217,8 +217,8 @@ rfbCloseScreen (int i, ScreenPtr pScreen
|
||
|
|
||
|
pScreen->CloseScreen = pVNC->CloseScreen;
|
||
|
pScreen->CreateGC = pVNC->CreateGC;
|
||
|
- pScreen->PaintWindowBackground = pVNC->PaintWindowBackground;
|
||
|
- pScreen->PaintWindowBorder = pVNC->PaintWindowBorder;
|
||
|
+// pScreen->PaintWindowBackground = pVNC->PaintWindowBackground;
|
||
|
+// pScreen->PaintWindowBorder = pVNC->PaintWindowBorder;
|
||
|
pScreen->CopyWindow = pVNC->CopyWindow;
|
||
|
pScreen->ClearToBackground = pVNC->ClearToBackground;
|
||
|
pScreen->RestoreAreas = pVNC->RestoreAreas;
|
||
|
@@ -252,7 +252,7 @@ rfbEnableDisableFBAccess (int index, Boo
|
||
|
* control even when switched away.
|
||
|
*/
|
||
|
if (!enable) {
|
||
|
- WindowPtr pWin = WindowTable[index];
|
||
|
+ WindowPtr pWin = pScrn->pScreen->root;
|
||
|
ScreenPtr pScreen = pWin->drawable.pScreen;
|
||
|
GCPtr pGC;
|
||
|
xRectangle rect;
|
||
|
@@ -268,7 +268,7 @@ rfbEnableDisableFBAccess (int index, Boo
|
||
|
CARD32 attributes[2];
|
||
|
attributes[0] = pScreen->whitePixel;
|
||
|
attributes[1] = pScreen->blackPixel;
|
||
|
- (void)ChangeGC(pGC, GCForeground | GCBackground, attributes);
|
||
|
+ (void)ChangeGC(NullClient, pGC, GCForeground | GCBackground, attributes);
|
||
|
|
||
|
ValidateGC((DrawablePtr)pWin, pGC);
|
||
|
|
||
|
@@ -317,6 +317,7 @@ rfbCreateGC (GCPtr pGC)
|
||
|
return ret;
|
||
|
}
|
||
|
|
||
|
+#if 0
|
||
|
/*
|
||
|
* PaintWindowBackground - the region being modified is just the given region.
|
||
|
*/
|
||
|
@@ -356,6 +357,7 @@ rfbPaintWindowBorder (WindowPtr pWin, Re
|
||
|
|
||
|
SCREEN_EPILOGUE(PaintWindowBorder,rfbPaintWindowBorder);
|
||
|
}
|
||
|
+#endif
|
||
|
|
||
|
#ifdef CHROMIUM
|
||
|
Bool
|
||
|
Index: xorg-server-1.9.2/hw/vnc/init.c
|
||
|
===================================================================
|
||
|
--- xorg-server-1.9.2.orig/hw/vnc/init.c
|
||
|
+++ xorg-server-1.9.2/hw/vnc/init.c
|
||
|
@@ -670,8 +670,8 @@ rfbScreenInit(index, pScreen, argc, argv
|
||
|
prfb->CloseScreen = pScreen->CloseScreen;
|
||
|
prfb->WakeupHandler = pScreen->WakeupHandler;
|
||
|
prfb->CreateGC = pScreen->CreateGC;
|
||
|
- prfb->PaintWindowBackground = pScreen->PaintWindowBackground;
|
||
|
- prfb->PaintWindowBorder = pScreen->PaintWindowBorder;
|
||
|
+// prfb->PaintWindowBackground = pScreen->PaintWindowBackground;
|
||
|
+// prfb->PaintWindowBorder = pScreen->PaintWindowBorder;
|
||
|
prfb->CopyWindow = pScreen->CopyWindow;
|
||
|
prfb->ClearToBackground = pScreen->ClearToBackground;
|
||
|
prfb->RestoreAreas = pScreen->RestoreAreas;
|
||
|
@@ -691,8 +691,8 @@ rfbScreenInit(index, pScreen, argc, argv
|
||
|
pScreen->CloseScreen = rfbCloseScreen;
|
||
|
pScreen->WakeupHandler = rfbWakeupHandler;
|
||
|
pScreen->CreateGC = rfbCreateGC;
|
||
|
- pScreen->PaintWindowBackground = rfbPaintWindowBackground;
|
||
|
- pScreen->PaintWindowBorder = rfbPaintWindowBorder;
|
||
|
+// pScreen->PaintWindowBackground = rfbPaintWindowBackground;
|
||
|
+// pScreen->PaintWindowBorder = rfbPaintWindowBorder;
|
||
|
pScreen->CopyWindow = rfbCopyWindow;
|
||
|
pScreen->ClearToBackground = rfbClearToBackground;
|
||
|
pScreen->RestoreAreas = rfbRestoreAreas;
|
||
|
Index: xorg-server-1.9.2/hw/vnc/sprite.c
|
||
|
===================================================================
|
||
|
--- xorg-server-1.9.2.orig/hw/vnc/sprite.c
|
||
|
+++ xorg-server-1.9.2/hw/vnc/sprite.c
|
||
|
@@ -96,8 +96,10 @@ static void rfbSpriteInstallColormap
|
||
|
static void rfbSpriteStoreColors(ColormapPtr pMap, int ndef,
|
||
|
xColorItem *pdef);
|
||
|
|
||
|
+#if 0
|
||
|
static void rfbSpritePaintWindowBackground(WindowPtr pWin,
|
||
|
RegionPtr pRegion, int what);
|
||
|
+#endif
|
||
|
static void rfbSpritePaintWindowBorder(WindowPtr pWin,
|
||
|
RegionPtr pRegion, int what);
|
||
|
static void rfbSpriteCopyWindow(WindowPtr pWin, DDXPointRec ptOldOrg,
|
||
|
@@ -329,7 +331,7 @@ rfbSpriteInitialize (pScreen, cursorFunc
|
||
|
rfbSpriteScreenPtr pPriv;
|
||
|
VisualPtr pVisual;
|
||
|
|
||
|
- if (!dixRequestPrivate(rfbSpriteGCKey, sizeof(rfbSpriteGCRec)))
|
||
|
+ if (!dixRegisterPrivateKey(rfbSpriteGCKey, PRIVATE_CLIENT, sizeof(rfbSpriteGCRec)))
|
||
|
return FALSE;
|
||
|
|
||
|
pPriv = (rfbSpriteScreenPtr) xalloc (sizeof (rfbSpriteScreenRec));
|
||
|
@@ -357,8 +359,8 @@ rfbSpriteInitialize (pScreen, cursorFunc
|
||
|
pPriv->StoreColors = pScreen->StoreColors;
|
||
|
pPriv->DisplayCursor = pScreen->DisplayCursor;
|
||
|
|
||
|
- pPriv->PaintWindowBackground = pScreen->PaintWindowBackground;
|
||
|
- pPriv->PaintWindowBorder = pScreen->PaintWindowBorder;
|
||
|
+// pPriv->PaintWindowBackground = pScreen->PaintWindowBackground;
|
||
|
+// pPriv->PaintWindowBorder = pScreen->PaintWindowBorder;
|
||
|
pPriv->CopyWindow = pScreen->CopyWindow;
|
||
|
pPriv->ClearToBackground = pScreen->ClearToBackground;
|
||
|
|
||
|
@@ -393,8 +395,8 @@ rfbSpriteInitialize (pScreen, cursorFunc
|
||
|
pScreen->InstallColormap = rfbSpriteInstallColormap;
|
||
|
pScreen->StoreColors = rfbSpriteStoreColors;
|
||
|
|
||
|
- pScreen->PaintWindowBackground = rfbSpritePaintWindowBackground;
|
||
|
- pScreen->PaintWindowBorder = rfbSpritePaintWindowBorder;
|
||
|
+// pScreen->PaintWindowBackground = rfbSpritePaintWindowBackground;
|
||
|
+// pScreen->PaintWindowBorder = rfbSpritePaintWindowBorder;
|
||
|
pScreen->CopyWindow = rfbSpriteCopyWindow;
|
||
|
pScreen->ClearToBackground = rfbSpriteClearToBackground;
|
||
|
|
||
|
@@ -435,8 +437,8 @@ rfbSpriteCloseScreen (i, pScreen)
|
||
|
pScreen->InstallColormap = pScreenPriv->InstallColormap;
|
||
|
pScreen->StoreColors = pScreenPriv->StoreColors;
|
||
|
|
||
|
- pScreen->PaintWindowBackground = pScreenPriv->PaintWindowBackground;
|
||
|
- pScreen->PaintWindowBorder = pScreenPriv->PaintWindowBorder;
|
||
|
+// pScreen->PaintWindowBackground = pScreenPriv->PaintWindowBackground;
|
||
|
+// pScreen->PaintWindowBorder = pScreenPriv->PaintWindowBorder;
|
||
|
pScreen->CopyWindow = pScreenPriv->CopyWindow;
|
||
|
pScreen->ClearToBackground = pScreenPriv->ClearToBackground;
|
||
|
|
||
|
@@ -809,6 +811,7 @@ rfbSpriteRestoreAreas (pWin, prgnExposed
|
||
|
* Window wrappers
|
||
|
*/
|
||
|
|
||
|
+#if 0
|
||
|
static void
|
||
|
rfbSpritePaintWindowBackground (pWin, pRegion, what)
|
||
|
WindowPtr pWin;
|
||
|
@@ -866,6 +869,7 @@ rfbSpritePaintWindowBorder (pWin, pRegio
|
||
|
|
||
|
SCREEN_EPILOGUE (pScreen, PaintWindowBorder, rfbSpritePaintWindowBorder);
|
||
|
}
|
||
|
+#endif
|
||
|
|
||
|
static void
|
||
|
rfbSpriteCopyWindow (pWin, ptOldOrg, pRegion)
|
||
|
Index: xorg-server-1.9.2/hw/vnc/spritest.h
|
||
|
===================================================================
|
||
|
--- xorg-server-1.9.2.orig/hw/vnc/spritest.h
|
||
|
+++ xorg-server-1.9.2/hw/vnc/spritest.h
|
||
|
@@ -70,8 +70,8 @@ typedef struct {
|
||
|
ScreenBlockHandlerProcPtr BlockHandler;
|
||
|
InstallColormapProcPtr InstallColormap;
|
||
|
StoreColorsProcPtr StoreColors;
|
||
|
- PaintWindowBackgroundProcPtr PaintWindowBackground;
|
||
|
- PaintWindowBorderProcPtr PaintWindowBorder;
|
||
|
+// PaintWindowBackgroundProcPtr PaintWindowBackground;
|
||
|
+// PaintWindowBorderProcPtr PaintWindowBorder;
|
||
|
CopyWindowProcPtr CopyWindow;
|
||
|
ClearToBackgroundProcPtr ClearToBackground;
|
||
|
SaveDoomedAreasProcPtr SaveDoomedAreas;
|
||
|
Index: xorg-server-1.9.2/hw/vnc/cutpaste.c
|
||
|
===================================================================
|
||
|
--- xorg-server-1.9.2.orig/hw/vnc/cutpaste.c
|
||
|
+++ xorg-server-1.9.2/hw/vnc/cutpaste.c
|
||
|
@@ -54,7 +54,7 @@ rfbSetXCutText(char *str, int len)
|
||
|
Selection *pSel;
|
||
|
|
||
|
inSetXCutText = TRUE;
|
||
|
- ChangeWindowProperty(WindowTable[0], XA_CUT_BUFFER0, XA_STRING,
|
||
|
+ ChangeWindowProperty(screenInfo.screens[0]->root, XA_CUT_BUFFER0, XA_STRING,
|
||
|
8, PropModeReplace, len,
|
||
|
(pointer)str, TRUE);
|
||
|
|
||
|
Index: xorg-server-1.9.2/hw/vnc/dispcur.c
|
||
|
===================================================================
|
||
|
--- xorg-server-1.9.2.orig/hw/vnc/dispcur.c
|
||
|
+++ xorg-server-1.9.2/hw/vnc/dispcur.c
|
||
|
@@ -340,7 +340,7 @@ rfbDCRealize (ScreenPtr pScreen, CursorP
|
||
|
0, 0, pCursor->bits->width, pCursor->bits->height,
|
||
|
0, XYPixmap, (char *)pCursor->bits->source);
|
||
|
gcvals[0] = GXand;
|
||
|
- ChangeGC (pGC, GCFunction, gcvals);
|
||
|
+ ChangeGCXIDs (NullClient, pGC, GCFunction, gcvals);
|
||
|
ValidateGC ((DrawablePtr)pPriv->sourceBits, pGC);
|
||
|
(*pGC->ops->PutImage) ((DrawablePtr)pPriv->sourceBits, pGC, 1,
|
||
|
0, 0, pCursor->bits->width, pCursor->bits->height,
|
||
|
@@ -348,13 +348,13 @@ rfbDCRealize (ScreenPtr pScreen, CursorP
|
||
|
|
||
|
/* mask bits -- pCursor->mask & ~pCursor->source */
|
||
|
gcvals[0] = GXcopy;
|
||
|
- ChangeGC (pGC, GCFunction, gcvals);
|
||
|
+ ChangeGCXIDs (NullClient, pGC, GCFunction, gcvals);
|
||
|
ValidateGC ((DrawablePtr)pPriv->maskBits, pGC);
|
||
|
(*pGC->ops->PutImage) ((DrawablePtr)pPriv->maskBits, pGC, 1,
|
||
|
0, 0, pCursor->bits->width, pCursor->bits->height,
|
||
|
0, XYPixmap, (char *)pCursor->bits->mask);
|
||
|
gcvals[0] = GXandInverted;
|
||
|
- ChangeGC (pGC, GCFunction, gcvals);
|
||
|
+ ChangeGCXIDs (NullClient, pGC, GCFunction, gcvals);
|
||
|
ValidateGC ((DrawablePtr)pPriv->maskBits, pGC);
|
||
|
(*pGC->ops->PutImage) ((DrawablePtr)pPriv->maskBits, pGC, 1,
|
||
|
0, 0, pCursor->bits->width, pCursor->bits->height,
|
||
|
@@ -396,7 +396,7 @@ rfbDCPutBits (DrawablePtr pDrawable, rfb
|
||
|
if (sourceGC->fgPixel != source)
|
||
|
{
|
||
|
gcvals[0] = source;
|
||
|
- DoChangeGC (sourceGC, GCForeground, gcvals, 0);
|
||
|
+ ChangeGCXIDs (NullClient, sourceGC, GCForeground, gcvals);
|
||
|
}
|
||
|
if (sourceGC->serialNumber != pDrawable->serialNumber)
|
||
|
ValidateGC (pDrawable, sourceGC);
|
||
|
@@ -404,7 +404,7 @@ rfbDCPutBits (DrawablePtr pDrawable, rfb
|
||
|
if (maskGC->fgPixel != mask)
|
||
|
{
|
||
|
gcvals[0] = mask;
|
||
|
- DoChangeGC (maskGC, GCForeground, gcvals, 0);
|
||
|
+ ChangeGCXIDs (NullClient, maskGC, GCForeground, gcvals);
|
||
|
}
|
||
|
if (maskGC->serialNumber != pDrawable->serialNumber)
|
||
|
ValidateGC (pDrawable, maskGC);
|
||
|
@@ -451,7 +451,7 @@ rfbDCPutUpCursor (pScreen, pCursor, x, y
|
||
|
}
|
||
|
pScreenPriv = (rfbDCScreenPtr)dixLookupPrivate(&pScreen->devPrivates,
|
||
|
rfbDCScreenKey);
|
||
|
- pWin = WindowTable[pScreen->myNum];
|
||
|
+ pWin = pScreen->root;
|
||
|
#ifdef ARGB_CURSOR
|
||
|
if (pPriv->pPicture)
|
||
|
{
|
||
|
@@ -498,7 +498,7 @@ rfbDCSaveUnderCursor (pScreen, x, y, w,
|
||
|
pScreenPriv = (rfbDCScreenPtr)dixLookupPrivate(&pScreen->devPrivates,
|
||
|
rfbDCScreenKey);
|
||
|
pSave = pScreenPriv->pSave;
|
||
|
- pWin = WindowTable[pScreen->myNum];
|
||
|
+ pWin = pScreen->root;
|
||
|
if (!pSave || pSave->drawable.width < w || pSave->drawable.height < h)
|
||
|
{
|
||
|
if (pSave)
|
||
|
@@ -531,7 +531,7 @@ rfbDCRestoreUnderCursor (pScreen, x, y,
|
||
|
pScreenPriv = (rfbDCScreenPtr)dixLookupPrivate(&pScreen->devPrivates,
|
||
|
rfbDCScreenKey);
|
||
|
pSave = pScreenPriv->pSave;
|
||
|
- pWin = WindowTable[pScreen->myNum];
|
||
|
+ pWin = pScreen->root;
|
||
|
if (!pSave)
|
||
|
return FALSE;
|
||
|
if (!EnsureGC(pScreenPriv->pRestoreGC, pWin))
|
||
|
@@ -558,7 +558,7 @@ rfbDCChangeSave (pScreen, x, y, w, h, dx
|
||
|
pScreenPriv = (rfbDCScreenPtr)dixLookupPrivate(&pScreen->devPrivates,
|
||
|
rfbDCScreenKey);
|
||
|
pSave = pScreenPriv->pSave;
|
||
|
- pWin = WindowTable[pScreen->myNum];
|
||
|
+ pWin = pScreen->root;
|
||
|
/*
|
||
|
* restore the bits which are about to get trashed
|
||
|
*/
|
||
|
@@ -702,7 +702,7 @@ rfbDCMoveCursor (pScreen, pCursor, x, y,
|
||
|
}
|
||
|
pScreenPriv = (rfbDCScreenPtr)dixLookupPrivate(&pScreen->devPrivates,
|
||
|
rfbDCScreenKey);
|
||
|
- pWin = WindowTable[pScreen->myNum];
|
||
|
+ pWin = pScreen->root;
|
||
|
pTemp = pScreenPriv->pTemp;
|
||
|
if (!pTemp ||
|
||
|
pTemp->drawable.width != pScreenPriv->pSave->drawable.width ||
|
||
|
Index: xorg-server-1.9.2/hw/vnc/kbdptr.c
|
||
|
===================================================================
|
||
|
--- xorg-server-1.9.2.orig/hw/vnc/kbdptr.c
|
||
|
+++ xorg-server-1.9.2/hw/vnc/kbdptr.c
|
||
|
@@ -153,7 +153,7 @@ KbdAddEvent(Bool down, KeySym keySym, rf
|
||
|
#ifdef CORBA
|
||
|
if (cl) {
|
||
|
CARD32 clientId = cl->sock;
|
||
|
- ChangeWindowProperty(WindowTable[0], VNC_LAST_CLIENT_ID, XA_INTEGER,
|
||
|
+ ChangeWindowProperty(screenInfo.screens[0]->root, VNC_LAST_CLIENT_ID, XA_INTEGER,
|
||
|
32, PropModeReplace, 1, (pointer)&clientId, TRUE);
|
||
|
}
|
||
|
#endif
|
||
|
@@ -310,7 +310,7 @@ PtrAddEvent(int buttonMask, int x, int y
|
||
|
#ifdef CORBA
|
||
|
if (cl) {
|
||
|
CARD32 clientId = cl->sock;
|
||
|
- ChangeWindowProperty(WindowTable[0], VNC_LAST_CLIENT_ID, XA_INTEGER,
|
||
|
+ ChangeWindowProperty(screenInfo.screens[0]->root, VNC_LAST_CLIENT_ID, XA_INTEGER,
|
||
|
32, PropModeReplace, 1, (pointer)&clientId, TRUE);
|
||
|
}
|
||
|
#endif
|
||
|
Index: xorg-server-1.9.2/hw/vnc/rfbserver.c
|
||
|
===================================================================
|
||
|
--- xorg-server-1.9.2.orig/hw/vnc/rfbserver.c
|
||
|
+++ xorg-server-1.9.2/hw/vnc/rfbserver.c
|
||
|
@@ -82,7 +82,7 @@ void
|
||
|
rfbRootPropertyChange(ScreenPtr pScreen)
|
||
|
{
|
||
|
PropertyPtr pProp;
|
||
|
- WindowPtr pWin = WindowTable[pScreen->myNum];
|
||
|
+ WindowPtr pWin = pScreen->root;
|
||
|
|
||
|
pProp = wUserProps (pWin);
|
||
|
|
||
|
@@ -1068,7 +1068,7 @@ rfbProcessClientNormalMessage(cl)
|
||
|
GenerateVncChromiumConnectedEvent(cl->sock);
|
||
|
if (enc == rfbEncodingChromium) {
|
||
|
/* Generate exposures for all windows */
|
||
|
- WindowPtr pWin = WindowTable[cl->pScreen->myNum];
|
||
|
+ WindowPtr pWin = cl->pScreen->root;
|
||
|
rfbSetClip(pWin, 1);
|
||
|
}
|
||
|
else {
|
||
|
@@ -1866,13 +1866,13 @@ rfbSendSetColourMapEntries(cl, firstColo
|
||
|
|
||
|
/* PseudoColor */
|
||
|
#if XFREE86VNC
|
||
|
- if (miInstalledMaps[cl->pScreen->myNum]->class == PseudoColor) {
|
||
|
+ if (GetInstalledmiColormap(cl->pScreen)->class == PseudoColor) {
|
||
|
#else
|
||
|
if (pVNC->rfbInstalledColormap->class == PseudoColor) {
|
||
|
#endif
|
||
|
scme->firstColour = Swap16IfLE(firstColour);
|
||
|
#if XFREE86VNC
|
||
|
- pent = (EntryPtr)&miInstalledMaps[cl->pScreen->myNum]->red[firstColour];
|
||
|
+ pent = (EntryPtr)&GetInstalledmiColormap(cl->pScreen)->red[firstColour];
|
||
|
#else
|
||
|
pent = (EntryPtr)&pVNC->rfbInstalledColormap->red[firstColour];
|
||
|
#endif
|
||
|
@@ -1894,12 +1894,12 @@ rfbSendSetColourMapEntries(cl, firstColo
|
||
|
|
||
|
/* Break the DirectColor pixel into its r/g/b components */
|
||
|
#if XFREE86VNC
|
||
|
- redPart = (firstColour & miInstalledMaps[cl->pScreen->myNum]->pVisual->redMask)
|
||
|
- >> miInstalledMaps[cl->pScreen->myNum]->pVisual->offsetRed;
|
||
|
- greenPart = (firstColour & miInstalledMaps[cl->pScreen->myNum]->pVisual->greenMask)
|
||
|
- >> miInstalledMaps[cl->pScreen->myNum]->pVisual->offsetGreen;
|
||
|
- bluePart = (firstColour & miInstalledMaps[cl->pScreen->myNum]->pVisual->blueMask)
|
||
|
- >> miInstalledMaps[cl->pScreen->myNum]->pVisual->offsetBlue;
|
||
|
+ redPart = (firstColour & GetInstalledmiColormap(cl->pScreen)->pVisual->redMask)
|
||
|
+ >> GetInstalledmiColormap(cl->pScreen)->pVisual->offsetRed;
|
||
|
+ greenPart = (firstColour & GetInstalledmiColormap(cl->pScreen)->pVisual->greenMask)
|
||
|
+ >> GetInstalledmiColormap(cl->pScreen)->pVisual->offsetGreen;
|
||
|
+ bluePart = (firstColour & GetInstalledmiColormap(cl->pScreen)->pVisual->blueMask)
|
||
|
+ >> GetInstalledmiColormap(cl->pScreen)->pVisual->offsetBlue;
|
||
|
#else
|
||
|
redPart = (firstColour & pVNC->rfbInstalledColormap->pVisual->redMask)
|
||
|
>> pVNC->rfbInstalledColormap->pVisual->offsetRed;
|
||
|
@@ -1918,9 +1918,9 @@ rfbSendSetColourMapEntries(cl, firstColo
|
||
|
scme->firstColour = Swap16IfLE((greenPart << 8) | bluePart);
|
||
|
|
||
|
#if XFREE86VNC
|
||
|
- redEntry = (EntryPtr)&miInstalledMaps[cl->pScreen->myNum]->red[redPart];
|
||
|
- greenEntry = (EntryPtr)&miInstalledMaps[cl->pScreen->myNum]->green[greenPart];
|
||
|
- blueEntry = (EntryPtr)&miInstalledMaps[cl->pScreen->myNum]->blue[bluePart];
|
||
|
+ redEntry = (EntryPtr)&GetInstalledmiColormap(cl->pScreen)->red[redPart];
|
||
|
+ greenEntry = (EntryPtr)&GetInstalledmiColormap(cl->pScreen)->green[greenPart];
|
||
|
+ blueEntry = (EntryPtr)&GetInstalledmiColormap(cl->pScreen)->blue[bluePart];
|
||
|
#else
|
||
|
redEntry = (EntryPtr)&pVNC->rfbInstalledColormap->red[redPart];
|
||
|
greenEntry = (EntryPtr)&pVNC->rfbInstalledColormap->green[greenPart];
|
||
|
Index: xorg-server-1.9.2/hw/vnc/tabletranstemplate.c
|
||
|
===================================================================
|
||
|
--- xorg-server-1.9.2.orig/hw/vnc/tabletranstemplate.c
|
||
|
+++ xorg-server-1.9.2/hw/vnc/tabletranstemplate.c
|
||
|
@@ -67,7 +67,7 @@ rfbTranslateWithSingleTableINtoOUT (Scre
|
||
|
OUT_T *op = (OUT_T *)optr;
|
||
|
OUT_T *opLineEnd;
|
||
|
OUT_T *t = (OUT_T *)table;
|
||
|
- DrawablePtr pDraw = (DrawablePtr)WindowTable[pScreen->myNum];
|
||
|
+ DrawablePtr pDraw = (DrawablePtr)pScreen->root;
|
||
|
int truewidth = PixmapBytePad(width, in->bitsPerPixel);
|
||
|
unsigned char *iptr = malloc(truewidth * height * in->bitsPerPixel / 8);
|
||
|
int ipextra = truewidth - width;
|
||
|
@@ -107,7 +107,7 @@ rfbTranslateWithRGBTablesINtoOUT (Screen
|
||
|
OUT_T *redTable = (OUT_T *)table;
|
||
|
OUT_T *greenTable = redTable + in->redMax + 1;
|
||
|
OUT_T *blueTable = greenTable + in->greenMax + 1;
|
||
|
- DrawablePtr pDraw = (DrawablePtr)WindowTable[pScreen->myNum];
|
||
|
+ DrawablePtr pDraw = (DrawablePtr)pScreen->root;
|
||
|
int truewidth = PixmapBytePad(width, in->bitsPerPixel);
|
||
|
unsigned char *iptr = malloc(truewidth * height * in->bitsPerPixel / 8);
|
||
|
int ipextra = truewidth - width;
|
||
|
Index: xorg-server-1.9.2/hw/vnc/translate.c
|
||
|
===================================================================
|
||
|
--- xorg-server-1.9.2.orig/hw/vnc/translate.c
|
||
|
+++ xorg-server-1.9.2/hw/vnc/translate.c
|
||
|
@@ -167,7 +167,7 @@ rfbTranslateNone(ScreenPtr pScreen, char
|
||
|
int width, int height, int x, int y)
|
||
|
{
|
||
|
VNCSCREENPTR(pScreen);
|
||
|
- DrawablePtr pDraw = (DrawablePtr)WindowTable[pScreen->myNum];
|
||
|
+ DrawablePtr pDraw = (DrawablePtr)pScreen->root;
|
||
|
int truewidth = PixmapBytePad(width, in->bitsPerPixel);
|
||
|
|
||
|
if ((x + width > pVNC->width) || truewidth != width * in->bitsPerPixel / 8) {
|
||
|
@@ -227,7 +227,7 @@ rfbSetTranslateFunction(cl)
|
||
|
if (!pVNC->rfbServerFormat.trueColour &&
|
||
|
(pVNC->rfbServerFormat.bitsPerPixel != 8) &&
|
||
|
#if XFREE86VNC
|
||
|
- (miInstalledMaps[cl->pScreen->myNum]->class == PseudoColor)) {
|
||
|
+ (GetInstalledmiColormap(cl->pScreen)->class == PseudoColor)) {
|
||
|
#else
|
||
|
(pVNC->rfbInstalledColormap->class == PseudoColor)) {
|
||
|
#endif
|
||
|
@@ -241,7 +241,7 @@ rfbSetTranslateFunction(cl)
|
||
|
if (!cl->format.trueColour &&
|
||
|
(cl->format.bitsPerPixel != 8) &&
|
||
|
#if XFREE86VNC
|
||
|
- (miInstalledMaps[cl->pScreen->myNum]->class == PseudoColor)) {
|
||
|
+ (GetInstalledmiColormap(cl->pScreen)->class == PseudoColor)) {
|
||
|
#else
|
||
|
(pVNC->rfbInstalledColormap->class == PseudoColor) ) {
|
||
|
#endif
|
||
|
@@ -265,7 +265,7 @@ rfbSetTranslateFunction(cl)
|
||
|
/* colour map -> colour map */
|
||
|
|
||
|
#if XFREE86VNC
|
||
|
- if (miInstalledMaps[cl->pScreen->myNum]->class == DirectColor) {
|
||
|
+ if (GetInstalledmiColormap(cl->pScreen)->class == DirectColor) {
|
||
|
#else
|
||
|
if (pVNC->rfbInstalledColormap->class == DirectColor) {
|
||
|
#endif
|
||
|
@@ -433,7 +433,7 @@ rfbSetClientColourMap(cl, firstColour, n
|
||
|
|
||
|
if (nColours == 0) {
|
||
|
#if XFREE86VNC
|
||
|
- nColours = miInstalledMaps[cl->pScreen->myNum]->pVisual->ColormapEntries;
|
||
|
+ nColours = GetInstalledmiColormap(cl->pScreen)->pVisual->ColormapEntries;
|
||
|
#else
|
||
|
nColours = pVNC->rfbInstalledColormap->pVisual->ColormapEntries;
|
||
|
#endif
|
||
|
Index: xorg-server-1.9.2/hw/dmx/vnc/vncint.h
|
||
|
===================================================================
|
||
|
--- xorg-server-1.9.2.orig/hw/dmx/vnc/vncint.h
|
||
|
+++ xorg-server-1.9.2/hw/dmx/vnc/vncint.h
|
||
|
@@ -114,8 +114,8 @@ typedef struct {
|
||
|
|
||
|
CloseScreenProcPtr CloseScreen;
|
||
|
CreateGCProcPtr CreateGC;
|
||
|
- PaintWindowBackgroundProcPtr PaintWindowBackground;
|
||
|
- PaintWindowBorderProcPtr PaintWindowBorder;
|
||
|
+// PaintWindowBackgroundProcPtr PaintWindowBackground;
|
||
|
+// PaintWindowBorderProcPtr PaintWindowBorder;
|
||
|
CopyWindowProcPtr CopyWindow;
|
||
|
ClearToBackgroundProcPtr ClearToBackground;
|
||
|
RestoreAreasProcPtr RestoreAreas;
|
||
|
Index: xorg-server-1.9.2/hw/xfree86/vnc/vncint.h
|
||
|
===================================================================
|
||
|
--- xorg-server-1.9.2.orig/hw/xfree86/vnc/vncint.h
|
||
|
+++ xorg-server-1.9.2/hw/xfree86/vnc/vncint.h
|
||
|
@@ -112,8 +112,8 @@ typedef struct {
|
||
|
|
||
|
CloseScreenProcPtr CloseScreen;
|
||
|
CreateGCProcPtr CreateGC;
|
||
|
- PaintWindowBackgroundProcPtr PaintWindowBackground;
|
||
|
- PaintWindowBorderProcPtr PaintWindowBorder;
|
||
|
+// PaintWindowBackgroundProcPtr PaintWindowBackground;
|
||
|
+// PaintWindowBorderProcPtr PaintWindowBorder;
|
||
|
CopyWindowProcPtr CopyWindow;
|
||
|
ClearToBackgroundProcPtr ClearToBackground;
|
||
|
RestoreAreasProcPtr RestoreAreas;
|
||
|
Index: xorg-server-1.9.2/hw/vnc/vncext.c
|
||
|
===================================================================
|
||
|
--- xorg-server-1.9.2.orig/hw/vnc/vncext.c
|
||
|
+++ xorg-server-1.9.2/hw/vnc/vncext.c
|
||
|
@@ -763,7 +763,7 @@ VncExtensionInit(void)
|
||
|
vncExtGeneration = serverGeneration;
|
||
|
|
||
|
// no allocation needed for screen privates
|
||
|
- if (!dixRequestPrivate(rfbGCKey, sizeof(rfbGCRec)))
|
||
|
+ if (!dixRegisterPrivateKey(rfbGCKey, PRIVATE_CLIENT, sizeof(rfbGCRec)))
|
||
|
return;
|
||
|
|
||
|
#if XFREE86VNC
|
||
|
Index: xorg-server-1.9.2/hw/vnc/tableinitcmtemplate.c
|
||
|
===================================================================
|
||
|
--- xorg-server-1.9.2.orig/hw/vnc/tableinitcmtemplate.c
|
||
|
+++ xorg-server-1.9.2/hw/vnc/tableinitcmtemplate.c
|
||
|
@@ -61,7 +61,7 @@ rfbInitColourMapSingleTableOUT (ScreenPt
|
||
|
t = (OUT_T *)*table;
|
||
|
|
||
|
#if XFREE86VNC
|
||
|
- pent = (EntryPtr)&miInstalledMaps[pScreen->myNum]->red[0];
|
||
|
+ pent = (EntryPtr)&GetInstalledmiColormap(pScreen)->red[0];
|
||
|
#else
|
||
|
pent = (EntryPtr)&pVNC->rfbInstalledColormap->red[0];
|
||
|
#endif
|
||
|
Index: xorg-server-1.9.2/hw/xfree86/vnc/vncInit.c
|
||
|
===================================================================
|
||
|
--- xorg-server-1.9.2.orig/hw/xfree86/vnc/vncInit.c
|
||
|
+++ xorg-server-1.9.2/hw/xfree86/vnc/vncInit.c
|
||
|
@@ -286,8 +286,8 @@ VNCInit(ScreenPtr pScreen, unsigned char
|
||
|
|
||
|
pScreenPriv->CloseScreen = pScreen->CloseScreen;
|
||
|
pScreenPriv->CreateGC = pScreen->CreateGC;
|
||
|
- pScreenPriv->PaintWindowBackground = pScreen->PaintWindowBackground;
|
||
|
- pScreenPriv->PaintWindowBorder = pScreen->PaintWindowBorder;
|
||
|
+// pScreenPriv->PaintWindowBackground = pScreen->PaintWindowBackground;
|
||
|
+// pScreenPriv->PaintWindowBorder = pScreen->PaintWindowBorder;
|
||
|
pScreenPriv->CopyWindow = pScreen->CopyWindow;
|
||
|
pScreenPriv->ClearToBackground = pScreen->ClearToBackground;
|
||
|
pScreenPriv->RestoreAreas = pScreen->RestoreAreas;
|
||
|
@@ -313,8 +313,8 @@ VNCInit(ScreenPtr pScreen, unsigned char
|
||
|
#endif
|
||
|
pScreen->CloseScreen = rfbCloseScreen;
|
||
|
pScreen->CreateGC = rfbCreateGC;
|
||
|
- pScreen->PaintWindowBackground = rfbPaintWindowBackground;
|
||
|
- pScreen->PaintWindowBorder = rfbPaintWindowBorder;
|
||
|
+// pScreen->PaintWindowBackground = rfbPaintWindowBackground;
|
||
|
+// pScreen->PaintWindowBorder = rfbPaintWindowBorder;
|
||
|
pScreen->CopyWindow = rfbCopyWindow;
|
||
|
pScreen->ClearToBackground = rfbClearToBackground;
|
||
|
pScreen->RestoreAreas = rfbRestoreAreas;
|