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
084d9cb5
Commit
084d9cb5
authored
Jun 24, 2019
by
Ulrich Sibiller
Committed by
Mike Gabriel
Sep 29, 2019
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
NXdispatch.c: replace hardcoded values by variables from Clipboard.c
parent
7a2836f8
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
21 additions
and
16 deletions
+21
-16
Clipboard.c
nx-X11/programs/Xserver/hw/nxagent/Clipboard.c
+3
-3
NXdispatch.c
nx-X11/programs/Xserver/hw/nxagent/NXdispatch.c
+18
-13
No files found.
nx-X11/programs/Xserver/hw/nxagent/Clipboard.c
View file @
084d9cb5
...
...
@@ -74,9 +74,9 @@ Atom serverCutProperty;
Atom
clientCutProperty
;
static
Window
serverWindow
;
static
const
int
nxagentPrimarySelection
=
0
;
static
const
int
nxagentClipboardSelection
=
1
;
static
const
int
nxagentMaxSelections
=
2
;
const
int
nxagentPrimarySelection
=
0
;
const
int
nxagentClipboardSelection
=
1
;
const
int
nxagentMaxSelections
=
2
;
typedef
struct
_SelectionOwner
{
...
...
nx-X11/programs/Xserver/hw/nxagent/NXdispatch.c
View file @
084d9cb5
...
...
@@ -194,6 +194,11 @@ extern int nxagentMaxAllowedResets;
extern
int
nxagentFindClientResource
(
int
,
RESTYPE
,
void
*
);
#ifdef NXAGENT_CLIPBOARD
extern
int
nxagentPrimarySelection
;
extern
int
nxagentClipboardSelection
;
extern
int
nxagentMaxSelections
;
#endif
void
InitSelections
()
...
...
@@ -206,23 +211,23 @@ InitSelections()
#ifdef NXAGENT_CLIPBOARD
{
Selection
*
newsels
;
newsels
=
(
Selection
*
)
malloc
(
2
*
sizeof
(
Selection
));
newsels
=
(
Selection
*
)
malloc
(
nxagentMaxSelections
*
sizeof
(
Selection
));
if
(
!
newsels
)
return
;
NumCurrentSelections
+=
2
;
NumCurrentSelections
+=
nxagentMaxSelections
;
CurrentSelections
=
newsels
;
CurrentSelections
[
0
].
selection
=
XA_PRIMARY
;
CurrentSelections
[
0
].
lastTimeChanged
=
ClientTimeToServerTime
(
0
);
CurrentSelections
[
0
].
window
=
screenInfo
.
screens
[
0
]
->
root
->
drawable
.
id
;
CurrentSelections
[
0
].
pWin
=
NULL
;
CurrentSelections
[
0
].
client
=
NullClient
;
CurrentSelections
[
1
].
selection
=
MakeAtom
(
"CLIPBOARD"
,
9
,
1
);
CurrentSelections
[
1
].
lastTimeChanged
=
ClientTimeToServerTime
(
0
);
CurrentSelections
[
1
].
window
=
screenInfo
.
screens
[
0
]
->
root
->
drawable
.
id
;
CurrentSelections
[
1
].
pWin
=
NULL
;
CurrentSelections
[
1
].
client
=
NullClient
;
CurrentSelections
[
nxagentPrimarySelection
].
selection
=
XA_PRIMARY
;
CurrentSelections
[
nxagentPrimarySelection
].
lastTimeChanged
=
ClientTimeToServerTime
(
0
);
CurrentSelections
[
nxagentPrimarySelection
].
window
=
screenInfo
.
screens
[
0
]
->
root
->
drawable
.
id
;
CurrentSelections
[
nxagentPrimarySelection
].
pWin
=
NULL
;
CurrentSelections
[
nxagentPrimarySelection
].
client
=
NullClient
;
CurrentSelections
[
nxagentClipboardSelection
].
selection
=
MakeAtom
(
"CLIPBOARD"
,
9
,
1
);
CurrentSelections
[
nxagentClipboardSelection
].
lastTimeChanged
=
ClientTimeToServerTime
(
0
);
CurrentSelections
[
nxagentClipboardSelection
].
window
=
screenInfo
.
screens
[
0
]
->
root
->
drawable
.
id
;
CurrentSelections
[
nxagentClipboardSelection
].
pWin
=
NULL
;
CurrentSelections
[
nxagentClipboardSelection
].
client
=
NullClient
;
}
#endif
...
...
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