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
e3b78317
Commit
e3b78317
authored
Aug 14, 2016
by
Bruno Jesus
Committed by
Alexandre Julliard
Aug 15, 2016
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
dinput: Add DirectInput8 device type names to debug.
Signed-off-by:
Bruno Jesus
<
00cpxxx@gmail.com
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
e2039d8e
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
24 additions
and
13 deletions
+24
-13
dinput_main.c
dlls/dinput/dinput_main.c
+24
-13
No files found.
dlls/dinput/dinput_main.c
View file @
e3b78317
...
...
@@ -181,15 +181,26 @@ HRESULT WINAPI DECLSPEC_HOTPATCH DirectInputCreateW(HINSTANCE hinst, DWORD dwVer
return
DirectInputCreateEx
(
hinst
,
dwVersion
,
&
IID_IDirectInput7W
,
(
LPVOID
*
)
ppDI
,
punkOuter
);
}
static
const
char
*
_dump_DIDEVTYPE_value
(
DWORD
dwDevType
)
{
switch
(
dwDevType
)
{
case
0
:
return
"All devices"
;
case
DIDEVTYPE_MOUSE
:
return
"DIDEVTYPE_MOUSE"
;
case
DIDEVTYPE_KEYBOARD
:
return
"DIDEVTYPE_KEYBOARD"
;
case
DIDEVTYPE_JOYSTICK
:
return
"DIDEVTYPE_JOYSTICK"
;
case
DIDEVTYPE_DEVICE
:
return
"DIDEVTYPE_DEVICE"
;
default:
return
"Unknown"
;
static
const
char
*
_dump_DIDEVTYPE_value
(
DWORD
dwDevType
,
DWORD
dwVersion
)
{
if
(
dwVersion
<
0x0800
)
{
switch
(
dwDevType
)
{
case
0
:
return
"All devices"
;
case
DIDEVTYPE_MOUSE
:
return
"DIDEVTYPE_MOUSE"
;
case
DIDEVTYPE_KEYBOARD
:
return
"DIDEVTYPE_KEYBOARD"
;
case
DIDEVTYPE_JOYSTICK
:
return
"DIDEVTYPE_JOYSTICK"
;
case
DIDEVTYPE_DEVICE
:
return
"DIDEVTYPE_DEVICE"
;
default:
return
"Unknown"
;
}
}
else
{
switch
(
dwDevType
)
{
case
DI8DEVCLASS_ALL
:
return
"All devices"
;
case
DI8DEVCLASS_POINTER
:
return
"DI8DEVCLASS_POINTER "
;
case
DI8DEVCLASS_KEYBOARD
:
return
"DI8DEVCLASS_KEYBOARD"
;
case
DI8DEVCLASS_DEVICE
:
return
"DI8DEVCLASS_DEVICE"
;
case
DI8DEVCLASS_GAMECTRL
:
return
"DI8DEVCLASS_GAMECTRL"
;
default:
return
"Unknown"
;
}
}
}
...
...
@@ -384,8 +395,8 @@ static HRESULT WINAPI IDirectInputAImpl_EnumDevices(
unsigned
int
i
;
int
j
,
r
;
TRACE
(
"(this=%p,0x%04x '%s',%p,%p,%04x)
\n
"
,
This
,
dwDevType
,
_dump_DIDEVTYPE_value
(
dwDevType
),
TRACE
(
"(this=%p,0x%04x '%s',%p,%p,
0x
%04x)
\n
"
,
This
,
dwDevType
,
_dump_DIDEVTYPE_value
(
dwDevType
,
This
->
dwVersion
),
lpCallback
,
pvRef
,
dwFlags
);
_dump_EnumDevices_dwFlags
(
dwFlags
);
...
...
@@ -424,8 +435,8 @@ static HRESULT WINAPI IDirectInputWImpl_EnumDevices(
int
j
;
HRESULT
r
;
TRACE
(
"(this=%p,0x%04x '%s',%p,%p,%04x)
\n
"
,
This
,
dwDevType
,
_dump_DIDEVTYPE_value
(
dwDevType
),
TRACE
(
"(this=%p,0x%04x '%s',%p,%p,
0x
%04x)
\n
"
,
This
,
dwDevType
,
_dump_DIDEVTYPE_value
(
dwDevType
,
This
->
dwVersion
),
lpCallback
,
pvRef
,
dwFlags
);
_dump_EnumDevices_dwFlags
(
dwFlags
);
...
...
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