Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-winehq
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-winehq
Commits
9e368483
Commit
9e368483
authored
Aug 05, 2007
by
Vitaliy Margolen
Committed by
Alexandre Julliard
Aug 06, 2007
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
dinput: Fix mapping of axes ids to property ids.
parent
d1bc6309
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
4 additions
and
3 deletions
+4
-3
device.c
dlls/dinput/device.c
+1
-1
device_private.h
dlls/dinput/device_private.h
+1
-0
joystick_linux.c
dlls/dinput/joystick_linux.c
+1
-1
joystick_linuxinput.c
dlls/dinput/joystick_linuxinput.c
+1
-1
No files found.
dlls/dinput/device.c
View file @
9e368483
...
@@ -448,7 +448,7 @@ static int offset_to_object(const DataFormat *df, int offset)
...
@@ -448,7 +448,7 @@ static int offset_to_object(const DataFormat *df, int offset)
return
-
1
;
return
-
1
;
}
}
static
int
id_to_object
(
LPCDIDATAFORMAT
df
,
int
id
)
int
id_to_object
(
LPCDIDATAFORMAT
df
,
int
id
)
{
{
int
i
;
int
i
;
...
...
dlls/dinput/device_private.h
View file @
9e368483
...
@@ -78,6 +78,7 @@ extern HRESULT create_DataFormat(LPCDIDATAFORMAT asked_format, DataFormat *forma
...
@@ -78,6 +78,7 @@ extern HRESULT create_DataFormat(LPCDIDATAFORMAT asked_format, DataFormat *forma
extern
void
release_DataFormat
(
DataFormat
*
df
)
;
extern
void
release_DataFormat
(
DataFormat
*
df
)
;
extern
void
queue_event
(
LPDIRECTINPUTDEVICE8A
iface
,
int
ofs
,
DWORD
data
,
DWORD
time
,
DWORD
seq
);
extern
void
queue_event
(
LPDIRECTINPUTDEVICE8A
iface
,
int
ofs
,
DWORD
data
,
DWORD
time
,
DWORD
seq
);
/* Helper functions to work with data format */
/* Helper functions to work with data format */
extern
int
id_to_object
(
LPCDIDATAFORMAT
df
,
int
id
);
extern
int
id_to_offset
(
const
DataFormat
*
df
,
int
id
);
extern
int
id_to_offset
(
const
DataFormat
*
df
,
int
id
);
extern
int
find_property
(
const
DataFormat
*
df
,
LPCDIPROPHEADER
ph
);
extern
int
find_property
(
const
DataFormat
*
df
,
LPCDIPROPHEADER
ph
);
...
...
dlls/dinput/joystick_linux.c
View file @
9e368483
...
@@ -764,7 +764,7 @@ static void joy_polldev(JoystickImpl *This) {
...
@@ -764,7 +764,7 @@ static void joy_polldev(JoystickImpl *This) {
if
(
number
<
12
)
if
(
number
<
12
)
{
{
inst_id
=
DIDFT_MAKEINSTANCE
(
number
)
|
(
number
<
8
?
DIDFT_ABSAXIS
:
DIDFT_POV
);
inst_id
=
DIDFT_MAKEINSTANCE
(
number
)
|
(
number
<
8
?
DIDFT_ABSAXIS
:
DIDFT_POV
);
value
=
map_axis
(
This
,
jse
.
value
,
number
);
value
=
map_axis
(
This
,
jse
.
value
,
id_to_object
(
This
->
base
.
data_format
.
wine_df
,
inst_id
)
);
/* FIXME do deadzone and saturation here */
/* FIXME do deadzone and saturation here */
TRACE
(
"changing axis %d => %d
\n
"
,
jse
.
number
,
number
);
TRACE
(
"changing axis %d => %d
\n
"
,
jse
.
number
,
number
);
...
...
dlls/dinput/joystick_linuxinput.c
View file @
9e368483
...
@@ -667,7 +667,7 @@ static void joy_polldev(JoystickImpl *This)
...
@@ -667,7 +667,7 @@ static void joy_polldev(JoystickImpl *This)
break
;
break
;
}
}
inst_id
=
DIDFT_MAKEINSTANCE
(
axis
)
|
(
ie
.
code
<
ABS_HAT0X
?
DIDFT_ABSAXIS
:
DIDFT_POV
);
inst_id
=
DIDFT_MAKEINSTANCE
(
axis
)
|
(
ie
.
code
<
ABS_HAT0X
?
DIDFT_ABSAXIS
:
DIDFT_POV
);
value
=
map_axis
(
This
,
axis
,
ie
.
value
);
value
=
map_axis
(
This
,
id_to_object
(
This
->
base
.
data_format
.
wine_df
,
inst_id
)
,
ie
.
value
);
switch
(
ie
.
code
)
{
switch
(
ie
.
code
)
{
case
ABS_X
:
This
->
js
.
lX
=
value
;
break
;
case
ABS_X
:
This
->
js
.
lX
=
value
;
break
;
...
...
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