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
b274278d
Commit
b274278d
authored
Nov 26, 2022
by
Rémi Bernon
Committed by
Alexandre Julliard
Nov 28, 2022
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
joy.cpl: Remove unnecessary joystick forcefeedback member.
parent
9b4cd908
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
11 deletions
+3
-11
main.c
dlls/joy.cpl/main.c
+3
-11
No files found.
dlls/joy.cpl/main.c
View file @
b274278d
...
...
@@ -78,7 +78,6 @@ struct effect
struct
Joystick
{
IDirectInputDevice8W
*
device
;
BOOL
forcefeedback
;
struct
list
effects
;
IDirectInputEffect
*
effect_selected
;
...
...
@@ -216,10 +215,10 @@ static BOOL CALLBACK enum_effects( const DIEFFECTINFOW *info, void *context )
static
BOOL
CALLBACK
enum_callback
(
const
DIDEVICEINSTANCEW
*
instance
,
void
*
context
)
{
DIDEVCAPS
caps
=
{.
dwSize
=
sizeof
(
DIDEVCAPS
)};
struct
JoystickData
*
data
=
context
;
struct
Joystick
*
joystick
;
DIPROPRANGE
proprange
;
DIDEVCAPS
caps
;
if
(
data
->
joysticks
==
NULL
)
{
...
...
@@ -233,15 +232,11 @@ static BOOL CALLBACK enum_callback(const DIDEVICEINSTANCEW *instance, void *cont
IDirectInput8_CreateDevice
(
data
->
di
,
&
instance
->
guidInstance
,
&
joystick
->
device
,
NULL
);
IDirectInputDevice8_SetDataFormat
(
joystick
->
device
,
&
c_dfDIJoystick
);
caps
.
dwSize
=
sizeof
(
caps
);
IDirectInputDevice8_GetCapabilities
(
joystick
->
device
,
&
caps
);
joystick
->
forcefeedback
=
caps
.
dwFlags
&
DIDC_FORCEFEEDBACK
;
list_init
(
&
joystick
->
effects
);
joystick
->
effect_selected
=
NULL
;
if
(
joystick
->
forcefeedback
)
data
->
num_ff
++
;
IDirectInputDevice8_GetCapabilities
(
joystick
->
device
,
&
caps
);
if
(
caps
.
dwFlags
&
DIDC_FORCEFEEDBACK
)
data
->
num_ff
++
;
/* Set axis range to ease the GUI visualization */
proprange
.
diph
.
dwSize
=
sizeof
(
DIPROPRANGE
);
...
...
@@ -252,9 +247,6 @@ static BOOL CALLBACK enum_callback(const DIDEVICEINSTANCEW *instance, void *cont
proprange
.
lMax
=
TEST_AXIS_MAX
;
IDirectInputDevice_SetProperty
(
joystick
->
device
,
DIPROP_RANGE
,
&
proprange
.
diph
);
if
(
!
joystick
->
forcefeedback
)
return
DIENUM_CONTINUE
;
IDirectInputDevice8_EnumEffects
(
joystick
->
device
,
enum_effects
,
(
void
*
)
joystick
,
0
);
return
DIENUM_CONTINUE
;
...
...
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