Removed DECLARE_OLD_HANDLE. Fixed a few remaining warnings.

This commit is contained in:
Alexandre Julliard 2002-10-19 17:20:02 +00:00
parent 2c481cebcd
commit 6fa2ac693e
7 changed files with 19 additions and 25 deletions

View File

@ -438,7 +438,7 @@ DWORD MCIAVI_OpenAudio(WINE_MCIAVI* wma, unsigned* nHdr, LPWAVEHDR* pWaveHdr)
LPWAVEHDR waveHdr;
unsigned i;
dwRet = waveOutOpen(&wma->hWave, WAVE_MAPPER, wma->lpWaveFormat,
dwRet = waveOutOpen((HWAVEOUT *)&wma->hWave, WAVE_MAPPER, wma->lpWaveFormat,
(DWORD)MCIAVI_waveCallback, (DWORD)wma, CALLBACK_FUNCTION);
if (dwRet != 0) {
TRACE("Can't open low level audio device %ld\n", dwRet);

View File

@ -775,7 +775,7 @@ static DWORD WAVE_mciPlay(UINT wDevID, DWORD dwFlags, LPMCI_PLAY_PARMS lpParms)
* change from output to input and back
*/
/* FIXME: how to choose between several output channels ? here mapper is forced */
dwRet = waveOutOpen(&wmw->hWave, WAVE_MAPPER, wmw->lpWaveFormat,
dwRet = waveOutOpen((HWAVEOUT *)&wmw->hWave, WAVE_MAPPER, wmw->lpWaveFormat,
(DWORD)WAVE_mciPlayCallback, (DWORD)wmw, CALLBACK_FUNCTION);
if (dwRet != 0) {
@ -1006,7 +1006,7 @@ static DWORD WAVE_mciRecord(UINT wDevID, DWORD dwFlags, LPMCI_RECORD_PARMS lpPar
* change from output to input and back
*/
/* FIXME: how to choose between several output channels ? here mapper is forced */
dwRet = waveInOpen(&wmw->hWave, WAVE_MAPPER, wmw->lpWaveFormat,
dwRet = waveInOpen((HWAVEIN*)&wmw->hWave, WAVE_MAPPER, wmw->lpWaveFormat,
(DWORD)WAVE_mciRecordCallback, (DWORD)wmw, CALLBACK_FUNCTION);
if (dwRet != 0) {

View File

@ -632,7 +632,7 @@ 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,
!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;

View File

@ -456,7 +456,7 @@ 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,
!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;

View File

@ -534,7 +534,7 @@ 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,
!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;

View File

@ -72,24 +72,24 @@ typedef DWORD COLORREF, *LPCOLORREF;
typedef int HFILE;
DECLARE_HANDLE(HACCEL);
DECLARE_OLD_HANDLE(HBITMAP);
DECLARE_OLD_HANDLE(HBRUSH);
DECLARE_HANDLE(HBITMAP);
DECLARE_HANDLE(HBRUSH);
DECLARE_HANDLE(HCOLORSPACE);
DECLARE_OLD_HANDLE(HDC);
DECLARE_HANDLE(HDC);
DECLARE_HANDLE(HDESK);
DECLARE_HANDLE(HENHMETAFILE);
DECLARE_OLD_HANDLE(HFONT);
DECLARE_HANDLE(HFONT);
DECLARE_HANDLE(HHOOK);
DECLARE_HANDLE(HICON);
DECLARE_OLD_HANDLE(HINSTANCE);
DECLARE_HANDLE(HINSTANCE);
DECLARE_HANDLE(HKEY);
DECLARE_HANDLE(HKL);
DECLARE_OLD_HANDLE(HMENU);
DECLARE_HANDLE(HMENU);
DECLARE_HANDLE(HMETAFILE);
DECLARE_HANDLE(HMONITOR);
DECLARE_HANDLE(HPALETTE);
DECLARE_OLD_HANDLE(HPEN);
DECLARE_OLD_HANDLE(HRGN);
DECLARE_HANDLE(HPEN);
DECLARE_HANDLE(HRGN);
DECLARE_HANDLE(HRSRC);
DECLARE_HANDLE(HTASK);
DECLARE_HANDLE(HWINEVENTHOOK);

View File

@ -561,20 +561,14 @@ typedef DWORD EXECUTION_STATE;
* we're ready we'll remove the '!defined(__WINE__)' (the equivalent
* of converting it from DECLARE_OLD_HANDLE to DECLARE_HANDLE).
*/
#if defined(STRICT) || (defined(__WINE__) && !defined(WINE_NO_STRICT))
typedef VOID* HANDLE;
#define DECLARE_OLD_HANDLE(a) \
typedef struct a##__ { int unused; } *a; \
typedef a *P##a
#if defined(__WINE__) && defined(WINE_NO_STRICT)
typedef UINT HANDLE;
#else
typedef UINT HANDLE;
#define DECLARE_OLD_HANDLE(a) \
typedef HANDLE a; \
typedef a *P##a
typedef void *HANDLE;
#endif
typedef HANDLE *PHANDLE, *LPHANDLE;
typedef HANDLE *PHANDLE, *LPHANDLE;
#ifdef STRICT
#if defined(STRICT) || (defined(__WINE__) && !defined(WINE_NO_STRICT))
#define DECLARE_HANDLE(a) \
typedef struct a##__ { int unused; } *a; \
typedef a *P##a