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
7392dd6a
Unverified
Commit
7392dd6a
authored
Oct 22, 2018
by
Mike Gabriel
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'uli42-pr/cleanup_wmisrunning' into 3.6.x
Attributes GH PR #728:
https://github.com/ArcticaProject/nx-libs/pull/728
parents
c478ba29
450760bc
Hide whitespace changes
Inline
Side-by-side
Showing
9 changed files
with
45 additions
and
52 deletions
+45
-52
Atoms.c
nx-X11/programs/Xserver/hw/nxagent/Atoms.c
+3
-3
Display.c
nx-X11/programs/Xserver/hw/nxagent/Display.c
+7
-9
Events.c
nx-X11/programs/Xserver/hw/nxagent/Events.c
+9
-10
NXdispatch.c
nx-X11/programs/Xserver/hw/nxagent/NXdispatch.c
+1
-1
Pixmap.c
nx-X11/programs/Xserver/hw/nxagent/Pixmap.c
+8
-8
Reconnect.c
nx-X11/programs/Xserver/hw/nxagent/Reconnect.c
+1
-1
Render.c
nx-X11/programs/Xserver/hw/nxagent/Render.c
+6
-6
Screen.c
nx-X11/programs/Xserver/hw/nxagent/Screen.c
+2
-2
Window.c
nx-X11/programs/Xserver/hw/nxagent/Window.c
+8
-12
No files found.
nx-X11/programs/Xserver/hw/nxagent/Atoms.c
View file @
7392dd6a
...
@@ -106,7 +106,7 @@ static void catchAndRedirect(Display* dpy, XErrorEvent* X)
...
@@ -106,7 +106,7 @@ static void catchAndRedirect(Display* dpy, XErrorEvent* X)
X
->
request_code
==
X_ChangeWindowAttributes
&&
X
->
request_code
==
X_ChangeWindowAttributes
&&
X
->
resourceid
==
DefaultRootWindow
(
dpy
))
X
->
resourceid
==
DefaultRootWindow
(
dpy
))
{
{
nxagentWMIsRunning
=
T
RUE
;
nxagentWMIsRunning
=
T
rue
;
}
}
else
else
{
{
...
@@ -122,7 +122,7 @@ static void startWMDetection(void)
...
@@ -122,7 +122,7 @@ static void startWMDetection(void)
* window.
* window.
*/
*/
nxagentWMIsRunning
=
F
ALSE
;
nxagentWMIsRunning
=
F
alse
;
previousErrorHandler
=
XSetErrorHandler
((
XErrorHandler
)
&
catchAndRedirect
);
previousErrorHandler
=
XSetErrorHandler
((
XErrorHandler
)
&
catchAndRedirect
);
...
@@ -166,7 +166,7 @@ static void finishWMDetection(Bool verbose)
...
@@ -166,7 +166,7 @@ static void finishWMDetection(Bool verbose)
void
nxagentWMDetect
()
void
nxagentWMDetect
()
{
{
Bool
verbose
=
False
;
Bool
verbose
=
False
;
int
windowManagerWasRunning
=
nxagentWMIsRunning
;
Bool
windowManagerWasRunning
=
nxagentWMIsRunning
;
startWMDetection
();
startWMDetection
();
...
...
nx-X11/programs/Xserver/hw/nxagent/Display.c
View file @
7392dd6a
...
@@ -2492,12 +2492,10 @@ static int nxagentInitAndCheckVisuals(int flexibility)
...
@@ -2492,12 +2492,10 @@ static int nxagentInitAndCheckVisuals(int flexibility)
long
viMask
;
long
viMask
;
int
i
,
n
;
int
i
,
n
;
int
matched
;
bool
matched
;
int
compatibl
e
;
bool
compatible
=
tru
e
;
int
viNumList
;
int
viNumList
;
compatible
=
1
;
viMask
=
VisualScreenMask
;
viMask
=
VisualScreenMask
;
viTemplate
.
screen
=
DefaultScreen
(
nxagentDisplay
);
viTemplate
.
screen
=
DefaultScreen
(
nxagentDisplay
);
viTemplate
.
depth
=
DefaultDepth
(
nxagentDisplay
,
DefaultScreen
(
nxagentDisplay
));
viTemplate
.
depth
=
DefaultDepth
(
nxagentDisplay
,
DefaultScreen
(
nxagentDisplay
));
...
@@ -2507,7 +2505,7 @@ static int nxagentInitAndCheckVisuals(int flexibility)
...
@@ -2507,7 +2505,7 @@ static int nxagentInitAndCheckVisuals(int flexibility)
for
(
i
=
0
;
i
<
nxagentNumVisuals
;
i
++
)
for
(
i
=
0
;
i
<
nxagentNumVisuals
;
i
++
)
{
{
matched
=
0
;
matched
=
false
;
for
(
n
=
0
;
n
<
viNumList
;
n
++
)
for
(
n
=
0
;
n
<
viNumList
;
n
++
)
{
{
...
@@ -2528,7 +2526,7 @@ FIXME: Should the visual be ignored in this case?
...
@@ -2528,7 +2526,7 @@ FIXME: Should the visual be ignored in this case?
#endif
#endif
}
}
matched
=
1
;
matched
=
true
;
nxagentVisualHasBeenIgnored
[
i
]
=
FALSE
;
nxagentVisualHasBeenIgnored
[
i
]
=
FALSE
;
...
@@ -2538,7 +2536,7 @@ FIXME: Should the visual be ignored in this case?
...
@@ -2538,7 +2536,7 @@ FIXME: Should the visual be ignored in this case?
}
}
}
}
if
(
matched
==
0
)
if
(
!
matched
)
{
{
if
(
nxagentVisuals
[
i
].
class
==
DirectColor
)
if
(
nxagentVisuals
[
i
].
class
==
DirectColor
)
{
{
...
@@ -2564,7 +2562,7 @@ FIXME: Should the visual be ignored in this case?
...
@@ -2564,7 +2562,7 @@ FIXME: Should the visual be ignored in this case?
fprintf
(
stderr
,
"
\t
bits_per_rgb = %d
\n
"
,
nxagentVisuals
[
i
].
bits_per_rgb
);
fprintf
(
stderr
,
"
\t
bits_per_rgb = %d
\n
"
,
nxagentVisuals
[
i
].
bits_per_rgb
);
#endif
#endif
compatible
=
0
;
compatible
=
false
;
break
;
break
;
}
}
...
@@ -2573,7 +2571,7 @@ FIXME: Should the visual be ignored in this case?
...
@@ -2573,7 +2571,7 @@ FIXME: Should the visual be ignored in this case?
XFree
(
viList
);
XFree
(
viList
);
if
(
compatible
==
1
)
if
(
compatible
)
{
{
#ifdef TEST
#ifdef TEST
fprintf
(
stderr
,
"nxagentInitAndCheckVisuals: New visuals match with old visuals.
\n
"
);
fprintf
(
stderr
,
"nxagentInitAndCheckVisuals: New visuals match with old visuals.
\n
"
);
...
...
nx-X11/programs/Xserver/hw/nxagent/Events.c
View file @
7392dd6a
...
@@ -373,7 +373,7 @@ void nxagentRemoteWindowID(Window window, Bool newline)
...
@@ -373,7 +373,7 @@ void nxagentRemoteWindowID(Window window, Bool newline)
}
}
}
}
if
(
newline
==
TRUE
)
if
(
newline
)
{
{
fprintf
(
stderr
,
"
\n
"
);
fprintf
(
stderr
,
"
\n
"
);
}
}
...
@@ -411,7 +411,7 @@ void nxagentRemoteWindowInfo(Window win, int indent, Bool newLine)
...
@@ -411,7 +411,7 @@ void nxagentRemoteWindowInfo(Window win, int indent, Bool newLine)
(
attributes
.
override_redirect
==
0
)
?
(
attributes
.
override_redirect
==
0
)
?
"No"
:
"Yes"
);
"No"
:
"Yes"
);
if
(
newLine
==
TRUE
)
if
(
newLine
)
{
{
fprintf
(
stderr
,
"
\n
"
);
fprintf
(
stderr
,
"
\n
"
);
}
}
...
@@ -537,7 +537,7 @@ void nxagentInternalWindowInfo(WindowPtr pWin, int indent, Bool newLine)
...
@@ -537,7 +537,7 @@ void nxagentInternalWindowInfo(WindowPtr pWin, int indent, Bool newLine)
(
pWin
->
overrideRedirect
==
0
)
?
(
pWin
->
overrideRedirect
==
0
)
?
"No"
:
"Yes"
);
"No"
:
"Yes"
);
if
(
newLine
==
TRUE
)
if
(
newLine
)
{
{
fprintf
(
stderr
,
"
\n
"
);
fprintf
(
stderr
,
"
\n
"
);
}
}
...
@@ -2046,7 +2046,7 @@ FIXME: Don't enqueue the KeyRelease event if the key was
...
@@ -2046,7 +2046,7 @@ FIXME: Don't enqueue the KeyRelease event if the key was
* event that would trigger xinerama updates. So we do that once
* event that would trigger xinerama updates. So we do that once
* the nxagent window gets mapped.
* the nxagent window gets mapped.
*/
*/
if
(
nxagentWMIsRunning
==
0
&&
if
(
!
nxagentWMIsRunning
&&
X
.
xmap
.
window
==
nxagentDefaultWindows
[
nxagentScreen
(
X
.
xmap
.
window
)
->
myNum
])
X
.
xmap
.
window
==
nxagentDefaultWindows
[
nxagentScreen
(
X
.
xmap
.
window
)
->
myNum
])
{
{
nxagentChangeScreenConfig
(
nxagentScreen
(
X
.
xmap
.
window
)
->
myNum
,
nxagentOption
(
Width
),
nxagentChangeScreenConfig
(
nxagentScreen
(
X
.
xmap
.
window
)
->
myNum
,
nxagentOption
(
Width
),
...
@@ -2767,7 +2767,7 @@ int nxagentHandleClientMessageEvent(XEvent *X, enum HandleEventResult *result)
...
@@ -2767,7 +2767,7 @@ int nxagentHandleClientMessageEvent(XEvent *X, enum HandleEventResult *result)
if
(
X
->
xclient
.
window
==
(
nxagentOption
(
Fullscreen
)
?
if
(
X
->
xclient
.
window
==
(
nxagentOption
(
Fullscreen
)
?
nxagentIconWindow
:
nxagentDefaultWindows
[
0
])
||
nxagentIconWindow
:
nxagentDefaultWindows
[
0
])
||
nxagentWMIsRunning
==
0
)
!
nxagentWMIsRunning
)
{
{
*
result
=
doCloseSession
;
*
result
=
doCloseSession
;
}
}
...
@@ -3353,7 +3353,7 @@ int nxagentHandleConfigureNotify(XEvent* X)
...
@@ -3353,7 +3353,7 @@ int nxagentHandleConfigureNotify(XEvent* X)
* by the window manager are relevant, see ICCCM Chapter 4,
* by the window manager are relevant, see ICCCM Chapter 4,
* "Configuring the Window"
* "Configuring the Window"
*/
*/
Bool
updatePos
=
(
nxagentWMIsRunning
==
0
||
X
->
xconfigure
.
send_event
!=
0
);
Bool
updatePos
=
(
!
nxagentWMIsRunning
||
X
->
xconfigure
.
send_event
!=
0
);
int
newX
=
X
->
xconfigure
.
x
;
int
newX
=
X
->
xconfigure
.
x
;
int
newY
=
X
->
xconfigure
.
y
;
int
newY
=
X
->
xconfigure
.
y
;
...
@@ -3395,7 +3395,7 @@ int nxagentHandleConfigureNotify(XEvent* X)
...
@@ -3395,7 +3395,7 @@ int nxagentHandleConfigureNotify(XEvent* X)
count
++
;
count
++
;
#endif
#endif
if
(
nxagentWMIsRunning
==
0
||
X
->
xconfigure
.
send_event
)
if
(
!
nxagentWMIsRunning
||
X
->
xconfigure
.
send_event
)
{
{
updatePos
=
True
;
updatePos
=
True
;
newX
=
X
->
xconfigure
.
x
;
newX
=
X
->
xconfigure
.
x
;
...
@@ -3626,7 +3626,7 @@ int nxagentHandleReparentNotify(XEvent* X)
...
@@ -3626,7 +3626,7 @@ int nxagentHandleReparentNotify(XEvent* X)
return
1
;
return
1
;
}
}
else
if
(
nxagentWMIsRunning
==
1
&&
nxagentOption
(
Fullscreen
)
==
0
&&
else
if
(
nxagentWMIsRunning
&&
nxagentOption
(
Fullscreen
)
==
0
&&
nxagentOption
(
WMBorderWidth
)
==
-
1
)
nxagentOption
(
WMBorderWidth
)
==
-
1
)
{
{
XlibWindow
w
;
XlibWindow
w
;
...
@@ -4061,8 +4061,7 @@ void nxagentHandleCollectPropertyEvent(XEvent *X)
...
@@ -4061,8 +4061,7 @@ void nxagentHandleCollectPropertyEvent(XEvent *X)
nxagentImportProperty
(
window
,
property
,
atomReturnType
,
resultFormat
,
nxagentImportProperty
(
window
,
property
,
atomReturnType
,
resultFormat
,
ulReturnItems
,
ulReturnBytesLeft
,
pszReturnData
);
ulReturnItems
,
ulReturnBytesLeft
,
pszReturnData
);
}
}
else
if
(
result
==
0
)
{
{
#ifdef DEBUG
#ifdef DEBUG
fprintf
(
stderr
,
"nxagentHandleCollectPropertyEvent: Failed to get reply data for client [%d].
\n
"
,
fprintf
(
stderr
,
"nxagentHandleCollectPropertyEvent: Failed to get reply data for client [%d].
\n
"
,
...
...
nx-X11/programs/Xserver/hw/nxagent/NXdispatch.c
View file @
7392dd6a
...
@@ -142,7 +142,7 @@ void nxagentWaitDisplay(void);
...
@@ -142,7 +142,7 @@ void nxagentWaitDisplay(void);
void
nxagentListRemoteFonts
(
const
char
*
,
int
);
void
nxagentListRemoteFonts
(
const
char
*
,
int
);
unsigned
int
nxagentWMtimeout
=
0
;
unsigned
int
nxagentWMtimeout
=
0
;
Bool
nxagentWMPassed
=
0
;
Bool
nxagentWMPassed
=
False
;
/*
/*
* Timeouts based on screen saver time.
* Timeouts based on screen saver time.
...
...
nx-X11/programs/Xserver/hw/nxagent/Pixmap.c
View file @
7392dd6a
...
@@ -860,10 +860,10 @@ void nxagentReconnectPixmap(void *p0, XID x1, void *p2)
...
@@ -860,10 +860,10 @@ void nxagentReconnectPixmap(void *p0, XID x1, void *p2)
Bool
*
pBool
=
(
Bool
*
)
p2
;
Bool
*
pBool
=
(
Bool
*
)
p2
;
nxagentPrivPixmapPtr
pPixmapPriv
;
nxagentPrivPixmapPtr
pPixmapPriv
;
if
(
*
pBool
==
0
||
pPixmap
==
NULL
||
if
(
!*
pBool
||
pPixmap
==
NULL
||
NXDisplayError
(
nxagentDisplay
)
==
1
)
NXDisplayError
(
nxagentDisplay
)
==
1
)
{
{
*
pBool
=
0
;
*
pBool
=
False
;
#ifdef TEST
#ifdef TEST
fprintf
(
stderr
,
"nxagentReconnectPixmap: Ignoring pixmap at [%p] while "
fprintf
(
stderr
,
"nxagentReconnectPixmap: Ignoring pixmap at [%p] while "
...
@@ -929,7 +929,7 @@ void nxagentReconnectPixmap(void *p0, XID x1, void *p2)
...
@@ -929,7 +929,7 @@ void nxagentReconnectPixmap(void *p0, XID x1, void *p2)
nxagentSplitTrap
=
0
;
nxagentSplitTrap
=
0
;
if
(
*
pBool
==
0
)
if
(
!*
pBool
)
{
{
#ifdef PANIC
#ifdef PANIC
fprintf
(
stderr
,
"nxagentReconnectPixmap: PANIC! Failed to synchronize the pixmap.
\n
"
);
fprintf
(
stderr
,
"nxagentReconnectPixmap: PANIC! Failed to synchronize the pixmap.
\n
"
);
...
@@ -1035,7 +1035,7 @@ static void nxagentCheckOnePixmapIntegrity(void *p0, XID x1, void *p2)
...
@@ -1035,7 +1035,7 @@ static void nxagentCheckOnePixmapIntegrity(void *p0, XID x1, void *p2)
PixmapPtr
pPixmap
=
(
PixmapPtr
)
p0
;
PixmapPtr
pPixmap
=
(
PixmapPtr
)
p0
;
Bool
*
pBool
=
(
Bool
*
)
p2
;
Bool
*
pBool
=
(
Bool
*
)
p2
;
if
(
*
pBool
==
False
)
if
(
!*
pBool
)
{
{
return
;
return
;
}
}
...
@@ -1065,7 +1065,7 @@ static void nxagentCheckOnePixmapIntegrity(void *p0, XID x1, void *p2)
...
@@ -1065,7 +1065,7 @@ static void nxagentCheckOnePixmapIntegrity(void *p0, XID x1, void *p2)
Bool
nxagentCheckPixmapIntegrity
(
PixmapPtr
pPixmap
)
Bool
nxagentCheckPixmapIntegrity
(
PixmapPtr
pPixmap
)
{
{
Bool
integrity
=
1
;
Bool
integrity
=
True
;
XImage
*
image
;
XImage
*
image
;
char
*
data
;
char
*
data
;
int
format
;
int
format
;
...
@@ -1121,11 +1121,11 @@ Bool nxagentCheckPixmapIntegrity(PixmapPtr pPixmap)
...
@@ -1121,11 +1121,11 @@ Bool nxagentCheckPixmapIntegrity(PixmapPtr pPixmap)
if
(
image
!=
NULL
&&
memcmp
(
image
->
data
,
data
,
length
)
!=
0
)
if
(
image
!=
NULL
&&
memcmp
(
image
->
data
,
data
,
length
)
!=
0
)
{
{
integrity
=
0
;
integrity
=
False
;
}
}
else
else
{
{
integrity
=
1
;
integrity
=
True
;
#ifdef TEST
#ifdef TEST
fprintf
(
stderr
,
"nxagentCheckPixmapIntegrity: Pixmap at [%p] has been realized. "
fprintf
(
stderr
,
"nxagentCheckPixmapIntegrity: Pixmap at [%p] has been realized. "
...
@@ -1135,7 +1135,7 @@ Bool nxagentCheckPixmapIntegrity(PixmapPtr pPixmap)
...
@@ -1135,7 +1135,7 @@ Bool nxagentCheckPixmapIntegrity(PixmapPtr pPixmap)
#ifdef WARNING
#ifdef WARNING
if
(
integrity
==
0
)
if
(
!
integrity
)
{
{
int
i
;
int
i
;
...
...
nx-X11/programs/Xserver/hw/nxagent/Reconnect.c
View file @
7392dd6a
...
@@ -402,7 +402,7 @@ void nxagentDisconnectSession(void)
...
@@ -402,7 +402,7 @@ void nxagentDisconnectSession(void)
nxagentDisconnectAllGCs
();
nxagentDisconnectAllGCs
();
nxagentDisconnectDisplay
();
nxagentDisconnectDisplay
();
nxagentWMIsRunning
=
0
;
nxagentWMIsRunning
=
False
;
#ifdef TEST
#ifdef TEST
fprintf
(
stderr
,
"nxagentDisconnectSession: Disconnection completed. SigHup is [%d]. IoError is [%d].
\n
"
,
fprintf
(
stderr
,
"nxagentDisconnectSession: Disconnection completed. SigHup is [%d]. IoError is [%d].
\n
"
,
...
...
nx-X11/programs/Xserver/hw/nxagent/Render.c
View file @
7392dd6a
...
@@ -2784,7 +2784,7 @@ void nxagentReconnectGlyphSet(void* p0, XID x1, void *p2)
...
@@ -2784,7 +2784,7 @@ void nxagentReconnectGlyphSet(void* p0, XID x1, void *p2)
Bool
nxagentReconnectAllGlyphSet
(
void
*
p
)
Bool
nxagentReconnectAllGlyphSet
(
void
*
p
)
{
{
Bool
success
=
T
RUE
;
Bool
success
=
T
rue
;
int
i
;
int
i
;
nxagentQueryFormats
();
nxagentQueryFormats
();
...
@@ -2826,7 +2826,7 @@ void nxagentReconnectPicture(void * p0, XID x1, void *p2)
...
@@ -2826,7 +2826,7 @@ void nxagentReconnectPicture(void * p0, XID x1, void *p2)
* and that the involved objects are valid.
* and that the involved objects are valid.
*/
*/
if
(
*
pBool
==
0
||
pPicture
==
NULL
||
if
(
!*
pBool
||
pPicture
==
NULL
||
nxagentPicture
(
pPicture
)
!=
0
)
nxagentPicture
(
pPicture
)
!=
0
)
{
{
return
;
return
;
...
@@ -2959,7 +2959,7 @@ Bool nxagentReconnectAllPicture(void *p)
...
@@ -2959,7 +2959,7 @@ Bool nxagentReconnectAllPicture(void *p)
fprintf
(
stderr
,
"nxagentReconnectAllPicture: Going to recreate all pictures.
\n
"
);
fprintf
(
stderr
,
"nxagentReconnectAllPicture: Going to recreate all pictures.
\n
"
);
#endif
#endif
for
(
i
=
0
,
r
=
1
;
i
<
MAXCLIENTS
;
i
++
)
for
(
i
=
0
,
r
=
True
;
i
<
MAXCLIENTS
;
i
++
)
{
{
if
(
clients
[
i
])
if
(
clients
[
i
])
{
{
...
@@ -2967,7 +2967,7 @@ Bool nxagentReconnectAllPicture(void *p)
...
@@ -2967,7 +2967,7 @@ Bool nxagentReconnectAllPicture(void *p)
#ifdef WARNING
#ifdef WARNING
if
(
r
==
False
)
if
(
!
r
)
{
{
fprintf
(
stderr
,
"nxagentReconnectAllPicture: WARNING! Failed to recreate "
fprintf
(
stderr
,
"nxagentReconnectAllPicture: WARNING! Failed to recreate "
"picture for client [%d].
\n
"
,
i
);
"picture for client [%d].
\n
"
,
i
);
...
@@ -3015,7 +3015,7 @@ Bool nxagentDisconnectAllPicture(void)
...
@@ -3015,7 +3015,7 @@ Bool nxagentDisconnectAllPicture(void)
fprintf
(
stderr
,
"nxagentDisconnectAllPicture.
\n
"
);
fprintf
(
stderr
,
"nxagentDisconnectAllPicture.
\n
"
);
#endif
#endif
for
(
i
=
0
,
r
=
1
;
i
<
MAXCLIENTS
;
i
++
)
for
(
i
=
0
,
r
=
True
;
i
<
MAXCLIENTS
;
i
++
)
{
{
if
(
clients
[
i
])
if
(
clients
[
i
])
{
{
...
@@ -3023,7 +3023,7 @@ Bool nxagentDisconnectAllPicture(void)
...
@@ -3023,7 +3023,7 @@ Bool nxagentDisconnectAllPicture(void)
#ifdef WARNING
#ifdef WARNING
if
(
r
==
False
)
if
(
!
r
)
{
{
fprintf
(
stderr
,
"nxagentDisconnectAllPicture: WARNING! Failed to disconnect "
fprintf
(
stderr
,
"nxagentDisconnectAllPicture: WARNING! Failed to disconnect "
"picture for client [%d].
\n
"
,
i
);
"picture for client [%d].
\n
"
,
i
);
...
...
nx-X11/programs/Xserver/hw/nxagent/Screen.c
View file @
7392dd6a
...
@@ -977,7 +977,7 @@ Bool nxagentOpenScreen(ScreenPtr pScreen,
...
@@ -977,7 +977,7 @@ Bool nxagentOpenScreen(ScreenPtr pScreen,
* fullscreen mode.
* fullscreen mode.
*/
*/
if
(
nxagentOption
(
Rootless
)
==
False
&&
nxagentWMIsRunning
==
False
)
if
(
nxagentOption
(
Rootless
)
==
False
&&
!
nxagentWMIsRunning
)
{
{
#ifdef TEST
#ifdef TEST
fprintf
(
stderr
,
"nxagentOpenScreen: Forcing fullscreen mode with no window manager running.
\n
"
);
fprintf
(
stderr
,
"nxagentOpenScreen: Forcing fullscreen mode with no window manager running.
\n
"
);
...
@@ -3057,7 +3057,7 @@ int nxagentShadowPoll(PixmapPtr nxagentShadowPixmapPtr, GCPtr nxagentShadowGCPtr
...
@@ -3057,7 +3057,7 @@ int nxagentShadowPoll(PixmapPtr nxagentShadowPixmapPtr, GCPtr nxagentShadowGCPtr
if
(
result
==
1
)
if
(
result
==
1
)
{
{
if
(
nxagentWMPassed
==
0
)
if
(
!
nxagentWMPassed
)
{
{
nxagentRemoveSplashWindow
(
NULL
);
nxagentRemoveSplashWindow
(
NULL
);
}
}
...
...
nx-X11/programs/Xserver/hw/nxagent/Window.c
View file @
7392dd6a
...
@@ -310,7 +310,7 @@ Bool nxagentCreateWindow(pWin)
...
@@ -310,7 +310,7 @@ Bool nxagentCreateWindow(pWin)
/*
/*
FIXME: We need to set save under on the real display?
FIXME: We need to set save under on the real display?
*/
*/
if
(
nxagentSaveUnder
==
True
)
if
(
nxagentSaveUnder
)
{
{
mask
|=
CWSaveUnder
;
mask
|=
CWSaveUnder
;
attributes
.
save_under
=
False
;
attributes
.
save_under
=
False
;
...
@@ -749,7 +749,7 @@ void nxagentSwitchFullscreen(ScreenPtr pScreen, Bool switchOn)
...
@@ -749,7 +749,7 @@ void nxagentSwitchFullscreen(ScreenPtr pScreen, Bool switchOn)
return
;
return
;
}
}
if
(
switchOn
==
0
)
if
(
!
switchOn
)
{
{
nxagentWMDetect
();
nxagentWMDetect
();
...
@@ -762,7 +762,7 @@ void nxagentSwitchFullscreen(ScreenPtr pScreen, Bool switchOn)
...
@@ -762,7 +762,7 @@ void nxagentSwitchFullscreen(ScreenPtr pScreen, Bool switchOn)
isItTimeToYield
=
1
;
isItTimeToYield
=
1
;
if
(
nxagentWMIsRunning
==
0
)
if
(
!
nxagentWMIsRunning
)
{
{
#ifdef WARNING
#ifdef WARNING
fprintf
(
stderr
,
"Warning: Can't switch to window mode, no window manager "
fprintf
(
stderr
,
"Warning: Can't switch to window mode, no window manager "
...
@@ -793,7 +793,7 @@ void nxagentSwitchFullscreen(ScreenPtr pScreen, Bool switchOn)
...
@@ -793,7 +793,7 @@ void nxagentSwitchFullscreen(ScreenPtr pScreen, Bool switchOn)
XSendEvent
(
nxagentDisplay
,
DefaultRootWindow
(
nxagentDisplay
),
False
,
XSendEvent
(
nxagentDisplay
,
DefaultRootWindow
(
nxagentDisplay
),
False
,
SubstructureRedirectMask
,
&
e
);
SubstructureRedirectMask
,
&
e
);
if
(
switchOn
==
1
)
if
(
switchOn
)
{
{
nxagentFullscreenWindow
=
nxagentDefaultWindows
[
pScreen
->
myNum
];
nxagentFullscreenWindow
=
nxagentDefaultWindows
[
pScreen
->
myNum
];
...
@@ -2552,7 +2552,7 @@ void nxagentMapDefaultWindows(void)
...
@@ -2552,7 +2552,7 @@ void nxagentMapDefaultWindows(void)
* Windows client.
* Windows client.
*/
*/
if
(
nxagentOption
(
Shadow
)
==
0
||
nxagentWMIsRunning
==
0
)
if
(
nxagentOption
(
Shadow
)
==
0
||
!
nxagentWMIsRunning
)
{
{
#ifdef TEST
#ifdef TEST
fprintf
(
stderr
,
"nxagentMapDefaultWindows: Mapping default window id [%ld].
\n
"
,
fprintf
(
stderr
,
"nxagentMapDefaultWindows: Mapping default window id [%ld].
\n
"
,
...
@@ -2561,7 +2561,7 @@ void nxagentMapDefaultWindows(void)
...
@@ -2561,7 +2561,7 @@ void nxagentMapDefaultWindows(void)
XMapWindow
(
nxagentDisplay
,
nxagentDefaultWindows
[
pScreen
->
myNum
]);
XMapWindow
(
nxagentDisplay
,
nxagentDefaultWindows
[
pScreen
->
myNum
]);
if
(
nxagentOption
(
Fullscreen
)
==
1
&&
nxagentWMIsRunning
==
1
)
if
(
nxagentOption
(
Fullscreen
)
==
1
&&
nxagentWMIsRunning
)
{
{
nxagentMaximizeToFullScreen
(
pScreen
);
nxagentMaximizeToFullScreen
(
pScreen
);
}
}
...
@@ -2683,7 +2683,7 @@ void nxagentDisconnectWindow(void * p0, XID x1, void * p2)
...
@@ -2683,7 +2683,7 @@ void nxagentDisconnectWindow(void * p0, XID x1, void * p2)
nxagentDisconnectCursor
(
pCursor
,
(
XID
)
0
,
pBool
);
nxagentDisconnectCursor
(
pCursor
,
(
XID
)
0
,
pBool
);
if
(
*
pBool
==
False
)
if
(
!*
pBool
)
{
{
#ifdef WARNING
#ifdef WARNING
fprintf
(
stderr
,
"nxagentDisconnectWindow: WARNING failed disconnection of cursor at [%p]"
fprintf
(
stderr
,
"nxagentDisconnectWindow: WARNING failed disconnection of cursor at [%p]"
...
@@ -2725,8 +2725,6 @@ Bool nxagentReconnectAllWindows(void *p0)
...
@@ -2725,8 +2725,6 @@ Bool nxagentReconnectAllWindows(void *p0)
{
{
int
flexibility
=
*
(
int
*
)
p0
;
int
flexibility
=
*
(
int
*
)
p0
;
flexibility
=
flexibility
;
#if defined(NXAGENT_RECONNECT_DEBUG) || defined(NXAGENT_RECONNECT_WINDOW_DEBUG)
#if defined(NXAGENT_RECONNECT_DEBUG) || defined(NXAGENT_RECONNECT_WINDOW_DEBUG)
fprintf
(
stderr
,
"nxagentReconnectAllWindows
\n
"
);
fprintf
(
stderr
,
"nxagentReconnectAllWindows
\n
"
);
#endif
#endif
...
@@ -2845,8 +2843,6 @@ Bool nxagentSetWindowCursors(void *p0)
...
@@ -2845,8 +2843,6 @@ Bool nxagentSetWindowCursors(void *p0)
{
{
int
flexibility
=
*
(
int
*
)
p0
;
int
flexibility
=
*
(
int
*
)
p0
;
flexibility
=
flexibility
;
#if defined(NXAGENT_RECONNECT_DEBUG) || defined(NXAGENT_RECONNECT_WINDOW_DEBUG)
#if defined(NXAGENT_RECONNECT_DEBUG) || defined(NXAGENT_RECONNECT_WINDOW_DEBUG)
fprintf
(
stderr
,
"nxagentSetWindowCursors: Going to loop over the windows.
\n
"
);
fprintf
(
stderr
,
"nxagentSetWindowCursors: Going to loop over the windows.
\n
"
);
#endif
#endif
...
@@ -2937,7 +2933,7 @@ static void nxagentReconnectWindow(void * param0, XID param1, void * data_buffer
...
@@ -2937,7 +2933,7 @@ static void nxagentReconnectWindow(void * param0, XID param1, void * data_buffer
/*
/*
FIXME: Do we need to set save unders attribute here?
FIXME: Do we need to set save unders attribute here?
*/
*/
if
(
nxagentSaveUnder
==
True
)
if
(
nxagentSaveUnder
)
{
{
mask
|=
CWSaveUnder
;
mask
|=
CWSaveUnder
;
attributes
.
save_under
=
pWin
->
saveUnder
;
attributes
.
save_under
=
pWin
->
saveUnder
;
...
...
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