Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
N
nx-libs
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
1
Issues
1
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
dimbor
nx-libs
Commits
8b15d574
Unverified
Commit
8b15d574
authored
Aug 27, 2019
by
Mike Gabriel
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'uli42-pr/fix_background' into 3.6.x
Attributes GH PR #836:
https://github.com/ArcticaProject/nx-libs/pull/836
parents
f24767b3
3563959c
Show whitespace changes
Inline
Side-by-side
Showing
14 changed files
with
98 additions
and
266 deletions
+98
-266
window.c
nx-X11/programs/Xserver/dix/window.c
+0
-2
Display.c
nx-X11/programs/Xserver/hw/nxagent/Display.c
+0
-16
Events.c
nx-X11/programs/Xserver/hw/nxagent/Events.c
+0
-15
Imakefile
nx-X11/programs/Xserver/hw/nxagent/Imakefile
+0
-1
Init.c
nx-X11/programs/Xserver/hw/nxagent/Init.c
+1
-0
NXdispatch.c
nx-X11/programs/Xserver/hw/nxagent/NXdispatch.c
+8
-20
NXwindow.c
nx-X11/programs/Xserver/hw/nxagent/NXwindow.c
+0
-81
Reconnect.c
nx-X11/programs/Xserver/hw/nxagent/Reconnect.c
+1
-1
Screen.c
nx-X11/programs/Xserver/hw/nxagent/Screen.c
+3
-8
Splash.c
nx-X11/programs/Xserver/hw/nxagent/Splash.c
+76
-59
Splash.h
nx-X11/programs/Xserver/hw/nxagent/Splash.h
+2
-11
Window.c
nx-X11/programs/Xserver/hw/nxagent/Window.c
+0
-50
nxagent.1
nx-X11/programs/Xserver/hw/nxagent/man/nxagent.1
+4
-2
utils.c
nx-X11/programs/Xserver/os/utils.c
+3
-0
No files found.
nx-X11/programs/Xserver/dix/window.c
View file @
8b15d574
...
...
@@ -305,7 +305,6 @@ SetWindowToDefaults(register WindowPtr pWin)
#endif
}
#ifndef NXAGENT_SERVER
static
void
MakeRootTile
(
WindowPtr
pWin
)
{
...
...
@@ -348,7 +347,6 @@ MakeRootTile(WindowPtr pWin)
FreeScratchGC
(
pGC
);
}
#endif
/* NXAGENT_SERVER */
WindowPtr
AllocateWindow
(
ScreenPtr
pScreen
)
...
...
nx-X11/programs/Xserver/hw/nxagent/Display.c
View file @
8b15d574
...
...
@@ -1386,15 +1386,6 @@ FIXME: Use of nxagentParentWindow is strongly deprecated.
nxagentChangeOption
(
BorderWidth
,
1
);
}
nxagentLogoDepth
=
DefaultDepth
(
nxagentDisplay
,
DefaultScreen
(
nxagentDisplay
)
);
nxagentLogoBlack
=
0x000000
;
nxagentLogoRed
=
0xff0000
;
nxagentLogoWhite
=
0xffffff
;
nxagentLogoGray
=
0x222222
;
#ifdef WATCH
fprintf
(
stderr
,
"nxagentOpenDisplay: Watchpoint 5.1.
\n
"
);
...
...
@@ -2860,13 +2851,6 @@ Bool nxagentReconnectDisplay(void *p0)
nxagentConfineWindow
);
#endif
nxagentLogoDepth
=
DefaultDepth
(
nxagentDisplay
,
DefaultScreen
(
nxagentDisplay
));
nxagentLogoBlack
=
0x000000
;
nxagentLogoRed
=
0xff0000
;
nxagentLogoWhite
=
0xffffff
;
nxagentLogoGray
=
0x222222
;
useXpmIcon
=
nxagentMakeIcon
(
nxagentDisplay
,
&
nxagentIconPixmap
,
&
nxagentIconShape
);
/*
...
...
nx-X11/programs/Xserver/hw/nxagent/Events.c
View file @
8b15d574
...
...
@@ -124,7 +124,6 @@
extern
Bool
nxagentOnce
;
extern
WindowPtr
nxagentRootTileWindow
;
extern
int
nxagentSplashCount
;
extern
int
nxagentLastClipboardClient
;
...
...
@@ -2453,20 +2452,6 @@ FIXME: This can be maybe optimized by consuming the
}
}
if
(
nxagentRootTileWindow
!=
NULL
)
{
if
(
nxagentWindowPriv
(
nxagentRootTileWindow
)
->
window
==
nxagentWindowPriv
(
pWin
)
->
window
&&
nxagentSplashCount
==
1
&&
X
->
xexpose
.
count
==
0
)
{
#ifdef DEBUG
fprintf
(
stderr
,
"nxagentHandleExposeEvent: Clearing root tile window id [%u].
\n
"
,
nxagentWindowPriv
(
nxagentRootTileWindow
)
->
window
);
#endif
XClearWindow
(
nxagentDisplay
,
nxagentWindowPriv
(
nxagentRootTileWindow
)
->
window
);
}
}
RegionUninit
(
&
sum
);
}
...
...
nx-X11/programs/Xserver/hw/nxagent/Imakefile
View file @
8b15d574
...
...
@@ -240,7 +240,6 @@ DEFINES = \
-DNXAGENT_VISIBILITY \
-DNXAGENT_WAKEUP=1000 \
-DNXAGENT_ONSTART \
-DNXAGENT_SPLASH \
-DNXAGENT_ARTSD \
-DNXAGENT_RANDR_MODE_PREFIX \
-UNX_DEBUG_INPUT \
...
...
nx-X11/programs/Xserver/hw/nxagent/Init.c
View file @
8b15d574
...
...
@@ -413,6 +413,7 @@ FIXME: These variables, if not removed at all because have probably
* background.
*/
if
(
!
whiteRoot
)
blackRoot
=
TRUE
;
nxagentInitKeystrokes
(
False
);
...
...
nx-X11/programs/Xserver/hw/nxagent/NXdispatch.c
View file @
8b15d574
...
...
@@ -141,9 +141,6 @@ void nxagentWaitDisplay(void);
void
nxagentListRemoteFonts
(
const
char
*
,
int
);
unsigned
int
nxagentWMtimeout
=
0
;
Bool
nxagentWMPassed
=
False
;
/*
* Timeouts based on screen saver time.
*/
...
...
@@ -243,8 +240,6 @@ Dispatch(void)
register
HWEventQueuePtr
*
icheck
=
checkForInput
;
long
start_tick
;
unsigned
long
currentDispatch
=
0
;
nextFreeClientID
=
1
;
InitSelections
();
nClients
=
0
;
...
...
@@ -265,12 +260,11 @@ Dispatch(void)
#ifdef NXAGENT_ONSTART
/*
* Set NX_WM property (used by NX client to identify
* the agent's window) three seconds since the first
* client connects.
* Set NX_WM property (used by NX client to identify the agent's
* window) three seconds since the first client connects.
*/
nxagentWMtimeout
=
GetTimeInMillis
()
+
3000
;
unsigned
int
nxagentWMtimeout
=
GetTimeInMillis
()
+
3000
;
#endif
...
...
@@ -370,17 +364,14 @@ Reply Total Cached Bits In Bits Out Bits/Reply Ratio
#ifdef NXAGENT_ONSTART
currentDispatch
=
GetTimeInMillis
();
/*
* If the timeout is expired set the
* selection informing the NX client
* that the agent is ready.
* If the timeout is expired set the selection informing the
* NX client that the agent is ready.
*/
if
(
!
nxagentWMPassed
&&
(
nxagentWMtimeout
<
currentDispatch
))
if
(
nxagentWMtimeout
<
GetTimeInMillis
(
))
{
nxagentRemoveSplashWindow
(
NULL
);
nxagentRemoveSplashWindow
(
);
}
nxagentClients
=
nClients
;
...
...
@@ -588,10 +579,7 @@ ProcReparentWindow(register ClientPtr client)
if
(
!
pWin
)
return
(
BadWindow
);
if
(
!
nxagentWMPassed
)
{
nxagentRemoveSplashWindow
(
pWin
);
}
nxagentRemoveSplashWindow
();
pParent
=
(
WindowPtr
)
SecurityLookupWindow
(
stuff
->
parent
,
client
,
DixWriteAccess
);
...
...
nx-X11/programs/Xserver/hw/nxagent/NXwindow.c
View file @
8b15d574
...
...
@@ -114,10 +114,6 @@ Equipment Corporation.
#include "Drawable.h"
#include "Colormap.h"
/* prototypes (only MakeRootTile() required here) */
static
void
MakeRootTile
(
WindowPtr
pWin
);
#include "../../dix/window.c"
extern
Bool
nxagentWMIsRunning
;
...
...
@@ -132,69 +128,8 @@ extern Bool nxagentScreenTrap;
#undef TEST
#undef DEBUG
WindowPtr
nxagentRootTileWindow
;
extern
void
nxagentSetVersionProperty
(
WindowPtr
pWin
);
void
nxagentClearSplash
(
WindowPtr
pW
)
{
ScreenPtr
pScreen
=
pW
->
drawable
.
pScreen
;
if
(
pW
->
backgroundState
==
BackgroundPixmap
)
{
(
*
pScreen
->
DestroyPixmap
)(
pW
->
background
.
pixmap
);
}
pW
->
backgroundState
=
BackgroundPixel
;
pW
->
background
.
pixel
=
nxagentLogoBlack
;
(
*
pScreen
->
ChangeWindowAttributes
)(
pW
,
CWBackPixmap
|
CWBackPixel
);
}
static
void
MakeRootTile
(
WindowPtr
pWin
)
{
ScreenPtr
pScreen
=
pWin
->
drawable
.
pScreen
;
GCPtr
pGC
;
unsigned
char
back
[
128
];
int
len
=
BitmapBytePad
(
sizeof
(
long
));
register
unsigned
char
*
from
,
*
to
;
register
int
i
,
j
;
pWin
->
background
.
pixmap
=
(
*
pScreen
->
CreatePixmap
)(
pScreen
,
4
,
4
,
pScreen
->
rootDepth
,
0
);
pWin
->
backgroundState
=
BackgroundPixmap
;
pGC
=
GetScratchGC
(
pScreen
->
rootDepth
,
pScreen
);
if
(
!
pWin
->
background
.
pixmap
||
!
pGC
)
FatalError
(
"could not create root tile"
);
{
CARD32
attributes
[
2
];
attributes
[
0
]
=
pScreen
->
whitePixel
;
attributes
[
1
]
=
pScreen
->
blackPixel
;
(
void
)
ChangeGC
(
pGC
,
GCForeground
|
GCBackground
,
attributes
);
}
ValidateGC
((
DrawablePtr
)
pWin
->
background
.
pixmap
,
pGC
);
from
=
(
screenInfo
.
bitmapBitOrder
==
LSBFirst
)
?
_back_lsb
:
_back_msb
;
to
=
back
;
for
(
i
=
4
;
i
>
0
;
i
--
,
from
++
)
for
(
j
=
len
;
j
>
0
;
j
--
)
*
to
++
=
*
from
;
(
*
pGC
->
ops
->
PutImage
)((
DrawablePtr
)
pWin
->
background
.
pixmap
,
pGC
,
1
,
0
,
0
,
len
,
4
,
0
,
XYBitmap
,
(
char
*
)
back
);
FreeScratchGC
(
pGC
);
nxagentRootTileWindow
=
pWin
;
}
void
InitRootWindow
(
WindowPtr
pWin
)
{
...
...
@@ -249,28 +184,12 @@ InitRootWindow(WindowPtr pWin)
pWin
->
optional
->
cursor
=
rootCursor
;
rootCursor
->
refcnt
++
;
#ifdef NXAGENT_SPLASH
if
(
blackRoot
)
pWin
->
background
.
pixel
=
pScreen
->
blackPixel
;
else
pWin
->
background
.
pixel
=
pScreen
->
whitePixel
;
backFlag
|=
CWBackPixel
;
MakeRootTile
(
pWin
);
#else
if
(
!
blackRoot
&&
!
whiteRoot
)
{
MakeRootTile
(
pWin
);
backFlag
|=
CWBackPixmap
;
}
else
{
if
(
blackRoot
)
pWin
->
background
.
pixel
=
pScreen
->
blackPixel
;
else
pWin
->
background
.
pixel
=
pScreen
->
whitePixel
;
backFlag
|=
CWBackPixel
;
}
#endif
pWin
->
backingStore
=
defaultBackingStore
;
pWin
->
forcedBS
=
(
defaultBackingStore
!=
NotUseful
);
...
...
nx-X11/programs/Xserver/hw/nxagent/Reconnect.c
View file @
8b15d574
...
...
@@ -681,7 +681,7 @@ Bool nxagentReconnectSession(void)
#endif
saveAgentState
(
"RUNNING"
);
nxagentRemoveSplashWindow
(
NULL
);
nxagentRemoveSplashWindow
();
/*
* We let the proxy flush the link on our behalf
...
...
nx-X11/programs/Xserver/hw/nxagent/Screen.c
View file @
8b15d574
...
...
@@ -146,9 +146,7 @@ Window nxagentInputWindows[MAXSCREENS];
Window
nxagentScreenSaverWindows
[
MAXSCREENS
];
#ifdef NXAGENT_ONSTART
Atom
nxagentWMStart
;
Window
nxagentSplashWindow
=
None
;
Pixmap
nxagentPixmapLogo
;
Atom
nxagentReadyAtom
;
#endif
ScreenPtr
nxagentDefaultScreen
=
NULL
;
...
...
@@ -934,7 +932,7 @@ Bool nxagentOpenScreen(ScreenPtr pScreen,
nxagentQueryAtoms
(
pScreen
);
#ifdef NXAGENT_ONSTART
nxagent
WMStart
=
nxagentAtoms
[
3
];
/* WM_NX_READY */
nxagent
ReadyAtom
=
nxagentAtoms
[
3
];
/* WM_NX_READY */
#endif
/*
...
...
@@ -3120,10 +3118,7 @@ int nxagentShadowPoll(PixmapPtr nxagentShadowPixmapPtr, GCPtr nxagentShadowGCPtr
if
(
result
==
1
)
{
if
(
!
nxagentWMPassed
)
{
nxagentRemoveSplashWindow
(
NULL
);
}
nxagentRemoveSplashWindow
();
NXShadowExportChanges
(
&
numRects
,
&
ptBox
);
pBox
=
(
BoxRec
*
)
ptBox
;
...
...
nx-X11/programs/Xserver/hw/nxagent/Splash.c
View file @
8b15d574
...
...
@@ -58,19 +58,24 @@
* Colors used to paint the splash screen.
*/
int
nxagentLogoDepth
;
int
nxagentLogoWhite
;
int
nxagentLogoRed
;
int
nxagentLogoBlack
;
int
nxagentLogoGray
;
#define nxagentLogoWhite 0xffffff
#define nxagentLogoBlack 0x000000
#define nxagentLogoDarkGray 0x222222
#define nxagentLogoLightGray 0xbbbbbb
void
nxagentPaintLogo
(
Window
win
,
GC
gc
,
int
scale
,
int
width
,
int
height
);
Pixmap
nxagentPixmapLogo
;
Window
nxagentSplashWindow
=
None
;
Bool
nxagentWMPassed
=
False
;
static
void
nxagentPaintLogo
(
Window
win
,
GC
gc
,
int
scale
,
int
width
,
int
height
);
/*
* From Screen.c.
*/
extern
Atom
nxagentWMStart
;
#ifdef NXAGENT_ONSTART
extern
Atom
nxagentReadyAtom
;
#endif
/*
* From Clipboard.c.
...
...
@@ -78,27 +83,35 @@ extern Atom nxagentWMStart;
extern
Atom
serverCutProperty
;
int
nxagentShowSplashWindow
(
Window
parentWindow
)
void
nxagentShowSplashWindow
(
Window
parentWindow
)
{
XWindowAttributes
getAttributes
;
XWindowChanges
values
;
XSetWindowAttributes
attributes
;
GC
gc
;
/*
* Show splash window only when running as X2Go Agent
*/
if
(
!
nxagentX2go
)
return
;
#ifdef TEST
fprintf
(
stderr
,
"
nxagentShowSplashWindow: Got called.
\n
"
);
fprintf
(
stderr
,
"
%s: Got called.
\n
"
,
__func__
);
#endif
#ifdef NXAGENT_TIMESTAMP
{
extern
unsigned
long
startTime
;
fprintf
(
stderr
,
"
nxagentShowSplashWindow: Initializing splash start at [%d] milliseconds.
\n
"
,
fprintf
(
stderr
,
"
%s: Initializing splash start at [%d] milliseconds.
\n
"
,
__func__
,
GetTimeInMillis
()
-
startTime
);
}
#endif
XSetSelectionOwner
(
nxagentDisplay
,
nxagentWMStart
,
None
,
CurrentTime
);
#ifdef NXAGENT_ONSTART
XSetSelectionOwner
(
nxagentDisplay
,
nxagentReadyAtom
,
None
,
CurrentTime
);
#endif
nxagentWMPassed
=
False
;
...
...
@@ -133,7 +146,7 @@ int nxagentShowSplashWindow(Window parentWindow)
getAttributes
.
height
=
nxagentOption
(
RootHeight
);
#ifdef TEST
fprintf
(
stderr
,
"
nxagentShowSplashWindow: Going to create new splash window.
\n
"
);
fprintf
(
stderr
,
"
%s: Going to create new splash window.
\n
"
,
__func__
);
#endif
nxagentSplashWindow
=
...
...
@@ -146,7 +159,7 @@ int nxagentShowSplashWindow(Window parentWindow)
BlackPixel
(
nxagentDisplay
,
0
));
#ifdef TEST
fprintf
(
stderr
,
"
nxagentShowSplashWindow: Created new splash window with id [%ld].
\n
"
,
fprintf
(
stderr
,
"
%s: Created new splash window with id [%ld].
\n
"
,
__func__
,
nxagentSplashWindow
);
#endif
...
...
@@ -162,45 +175,34 @@ int nxagentShowSplashWindow(Window parentWindow)
#ifdef NXAGENT_TIMESTAMP
{
extern
unsigned
long
startTime
;
fprintf
(
stderr
,
"
nxagentShowSplashWindow: Splash ends [%d] milliseconds.
\n
"
,
fprintf
(
stderr
,
"
%s: Splash ends [%d] milliseconds.
\n
"
,
__func__
,
GetTimeInMillis
()
-
startTime
);
}
#endif
return
True
;
}
void
nxagentPaintLogo
(
Window
win
,
GC
gc
,
int
scale
,
int
width
,
int
height
)
{
XPoint
rect
[
4
];
int
w
,
h
,
c
,
w2
,
h2
;
/*
* Show only X2GO Logo when running as X2Go Agent
*/
if
(
!
nxagentX2go
)
{
nxagentPixmapLogo
=
0L
;
return
;
}
int
depth
=
DefaultDepth
(
nxagentDisplay
,
DefaultScreen
(
nxagentDisplay
));
#ifdef DEBUG
fprintf
(
stderr
,
"
nxagentPaintLogo: Got called.
\n
"
);
fprintf
(
stderr
,
"
%s: Got called.
\n
"
,
__func__
);
#endif
#ifdef NXAGENT_LOGO_DEBUG
fprintf
(
stderr
,
"
nxagentPaintLogo: begin
\n
"
);
fprintf
(
stderr
,
"
nxagentPaintLogo: gen params are: w=%d h=%d d=%d r=%x w=%x b=%x
\n
"
,
width
,
height
,
nxagentLogoDepth
,
nxagentLogoRed
,
nxagentLogoWhite
,
nxagentLogoBlack
);
fprintf
(
stderr
,
"
%s: begin
\n
"
,
__func__
);
fprintf
(
stderr
,
"
%s: gen params are: w=%d h=%d d=%d w=%x b=%x g1=%x g2=%x
\n
"
,
__func__
,
width
,
height
,
depth
,
nxagentLogoWhite
,
nxagentLogoBlack
,
nxagentLogoDarkGray
,
nxagentLogoLightGray
);
#endif
w
=
width
/
scale
;
h
=
height
/
scale
;
int
w
=
width
/
scale
;
int
h
=
height
/
scale
;
w2
=
w
/
2
;
h2
=
h
/
2
;
int
w2
=
w
/
2
;
int
h2
=
h
/
2
;
int
c
;
if
(
height
>
width
)
{
c
=
w
/
30
;
...
...
@@ -210,42 +212,52 @@ void nxagentPaintLogo(Window win, GC gc, int scale, int width, int height)
c
=
w
/
48
;
}
rect
[
0
].
x
=
0
;
rect
[
0
].
y
=
0
;
rect
[
1
].
x
=
0
;
rect
[
1
].
y
=
h
;
rect
[
2
].
x
=
w
;
rect
[
2
].
y
=
h
;
rect
[
3
].
x
=
w
;
rect
[
3
].
y
=
0
;
XSetFunction
(
nxagentDisplay
,
gc
,
GXcopy
);
XSetFillStyle
(
nxagentDisplay
,
gc
,
FillSolid
);
XSetForeground
(
nxagentDisplay
,
gc
,
nxagentLogoBlack
);
XSetBackground
(
nxagentDisplay
,
gc
,
nxagentLogoRed
);
nxagentPixmapLogo
=
XCreatePixmap
(
nxagentDisplay
,
win
,
width
,
height
,
nxagentLogoDepth
);
nxagentPixmapLogo
=
XCreatePixmap
(
nxagentDisplay
,
win
,
width
,
height
,
depth
);
if
(
!
nxagentPixmapLogo
)
{
return
;
}
if
(
blackRoot
)
{
XSetForeground
(
nxagentDisplay
,
gc
,
nxagentLogoBlack
);
XSetBackground
(
nxagentDisplay
,
gc
,
nxagentLogoWhite
);
}
else
{
XSetForeground
(
nxagentDisplay
,
gc
,
nxagentLogoWhite
);
XSetBackground
(
nxagentDisplay
,
gc
,
nxagentLogoBlack
);
}
XPoint
rect
[
4
];
rect
[
0
].
x
=
0
;
rect
[
0
].
y
=
0
;
rect
[
1
].
x
=
0
;
rect
[
1
].
y
=
h
;
rect
[
2
].
x
=
w
;
rect
[
2
].
y
=
h
;
rect
[
3
].
x
=
w
;
rect
[
3
].
y
=
0
;
/* paint background */
XFillPolygon
(
nxagentDisplay
,
nxagentPixmapLogo
,
gc
,
rect
,
4
,
Convex
,
CoordModeOrigin
);
#ifdef NXAGENT_LOGO_DEBUG
fprintf
(
stderr
,
"
filled first poly
\n
"
);
fprintf
(
stderr
,
"
%s: filled first poly
\n
"
,
__func__
);
#endif
XSetForeground
(
nxagentDisplay
,
gc
,
nxagentLogoRed
);
XSetBackground
(
nxagentDisplay
,
gc
,
nxagentLogoWhite
);
/*
* Draw X2GO Logo
*/
if
(
blackRoot
)
XSetForeground
(
nxagentDisplay
,
gc
,
nxagentLogoDarkGray
);
else
XSetForeground
(
nxagentDisplay
,
gc
,
nxagentLogoLightGray
);
/*
*
Begin
'X'.
*
Start
'X'.
*/
XSetForeground
(
nxagentDisplay
,
gc
,
nxagentLogoGray
);
XSetBackground
(
nxagentDisplay
,
gc
,
nxagentLogoWhite
);
rect
[
0
].
x
=
w2
-
7
*
c
;
rect
[
0
].
y
=
h2
-
5
*
c
;
rect
[
1
].
x
=
w2
-
8
*
c
;
rect
[
1
].
y
=
h2
-
5
*
c
;
rect
[
2
].
x
=
w2
-
4
*
c
;
rect
[
2
].
y
=
h2
+
3
*
c
;
...
...
@@ -379,22 +391,28 @@ void nxagentPaintLogo(Window win, GC gc, int scale, int width, int height)
XSetWindowBackgroundPixmap
(
nxagentDisplay
,
win
,
nxagentPixmapLogo
);
#ifdef NXAGENT_LOGO_DEBUG
fprintf
(
stderr
,
"
nxagentPaintLogo: end
\n
"
);
fprintf
(
stderr
,
"
%s: end
\n
"
,
__func__
);
#endif
}
void
nxagentRemoveSplashWindow
(
WindowPtr
pWin
)
void
nxagentRemoveSplashWindow
(
void
)
{
if
(
nxagentReconnectTrap
)
return
;
if
(
nxagentWMPassed
)
return
;
if
(
nxagentReconnectTrap
)
return
;
#ifdef TEST
fprintf
(
stderr
,
"
nxagentRemoveSplashWindow: Destroying the splash window.
\n
"
);
fprintf
(
stderr
,
"
%s: Destroying the splash window.
\n
"
,
__func__
);
#endif
if
(
!
nxagentWMPassed
)
{
XSetSelectionOwner
(
nxagentDisplay
,
nxagentWMStart
,
#ifdef NXAGENT_ONSTART
XSetSelectionOwner
(
nxagentDisplay
,
nxagentReadyAtom
,
nxagentDefaultWindows
[
0
],
CurrentTime
);
#endif
nxagentWMPassed
=
True
;
}
...
...
@@ -407,7 +425,7 @@ void nxagentRemoveSplashWindow(WindowPtr pWin)
nxagentRefreshWindows
(
screenInfo
.
screens
[
0
]
->
root
);
#ifdef TEST
fprintf
(
stderr
,
"
nxagentRemoveSplashWindow: setting the ownership of %s (%d) on window 0x%lx
\n
"
,
fprintf
(
stderr
,
"
%s: setting the ownership of %s (%d) on window 0x%lx
\n
"
,
__func__
"NX_CUT_BUFFER_SERVER"
,
(
int
)
serverCutProperty
,
nxagentWindow
(
screenInfo
.
screens
[
0
]
->
root
));
#endif
...
...
@@ -418,7 +436,6 @@ void nxagentRemoveSplashWindow(WindowPtr pWin)
if
(
nxagentPixmapLogo
)
{
XFreePixmap
(
nxagentDisplay
,
nxagentPixmapLogo
);
nxagentPixmapLogo
=
(
Pixmap
)
0
;
}
}
nx-X11/programs/Xserver/hw/nxagent/Splash.h
View file @
8b15d574
...
...
@@ -37,18 +37,9 @@ extern int XdmcpTimeOutRtx;
extern
int
XdmcpStartTime
;
extern
int
nxagentXdmcpUp
;
extern
int
nxagentLogoDepth
;
extern
int
nxagentLogoWhite
;
extern
int
nxagentLogoRed
;
extern
int
nxagentLogoBlack
;
extern
int
nxagentLogoGray
;
extern
Window
nxagentSplashWindow
;
extern
int
nxagentWMPassed
;
extern
int
nxagentShowSplashWindow
(
Window
);
extern
void
nxagentRemoveSplashWindow
(
WindowPtr
pWin
);
extern
void
nxagentShowSplashWindow
(
Window
);
extern
void
nxagentRemoveSplashWindow
();
#endif
/* __Splash_H__ */
nx-X11/programs/Xserver/hw/nxagent/Window.c
View file @
8b15d574
...
...
@@ -118,12 +118,6 @@ extern WindowPtr nxagentRootTileWindow;
extern
Bool
nxagentReportPrivateWindowIds
;
/*
* Also referenced in Events.c.
*/
int
nxagentSplashCount
=
0
;
#define RECTLIMIT 25
#define BSPIXMAPLIMIT 128
...
...
@@ -156,12 +150,6 @@ int GetWindowProperty(WindowPtr, Atom, long, long, Bool, Atom, Atom*, int*,
unsigned
long
*
,
unsigned
long
*
,
unsigned
char
**
);
/*
* From NXwindow.c.
*/
void
nxagentClearSplash
(
WindowPtr
pWin
);
/*
* Other local functions.
*/
...
...
@@ -268,16 +256,6 @@ Bool nxagentCreateWindow(WindowPtr pWin)
return
True
;
}
nxagentSplashCount
++
;
if
(
nxagentSplashCount
==
2
)
{
nxagentClearSplash
(
nxagentRootTileWindow
);
}
#ifdef NXAGENT_LOGO_DEBUG
fprintf
(
stderr
,
"nxagentCreateWindow: nxagentSplashCount [%d]
\n
"
,
nxagentSplashCount
);
#endif
if
(
pWin
->
drawable
.
class
==
InputOnly
)
{
mask
=
CWEventMask
;
...
...
@@ -487,14 +465,6 @@ Bool nxagentCreateWindow(WindowPtr pWin)
nxagentWindowPriv
(
pWin
)
->
siblingAbove
=
None
;
nxagentWindowPriv
(
pWin
)
->
pPicture
=
NULL
;
if
(
nxagentRootTileWindow
)
{
if
(
nxagentWindowPriv
(
pWin
)
->
window
!=
nxagentWindowPriv
(
nxagentRootTileWindow
)
->
window
)
{
XClearWindow
(
nxagentDisplay
,
nxagentWindowPriv
(
nxagentRootTileWindow
)
->
window
);
}
}
if
(
pWin
->
nextSib
)
{
nxagentWindowPriv
(
pWin
->
nextSib
)
->
siblingAbove
=
nxagentWindow
(
pWin
);
...
...
@@ -662,24 +632,6 @@ Bool nxagentDestroyWindow(WindowPtr pWin)
nxagentRootlessDelTopLevelWindow
(
pWin
);
}
nxagentSplashCount
--
;
#ifdef DEBUG
fprintf
(
stderr
,
"nxagentDestroyWindow: The splash counter is now [%d].
\n
"
,
nxagentSplashCount
);
#endif
if
(
nxagentSplashCount
==
1
)
{
XClearWindow
(
nxagentDisplay
,
nxagentWindowPriv
(
nxagentRootTileWindow
)
->
window
);
}
if
(
pWin
==
nxagentRootTileWindow
)
{
nxagentWindowPriv
(
nxagentRootTileWindow
)
->
window
=
None
;
nxagentRootTileWindow
=
None
;
}
pWindowPriv
->
window
=
None
;
if
(
pWin
->
optional
)
...
...
@@ -1486,7 +1438,6 @@ void nxagentConfigureWindow(WindowPtr pWin, unsigned int mask)
#endif
}
#ifdef NXAGENT_SPLASH
/*
* This should bring again the splash window
* on top, so why the else clause? Is this
...
...
@@ -1512,7 +1463,6 @@ void nxagentConfigureWindow(WindowPtr pWin, unsigned int mask)
* }
* }
*/
#endif
/* NXAGENT_SPLASH */
if
(
mask
&
CW_RootlessRestack
)
{
...
...
nx-X11/programs/Xserver/hw/nxagent/man/nxagent.1
View file @
8b15d574
...
...
@@ -142,8 +142,10 @@ to authenticate access. See also the \fIxdm\fP(1) and
disables backing store support on all screens.
.TP 8
.B \-br
sets the default root window to solid black instead of the standard root weave
pattern.
sets the default root window to solid black (default).
.TP 8
.B \-wr
sets the default root window to solid white.
.TP 8
.B \-c
turns off key-click.
...
...
nx-X11/programs/Xserver/os/utils.c
View file @
8b15d574
...
...
@@ -634,6 +634,7 @@ void UseMsg(void)
ErrorF
(
"v video blanking for screen-saver
\n
"
);
ErrorF
(
"-v screen-saver without video blanking
\n
"
);
ErrorF
(
"-wm WhenMapped default backing-store
\n
"
);
ErrorF
(
"-wr create root window with white background
\n
"
);
ErrorF
(
"-maxbigreqsize set maximal bigrequest size
\n
"
);
#ifdef PANORAMIX
ErrorF
(
"+xinerama Enable XINERAMA (PanoramiX) extension
\n
"
);
...
...
@@ -996,6 +997,8 @@ ProcessCommandLine(int argc, char *argv[])
defaultScreenSaverBlanking
=
DontPreferBlanking
;
else
if
(
strcmp
(
argv
[
i
],
"-wm"
)
==
0
)
defaultBackingStore
=
WhenMapped
;
else
if
(
strcmp
(
argv
[
i
],
"-wr"
)
==
0
)
whiteRoot
=
TRUE
;
else
if
(
strcmp
(
argv
[
i
],
"-maxbigreqsize"
)
==
0
)
{
if
(
++
i
<
argc
)
{
long
reqSizeArg
=
atol
(
argv
[
i
]);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment