Skip to content

Commit 9ee3a20

Browse files
committed
nxagent: move atom initiatialization to Init.c
is not dependent on any root window and need only be called once on startup.
1 parent 047ab33 commit 9ee3a20

File tree

4 files changed

+5
-4
lines changed

4 files changed

+5
-4
lines changed

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

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -176,7 +176,7 @@ void nxagentWMDetect()
176176
finishWMDetection(verbose);
177177
}
178178

179-
int nxagentInitAtoms(WindowPtr pWin)
179+
int nxagentInitAtoms(void)
180180
{
181181
Atom atom;
182182

nx-X11/programs/Xserver/hw/nxagent/Atoms.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ extern Bool nxagentWMIsRunning;
4141
* to the agent server.
4242
*/
4343

44-
int nxagentInitAtoms(WindowPtr pWin);
44+
int nxagentInitAtoms(void);
4545

4646
/*
4747
* Query and create all the required atoms

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

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -71,6 +71,7 @@ is" without express or implied warranty.
7171
#include "Millis.h"
7272
#include "Error.h"
7373
#include "Keystroke.h"
74+
#include "Atoms.h"
7475

7576
#include <nx/NX.h>
7677
#include "compext/Compext.h"
@@ -421,6 +422,8 @@ FIXME: These variables, if not removed at all because have probably
421422
#ifdef NXAGENT_CLIPBOARD
422423
AddCallback(&SelectionCallback, nxagentSetSelectionCallback, NULL);
423424
#endif
425+
426+
nxagentInitAtoms();
424427
}
425428

426429
void

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

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -167,8 +167,6 @@ InitRootWindow(WindowPtr pWin)
167167
fprintf(stderr, "InitRootWindow: Mapping default windows.\n");
168168
#endif
169169

170-
nxagentInitAtoms(pWin);
171-
172170
nxagentInitClipboard(pWin);
173171

174172
nxagentMapDefaultWindows();

0 commit comments

Comments
 (0)