Commit 8b97a3a3 authored by Francois Gouget's avatar Francois Gouget Committed by Alexandre Julliard

In the latest sdk the {waveOut,midiOut}{Get,Set}Volume functions take

a handle as the first parameter.
parent 59227d6b
......@@ -808,7 +808,7 @@ UINT16 WINAPI midiOutReset16(HMIDIOUT16 hMidiOut)
*/
UINT16 WINAPI midiOutGetVolume16(UINT16 uDeviceID, DWORD* lpdwVolume)
{
return midiOutGetVolume(uDeviceID, lpdwVolume);
return midiOutGetVolume(HMIDIOUT_32(uDeviceID), lpdwVolume);
}
/**************************************************************************
......@@ -816,7 +816,7 @@ UINT16 WINAPI midiOutGetVolume16(UINT16 uDeviceID, DWORD* lpdwVolume)
*/
UINT16 WINAPI midiOutSetVolume16(UINT16 uDeviceID, DWORD dwVolume)
{
return midiOutSetVolume(uDeviceID, dwVolume);
return midiOutSetVolume(HMIDIOUT_32(uDeviceID), dwVolume);
}
/**************************************************************************
......@@ -1413,7 +1413,7 @@ UINT16 WINAPI waveOutSetPlaybackRate16(HWAVEOUT16 hWaveOut16, DWORD dw)
*/
UINT16 WINAPI waveOutGetVolume16(UINT16 devid, LPDWORD lpdw)
{
return waveOutGetVolume(devid, lpdw);
return waveOutGetVolume(HWAVEOUT_32(devid), lpdw);
}
/**************************************************************************
......@@ -1421,7 +1421,7 @@ UINT16 WINAPI waveOutGetVolume16(UINT16 devid, LPDWORD lpdw)
*/
UINT16 WINAPI waveOutSetVolume16(UINT16 devid, DWORD dw)
{
return waveOutSetVolume(devid, dw);
return waveOutSetVolume(HWAVEOUT_32(devid), dw);
}
/**************************************************************************
......
......@@ -405,14 +405,14 @@ static DWORD wodGetDevCaps(UINT wDevID, WAVEMAPDATA* wom, LPWAVEOUTCAPSA lpWaveC
static DWORD wodGetVolume(UINT wDevID, WAVEMAPDATA* wom, LPDWORD lpVol)
{
if (WAVEMAP_IsData(wom))
return waveOutGetVolume((UINT)wom->u.out.hInnerWave, lpVol);
return waveOutGetVolume(wom->u.out.hInnerWave, lpVol);
return MMSYSERR_NOERROR;
}
static DWORD wodSetVolume(UINT wDevID, WAVEMAPDATA* wom, DWORD vol)
{
if (WAVEMAP_IsData(wom))
return waveOutSetVolume((UINT)wom->u.out.hInnerWave, vol);
return waveOutSetVolume(wom->u.out.hInnerWave, vol);
return MMSYSERR_NOERROR;
}
......
......@@ -1182,13 +1182,13 @@ UINT WINAPI midiOutReset(HMIDIOUT hMidiOut)
/**************************************************************************
* midiOutGetVolume [WINMM.@]
*/
UINT WINAPI midiOutGetVolume(UINT uDeviceID, DWORD* lpdwVolume)
UINT WINAPI midiOutGetVolume(HMIDIOUT hMidiOut, DWORD* lpdwVolume)
{
LPWINE_MLD wmld;
TRACE("(%04X, %p);\n", uDeviceID, lpdwVolume);
TRACE("(%p, %p);\n", hMidiOut, lpdwVolume);
if ((wmld = MMDRV_Get((HANDLE)uDeviceID, MMDRV_MIDIOUT, TRUE)) == NULL)
if ((wmld = MMDRV_Get(hMidiOut, MMDRV_MIDIOUT, TRUE)) == NULL)
return MMSYSERR_INVALHANDLE;
return MMDRV_Message(wmld, MODM_GETVOLUME, (DWORD)lpdwVolume, 0L, TRUE);
......@@ -1197,13 +1197,13 @@ UINT WINAPI midiOutGetVolume(UINT uDeviceID, DWORD* lpdwVolume)
/**************************************************************************
* midiOutSetVolume [WINMM.@]
*/
UINT WINAPI midiOutSetVolume(UINT uDeviceID, DWORD dwVolume)
UINT WINAPI midiOutSetVolume(HMIDIOUT hMidiOut, DWORD dwVolume)
{
LPWINE_MLD wmld;
TRACE("(%04X, %ld);\n", uDeviceID, dwVolume);
TRACE("(%p, %ld);\n", hMidiOut, dwVolume);
if ((wmld = MMDRV_Get((HANDLE)uDeviceID, MMDRV_MIDIOUT, TRUE)) == NULL)
if ((wmld = MMDRV_Get(hMidiOut, MMDRV_MIDIOUT, TRUE)) == NULL)
return MMSYSERR_INVALHANDLE;
return MMDRV_Message(wmld, MODM_SETVOLUME, dwVolume, 0L, TRUE);
......@@ -2519,13 +2519,13 @@ UINT WINAPI waveOutSetPlaybackRate(HWAVEOUT hWaveOut, DWORD dw)
/**************************************************************************
* waveOutGetVolume [WINMM.@]
*/
UINT WINAPI waveOutGetVolume(UINT devid, LPDWORD lpdw)
UINT WINAPI waveOutGetVolume(HWAVEOUT hWaveOut, LPDWORD lpdw)
{
LPWINE_MLD wmld;
TRACE("(%04X, %08lx);\n", devid, (DWORD)lpdw);
TRACE("(%p, %08lx);\n", hWaveOut, (DWORD)lpdw);
if ((wmld = MMDRV_Get((HANDLE)devid, MMDRV_WAVEOUT, TRUE)) == NULL)
if ((wmld = MMDRV_Get(hWaveOut, MMDRV_WAVEOUT, TRUE)) == NULL)
return MMSYSERR_INVALHANDLE;
return MMDRV_Message(wmld, WODM_GETVOLUME, (DWORD)lpdw, 0L, TRUE);
......@@ -2534,13 +2534,13 @@ UINT WINAPI waveOutGetVolume(UINT devid, LPDWORD lpdw)
/**************************************************************************
* waveOutSetVolume [WINMM.@]
*/
UINT WINAPI waveOutSetVolume(UINT devid, DWORD dw)
UINT WINAPI waveOutSetVolume(HWAVEOUT hWaveOut, DWORD dw)
{
LPWINE_MLD wmld;
TRACE("(%04X, %08lx);\n", devid, dw);
TRACE("(%p, %08lx);\n", hWaveOut, dw);
if ((wmld = MMDRV_Get((HANDLE)devid, MMDRV_WAVEOUT, TRUE)) == NULL)
if ((wmld = MMDRV_Get(hWaveOut, MMDRV_WAVEOUT, TRUE)) == NULL)
return MMSYSERR_INVALHANDLE;
return MMDRV_Message(wmld, WODM_SETVOLUME, dw, 0L, TRUE);
......
......@@ -435,8 +435,8 @@ UINT WINAPI waveOutGetNumDevs(void);
UINT WINAPI waveOutGetDevCapsA(UINT,LPWAVEOUTCAPSA,UINT);
UINT WINAPI waveOutGetDevCapsW(UINT,LPWAVEOUTCAPSW,UINT);
#define waveOutGetDevCaps WINELIB_NAME_AW(waveOutGetDevCaps)
UINT WINAPI waveOutGetVolume(UINT,DWORD*);
UINT WINAPI waveOutSetVolume(UINT,DWORD);
UINT WINAPI waveOutGetVolume(HWAVEOUT,DWORD*);
UINT WINAPI waveOutSetVolume(HWAVEOUT,DWORD);
UINT WINAPI waveOutGetErrorTextA(UINT,LPSTR,UINT);
UINT WINAPI waveOutGetErrorTextW(UINT,LPWSTR,UINT);
#define waveOutGetErrorText WINELIB_NAME_AW(waveOutGetErrorText)
......@@ -637,8 +637,8 @@ UINT WINAPI midiOutGetNumDevs(void);
UINT WINAPI midiOutGetDevCapsA(UINT,LPMIDIOUTCAPSA,UINT);
UINT WINAPI midiOutGetDevCapsW(UINT,LPMIDIOUTCAPSW,UINT);
#define midiOutGetDevCaps WINELIB_NAME_AW(midiOutGetDevCaps)
UINT WINAPI midiOutGetVolume(UINT,DWORD*);
UINT WINAPI midiOutSetVolume(UINT,DWORD);
UINT WINAPI midiOutGetVolume(HMIDIOUT,DWORD*);
UINT WINAPI midiOutSetVolume(HMIDIOUT,DWORD);
UINT WINAPI midiOutGetErrorTextA(UINT,LPSTR,UINT);
UINT WINAPI midiOutGetErrorTextW(UINT,LPWSTR,UINT);
#define midiOutGetErrorText WINELIB_NAME_AW(midiOutGetErrorText)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment