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
024a2bc2
Commit
024a2bc2
authored
Oct 31, 2019
by
Ulrich Sibiller
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Pointer.c: scope improvements
parent
c9549f3c
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
12 deletions
+6
-12
Pointer.c
nx-X11/programs/Xserver/hw/nxagent/Pointer.c
+6
-12
No files found.
nx-X11/programs/Xserver/hw/nxagent/Pointer.c
View file @
024a2bc2
...
...
@@ -103,10 +103,6 @@ void nxagentChangePointerControl(DeviceIntPtr pDev, PtrCtrl *ctrl)
int
nxagentPointerProc
(
DeviceIntPtr
pDev
,
int
onoff
)
{
CARD8
map
[
MAXBUTTONS
];
int
nmap
;
int
i
;
switch
(
onoff
)
{
case
DEVICE_INIT
:
...
...
@@ -120,8 +116,10 @@ int nxagentPointerProc(DeviceIntPtr pDev, int onoff)
return
Success
;
}
nmap
=
XGetPointerMapping
(
nxagentDisplay
,
map
,
MAXBUTTONS
);
for
(
i
=
0
;
i
<=
nmap
;
i
++
)
CARD8
map
[
MAXBUTTONS
];
int
nmap
=
XGetPointerMapping
(
nxagentDisplay
,
map
,
MAXBUTTONS
);
for
(
int
i
=
0
;
i
<=
nmap
;
i
++
)
map
[
i
]
=
i
;
/* buttons are already mapped */
InitPointerDeviceStruct
((
DevicePtr
)
pDev
,
map
,
nmap
,
miPointerGetMotionEvents
,
...
...
@@ -173,10 +171,6 @@ int nxagentPointerProc(DeviceIntPtr pDev, int onoff)
void
nxagentInitPointerMap
(
void
)
{
int
numButtons
;
int
i
;
unsigned
char
pointerMap
[
MAXBUTTONS
];
#ifdef DEBUG
...
...
@@ -184,13 +178,13 @@ void nxagentInitPointerMap(void)
"pointer map from remote display.
\n
"
);
#endif
numButtons
=
XGetPointerMapping
(
nxagentDisplay
,
pointerMap
,
MAXBUTTONS
);
int
numButtons
=
XGetPointerMapping
(
nxagentDisplay
,
pointerMap
,
MAXBUTTONS
);
/*
* Computing revers pointer map.
*/
for
(
i
=
1
;
i
<=
numButtons
;
i
++
)
for
(
i
nt
i
=
1
;
i
<=
numButtons
;
i
++
)
{
nxagentReversePointerMap
[
pointerMap
[
i
-
1
]]
=
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