Skip to content

Commit 1747ce0

Browse files
committed
nxagent: Fake backing store support via Composite extension.
1 parent ce182e8 commit 1747ce0

37 files changed

+4
-5218
lines changed

nx-X11/programs/Xserver/composite/compinit.c

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -99,8 +99,6 @@ compInstallColormap (ColormapPtr pColormap)
9999
pScreen->InstallColormap = compInstallColormap;
100100
}
101101

102-
/* Unsupported by current architecture, drop for now. */
103-
#if 0
104102
static void
105103
compCheckBackingStore(WindowPtr pWin)
106104
{
@@ -134,7 +132,6 @@ compChangeWindowAttributes(WindowPtr pWin, unsigned long mask)
134132

135133
return ret;
136134
}
137-
#endif /* 0 */
138135

139136
static void
140137
compGetImage(DrawablePtr pDrawable,
@@ -464,11 +461,8 @@ compScreenInit (ScreenPtr pScreen)
464461
cs->InstallColormap = pScreen->InstallColormap;
465462
pScreen->InstallColormap = compInstallColormap;
466463

467-
/* Unsupported by our current architecture, drop for now. */
468-
/*
469464
cs->ChangeWindowAttributes = pScreen->ChangeWindowAttributes;
470465
pScreen->ChangeWindowAttributes = compChangeWindowAttributes;
471-
*/
472466

473467
cs->BlockHandler = NULL;
474468

nx-X11/programs/Xserver/dix/window.c

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2928,9 +2928,6 @@ UnrealizeTree(
29282928
deltaSaveUndersViewable--;
29292929
#endif
29302930
pChild->viewable = FALSE;
2931-
if (pChild->backStorage)
2932-
(*pChild->drawable.pScreen->SaveDoomedAreas)(
2933-
pChild, &pChild->clipList, 0, 0);
29342931
(* MarkUnrealizedWindow)(pChild, pWin, fromConfigure);
29352932
pChild->drawable.serialNumber = NEXT_SERIAL_NUMBER;
29362933
}
@@ -3061,9 +3058,6 @@ UnmapSubwindows(register WindowPtr pWin)
30613058
#ifdef DO_SAVE_UNDERS
30623059
pChild->DIXsaveUnder = FALSE;
30633060
#endif /* DO_SAVE_UNDERS */
3064-
if (pChild->backStorage)
3065-
(*pScreen->SaveDoomedAreas)(
3066-
pChild, &pChild->clipList, 0, 0);
30673061
}
30683062
}
30693063
}

nx-X11/programs/Xserver/fb/Imakefile

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,6 @@ SRCS = $(XFMODSRC) \
3030
fbbits.c \
3131
fbblt.c \
3232
fbbltone.c \
33-
fbbstore.c \
3433
fbcmap.c \
3534
$(RENDERSRC) \
3635
fbcopy.c \
@@ -66,7 +65,6 @@ OBJS = $(XFMODOBJ) \
6665
fbbits.o \
6766
fbblt.o \
6867
fbbltone.o \
69-
fbbstore.o \
7068
fbcmap.o \
7169
$(RENDEROBJ) \
7270
fbcopy.o \
@@ -128,7 +126,6 @@ LinkSourceFile(fbarc.c,LinkDirectory)
128126
LinkSourceFile(fbbits.c,LinkDirectory)
129127
LinkSourceFile(fbblt.c,LinkDirectory)
130128
LinkSourceFile(fbbltone.c,LinkDirectory)
131-
LinkSourceFile(fbbstore.c,LinkDirectory)
132129
LinkSourceFile(fbcmap.c,LinkDirectory)
133130
#if BuildRender
134131
LinkSourceFile(fbcompose.c,LinkDirectory)

nx-X11/programs/Xserver/fb/fb.h

Lines changed: 0 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,6 @@
3636
#include "windowstr.h"
3737
#include "mi.h"
3838
#include "migc.h"
39-
#include "mibstore.h"
4039
#ifdef RENDER
4140
#include "picturestr.h"
4241
#else
@@ -1220,23 +1219,6 @@ fbBltPlane (FbBits *src,
12201219
FbStip bgxor,
12211220
Pixel planeMask);
12221221

1223-
/*
1224-
* fbbstore.c
1225-
*/
1226-
void
1227-
fbSaveAreas(PixmapPtr pPixmap,
1228-
RegionPtr prgnSave,
1229-
int xorg,
1230-
int yorg,
1231-
WindowPtr pWin);
1232-
1233-
void
1234-
fbRestoreAreas(PixmapPtr pPixmap,
1235-
RegionPtr prgnRestore,
1236-
int xorg,
1237-
int yorg,
1238-
WindowPtr pWin);
1239-
12401222
/*
12411223
* fbcmap.c
12421224
*/

nx-X11/programs/Xserver/fb/fbbstore.c

Lines changed: 0 additions & 65 deletions
This file was deleted.

nx-X11/programs/Xserver/fb/fbscreen.c

Lines changed: 0 additions & 37 deletions
Original file line numberDiff line numberDiff line change
@@ -146,12 +146,6 @@ fbSetupScreen(ScreenPtr pScreen,
146146
#ifndef FB_OLD_SCREEN
147147
pScreen->GetWindowPixmap = _fbGetWindowPixmap;
148148
pScreen->SetWindowPixmap = _fbSetWindowPixmap;
149-
150-
pScreen->BackingStoreFuncs.SaveAreas = fbSaveAreas;
151-
pScreen->BackingStoreFuncs.RestoreAreas = fbRestoreAreas;
152-
pScreen->BackingStoreFuncs.SetClipmaskRgn = 0;
153-
pScreen->BackingStoreFuncs.GetImagePixmap = 0;
154-
pScreen->BackingStoreFuncs.GetSpansPixmap = 0;
155149
#endif
156150

157151
return TRUE;
@@ -245,14 +239,6 @@ fbFinishScreenInit(ScreenPtr pScreen,
245239
pScreen->ModifyPixmapHeader = fb24_32ModifyPixmapHeader;
246240
pScreen->CreateScreenResources = fb24_32CreateScreenResources;
247241
}
248-
#endif
249-
#if 0
250-
/* leave backing store initialization to the enclosing code so
251-
* it can choose the correct order of wrappers
252-
*/
253-
/* init backing store here so we can overwrite CloseScreen without stepping
254-
* on the backing store wrapped version */
255-
fbInitializeBackingStore (pScreen);
256242
#endif
257243
return TRUE;
258244
}
@@ -275,26 +261,3 @@ fbScreenInit(ScreenPtr pScreen,
275261
return FALSE;
276262
return TRUE;
277263
}
278-
279-
280-
#ifdef FB_OLD_SCREEN
281-
const miBSFuncRec fbBSFuncRec = {
282-
fbSaveAreas,
283-
fbRestoreAreas,
284-
(void (*)(GCPtr, RegionPtr)) 0,
285-
(PixmapPtr (*)(void)) 0,
286-
(PixmapPtr (*)(void)) 0,
287-
};
288-
#endif
289-
290-
#if 0
291-
void
292-
fbInitializeBackingStore (ScreenPtr pScreen)
293-
{
294-
#ifdef FB_OLD_SCREEN
295-
miInitializeBackingStore (pScreen, (miBSFuncRec *) &fbBSFuncRec);
296-
#else
297-
miInitializeBackingStore (pScreen);
298-
#endif
299-
}
300-
#endif

nx-X11/programs/Xserver/hw/nxagent/Drawable.c

Lines changed: 0 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -44,8 +44,6 @@
4444

4545
#include "compext/Compext.h"
4646

47-
#include "mibstorest.h"
48-
4947
#define PANIC
5048
#define WARNING
5149
#undef TEST
@@ -3055,7 +3053,6 @@ int nxagentSynchronizationPredicate()
30553053
void nxagentSendBackgroundExpose(WindowPtr pWin, PixmapPtr pBackground, RegionPtr pExpose)
30563054
{
30573055
RegionRec expose;
3058-
miBSWindowPtr pBackingStore;
30593056

30603057
RegionInit(&expose, NullBox, 1);
30613058

@@ -3111,21 +3108,6 @@ void nxagentSendBackgroundExpose(WindowPtr pWin, PixmapPtr pBackground, RegionPt
31113108
expose.extents.x1, expose.extents.y1, expose.extents.x2, expose.extents.y2);
31123109
#endif
31133110

3114-
/*
3115-
* This prevents hidden region to be exposed.
3116-
*/
3117-
3118-
pBackingStore = (miBSWindowPtr)pWin->backStorage;
3119-
3120-
if ((pBackingStore != NULL) && (RegionNil(&pBackingStore->SavedRegion) == 0))
3121-
{
3122-
RegionTranslate(&expose, -pWin -> drawable.x, -pWin -> drawable.y);
3123-
3124-
RegionSubtract(&expose, &expose, &pBackingStore -> SavedRegion);
3125-
3126-
RegionTranslate(&expose, pWin -> drawable.x, pWin -> drawable.y);
3127-
}
3128-
31293111
RegionIntersect(&expose, &expose, &pWin -> clipList);
31303112

31313113
/*

nx-X11/programs/Xserver/hw/nxagent/Events.c

Lines changed: 0 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,6 @@
3838
#include "selection.h"
3939
#include "keysym.h"
4040
#include "fb.h"
41-
#include "mibstorest.h"
4241
#include "osdep.h"
4342

4443
#include "Agent.h"
@@ -2545,7 +2544,6 @@ int nxagentHandleGraphicsExposeEvent(XEvent *X)
25452544
BoxRec rect;
25462545
WindowPtr pWin;
25472546
StoringPixmapPtr pStoringPixmapRec = NULL;
2548-
miBSWindowPtr pBSwindow = NULL;
25492547
int drawableType;
25502548

25512549
pWin = nxagentWindowPtr(X -> xgraphicsexpose.drawable);
@@ -2561,28 +2559,6 @@ int nxagentHandleGraphicsExposeEvent(XEvent *X)
25612559

25622560
if (drawableType == DRAWABLE_PIXMAP)
25632561
{
2564-
pStoringPixmapRec = nxagentFindItemBSPixmapList(X -> xgraphicsexpose.drawable);
2565-
2566-
if (pStoringPixmapRec == NULL)
2567-
{
2568-
#ifdef TEST
2569-
fprintf(stderr, "nxagentHandleGraphicsExposeEvent: WARNING! Storing pixmap not found.\n");
2570-
#endif
2571-
2572-
return 1;
2573-
}
2574-
2575-
pBSwindow = (miBSWindowPtr) pStoringPixmapRec -> pSavedWindow -> backStorage;
2576-
2577-
if (pBSwindow == NULL)
2578-
{
2579-
#ifdef TEST
2580-
fprintf(stderr, "nxagentHandleGraphicsExposeEvent: WARNING! Back storage not found.\n");
2581-
#endif
2582-
2583-
return 1;
2584-
}
2585-
25862562
pWin = pStoringPixmapRec -> pSavedWindow;
25872563
}
25882564

@@ -2616,13 +2592,6 @@ int nxagentHandleGraphicsExposeEvent(XEvent *X)
26162592
RegionTranslate(exposeRegion, pStoringPixmapRec -> backingStoreX,
26172593
pStoringPixmapRec -> backingStoreY);
26182594

2619-
/*
2620-
* We remove from SavedRegion the part
2621-
* affected by the GraphicsExpose event.
2622-
*/
2623-
2624-
RegionSubtract(&(pBSwindow -> SavedRegion), &(pBSwindow -> SavedRegion),
2625-
exposeRegion);
26262595
}
26272596

26282597
/*

nx-X11/programs/Xserver/hw/nxagent/Init.c

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -315,8 +315,6 @@ void InitOutput(ScreenInfo *screenInfo, int argc, char *argv[])
315315
}
316316
}
317317

318-
nxagentInitBSPixmapList();
319-
320318
/*
321319
* Open the display. We are at the early startup and
322320
* the information we'll get from the remote X server

0 commit comments

Comments
 (0)