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
ec7d7b72
Commit
ec7d7b72
authored
Aug 09, 2002
by
Michael Stefaniuc
Committed by
Alexandre Julliard
Aug 09, 2002
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
- Convert HDRVR to a void*.
- Fix declaration of DriverCallback().
parent
6a775981
Show whitespace changes
Inline
Side-by-side
Showing
11 changed files
with
40 additions
and
30 deletions
+40
-30
driver.c
dlls/msacm/driver.c
+1
-1
msvideo_main.c
dlls/msvideo/msvideo_main.c
+5
-2
driver.c
dlls/winmm/driver.c
+1
-2
joystick.c
dlls/winmm/joystick.c
+2
-1
lolvldrv.c
dlls/winmm/lolvldrv.c
+1
-1
mmsystem.c
dlls/winmm/mmsystem.c
+15
-11
wavemap.c
dlls/winmm/wavemap/wavemap.c
+4
-4
winemm.h
dlls/winmm/winemm.h
+2
-0
audio.c
dlls/winmm/wineoss/audio.c
+7
-5
mmddk.h
include/mmddk.h
+1
-2
mmsystem.h
include/mmsystem.h
+1
-1
No files found.
dlls/msacm/driver.c
View file @
ec7d7b72
...
...
@@ -271,7 +271,7 @@ MMRESULT WINAPI acmDriverOpen(PHACMDRIVER phad, HACMDRIVERID hadid, DWORD fdwOpe
pad
->
obj
.
dwType
=
WINE_ACMOBJ_DRIVER
;
pad
->
obj
.
pACMDriverID
=
padid
;
if
(
!
(
pad
->
hDrvr
=
padid
->
hInstModule
))
if
(
!
(
pad
->
hDrvr
=
(
HDRVR
)
padid
->
hInstModule
))
{
ACMDRVOPENDESCW
adod
;
int
len
;
...
...
dlls/msvideo/msvideo_main.c
View file @
ec7d7b72
...
...
@@ -46,6 +46,9 @@ LPVOID MSVIDEO_MapMsg16To32(UINT msg, LPDWORD lParam1, LPDWORD lParam2);
void
MSVIDEO_UnmapMsg16To32
(
UINT
msg
,
LPVOID
lpv
,
LPDWORD
lParam1
,
LPDWORD
lParam2
);
LRESULT
MSVIDEO_SendMessage
(
HIC
hic
,
UINT
msg
,
DWORD
lParam1
,
DWORD
lParam2
,
BOOL
bFrom32
);
#define HDRVR_16(h32) (LOWORD(h32))
/***********************************************************************
* VideoForWindowsVersion [MSVFW32.2]
* VideoForWindowsVersion [MSVIDEO.2]
...
...
@@ -268,7 +271,7 @@ HIC MSVIDEO_OpenFunc(DWORD fccType, DWORD fccHandler, UINT wMode, FARPROC lpfnHa
MSVIDEO_SendMessage
(
hic
,
DRV_ENABLE
,
0L
,
0L
,
bFrom32
);
seg_icopen
=
MapLS
(
&
icopen
);
whic
->
hdrv
=
MSVIDEO_SendMessage
(
hic
,
DRV_OPEN
,
0
,
seg_icopen
,
FALSE
);
whic
->
hdrv
=
(
HDRVR
)
MSVIDEO_SendMessage
(
hic
,
DRV_OPEN
,
0
,
seg_icopen
,
FALSE
);
UnMapLS
(
seg_icopen
);
if
(
whic
->
hdrv
==
0
)
{
WARN
(
"DRV_OPEN failed for hic 0x%08lx
\n
"
,(
DWORD
)
hic
);
...
...
@@ -976,7 +979,7 @@ LRESULT MSVIDEO_SendMessage(HIC hic,UINT msg,DWORD lParam1,DWORD lParam2, BOOL b
if
(
bDrv32
)
{
ret
=
whic
->
driverproc
(
whic
->
hdrv
,
hic
,
msg
,
lParam1
,
lParam2
);
}
else
{
ret
=
MSVIDEO_CallTo16_long_lwwll
((
FARPROC16
)
whic
->
driverproc
,
whic
->
hdrv
,
hic
,
msg
,
lParam1
,
lParam2
);
ret
=
MSVIDEO_CallTo16_long_lwwll
((
FARPROC16
)
whic
->
driverproc
,
HDRVR_16
(
whic
->
hdrv
)
,
hic
,
msg
,
lParam1
,
lParam2
);
}
}
else
{
ret
=
SendDriverMessage
(
whic
->
hdrv
,
msg
,
lParam1
,
lParam2
);
...
...
dlls/winmm/driver.c
View file @
ec7d7b72
...
...
@@ -458,7 +458,7 @@ HDRVR WINAPI OpenDriverA(LPCSTR lpDriverName, LPCSTR lpSectionName, LPARAM lPara
TRACE
(
"Failed to open driver %s from system.ini file, section %s
\n
"
,
debugstr_a
(
lpDriverName
),
debugstr_a
(
lpSectionName
));
the_end:
if
(
lpDrv
)
TRACE
(
"=> %08lx
\n
"
,
(
DWORD
)
lpDrv
);
return
(
DWORD
)
lpDrv
;
return
(
HDRVR
)
lpDrv
;
}
/**************************************************************************
...
...
@@ -638,4 +638,3 @@ LRESULT WINAPI DriverProc16(DWORD dwDevID, HDRVR16 hDrv, WORD wMsg,
return
DrvDefDriverProc16
(
dwDevID
,
hDrv
,
wMsg
,
dwParam1
,
dwParam2
);
}
dlls/winmm/joystick.c
View file @
ec7d7b72
...
...
@@ -70,7 +70,8 @@ static BOOL JOY_LoadDriver(DWORD dwJoyID)
if
(
JOY_Sticks
[
dwJoyID
].
hDriver
)
return
TRUE
;
return
JOY_Sticks
[
dwJoyID
].
hDriver
=
OpenDriverA
(
"joystick.drv"
,
0
,
dwJoyID
);
JOY_Sticks
[
dwJoyID
].
hDriver
=
OpenDriverA
(
"joystick.drv"
,
0
,
dwJoyID
);
return
(
JOY_Sticks
[
dwJoyID
].
hDriver
!=
0
);
}
/**************************************************************************
...
...
dlls/winmm/lolvldrv.c
View file @
ec7d7b72
...
...
@@ -198,7 +198,7 @@ static void MMDRV_Callback(LPWINE_MLD mld, HDRVR hDev, UINT uMsg, DWORD dwParam1
if
(
!
mld
->
bFrom32
&&
(
mld
->
dwFlags
&
DCB_TYPEMASK
)
==
DCB_FUNCTION
)
{
/* 16 bit func, call it */
TRACE
(
"Function (16 bit) !
\n
"
);
MMDRV_CallTo16_word_wwlll
((
FARPROC16
)
mld
->
dwCallback
,
hDev
,
uMsg
,
MMDRV_CallTo16_word_wwlll
((
FARPROC16
)
mld
->
dwCallback
,
HDRVR_16
(
hDev
)
,
uMsg
,
mld
->
dwClientInstance
,
dwParam1
,
dwParam2
);
}
else
{
DriverCallback
(
mld
->
dwCallback
,
mld
->
dwFlags
,
hDev
,
uMsg
,
...
...
dlls/winmm/mmsystem.c
View file @
ec7d7b72
...
...
@@ -755,11 +755,11 @@ BOOL WINAPI DriverCallback(DWORD dwCallBack, UINT uFlags, HDRVR hDev,
break
;
case
DCB_WINDOW
:
TRACE
(
"Window(%04lX) handle=%04X!
\n
"
,
dwCallBack
,
hDev
);
PostMessageA
((
HWND
)
dwCallBack
,
wMsg
,
hDev
,
dwParam1
);
PostMessageA
((
HWND
)
dwCallBack
,
wMsg
,
(
WPARAM
)
hDev
,
dwParam1
);
break
;
case
DCB_TASK
:
/* aka DCB_THREAD */
TRACE
(
"Task(%04lx) !
\n
"
,
dwCallBack
);
PostThreadMessageA
(
dwCallBack
,
wMsg
,
hDev
,
dwParam1
);
PostThreadMessageA
(
dwCallBack
,
wMsg
,
(
WPARAM
)
hDev
,
dwParam1
);
break
;
case
DCB_FUNCTION
:
TRACE
(
"Function (32 bit) !
\n
"
);
...
...
@@ -804,7 +804,7 @@ BOOL16 WINAPI DriverCallback16(DWORD dwCallBack, UINT16 uFlags, HDRVR16 hDev,
WORD
wMsg
,
DWORD
dwUser
,
DWORD
dwParam1
,
DWORD
dwParam2
)
{
return
DriverCallback
(
dwCallBack
,
uFlags
,
hDev
,
wMsg
,
dwUser
,
dwParam1
,
dwParam2
);
return
DriverCallback
(
dwCallBack
,
uFlags
,
HDRVR_32
(
hDev
)
,
wMsg
,
dwUser
,
dwParam1
,
dwParam2
);
}
/**************************************************************************
...
...
@@ -3158,8 +3158,9 @@ static BOOL MMSYSTEM_MidiStream_MessageHandler(WINE_MIDIStream* lpMidiStrm, LPWI
lpMidiHdr
->
dwFlags
|=
MHDR_DONE
;
lpMidiHdr
->
dwFlags
&=
~
MHDR_INQUEUE
;
DriverCallback
(
lpwm
->
mod
.
dwCallback
,
lpMidiStrm
->
wFlags
,
lpMidiStrm
->
hDevice
,
MM_MOM_DONE
,
lpwm
->
mod
.
dwInstance
,
(
DWORD
)
lpMidiHdr
,
0L
);
DriverCallback
(
lpwm
->
mod
.
dwCallback
,
lpMidiStrm
->
wFlags
,
(
HDRVR
)
lpMidiStrm
->
hDevice
,
MM_MOM_DONE
,
lpwm
->
mod
.
dwInstance
,
(
DWORD
)
lpMidiHdr
,
0L
);
}
lpMidiStrm
->
lpMidiHdr
=
0
;
SetEvent
(
lpMidiStrm
->
hEvent
);
...
...
@@ -3231,8 +3232,9 @@ static BOOL MMSYSTEM_MidiStream_MessageHandler(WINE_MIDIStream* lpMidiStrm, LPWI
lpMidiHdr
->
dwFlags
|=
MHDR_DONE
;
lpMidiHdr
->
dwFlags
&=
~
MHDR_INQUEUE
;
DriverCallback
(
lpwm
->
mod
.
dwCallback
,
lpMidiStrm
->
wFlags
,
lpMidiStrm
->
hDevice
,
MM_MOM_DONE
,
lpwm
->
mod
.
dwInstance
,
(
DWORD
)
lpMidiHdr
,
0L
);
DriverCallback
(
lpwm
->
mod
.
dwCallback
,
lpMidiStrm
->
wFlags
,
(
HDRVR
)
lpMidiStrm
->
hDevice
,
MM_MOM_DONE
,
lpwm
->
mod
.
dwInstance
,
(
DWORD
)
lpMidiHdr
,
0L
);
break
;
}
...
...
@@ -3352,8 +3354,9 @@ static DWORD CALLBACK MMSYSTEM_MidiStream_Player(LPVOID pmt)
break
;
}
if
(
me
->
dwEvent
&
MEVT_F_CALLBACK
)
{
DriverCallback
(
lpwm
->
mod
.
dwCallback
,
lpMidiStrm
->
wFlags
,
lpMidiStrm
->
hDevice
,
MM_MOM_POSITIONCB
,
lpwm
->
mod
.
dwInstance
,
(
LPARAM
)
lpMidiHdr
,
0L
);
DriverCallback
(
lpwm
->
mod
.
dwCallback
,
lpMidiStrm
->
wFlags
,
(
HDRVR
)
lpMidiStrm
->
hDevice
,
MM_MOM_POSITIONCB
,
lpwm
->
mod
.
dwInstance
,
(
LPARAM
)
lpMidiHdr
,
0L
);
}
lpMidiHdr
->
dwOffset
+=
sizeof
(
MIDIEVENT
)
-
sizeof
(
me
->
dwParms
);
if
(
me
->
dwEvent
&
MEVT_F_LONG
)
...
...
@@ -3364,8 +3367,9 @@ static DWORD CALLBACK MMSYSTEM_MidiStream_Player(LPVOID pmt)
lpMidiHdr
->
dwFlags
&=
~
MHDR_INQUEUE
;
lpMidiStrm
->
lpMidiHdr
=
(
LPMIDIHDR
)
lpMidiHdr
->
lpNext
;
DriverCallback
(
lpwm
->
mod
.
dwCallback
,
lpMidiStrm
->
wFlags
,
lpMidiStrm
->
hDevice
,
MM_MOM_DONE
,
lpwm
->
mod
.
dwInstance
,
(
DWORD
)
lpMidiHdr
,
0L
);
DriverCallback
(
lpwm
->
mod
.
dwCallback
,
lpMidiStrm
->
wFlags
,
(
HDRVR
)
lpMidiStrm
->
hDevice
,
MM_MOM_DONE
,
lpwm
->
mod
.
dwInstance
,
(
DWORD
)
lpMidiHdr
,
0L
);
lpData
=
0
;
}
}
...
...
dlls/winmm/wavemap/wavemap.c
View file @
ec7d7b72
...
...
@@ -94,8 +94,8 @@ static void CALLBACK wodCallback(HWAVE hWave, UINT uMsg, DWORD dwInstance,
ERR
(
"Unknown msg %u
\n
"
,
uMsg
);
}
DriverCallback
(
wom
->
dwCallback
,
HIWORD
(
wom
->
dwFlags
),
wom
->
hOuterWave
,
uMsg
,
wom
->
dwClientInstance
,
dwParam1
,
dwParam2
);
DriverCallback
(
wom
->
dwCallback
,
HIWORD
(
wom
->
dwFlags
),
(
HDRVR
)
wom
->
hOuterWave
,
uMsg
,
wom
->
dwClientInstance
,
dwParam1
,
dwParam2
);
}
static
DWORD
wodOpenHelper
(
WAVEMAPDATA
*
wom
,
UINT
idx
,
...
...
@@ -502,8 +502,8 @@ static void CALLBACK widCallback(HWAVE hWave, UINT uMsg, DWORD dwInstance,
ERR
(
"Unknown msg %u
\n
"
,
uMsg
);
}
DriverCallback
(
wim
->
dwCallback
,
HIWORD
(
wim
->
dwFlags
),
wim
->
hOuterWave
,
uMsg
,
wim
->
dwClientInstance
,
dwParam1
,
dwParam2
);
DriverCallback
(
wim
->
dwCallback
,
HIWORD
(
wim
->
dwFlags
),
(
HDRVR
)
wim
->
hOuterWave
,
uMsg
,
wim
->
dwClientInstance
,
dwParam1
,
dwParam2
);
}
static
DWORD
widOpenHelper
(
WAVEMAPDATA
*
wim
,
UINT
idx
,
...
...
dlls/winmm/winemm.h
View file @
ec7d7b72
...
...
@@ -228,6 +228,7 @@ LPWINE_MM_IDATA TIME_MMTimeStart(void);
void
TIME_MMTimeStop
(
void
);
/* HANDLE16 -> HANDLE conversions */
#define HDRVR_32(h16) ((HDRVR)(ULONG_PTR)(h16))
#define HMIDI_32(h16) ((HMIDI)(ULONG_PTR)(h16))
#define HMIDIIN_32(h16) ((HMIDIIN)(ULONG_PTR)(h16))
#define HMIDIOUT_32(h16) ((HMIDIOUT)(ULONG_PTR)(h16))
...
...
@@ -239,6 +240,7 @@ void TIME_MMTimeStop(void);
#define HWAVEOUT_32(h16) ((HWAVEOUT)(ULONG_PTR)(h16))
/* HANDLE -> HANDLE16 conversions */
#define HDRVR_16(h32) (LOWORD(h32))
#define HMIDI_16(h32) (LOWORD(h32))
#define HMIDIIN_16(h32) (LOWORD(h32))
#define HMIDIOUT_16(h32) (LOWORD(h32))
...
...
dlls/winmm/wineoss/audio.c
View file @
ec7d7b72
...
...
@@ -217,7 +217,7 @@ static DWORD OSS_OpenDevice(unsigned wDevID, int* pfd, unsigned req_access,
int
val
;
int
fd
=
-
1
;
if
(
wDevID
>=
MAX_WAVEDRV
)
return
MMSYSERR_BADDEVICEID
;
;
if
(
wDevID
>=
MAX_WAVEDRV
)
return
MMSYSERR_BADDEVICEID
;
ossdev
=
&
OSS_Devices
[
wDevID
];
if
(
ossdev
->
full_duplex
&&
(
req_access
==
O_RDONLY
||
req_access
==
O_WRONLY
))
...
...
@@ -702,8 +702,9 @@ static DWORD wodNotifyClient(WINE_WAVEOUT* wwo, WORD wMsg, DWORD dwParam1, DWORD
case
WOM_CLOSE
:
case
WOM_DONE
:
if
(
wwo
->
wFlags
!=
DCB_NULL
&&
!
DriverCallback
(
wwo
->
waveDesc
.
dwCallback
,
wwo
->
wFlags
,
wwo
->
waveDesc
.
hWave
,
wMsg
,
wwo
->
waveDesc
.
dwInstance
,
dwParam1
,
dwParam2
))
{
!
DriverCallback
(
wwo
->
waveDesc
.
dwCallback
,
wwo
->
wFlags
,
(
HDRVR
)
wwo
->
waveDesc
.
hWave
,
wMsg
,
wwo
->
waveDesc
.
dwInstance
,
dwParam1
,
dwParam2
))
{
WARN
(
"can't notify client !
\n
"
);
return
MMSYSERR_ERROR
;
}
...
...
@@ -2079,8 +2080,9 @@ static DWORD widNotifyClient(WINE_WAVEIN* wwi, WORD wMsg, DWORD dwParam1, DWORD
case
WIM_CLOSE
:
case
WIM_DATA
:
if
(
wwi
->
wFlags
!=
DCB_NULL
&&
!
DriverCallback
(
wwi
->
waveDesc
.
dwCallback
,
wwi
->
wFlags
,
wwi
->
waveDesc
.
hWave
,
wMsg
,
wwi
->
waveDesc
.
dwInstance
,
dwParam1
,
dwParam2
))
{
!
DriverCallback
(
wwi
->
waveDesc
.
dwCallback
,
wwi
->
wFlags
,
(
HDRVR
)
wwi
->
waveDesc
.
hWave
,
wMsg
,
wwi
->
waveDesc
.
dwInstance
,
dwParam1
,
dwParam2
))
{
WARN
(
"can't notify client !
\n
"
);
return
MMSYSERR_ERROR
;
}
...
...
include/mmddk.h
View file @
ec7d7b72
...
...
@@ -515,10 +515,9 @@ BOOL16 WINAPI mmThreadIsCurrent16(HANDLE16 hndl);
BOOL16
WINAPI
DriverCallback16
(
DWORD
dwCallBack
,
UINT16
uFlags
,
HANDLE16
hDev
,
WORD
wMsg
,
DWORD
dwUser
,
DWORD
dwParam1
,
DWORD
dwParam2
);
BOOL
WINAPI
DriverCallback
(
DWORD
dwCallBack
,
UINT
uFlags
,
H
ANDLE
hDev
,
BOOL
WINAPI
DriverCallback
(
DWORD
dwCallBack
,
UINT
uFlags
,
H
DRVR
hDev
,
UINT
wMsg
,
DWORD
dwUser
,
DWORD
dwParam1
,
DWORD
dwParam2
);
#include "poppack.h"
#endif
/* __MMDDK_H */
include/mmsystem.h
View file @
ec7d7b72
...
...
@@ -30,7 +30,7 @@ extern "C" {
typedef
LPSTR
HPSTR
;
/* a huge version of LPSTR */
typedef
LPCSTR
HPCSTR
;
/* a huge version of LPCSTR */
DECLARE_
OLD_
HANDLE
(
HDRVR
);
DECLARE_HANDLE
(
HDRVR
);
DECLARE_HANDLE
(
HWAVE
);
DECLARE_HANDLE
(
HWAVEIN
);
DECLARE_HANDLE
(
HWAVEOUT
);
...
...
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