[xserver-commit] xserver/mi mi.h,3.12,3.13 midispcur.c,1.12,1.13 mivaltree.c,1.13,1.14
Keith Packard
xserver-commit@pdx.freedesktop.org
Fri, 07 Nov 2003 15:29:32 -0800
Committed by: keithp
Update of /cvs/xserver/xserver/mi
In directory pdx:/tmp/cvs-serv8754/mi
Modified Files:
mi.h midispcur.c mivaltree.c
Log Message:
* composite/compalloc.c: (compReportDamage), (compRedirectWindow),
(compFreeClientWindow), (compFreeClientSubwindows),
(compRedirectOneSubwindow), (compUnredirectOneSubwindow),
(compAllocPixmap), (compFreePixmap), (compReallocPixmap):
* composite/compext.c: (CompositeExtensionInit):
* composite/compinit.c: (compScreenInit):
* composite/compint.h:
* composite/compwindow.c: (compCheckRedirect),
(compReparentWindow), (compCopyWindow), (compDestroyWindow),
(compSetRedirectBorderClip), (compGetRedirectBorderClip),
(compWindowUpdateAutomatic), (compWindowUpdate):
* fb/fb.h:
* fb/fbpixmap.c: (fbCreatePixmapBpp):
* fb/fbwindow.c: (fbCopyWindow):
* hw/kdrive/fbdev/fbdev.c: (fbdevInitialize), (fbdevScreenInit):
* hw/kdrive/linux/keyboard.c: (readKernelMapping):
* hw/kdrive/linux/linux.c: (LinuxInit), (LinuxSpecialKey),
(LinuxFini):
* hw/kdrive/linux/mouse.c: (MouseWaitForReadable), (MouseReadByte),
(ps2SkipInit), (MouseRead):
* hw/kdrive/smi/smi.c: (smiScreenInit):
* include/pixmapstr.h:
* mi/mi.h:
* mi/midispcur.c:
* mi/mivaltree.c: (miRegisterRedirectBorderClipProc),
(miComputeClips):
* miext/damage/damage.c: (DamageDamageRegion):
* miext/damage/damage.h:
* render/mipict.c: (miValidatePicture):
Ok, Composite extension is semi-working; when no-one asks
for redirection, the server seems to act as before. With
RedirectSubwindows (root, automatic), the server looks just
like a regular X server. Now to go rewrite the (currently lame)
compositing manager to get some real action on the screen.
Some of the fixes here are to make valgrind quiet with
various ioctls used by kdrive/linux.
Also fixed a bug where fbdev initialization was out of order
in fbdev.c and smi.c
Index: mi.h
===================================================================
RCS file: /cvs/xserver/xserver/mi/mi.h,v
retrieving revision 3.12
retrieving revision 3.13
diff -u -d -r3.12 -r3.13
--- mi.h 5 Nov 2003 05:45:31 -0000 3.12
+++ mi.h 7 Nov 2003 23:29:29 -0000 3.13
@@ -496,13 +496,14 @@
);
typedef void
-(*RedirectBorderClipProcPtr) (WindowPtr pWindow, RegionPtr pRegion);
+(*SetRedirectBorderClipProcPtr) (WindowPtr pWindow, RegionPtr pRegion);
-void
-miRegisterRedirectBorderClipProc (RedirectBorderClipProcPtr redirectBorderClip);
+typedef RegionPtr
+(*GetRedirectBorderClipProcPtr) (WindowPtr pWindow);
-RedirectBorderClipProcPtr
-miGetRedirectBorderClipProc (void);
+void
+miRegisterRedirectBorderClipProc (SetRedirectBorderClipProcPtr setBorderClip,
+ GetRedirectBorderClipProcPtr getBorderClip);
extern int miValidateTree(
WindowPtr /*pParent*/,
Index: midispcur.c
===================================================================
RCS file: /cvs/xserver/xserver/mi/midispcur.c,v
retrieving revision 1.12
retrieving revision 1.13
diff -u -d -r1.12 -r1.13
--- midispcur.c 11 Sep 2003 05:12:51 -0000 1.12
+++ midispcur.c 7 Nov 2003 23:29:29 -0000 1.13
@@ -182,7 +182,7 @@
tossPix (pScreenPriv->pSave);
tossPix (pScreenPriv->pTemp);
#ifdef ARGB_CURSOR
- tossPict (pScreenPriv->pRootPicture);
+ /* tossPict (pScreenPriv->pRootPicture); freed when root is freed */
tossPict (pScreenPriv->pTempPicture);
#endif
xfree ((pointer) pScreenPriv);
Index: mivaltree.c
===================================================================
RCS file: /cvs/xserver/xserver/mi/mivaltree.c,v
retrieving revision 1.13
retrieving revision 1.14
diff -u -d -r1.13 -r1.14
--- mivaltree.c 5 Nov 2003 05:45:31 -0000 1.13
+++ mivaltree.c 7 Nov 2003 23:29:29 -0000 1.14
@@ -162,18 +162,15 @@
}
#endif
-static RedirectBorderClipProcPtr miRedirectBorderClipProc;
+static GetRedirectBorderClipProcPtr miGetRedirectBorderClipProc;
+static SetRedirectBorderClipProcPtr miSetRedirectBorderClipProc;
void
-miRegisterRedirectBorderClipProc (RedirectBorderClipProcPtr redirectBorderClip)
-{
- miRedirectBorderClipProc = redirectBorderClip;
-}
-
-RedirectBorderClipProcPtr
-miGetRedirectBorderClipProc (void)
+miRegisterRedirectBorderClipProc (SetRedirectBorderClipProcPtr setBorderClip,
+ GetRedirectBorderClipProcPtr getBorderClip)
{
- return miRedirectBorderClipProc;
+ miSetRedirectBorderClipProc = setBorderClip;
+ miGetRedirectBorderClipProc = getBorderClip;
}
#define HasParentRelativeBorder(w) (!(w)->borderIsPixel && \
@@ -279,8 +276,8 @@
*/
if (pParent->redirectDraw)
{
- if (miRedirectBorderClipProc)
- (*miRedirectBorderClipProc) (pParent, universe);
+ if (miSetRedirectBorderClipProc)
+ (*miSetRedirectBorderClipProc) (pParent, universe);
REGION_COPY(pScreen, universe, &pParent->borderSize);
}
#endif
@@ -663,7 +660,10 @@
{
if (pWin->valdata)
{
- REGION_APPEND( pScreen, &totalClip, &pWin->borderClip);
+ RegionPtr pBorderClip = &pWin->borderClip;
+ if (pWin->redirectDraw && miGetRedirectBorderClipProc)
+ pBorderClip = (*miGetRedirectBorderClipProc)(pWin);
+ REGION_APPEND( pScreen, &totalClip, pBorderClip );
if (pWin->viewable)
viewvals++;
}
@@ -677,7 +677,10 @@
{
if (pWin->valdata)
{
- REGION_APPEND( pScreen, &totalClip, &pWin->borderClip);
+ RegionPtr pBorderClip = &pWin->borderClip;
+ if (pWin->redirectDraw && miGetRedirectBorderClipProc)
+ pBorderClip = (*miGetRedirectBorderClipProc)(pWin);
+ REGION_APPEND( pScreen, &totalClip, pBorderClip );
if (pWin->viewable)
viewvals++;
}