diff options
author | Ulrich Sibiller <uli42@gmx.de> | 2017-11-04 23:51:30 +0100 |
---|---|---|
committer | Mihai Moldovan <ionic@ionic.de> | 2018-02-26 04:54:35 +0100 |
commit | 50a33794069fd22e615f6208cd4c82a64452b485 (patch) | |
tree | c272cfb28c3d5c1940332d118993514907993188 /nx-X11/programs/Xserver/dix | |
parent | b40dec982d17b010cedc183ebdc4c75ca7de785f (diff) | |
download | nx-libs-50a33794069fd22e615f6208cd4c82a64452b485.tar.gz nx-libs-50a33794069fd22e615f6208cd4c82a64452b485.tar.bz2 nx-libs-50a33794069fd22e615f6208cd4c82a64452b485.zip |
Lift dix to xorg-xserver-7.1/1.1.0 state
Diffstat (limited to 'nx-X11/programs/Xserver/dix')
-rw-r--r-- | nx-X11/programs/Xserver/dix/colormap.c | 7 | ||||
-rw-r--r-- | nx-X11/programs/Xserver/dix/globals.c | 7 | ||||
-rw-r--r-- | nx-X11/programs/Xserver/dix/main.c | 2 | ||||
-rw-r--r-- | nx-X11/programs/Xserver/dix/pixmap.c | 8 | ||||
-rw-r--r-- | nx-X11/programs/Xserver/dix/window.c | 31 |
5 files changed, 47 insertions, 8 deletions
diff --git a/nx-X11/programs/Xserver/dix/colormap.c b/nx-X11/programs/Xserver/dix/colormap.c index 81b93d2de..42ba8002a 100644 --- a/nx-X11/programs/Xserver/dix/colormap.c +++ b/nx-X11/programs/Xserver/dix/colormap.c @@ -273,6 +273,13 @@ CreateColormap (Colormap mid, ScreenPtr pScreen, VisualPtr pVisual, pmap = (ColormapPtr) malloc(sizebytes); if (!pmap) return (BadAlloc); +#if defined(_XSERVER64) + pmap->pad0 = 0; + pmap->pad1 = 0; +#if (X_BYTE_ORDER == X_LITTLE_ENDIAN) + pmap->pad2 = 0; +#endif +#endif pmap->red = (EntryPtr)((char *)pmap + sizeof(ColormapRec)); sizebytes = size * sizeof(Entry); pmap->clientPixelsRed = (Pixel **)((char *)pmap->red + sizebytes); diff --git a/nx-X11/programs/Xserver/dix/globals.c b/nx-X11/programs/Xserver/dix/globals.c index 6f4774a5c..04e6585dd 100644 --- a/nx-X11/programs/Xserver/dix/globals.c +++ b/nx-X11/programs/Xserver/dix/globals.c @@ -103,7 +103,7 @@ int ScreenSaverAllowExposures; # define DEFAULT_OFF_TIME DEFAULT_SCREEN_SAVER_TIME * 4 # endif # ifndef DEFAULT_DPMS_ENABLED -# define DEFAULT_DPMS_ENABLED FALSE +# define DEFAULT_DPMS_ENABLED TRUE # endif CARD32 defaultDPMSStandbyTime = DEFAULT_STANDBY_TIME; CARD32 defaultDPMSSuspendTime = DEFAULT_SUSPEND_TIME; @@ -140,15 +140,12 @@ FontPtr defaultFont; /* not declared in dix.h to avoid including font.h in Bool loadableFonts = FALSE; CursorPtr rootCursor; Bool blackRoot=FALSE; +Bool whiteRoot=FALSE; ClientPtr requestingClient; /* XXX this should be obsolete now, remove? */ TimeStamp currentTime; TimeStamp lastDeviceEventTime; -Bool permitOldBugs = FALSE; /* turn off some error checking, to permit certain - * old broken clients (like R2/R3 xterms) to work - */ - int defaultColorVisualClass = -1; int monitorResolution = 0; diff --git a/nx-X11/programs/Xserver/dix/main.c b/nx-X11/programs/Xserver/dix/main.c index eb8f359a6..d5503676d 100644 --- a/nx-X11/programs/Xserver/dix/main.c +++ b/nx-X11/programs/Xserver/dix/main.c @@ -167,7 +167,7 @@ ReplyNotSwappd( int main(int argc, char *argv[], char *envp[]) { - int i, error; + int i; char *xauthfile; HWEventQueueType alwaysCheckForInput[2]; diff --git a/nx-X11/programs/Xserver/dix/pixmap.c b/nx-X11/programs/Xserver/dix/pixmap.c index 709f413ed..f13473498 100644 --- a/nx-X11/programs/Xserver/dix/pixmap.c +++ b/nx-X11/programs/Xserver/dix/pixmap.c @@ -146,5 +146,13 @@ AllocatePixmap(ScreenPtr pScreen, int pixDataSize) #else pPixmap = (PixmapPtr)calloc(1, sizeof(PixmapRec) + pixDataSize); #endif + +#ifdef _XSERVER64 + if (pPixmap) { + pPixmap->drawable.pad0 = 0; + pPixmap->drawable.pad1 = 0; + } +#endif + return pPixmap; } diff --git a/nx-X11/programs/Xserver/dix/window.c b/nx-X11/programs/Xserver/dix/window.c index ba9cfc2d2..7cb5a5f4b 100644 --- a/nx-X11/programs/Xserver/dix/window.c +++ b/nx-X11/programs/Xserver/dix/window.c @@ -358,6 +358,10 @@ AllocateWindow(ScreenPtr pScreen) else ppriv->ptr = (void *)NULL; } +#if _XSERVER64 + pWin->drawable.pad0 = 0; + pWin->drawable.pad1 = 0; +#endif } return pWin; } @@ -2709,7 +2713,7 @@ MapWindow(register WindowPtr pWin, ClientPtr client) } pWin->mapped = TRUE; - if (SubStrSend(pWin, pParent)) + if (SubStrSend(pWin, pParent) && MapUnmapEventsEnabled(pWin)) { memset(&event, 0, sizeof(xEvent)); event.u.u.type = MapNotify; @@ -2968,7 +2972,7 @@ UnmapWindow(register WindowPtr pWin, Bool fromConfigure) if ((!pWin->mapped) || (!(pParent = pWin->parent))) return(Success); - if (SubStrSend(pWin, pParent)) + if (SubStrSend(pWin, pParent) && MapUnmapEventsEnabled(pWin)) { memset(&event, 0, sizeof(xEvent)); event.u.u.type = UnmapNotify; @@ -3271,6 +3275,29 @@ SendVisibilityNotify(WindowPtr pWin) DeliverEvents(pWin, &event, 1, NullWindow); } +static WindowPtr windowDisableMapUnmapEvents; + +void +DisableMapUnmapEvents(WindowPtr pWin) +{ + assert (windowDisableMapUnmapEvents == NULL); + + windowDisableMapUnmapEvents = pWin; +} + +void +EnableMapUnmapEvents(WindowPtr pWin) +{ + assert (windowDisableMapUnmapEvents != NULL); + + windowDisableMapUnmapEvents = NULL; +} + +Bool +MapUnmapEventsEnabled(WindowPtr pWin) +{ + return pWin != windowDisableMapUnmapEvents; +} #define RANDOM_WIDTH 32 |