winmm/mmsystem now compiles with -DSTRICT.
This commit is contained in:
parent
4bbd7b3e26
commit
ac5de27d1c
|
@ -1,4 +1,4 @@
|
|||
EXTRADEFS = -D_WINMM_ -DWINE_NO_STRICT
|
||||
EXTRADEFS = -D_WINMM_
|
||||
TOPSRCDIR = @top_srcdir@
|
||||
TOPOBJDIR = ../..
|
||||
SRCDIR = @srcdir@
|
||||
|
|
|
@ -91,10 +91,10 @@ static LRESULT inline DRIVER_SendMessage(LPWINE_DRIVER lpDrv, UINT msg,
|
|||
if (pFnSendMessage16)
|
||||
ret = pFnSendMessage16(lpDrv->d.d16.hDriver16, msg, lParam1, lParam2);
|
||||
} else {
|
||||
TRACE("Before call32 proc=%p drvrID=%08lx hDrv=%08x wMsg=%04x p1=%08lx p2=%08lx\n",
|
||||
TRACE("Before call32 proc=%p drvrID=%08lx hDrv=%p wMsg=%04x p1=%08lx p2=%08lx\n",
|
||||
lpDrv->d.d32.lpDrvProc, lpDrv->d.d32.dwDriverID, (HDRVR)lpDrv, msg, lParam1, lParam2);
|
||||
ret = lpDrv->d.d32.lpDrvProc(lpDrv->d.d32.dwDriverID, (HDRVR)lpDrv, msg, lParam1, lParam2);
|
||||
TRACE("After call32 proc=%p drvrID=%08lx hDrv=%08x wMsg=%04x p1=%08lx p2=%08lx => %08lx\n",
|
||||
TRACE("After call32 proc=%p drvrID=%08lx hDrv=%p wMsg=%04x p1=%08lx p2=%08lx => %08lx\n",
|
||||
lpDrv->d.d32.lpDrvProc, lpDrv->d.d32.dwDriverID, (HDRVR)lpDrv, msg, lParam1, lParam2, ret);
|
||||
}
|
||||
return ret;
|
||||
|
@ -110,12 +110,12 @@ LRESULT WINAPI SendDriverMessage(HDRVR hDriver, UINT msg, LPARAM lParam1,
|
|||
LPWINE_DRIVER lpDrv;
|
||||
LRESULT retval = 0;
|
||||
|
||||
TRACE("(%04x, %04X, %08lX, %08lX)\n", hDriver, msg, lParam1, lParam2);
|
||||
TRACE("(%p, %04X, %08lX, %08lX)\n", hDriver, msg, lParam1, lParam2);
|
||||
|
||||
if ((lpDrv = DRIVER_FindFromHDrvr(hDriver)) != NULL) {
|
||||
retval = DRIVER_SendMessage(lpDrv, msg, lParam1, lParam2);
|
||||
} else {
|
||||
WARN("Bad driver handle %u\n", hDriver);
|
||||
WARN("Bad driver handle %p\n", hDriver);
|
||||
}
|
||||
TRACE("retval = %ld\n", retval);
|
||||
|
||||
|
@ -343,7 +343,7 @@ LRESULT WINAPI CloseDriver(HDRVR hDrvr, LPARAM lParam1, LPARAM lParam2)
|
|||
{
|
||||
LPWINE_DRIVER lpDrv;
|
||||
|
||||
TRACE("(%04x, %08lX, %08lX);\n", hDrvr, lParam1, lParam2);
|
||||
TRACE("(%p, %08lX, %08lX);\n", hDrvr, lParam1, lParam2);
|
||||
|
||||
if ((lpDrv = DRIVER_FindFromHDrvr(hDrvr)) != NULL)
|
||||
{
|
||||
|
@ -399,7 +399,7 @@ DWORD WINAPI GetDriverFlags(HDRVR hDrvr)
|
|||
LPWINE_DRIVER lpDrv;
|
||||
DWORD ret = 0;
|
||||
|
||||
TRACE("(%04x)\n", hDrvr);
|
||||
TRACE("(%p)\n", hDrvr);
|
||||
|
||||
if ((lpDrv = DRIVER_FindFromHDrvr(hDrvr)) != NULL) {
|
||||
ret = WINE_GDF_EXIST | lpDrv->dwFlags;
|
||||
|
@ -416,13 +416,13 @@ HMODULE WINAPI GetDriverModuleHandle(HDRVR hDrvr)
|
|||
LPWINE_DRIVER lpDrv;
|
||||
HMODULE hModule = 0;
|
||||
|
||||
TRACE("(%04x);\n", hDrvr);
|
||||
TRACE("(%p);\n", hDrvr);
|
||||
|
||||
if ((lpDrv = DRIVER_FindFromHDrvr(hDrvr)) != NULL) {
|
||||
if (!(lpDrv->dwFlags & WINE_GDF_16BIT))
|
||||
hModule = lpDrv->d.d32.hModule;
|
||||
}
|
||||
TRACE("=> %04x\n", hModule);
|
||||
TRACE("=> %p\n", hModule);
|
||||
return hModule;
|
||||
}
|
||||
|
||||
|
@ -454,7 +454,7 @@ BOOL WINAPI DriverCallback(DWORD dwCallBack, UINT uFlags, HDRVR hDev,
|
|||
UINT wMsg, DWORD dwUser, DWORD dwParam1,
|
||||
DWORD dwParam2)
|
||||
{
|
||||
TRACE("(%08lX, %04X, %04X, %04X, %08lX, %08lX, %08lX); !\n",
|
||||
TRACE("(%08lX, %04X, %p, %04X, %08lX, %08lX, %08lX); !\n",
|
||||
dwCallBack, uFlags, hDev, wMsg, dwUser, dwParam1, dwParam2);
|
||||
|
||||
switch (uFlags & DCB_TYPEMASK) {
|
||||
|
@ -464,7 +464,7 @@ BOOL WINAPI DriverCallback(DWORD dwCallBack, UINT uFlags, HDRVR hDev,
|
|||
WARN("uFlags=%04X has null DCB value, but dwCallBack=%08lX is not null !\n", uFlags, dwCallBack);
|
||||
break;
|
||||
case DCB_WINDOW:
|
||||
TRACE("Window(%04lX) handle=%04X!\n", dwCallBack, hDev);
|
||||
TRACE("Window(%04lX) handle=%p!\n", dwCallBack, hDev);
|
||||
PostMessageA((HWND)dwCallBack, wMsg, (WPARAM)hDev, dwParam1);
|
||||
break;
|
||||
case DCB_TASK: /* aka DCB_THREAD */
|
||||
|
|
|
@ -269,7 +269,7 @@ MMRESULT WINAPI joyReleaseCapture(UINT wID)
|
|||
*/
|
||||
MMRESULT WINAPI joySetCapture(HWND hWnd, UINT wID, UINT wPeriod, BOOL bChanged)
|
||||
{
|
||||
TRACE("(%04X, %04X, %d, %d);\n", hWnd, wID, wPeriod, bChanged);
|
||||
TRACE("(%p, %04X, %d, %d);\n", hWnd, wID, wPeriod, bChanged);
|
||||
|
||||
if (wID >= MAXJOYSTICK || hWnd == 0) return JOYERR_PARMS;
|
||||
if (wPeriod<JOY_PERIOD_MIN || wPeriod>JOY_PERIOD_MAX) return JOYERR_PARMS;
|
||||
|
|
|
@ -295,10 +295,10 @@ LPWINE_MLD MMDRV_Alloc(UINT size, UINT type, LPHANDLE hndl, DWORD* dwFlags,
|
|||
if (!mld) return NULL;
|
||||
|
||||
/* find an empty slot in MM_MLDrvs table */
|
||||
for (*hndl = 0; *hndl < MAX_MM_MLDRVS; (*hndl)++) {
|
||||
for (*hndl = 0; (DWORD)*hndl < MAX_MM_MLDRVS; (*hndl)++) {
|
||||
if (!MM_MLDrvs[(UINT)*hndl]) break;
|
||||
}
|
||||
if (*hndl == MAX_MM_MLDRVS) {
|
||||
if ((DWORD)*hndl == MAX_MM_MLDRVS) {
|
||||
/* the MM_MLDrvs table could be made growable in the future if needed */
|
||||
ERR("Too many open drivers\n");
|
||||
return NULL;
|
||||
|
@ -343,7 +343,7 @@ void MMDRV_Free(HANDLE hndl, LPWINE_MLD mld)
|
|||
return;
|
||||
}
|
||||
}
|
||||
ERR("Bad Handle %08x at %p (not freed)\n", hndl, mld);
|
||||
ERR("Bad Handle %p at %p (not freed)\n", hndl, mld);
|
||||
}
|
||||
|
||||
/**************************************************************************
|
||||
|
@ -413,26 +413,27 @@ LPWINE_MLD MMDRV_GetByID(UINT uDevID, UINT type)
|
|||
/**************************************************************************
|
||||
* MMDRV_Get [internal]
|
||||
*/
|
||||
LPWINE_MLD MMDRV_Get(HANDLE hndl, UINT type, BOOL bCanBeID)
|
||||
LPWINE_MLD MMDRV_Get(HANDLE _hndl, UINT type, BOOL bCanBeID)
|
||||
{
|
||||
LPWINE_MLD mld = NULL;
|
||||
UINT hndl = (UINT)_hndl;
|
||||
|
||||
assert(type < MMDRV_MAX);
|
||||
|
||||
if ((UINT)hndl >= llTypes[type].wMaxId &&
|
||||
if (hndl >= llTypes[type].wMaxId &&
|
||||
hndl != (UINT16)-1 && hndl != (UINT)-1) {
|
||||
if ((UINT)hndl & 0x8000) {
|
||||
hndl = (HANDLE)((UINT)hndl & ~0x8000);
|
||||
if (hndl & 0x8000) {
|
||||
hndl = hndl & ~0x8000;
|
||||
if (hndl < sizeof(MM_MLDrvs) / sizeof(MM_MLDrvs[0])) {
|
||||
mld = MM_MLDrvs[(UINT)hndl];
|
||||
mld = MM_MLDrvs[hndl];
|
||||
if (!mld || !HeapValidate(GetProcessHeap(), 0, mld) || mld->type != type)
|
||||
mld = NULL;
|
||||
}
|
||||
hndl = (HANDLE)((UINT)hndl | 0x8000);
|
||||
hndl = hndl | 0x8000;
|
||||
}
|
||||
}
|
||||
if (mld == NULL && bCanBeID) {
|
||||
mld = MMDRV_GetByID((UINT)hndl, type);
|
||||
mld = MMDRV_GetByID(hndl, type);
|
||||
}
|
||||
return mld;
|
||||
}
|
||||
|
|
|
@ -217,7 +217,7 @@ static BOOL MCI_IsCommandTableValid(UINT uTbl)
|
|||
int idx = 0;
|
||||
BOOL inCst = FALSE;
|
||||
|
||||
TRACE("Dumping cmdTbl=%d [hMem=%08x devType=%d]\n",
|
||||
TRACE("Dumping cmdTbl=%d [hMem=%p devType=%d]\n",
|
||||
uTbl, S_MciCmdTable[uTbl].hMem, S_MciCmdTable[uTbl].uDevType);
|
||||
|
||||
if (uTbl >= MAX_MCICMDTABLE || !S_MciCmdTable[uTbl].hMem || !S_MciCmdTable[uTbl].lpTable)
|
||||
|
@ -315,7 +315,7 @@ static UINT MCI_GetCommandTable(UINT uDevType)
|
|||
if (hMem) {
|
||||
uTbl = MCI_SetCommandTable(hMem, uDevType);
|
||||
} else {
|
||||
WARN("No command table found in resource %04x[%s]\n",
|
||||
WARN("No command table found in resource %p[%s]\n",
|
||||
WINMM_IData->hWinMM32Instance, str);
|
||||
}
|
||||
}
|
||||
|
@ -538,7 +538,7 @@ static DWORD MCI_LoadMciDriver(LPCSTR _strDevTyp, LPWINE_MCIDRIVER* lpwmd)
|
|||
wmd->uSpecificCmdTable = LOWORD(modp.wCustomCommandTable);
|
||||
wmd->uTypeCmdTable = MCI_COMMAND_TABLE_NOT_LOADED;
|
||||
|
||||
TRACE("Loaded driver %x (%s), type is %d, cmdTable=%08x\n",
|
||||
TRACE("Loaded driver %p (%s), type is %d, cmdTable=%08x\n",
|
||||
wmd->hDriver, strDevTyp, modp.wType, modp.wCustomCommandTable);
|
||||
|
||||
wmd->lpstrDeviceType = strDevTyp;
|
||||
|
@ -878,7 +878,7 @@ DWORD WINAPI mciSendStringA(LPCSTR lpstrCommand, LPSTR lpstrRet,
|
|||
LPSTR devAlias = NULL;
|
||||
BOOL bAutoOpen = FALSE;
|
||||
|
||||
TRACE("('%s', %p, %d, %X)\n", lpstrCommand, lpstrRet, uRetLen, hwndCallback);
|
||||
TRACE("('%s', %p, %d, %p)\n", lpstrCommand, lpstrRet, uRetLen, hwndCallback);
|
||||
|
||||
/* format is <command> <device> <optargs> */
|
||||
if (!(verb = HeapAlloc(GetProcessHeap(), 0, strlen(lpstrCommand)+1)))
|
||||
|
@ -1103,7 +1103,7 @@ UINT WINAPI mciLoadCommandResource(HINSTANCE hInst, LPCWSTR resNameW, UINT type)
|
|||
HGLOBAL hMem;
|
||||
UINT16 ret = MCI_NO_COMMAND_TABLE;
|
||||
|
||||
TRACE("(%04x, %s, %d)!\n", hInst, debugstr_w(resNameW), type);
|
||||
TRACE("(%p, %s, %d)!\n", hInst, debugstr_w(resNameW), type);
|
||||
|
||||
/* if a file named "resname.mci" exits, then load resource "resname" from it
|
||||
* otherwise directly from driver
|
||||
|
@ -1333,14 +1333,14 @@ static DWORD MCI_Open(DWORD dwParam, LPMCI_OPEN_PARMSA lpParms)
|
|||
TRACE("wDevID=%04X wDeviceID=%d dwRet=%ld\n", wmd->wDeviceID, lpParms->wDeviceID, dwRet);
|
||||
|
||||
if (dwParam & MCI_NOTIFY)
|
||||
mciDriverNotify(lpParms->dwCallback, wmd->wDeviceID, MCI_NOTIFY_SUCCESSFUL);
|
||||
mciDriverNotify((HWND)lpParms->dwCallback, wmd->wDeviceID, MCI_NOTIFY_SUCCESSFUL);
|
||||
|
||||
return 0;
|
||||
errCleanUp:
|
||||
if (wmd) MCI_UnLoadMciDriver(wmd);
|
||||
|
||||
if (dwParam & MCI_NOTIFY)
|
||||
mciDriverNotify(lpParms->dwCallback, 0, MCI_NOTIFY_FAILURE);
|
||||
mciDriverNotify((HWND)lpParms->dwCallback, 0, MCI_NOTIFY_FAILURE);
|
||||
return dwRet;
|
||||
}
|
||||
|
||||
|
@ -1380,7 +1380,7 @@ static DWORD MCI_Close(UINT16 wDevID, DWORD dwParam, LPMCI_GENERIC_PARMS lpParms
|
|||
MCI_UnLoadMciDriver(wmd);
|
||||
|
||||
if (dwParam & MCI_NOTIFY)
|
||||
mciDriverNotify(lpParms->dwCallback, wDevID,
|
||||
mciDriverNotify((HWND)lpParms->dwCallback, wDevID,
|
||||
(dwRet == 0) ? MCI_NOTIFY_SUCCESSFUL : MCI_NOTIFY_FAILURE);
|
||||
|
||||
return dwRet;
|
||||
|
@ -1503,7 +1503,7 @@ static DWORD MCI_Break(UINT wDevID, DWORD dwFlags, LPMCI_BREAK_PARMS lpParms)
|
|||
if (lpParms == NULL) return MCIERR_NULL_PARAMETER_BLOCK;
|
||||
|
||||
if (dwFlags & MCI_NOTIFY)
|
||||
mciDriverNotify(lpParms->dwCallback, wDevID,
|
||||
mciDriverNotify((HWND)lpParms->dwCallback, wDevID,
|
||||
(dwRet == 0) ? MCI_NOTIFY_SUCCESSFUL : MCI_NOTIFY_FAILURE);
|
||||
|
||||
return dwRet;
|
||||
|
|
|
@ -41,7 +41,7 @@ extern WORD CALLBACK MMDRV_CallTo16_word_wwlll(FARPROC16,WORD,WORD,LONG,LONG,LON
|
|||
*/
|
||||
static void MMDRV_Callback(LPWINE_MLD mld, HDRVR hDev, UINT uMsg, DWORD dwParam1, DWORD dwParam2)
|
||||
{
|
||||
TRACE("CB (*%08lx)(%08x %08x %08lx %08lx %08lx\n",
|
||||
TRACE("CB (*%08lx)(%p %08x %08lx %08lx %08lx\n",
|
||||
mld->dwCallback, hDev, uMsg, mld->dwClientInstance, dwParam1, dwParam2);
|
||||
|
||||
if (!mld->bFrom32 && (mld->dwFlags & DCB_TYPEMASK) == DCB_FUNCTION) {
|
||||
|
@ -1764,7 +1764,7 @@ static BOOL MMDRV_GetDescription16(const char* fname, char* buf, int buflen)
|
|||
ret = TRUE;
|
||||
TRACE("Got '%s' [%d]\n", buf, buflen);
|
||||
theEnd:
|
||||
CloseHandle(hFile);
|
||||
_lclose(hFile);
|
||||
return ret;
|
||||
}
|
||||
|
||||
|
|
|
@ -671,7 +671,7 @@ HMMIO MMIO_Open(LPSTR szFileName, MMIOINFO* refmminfo, DWORD dwOpenFlags,
|
|||
(LPARAM)szFileName, 0, MMIO_PROC_32A);
|
||||
|
||||
/* grab file size, when possible */
|
||||
wm->dwFileSize = GetFileSize(wm->info.adwInfo[0], NULL);
|
||||
wm->dwFileSize = GetFileSize((HANDLE)wm->info.adwInfo[0], NULL);
|
||||
|
||||
if (refmminfo->wErrorRet == 0)
|
||||
return wm->info.hmmio;
|
||||
|
@ -714,7 +714,7 @@ MMRESULT WINAPI mmioClose(HMMIO hmmio, UINT uFlags)
|
|||
LPWINE_MMIO wm;
|
||||
MMRESULT result;
|
||||
|
||||
TRACE("(%04X, %04X);\n", hmmio, uFlags);
|
||||
TRACE("(%p, %04X);\n", hmmio, uFlags);
|
||||
|
||||
if ((wm = MMIO_Get(hmmio)) == NULL)
|
||||
return MMSYSERR_INVALHANDLE;
|
||||
|
@ -746,7 +746,7 @@ LONG WINAPI mmioRead(HMMIO hmmio, HPSTR pch, LONG cch)
|
|||
LPWINE_MMIO wm;
|
||||
LONG count;
|
||||
|
||||
TRACE("(%04X, %p, %ld);\n", hmmio, pch, cch);
|
||||
TRACE("(%p, %p, %ld);\n", hmmio, pch, cch);
|
||||
|
||||
if ((wm = MMIO_Get(hmmio)) == NULL)
|
||||
return -1;
|
||||
|
@ -796,7 +796,7 @@ LONG WINAPI mmioWrite(HMMIO hmmio, HPCSTR pch, LONG cch)
|
|||
LPWINE_MMIO wm;
|
||||
LONG count;
|
||||
|
||||
TRACE("(%04X, %p, %ld);\n", hmmio, pch, cch);
|
||||
TRACE("(%p, %p, %ld);\n", hmmio, pch, cch);
|
||||
|
||||
if ((wm = MMIO_Get(hmmio)) == NULL)
|
||||
return -1;
|
||||
|
@ -851,7 +851,7 @@ LONG WINAPI mmioSeek(HMMIO hmmio, LONG lOffset, INT iOrigin)
|
|||
LPWINE_MMIO wm;
|
||||
LONG offset;
|
||||
|
||||
TRACE("(%04X, %08lX, %d);\n", hmmio, lOffset, iOrigin);
|
||||
TRACE("(%p, %08lX, %d);\n", hmmio, lOffset, iOrigin);
|
||||
|
||||
if ((wm = MMIO_Get(hmmio)) == NULL)
|
||||
return MMSYSERR_INVALHANDLE;
|
||||
|
@ -916,7 +916,7 @@ MMRESULT WINAPI mmioGetInfo(HMMIO hmmio, MMIOINFO* lpmmioinfo, UINT uFlags)
|
|||
{
|
||||
LPWINE_MMIO wm;
|
||||
|
||||
TRACE("(0x%04x,%p,0x%08x)\n",hmmio,lpmmioinfo,uFlags);
|
||||
TRACE("(%p,%p,0x%08x)\n",hmmio,lpmmioinfo,uFlags);
|
||||
|
||||
if ((wm = MMIO_Get(hmmio)) == NULL)
|
||||
return MMSYSERR_INVALHANDLE;
|
||||
|
@ -936,7 +936,7 @@ MMRESULT WINAPI mmioSetInfo(HMMIO hmmio, const MMIOINFO* lpmmioinfo, UINT uFlags
|
|||
{
|
||||
LPWINE_MMIO wm;
|
||||
|
||||
TRACE("(0x%04x,%p,0x%08x)\n",hmmio,lpmmioinfo,uFlags);
|
||||
TRACE("(%p,%p,0x%08x)\n",hmmio,lpmmioinfo,uFlags);
|
||||
|
||||
if ((wm = MMIO_Get(hmmio)) == NULL)
|
||||
return MMSYSERR_INVALHANDLE;
|
||||
|
@ -963,7 +963,7 @@ MMRESULT WINAPI mmioSetBuffer(HMMIO hmmio, LPSTR pchBuffer, LONG cchBuffer, UINT
|
|||
{
|
||||
LPWINE_MMIO wm;
|
||||
|
||||
TRACE("(hmmio=%04x, pchBuf=%p, cchBuf=%ld, uFlags=%#08x)\n",
|
||||
TRACE("(hmmio=%p, pchBuf=%p, cchBuf=%ld, uFlags=%#08x)\n",
|
||||
hmmio, pchBuffer, cchBuffer, uFlags);
|
||||
|
||||
if ((wm = MMIO_Get(hmmio)) == NULL)
|
||||
|
@ -979,7 +979,7 @@ MMRESULT WINAPI mmioFlush(HMMIO hmmio, UINT uFlags)
|
|||
{
|
||||
LPWINE_MMIO wm;
|
||||
|
||||
TRACE("(%04X, %04X)\n", hmmio, uFlags);
|
||||
TRACE("(%p, %04X)\n", hmmio, uFlags);
|
||||
|
||||
if ((wm = MMIO_Get(hmmio)) == NULL)
|
||||
return MMSYSERR_INVALHANDLE;
|
||||
|
@ -994,7 +994,7 @@ MMRESULT WINAPI mmioAdvance(HMMIO hmmio, MMIOINFO* lpmmioinfo, UINT uFlags)
|
|||
{
|
||||
LPWINE_MMIO wm;
|
||||
|
||||
TRACE("hmmio=%04X, lpmmioinfo=%p, uFlags=%04X\n", hmmio, lpmmioinfo, uFlags);
|
||||
TRACE("hmmio=%p, lpmmioinfo=%p, uFlags=%04X\n", hmmio, lpmmioinfo, uFlags);
|
||||
|
||||
/* NOTE: mmioAdvance16 heavily relies on parameters from lpmmioinfo we're using
|
||||
* here. be sure if you change something here to check mmioAdvance16 as well
|
||||
|
@ -1101,7 +1101,7 @@ LRESULT MMIO_SendMessage(HMMIO hmmio, UINT uMessage, LPARAM lParam1,
|
|||
{
|
||||
LPWINE_MMIO wm;
|
||||
|
||||
TRACE("(%04X, %u, %ld, %ld, %d)\n", hmmio, uMessage, lParam1, lParam2, type);
|
||||
TRACE("(%p, %u, %ld, %ld, %d)\n", hmmio, uMessage, lParam1, lParam2, type);
|
||||
|
||||
if (uMessage < MMIOM_USER)
|
||||
return MMSYSERR_INVALPARAM;
|
||||
|
@ -1132,7 +1132,7 @@ MMRESULT WINAPI mmioDescend(HMMIO hmmio, LPMMCKINFO lpck,
|
|||
FOURCC srchType;
|
||||
|
||||
|
||||
TRACE("(%04X, %p, %p, %04X);\n", hmmio, lpck, lpckParent, uFlags);
|
||||
TRACE("(%p, %p, %p, %04X);\n", hmmio, lpck, lpckParent, uFlags);
|
||||
|
||||
if (lpck == NULL)
|
||||
return MMSYSERR_INVALPARAM;
|
||||
|
@ -1230,7 +1230,7 @@ MMRESULT WINAPI mmioDescend(HMMIO hmmio, LPMMCKINFO lpck,
|
|||
*/
|
||||
MMRESULT WINAPI mmioAscend(HMMIO hmmio, LPMMCKINFO lpck, UINT uFlags)
|
||||
{
|
||||
TRACE("(%04X, %p, %04X);\n", hmmio, lpck, uFlags);
|
||||
TRACE("(%p, %p, %04X);\n", hmmio, lpck, uFlags);
|
||||
|
||||
if (lpck->dwFlags & MMIO_DIRTY) {
|
||||
DWORD dwOldPos, dwNewSize;
|
||||
|
@ -1268,7 +1268,7 @@ MMRESULT WINAPI mmioCreateChunk(HMMIO hmmio, MMCKINFO* lpck, UINT uFlags)
|
|||
LONG size;
|
||||
LONG ix;
|
||||
|
||||
TRACE("(%04X, %p, %04X);\n", hmmio, lpck, uFlags);
|
||||
TRACE("(%p, %p, %04X);\n", hmmio, lpck, uFlags);
|
||||
|
||||
dwOldPos = mmioSeek(hmmio, 0, SEEK_CUR);
|
||||
TRACE("dwOldPos=%ld\n", dwOldPos);
|
||||
|
|
|
@ -55,6 +55,9 @@ static LRESULT DRIVER_CloseDriver16(HDRVR16, LPARAM, LPARAM);
|
|||
static LRESULT DRIVER_SendMessage16(HDRVR16, UINT, LPARAM, LPARAM);
|
||||
static LRESULT MMIO_Callback16(SEGPTR, LPMMIOINFO, UINT, LPARAM, LPARAM);
|
||||
|
||||
#define HMODULE_32(h16) ((HMODULE)(ULONG_PTR)(h16))
|
||||
#define HINSTANCE_32(h16) ((HMODULE)(ULONG_PTR)(h16))
|
||||
|
||||
/* ###################################################
|
||||
* # LIBRARY #
|
||||
* ###################################################
|
||||
|
@ -69,7 +72,7 @@ static LRESULT MMIO_Callback16(SEGPTR, LPMMIOINFO, UINT, LPARAM, LPARAM
|
|||
BOOL WINAPI MMSYSTEM_LibMain(DWORD fdwReason, HINSTANCE hinstDLL, WORD ds,
|
||||
WORD wHeapSize, DWORD dwReserved1, WORD wReserved2)
|
||||
{
|
||||
TRACE("0x%x 0x%lx\n", hinstDLL, fdwReason);
|
||||
TRACE("%p 0x%lx\n", hinstDLL, fdwReason);
|
||||
|
||||
switch (fdwReason) {
|
||||
case DLL_PROCESS_ATTACH:
|
||||
|
@ -130,7 +133,7 @@ BOOL16 WINAPI PlaySound16(LPCSTR pszSound, HMODULE16 hmod, DWORD fdwSound)
|
|||
DWORD lc;
|
||||
|
||||
ReleaseThunkLock(&lc);
|
||||
retv = PlaySoundA(pszSound, hmod, fdwSound);
|
||||
retv = PlaySoundA(pszSound, HMODULE_32(hmod), fdwSound);
|
||||
RestoreThunkLock(lc);
|
||||
|
||||
return retv;
|
||||
|
@ -444,7 +447,7 @@ UINT16 WINAPI auxGetDevCaps16(UINT16 uDeviceID, LPAUXCAPS16 lpCaps, UINT16 uSize
|
|||
|
||||
TRACE("(%04X, %p, %d) !\n", uDeviceID, lpCaps, uSize);
|
||||
|
||||
if ((wmld = MMDRV_Get(uDeviceID, MMDRV_AUX, TRUE)) == NULL)
|
||||
if ((wmld = MMDRV_Get((HANDLE)(ULONG_PTR)uDeviceID, MMDRV_AUX, TRUE)) == NULL)
|
||||
return MMSYSERR_INVALHANDLE;
|
||||
return MMDRV_Message(wmld, AUXDM_GETDEVCAPS, (DWORD)lpCaps, uSize, TRUE);
|
||||
}
|
||||
|
@ -458,7 +461,7 @@ UINT16 WINAPI auxGetVolume16(UINT16 uDeviceID, LPDWORD lpdwVolume)
|
|||
|
||||
TRACE("(%04X, %p) !\n", uDeviceID, lpdwVolume);
|
||||
|
||||
if ((wmld = MMDRV_Get(uDeviceID, MMDRV_AUX, TRUE)) == NULL)
|
||||
if ((wmld = MMDRV_Get((HANDLE)(ULONG_PTR)uDeviceID, MMDRV_AUX, TRUE)) == NULL)
|
||||
return MMSYSERR_INVALHANDLE;
|
||||
return MMDRV_Message(wmld, AUXDM_GETVOLUME, (DWORD)lpdwVolume, 0L, TRUE);
|
||||
}
|
||||
|
@ -472,7 +475,7 @@ UINT16 WINAPI auxSetVolume16(UINT16 uDeviceID, DWORD dwVolume)
|
|||
|
||||
TRACE("(%04X, %lu) !\n", uDeviceID, dwVolume);
|
||||
|
||||
if ((wmld = MMDRV_Get(uDeviceID, MMDRV_AUX, TRUE)) == NULL)
|
||||
if ((wmld = MMDRV_Get((HANDLE)(ULONG_PTR)uDeviceID, MMDRV_AUX, TRUE)) == NULL)
|
||||
return MMSYSERR_INVALHANDLE;
|
||||
return MMDRV_Message(wmld, AUXDM_SETVOLUME, dwVolume, 0L, TRUE);
|
||||
}
|
||||
|
@ -500,7 +503,7 @@ DWORD WINAPI auxOutMessage16(UINT16 uDeviceID, UINT16 uMessage, DWORD dw1, DWORD
|
|||
uDeviceID, uMessage, dw1, dw2);
|
||||
break;
|
||||
}
|
||||
if ((wmld = MMDRV_Get(uDeviceID, MMDRV_AUX, TRUE)) == NULL)
|
||||
if ((wmld = MMDRV_Get((HANDLE)(ULONG_PTR)uDeviceID, MMDRV_AUX, TRUE)) == NULL)
|
||||
return MMSYSERR_INVALHANDLE;
|
||||
|
||||
return MMDRV_Message(wmld, uMessage, dw1, dw2, TRUE);
|
||||
|
@ -633,7 +636,8 @@ HTASK16 WINAPI mciGetCreatorTask16(UINT16 uDeviceID)
|
|||
LPWINE_MCIDRIVER wmd;
|
||||
HTASK16 ret = 0;
|
||||
|
||||
if ((wmd = MCI_GetDriver(uDeviceID))) ret = K32WOWHandle16(wmd->CreatorThread, WOW_TYPE_HTASK);
|
||||
if ((wmd = MCI_GetDriver(uDeviceID)))
|
||||
ret = HTASK_16(wmd->CreatorThread);
|
||||
|
||||
TRACE("(%u) => %04x\n", uDeviceID, ret);
|
||||
return ret;
|
||||
|
@ -1214,7 +1218,7 @@ UINT16 WINAPI waveOutOpen16(HWAVEOUT16* lphWaveOut, UINT16 uDeviceID,
|
|||
const LPWAVEFORMATEX lpFormat, DWORD dwCallback,
|
||||
DWORD dwInstance, DWORD dwFlags)
|
||||
{
|
||||
HWAVEOUT hWaveOut;
|
||||
HANDLE hWaveOut;
|
||||
UINT ret;
|
||||
|
||||
/* since layout of WAVEFORMATEX is the same for 16/32 bits, we directly
|
||||
|
@ -1508,7 +1512,7 @@ UINT16 WINAPI waveInOpen16(HWAVEIN16* lphWaveIn, UINT16 uDeviceID,
|
|||
const LPWAVEFORMATEX lpFormat, DWORD dwCallback,
|
||||
DWORD dwInstance, DWORD dwFlags)
|
||||
{
|
||||
HWAVEIN hWaveIn;
|
||||
HANDLE hWaveIn;
|
||||
UINT ret;
|
||||
|
||||
/* since layout of WAVEFORMATEX is the same for 16/32 bits, we directly
|
||||
|
@ -1856,7 +1860,7 @@ void WINAPI WINE_mmThreadEntryPoint(DWORD);
|
|||
* bit.0 set means create a 16 bit task instead of thread calling a 16 bit proc
|
||||
* bit.1 set means to open a VxD for this thread (unsupported)
|
||||
*/
|
||||
LRESULT WINAPI mmThreadCreate16(FARPROC16 fpThreadAddr, LPHANDLE lpHndl, DWORD dwPmt, DWORD dwFlags)
|
||||
LRESULT WINAPI mmThreadCreate16(FARPROC16 fpThreadAddr, LPHANDLE16 lpHndl, DWORD dwPmt, DWORD dwFlags)
|
||||
{
|
||||
HANDLE16 hndl;
|
||||
LRESULT ret;
|
||||
|
@ -1912,7 +1916,7 @@ LRESULT WINAPI mmThreadCreate16(FARPROC16 fpThreadAddr, LPHANDLE lpHndl, DWORD d
|
|||
CloseHandle(lpMMThd->hEvent);
|
||||
ret = 2;
|
||||
} else {
|
||||
TRACE("Got a nice thread hndl=0x%04x id=0x%08lx\n", lpMMThd->hThread, lpMMThd->dwThreadID);
|
||||
TRACE("Got a nice thread hndl=%p id=0x%08lx\n", lpMMThd->hThread, lpMMThd->dwThreadID);
|
||||
ret = 0;
|
||||
}
|
||||
} else {
|
||||
|
@ -2103,21 +2107,21 @@ void WINAPI WINE_mmThreadEntryPoint(DWORD _pmt)
|
|||
TRACE("(%04x %p)\n", hndl, lpMMThd);
|
||||
|
||||
lpMMThd->hTask = LOWORD(GetCurrentTask());
|
||||
TRACE("[10-%08x] setting hTask to 0x%08x\n", lpMMThd->hThread, lpMMThd->hTask);
|
||||
TRACE("[10-%p] setting hTask to 0x%08x\n", lpMMThd->hThread, lpMMThd->hTask);
|
||||
lpMMThd->dwStatus = 0x10;
|
||||
MMSYSTEM_ThreadBlock(lpMMThd);
|
||||
TRACE("[20-%08x]\n", lpMMThd->hThread);
|
||||
TRACE("[20-%p]\n", lpMMThd->hThread);
|
||||
lpMMThd->dwStatus = 0x20;
|
||||
if (lpMMThd->fpThread) {
|
||||
MMSYSTEM_CallTo16_long_l(lpMMThd->fpThread, lpMMThd->dwThreadPmt);
|
||||
}
|
||||
lpMMThd->dwStatus = 0x30;
|
||||
TRACE("[30-%08x]\n", lpMMThd->hThread);
|
||||
TRACE("[30-%p]\n", lpMMThd->hThread);
|
||||
while (lpMMThd->dwCounter) {
|
||||
Sleep(1);
|
||||
/* K32WOWYield16();*/
|
||||
}
|
||||
TRACE("[XX-%08x]\n", lpMMThd->hThread);
|
||||
TRACE("[XX-%p]\n", lpMMThd->hThread);
|
||||
/* paranoia */
|
||||
lpMMThd->dwSignature = WINE_MMTHREAD_DELETED;
|
||||
/* close lpMMThread->hVxD directIO */
|
||||
|
@ -2138,7 +2142,7 @@ BOOL16 WINAPI mmShowMMCPLPropertySheet16(HWND hWnd, LPCSTR lpStrDevice,
|
|||
HANDLE hndl;
|
||||
BOOL16 ret = FALSE;
|
||||
|
||||
TRACE("(%04x \"%s\" \"%s\" \"%s\")\n", hWnd, lpStrDevice, lpStrTab, lpStrTitle);
|
||||
TRACE("(%p \"%s\" \"%s\" \"%s\")\n", hWnd, lpStrDevice, lpStrTab, lpStrTitle);
|
||||
|
||||
hndl = LoadLibraryA("MMSYS.CPL");
|
||||
if (hndl != 0) {
|
||||
|
@ -2546,10 +2550,10 @@ DWORD WINAPI mciSendString16(LPCSTR lpstrCommand, LPSTR lpstrRet,
|
|||
/**************************************************************************
|
||||
* mciLoadCommandResource [MMSYSTEM.705]
|
||||
*/
|
||||
UINT16 WINAPI mciLoadCommandResource16(HANDLE16 hInst, LPCSTR resname, UINT16 type)
|
||||
UINT16 WINAPI mciLoadCommandResource16(HINSTANCE16 hInst, LPCSTR resname, UINT16 type)
|
||||
{
|
||||
LPCWSTR ptr = HEAP_strdupAtoW(GetProcessHeap(), 0, resname);
|
||||
UINT ret = mciLoadCommandResource(hInst, ptr, type);
|
||||
UINT ret = mciLoadCommandResource(HINSTANCE_32(hInst), ptr, type);
|
||||
HeapFree(GetProcessHeap(), 0, (LPWSTR)ptr);
|
||||
return ret;
|
||||
}
|
||||
|
@ -2697,7 +2701,7 @@ HMMIO16 WINAPI mmioOpen16(LPSTR szFileName, MMIOINFO16* lpmmioinfo16,
|
|||
mmioinfo.adwInfo[0] = lpmmioinfo16->adwInfo[0];
|
||||
/* if we don't have a file name, it's likely a passed open file descriptor */
|
||||
if (!szFileName)
|
||||
mmioinfo.adwInfo[0] = DosFileHandleToWin32Handle(mmioinfo.adwInfo[0]);
|
||||
mmioinfo.adwInfo[0] = (DWORD)DosFileHandleToWin32Handle(mmioinfo.adwInfo[0]);
|
||||
mmioinfo.adwInfo[1] = lpmmioinfo16->adwInfo[1];
|
||||
mmioinfo.adwInfo[2] = lpmmioinfo16->adwInfo[2];
|
||||
mmioinfo.adwInfo[3] = lpmmioinfo16->adwInfo[3];
|
||||
|
@ -2756,7 +2760,7 @@ MMRESULT16 WINAPI mmioGetInfo16(HMMIO16 hmmio, MMIOINFO16* lpmmioinfo, UINT16 uF
|
|||
|
||||
TRACE("(0x%04x,%p,0x%08x)\n", hmmio, lpmmioinfo, uFlags);
|
||||
|
||||
if ((wm = MMIO_Get(hmmio)) == NULL)
|
||||
if ((wm = MMIO_Get(HMMIO_32(hmmio))) == NULL)
|
||||
return MMSYSERR_INVALHANDLE;
|
||||
|
||||
ret = mmioGetInfo(HMMIO_32(hmmio), &mmioinfo, uFlags);
|
||||
|
@ -2767,7 +2771,7 @@ MMRESULT16 WINAPI mmioGetInfo16(HMMIO16 hmmio, MMIOINFO16* lpmmioinfo, UINT16 uF
|
|||
lpmmioinfo->pIOProc = (wm->ioProc->type == MMIO_PROC_16) ?
|
||||
(LPMMIOPROC16)wm->ioProc->pIOProc : NULL;
|
||||
lpmmioinfo->wErrorRet = mmioinfo.wErrorRet;
|
||||
lpmmioinfo->hTask = mmioinfo.hTask;
|
||||
lpmmioinfo->hTask = HTASK_16(mmioinfo.hTask);
|
||||
lpmmioinfo->cchBuffer = mmioinfo.cchBuffer;
|
||||
lpmmioinfo->pchBuffer = (void*)wm->segBuffer16;
|
||||
lpmmioinfo->pchNext = (void*)(wm->segBuffer16 + (mmioinfo.pchNext - mmioinfo.pchBuffer));
|
||||
|
|
|
@ -409,7 +409,7 @@ BOOL MULTIMEDIA_PlaySound(const void* pszSound, HMODULE hmod, DWORD fdwSound, BO
|
|||
{
|
||||
WINE_PLAYSOUND* wps = NULL;
|
||||
|
||||
TRACE("pszSound='%p' hmod=%04X fdwSound=%08lX\n",
|
||||
TRACE("pszSound='%p' hmod=%p fdwSound=%08lX\n",
|
||||
pszSound, hmod, fdwSound);
|
||||
|
||||
/* FIXME? I see no difference between SND_NOWAIT and SND_NOSTOP !
|
||||
|
|
|
@ -200,7 +200,6 @@ typedef struct tagWINE_MM_IDATA {
|
|||
/* winmm part */
|
||||
HANDLE hWinMM32Instance;
|
||||
HANDLE hWinMM16Instance;
|
||||
HANDLE h16Module32;
|
||||
CRITICAL_SECTION cs;
|
||||
/* mm timer part */
|
||||
HANDLE hMMTimer;
|
||||
|
|
|
@ -115,7 +115,7 @@ BOOL WINMM_CheckForMMSystem(void)
|
|||
*/
|
||||
BOOL WINAPI WINMM_LibMain(HINSTANCE hInstDLL, DWORD fdwReason, LPVOID fImpLoad)
|
||||
{
|
||||
TRACE("0x%x 0x%lx %p\n", hInstDLL, fdwReason, fImpLoad);
|
||||
TRACE("%p 0x%lx %p\n", hInstDLL, fdwReason, fImpLoad);
|
||||
|
||||
switch (fdwReason) {
|
||||
case DLL_PROCESS_ATTACH:
|
||||
|
@ -203,7 +203,7 @@ UINT WINAPI mixerGetDevCapsA(UINT devid, LPMIXERCAPSA mixcaps, UINT size)
|
|||
{
|
||||
LPWINE_MLD wmld;
|
||||
|
||||
if ((wmld = MMDRV_Get(devid, MMDRV_MIXER, TRUE)) == NULL)
|
||||
if ((wmld = MMDRV_Get((HANDLE)devid, MMDRV_MIXER, TRUE)) == NULL)
|
||||
return MMSYSERR_BADDEVICEID;
|
||||
|
||||
return MMDRV_Message(wmld, MXDM_GETDEVCAPS, (DWORD)mixcaps, size, TRUE);
|
||||
|
@ -232,7 +232,7 @@ UINT WINAPI mixerGetDevCapsW(UINT devid, LPMIXERCAPSW mixcaps, UINT size)
|
|||
UINT MIXER_Open(LPHMIXER lphMix, UINT uDeviceID, DWORD dwCallback,
|
||||
DWORD dwInstance, DWORD fdwOpen, BOOL bFrom32)
|
||||
{
|
||||
HMIXER hMix;
|
||||
HANDLE hMix;
|
||||
LPWINE_MLD wmld;
|
||||
DWORD dwRet = 0;
|
||||
MIXEROPENDESC mod;
|
||||
|
@ -255,7 +255,7 @@ UINT MIXER_Open(LPHMIXER lphMix, UINT uDeviceID, DWORD dwCallback,
|
|||
hMix = 0;
|
||||
}
|
||||
if (lphMix) *lphMix = hMix;
|
||||
TRACE("=> %ld hMixer=%04x\n", dwRet, hMix);
|
||||
TRACE("=> %ld hMixer=%p\n", dwRet, hMix);
|
||||
|
||||
return dwRet;
|
||||
}
|
||||
|
@ -277,7 +277,7 @@ UINT WINAPI mixerClose(HMIXER hMix)
|
|||
LPWINE_MLD wmld;
|
||||
DWORD dwRet;
|
||||
|
||||
TRACE("(%04x)\n", hMix);
|
||||
TRACE("(%p)\n", hMix);
|
||||
|
||||
if ((wmld = MMDRV_Get(hMix, MMDRV_MIXER, FALSE)) == NULL) return MMSYSERR_INVALHANDLE;
|
||||
|
||||
|
@ -294,7 +294,7 @@ UINT WINAPI mixerGetID(HMIXEROBJ hmix, LPUINT lpid, DWORD fdwID)
|
|||
{
|
||||
LPWINE_MIXER lpwm;
|
||||
|
||||
TRACE("(%04x %p %08lx)\n", hmix, lpid, fdwID);
|
||||
TRACE("(%p %p %08lx)\n", hmix, lpid, fdwID);
|
||||
|
||||
if ((lpwm = MIXER_GetDev(hmix, fdwID)) == NULL) {
|
||||
return MMSYSERR_INVALHANDLE;
|
||||
|
@ -314,7 +314,7 @@ UINT WINAPI mixerGetControlDetailsA(HMIXEROBJ hmix, LPMIXERCONTROLDETAILS lpmcdA
|
|||
{
|
||||
LPWINE_MIXER lpwm;
|
||||
|
||||
TRACE("(%04x, %p, %08lx)\n", hmix, lpmcdA, fdwDetails);
|
||||
TRACE("(%p, %p, %08lx)\n", hmix, lpmcdA, fdwDetails);
|
||||
|
||||
if ((lpwm = MIXER_GetDev(hmix, fdwDetails)) == NULL)
|
||||
return MMSYSERR_INVALHANDLE;
|
||||
|
@ -333,7 +333,7 @@ UINT WINAPI mixerGetControlDetailsW(HMIXEROBJ hmix, LPMIXERCONTROLDETAILS lpmcd,
|
|||
{
|
||||
DWORD ret = MMSYSERR_NOTENABLED;
|
||||
|
||||
TRACE("(%04x, %p, %08lx)\n", hmix, lpmcd, fdwDetails);
|
||||
TRACE("(%p, %p, %08lx)\n", hmix, lpmcd, fdwDetails);
|
||||
|
||||
if (lpmcd == NULL || lpmcd->cbStruct != sizeof(*lpmcd))
|
||||
return MMSYSERR_INVALPARAM;
|
||||
|
@ -392,7 +392,7 @@ UINT WINAPI mixerGetLineControlsA(HMIXEROBJ hmix, LPMIXERLINECONTROLSA lpmlcA,
|
|||
{
|
||||
LPWINE_MIXER lpwm;
|
||||
|
||||
TRACE("(%04x, %p, %08lx)\n", hmix, lpmlcA, fdwControls);
|
||||
TRACE("(%p, %p, %08lx)\n", hmix, lpmlcA, fdwControls);
|
||||
|
||||
if ((lpwm = MIXER_GetDev(hmix, fdwControls)) == NULL)
|
||||
return MMSYSERR_INVALHANDLE;
|
||||
|
@ -414,7 +414,7 @@ UINT WINAPI mixerGetLineControlsW(HMIXEROBJ hmix, LPMIXERLINECONTROLSW lpmlcW,
|
|||
DWORD ret;
|
||||
int i;
|
||||
|
||||
TRACE("(%04x, %p, %08lx)\n", hmix, lpmlcW, fdwControls);
|
||||
TRACE("(%p, %p, %08lx)\n", hmix, lpmlcW, fdwControls);
|
||||
|
||||
if (lpmlcW == NULL || lpmlcW->cbStruct != sizeof(*lpmlcW) ||
|
||||
lpmlcW->cbmxctrl != sizeof(MIXERCONTROLW))
|
||||
|
@ -472,7 +472,7 @@ UINT WINAPI mixerGetLineInfoA(HMIXEROBJ hmix, LPMIXERLINEA lpmliW, DWORD fdwInfo
|
|||
{
|
||||
LPWINE_MIXER lpwm;
|
||||
|
||||
TRACE("(%04x, %p, %08lx)\n", hmix, lpmliW, fdwInfo);
|
||||
TRACE("(%p, %p, %08lx)\n", hmix, lpmliW, fdwInfo);
|
||||
|
||||
if ((lpwm = MIXER_GetDev(hmix, fdwInfo)) == NULL)
|
||||
return MMSYSERR_INVALHANDLE;
|
||||
|
@ -490,7 +490,7 @@ UINT WINAPI mixerGetLineInfoW(HMIXEROBJ hmix, LPMIXERLINEW lpmliW,
|
|||
MIXERLINEA mliA;
|
||||
UINT ret;
|
||||
|
||||
TRACE("(%04x, %p, %08lx)\n", hmix, lpmliW, fdwInfo);
|
||||
TRACE("(%p, %p, %08lx)\n", hmix, lpmliW, fdwInfo);
|
||||
|
||||
if (lpmliW == NULL || lpmliW->cbStruct != sizeof(*lpmliW))
|
||||
return MMSYSERR_INVALPARAM;
|
||||
|
@ -555,7 +555,7 @@ UINT WINAPI mixerSetControlDetails(HMIXEROBJ hmix, LPMIXERCONTROLDETAILS lpmcdA,
|
|||
{
|
||||
LPWINE_MIXER lpwm;
|
||||
|
||||
TRACE("(%04x, %p, %08lx)\n", hmix, lpmcdA, fdwDetails);
|
||||
TRACE("(%p, %p, %08lx)\n", hmix, lpmcdA, fdwDetails);
|
||||
|
||||
if ((lpwm = MIXER_GetDev(hmix, fdwDetails)) == NULL)
|
||||
return MMSYSERR_INVALHANDLE;
|
||||
|
@ -615,7 +615,7 @@ UINT WINAPI auxGetDevCapsA(UINT uDeviceID, LPAUXCAPSA lpCaps, UINT uSize)
|
|||
|
||||
TRACE("(%04X, %p, %d) !\n", uDeviceID, lpCaps, uSize);
|
||||
|
||||
if ((wmld = MMDRV_Get(uDeviceID, MMDRV_AUX, TRUE)) == NULL)
|
||||
if ((wmld = MMDRV_Get((HANDLE)uDeviceID, MMDRV_AUX, TRUE)) == NULL)
|
||||
return MMSYSERR_INVALHANDLE;
|
||||
return MMDRV_Message(wmld, AUXDM_GETDEVCAPS, (DWORD)lpCaps, uSize, TRUE);
|
||||
}
|
||||
|
@ -629,7 +629,7 @@ UINT WINAPI auxGetVolume(UINT uDeviceID, DWORD* lpdwVolume)
|
|||
|
||||
TRACE("(%04X, %p) !\n", uDeviceID, lpdwVolume);
|
||||
|
||||
if ((wmld = MMDRV_Get(uDeviceID, MMDRV_AUX, TRUE)) == NULL)
|
||||
if ((wmld = MMDRV_Get((HANDLE)uDeviceID, MMDRV_AUX, TRUE)) == NULL)
|
||||
return MMSYSERR_INVALHANDLE;
|
||||
return MMDRV_Message(wmld, AUXDM_GETVOLUME, (DWORD)lpdwVolume, 0L, TRUE);
|
||||
}
|
||||
|
@ -643,7 +643,7 @@ UINT WINAPI auxSetVolume(UINT uDeviceID, DWORD dwVolume)
|
|||
|
||||
TRACE("(%04X, %lu) !\n", uDeviceID, dwVolume);
|
||||
|
||||
if ((wmld = MMDRV_Get(uDeviceID, MMDRV_AUX, TRUE)) == NULL)
|
||||
if ((wmld = MMDRV_Get((HANDLE)uDeviceID, MMDRV_AUX, TRUE)) == NULL)
|
||||
return MMSYSERR_INVALHANDLE;
|
||||
return MMDRV_Message(wmld, AUXDM_SETVOLUME, dwVolume, 0L, TRUE);
|
||||
}
|
||||
|
@ -655,7 +655,7 @@ DWORD WINAPI auxOutMessage(UINT uDeviceID, UINT uMessage, DWORD dw1, DWORD dw2)
|
|||
{
|
||||
LPWINE_MLD wmld;
|
||||
|
||||
if ((wmld = MMDRV_Get(uDeviceID, MMDRV_AUX, TRUE)) == NULL)
|
||||
if ((wmld = MMDRV_Get((HANDLE)uDeviceID, MMDRV_AUX, TRUE)) == NULL)
|
||||
return MMSYSERR_INVALHANDLE;
|
||||
|
||||
return MMDRV_Message(wmld, uMessage, dw1, dw2, TRUE);
|
||||
|
@ -698,7 +698,7 @@ BOOL WINAPI mciGetErrorStringA(DWORD dwError, LPSTR lpstrBuffer, UINT uLength)
|
|||
BOOL WINAPI mciDriverNotify(HWND hWndCallBack, UINT wDevID, UINT wStatus)
|
||||
{
|
||||
|
||||
TRACE("(%08X, %04x, %04X)\n", hWndCallBack, wDevID, wStatus);
|
||||
TRACE("(%p, %04x, %04X)\n", hWndCallBack, wDevID, wStatus);
|
||||
|
||||
return PostMessageA(hWndCallBack, MM_MCINOTIFY, wStatus, wDevID);
|
||||
}
|
||||
|
@ -880,7 +880,7 @@ HTASK WINAPI mciGetCreatorTask(UINT uDeviceID)
|
|||
|
||||
if ((wmd = MCI_GetDriver(uDeviceID))) ret = (HTASK)wmd->CreatorThread;
|
||||
|
||||
TRACE("(%u) => %08x\n", uDeviceID, ret);
|
||||
TRACE("(%u) => %p\n", uDeviceID, ret);
|
||||
return ret;
|
||||
}
|
||||
|
||||
|
@ -946,7 +946,7 @@ UINT WINAPI midiOutGetDevCapsA(UINT uDeviceID, LPMIDIOUTCAPSA lpCaps,
|
|||
|
||||
if (lpCaps == NULL) return MMSYSERR_INVALPARAM;
|
||||
|
||||
if ((wmld = MMDRV_Get(uDeviceID, MMDRV_MIDIOUT, TRUE)) == NULL)
|
||||
if ((wmld = MMDRV_Get((HANDLE)uDeviceID, MMDRV_MIDIOUT, TRUE)) == NULL)
|
||||
return MMSYSERR_INVALHANDLE;
|
||||
|
||||
return MMDRV_Message(wmld, MODM_GETDEVCAPS, (DWORD)lpCaps, uSize, TRUE);
|
||||
|
@ -1006,7 +1006,7 @@ static LPWINE_MIDI MIDI_OutAlloc(HMIDIOUT* lphMidiOut, LPDWORD lpdwCallback,
|
|||
LPDWORD lpdwInstance, LPDWORD lpdwFlags,
|
||||
DWORD cIDs, MIDIOPENSTRMID* lpIDs, BOOL bFrom32)
|
||||
{
|
||||
HMIDIOUT hMidiOut;
|
||||
HANDLE hMidiOut;
|
||||
LPWINE_MIDI lpwm;
|
||||
UINT size;
|
||||
|
||||
|
@ -1058,7 +1058,7 @@ UINT MIDI_OutOpen(HMIDIOUT* lphMidiOut, UINT uDeviceID, DWORD dwCallback,
|
|||
}
|
||||
|
||||
if (lphMidiOut) *lphMidiOut = hMidiOut;
|
||||
TRACE("=> %d hMidi=%04x\n", dwRet, hMidiOut);
|
||||
TRACE("=> %d hMidi=%p\n", dwRet, hMidiOut);
|
||||
|
||||
return dwRet;
|
||||
}
|
||||
|
@ -1080,7 +1080,7 @@ UINT WINAPI midiOutClose(HMIDIOUT hMidiOut)
|
|||
LPWINE_MLD wmld;
|
||||
DWORD dwRet;
|
||||
|
||||
TRACE("(%04X)\n", hMidiOut);
|
||||
TRACE("(%p)\n", hMidiOut);
|
||||
|
||||
if ((wmld = MMDRV_Get(hMidiOut, MMDRV_MIDIOUT, FALSE)) == NULL)
|
||||
return MMSYSERR_INVALHANDLE;
|
||||
|
@ -1099,7 +1099,7 @@ UINT WINAPI midiOutPrepareHeader(HMIDIOUT hMidiOut,
|
|||
{
|
||||
LPWINE_MLD wmld;
|
||||
|
||||
TRACE("(%04X, %p, %d)\n", hMidiOut, lpMidiOutHdr, uSize);
|
||||
TRACE("(%p, %p, %d)\n", hMidiOut, lpMidiOutHdr, uSize);
|
||||
|
||||
if ((wmld = MMDRV_Get(hMidiOut, MMDRV_MIDIOUT, FALSE)) == NULL)
|
||||
return MMSYSERR_INVALHANDLE;
|
||||
|
@ -1115,7 +1115,7 @@ UINT WINAPI midiOutUnprepareHeader(HMIDIOUT hMidiOut,
|
|||
{
|
||||
LPWINE_MLD wmld;
|
||||
|
||||
TRACE("(%04X, %p, %d)\n", hMidiOut, lpMidiOutHdr, uSize);
|
||||
TRACE("(%p, %p, %d)\n", hMidiOut, lpMidiOutHdr, uSize);
|
||||
|
||||
if (!(lpMidiOutHdr->dwFlags & MHDR_PREPARED)) {
|
||||
return MMSYSERR_NOERROR;
|
||||
|
@ -1134,7 +1134,7 @@ UINT WINAPI midiOutShortMsg(HMIDIOUT hMidiOut, DWORD dwMsg)
|
|||
{
|
||||
LPWINE_MLD wmld;
|
||||
|
||||
TRACE("(%04X, %08lX)\n", hMidiOut, dwMsg);
|
||||
TRACE("(%p, %08lX)\n", hMidiOut, dwMsg);
|
||||
|
||||
if ((wmld = MMDRV_Get(hMidiOut, MMDRV_MIDIOUT, FALSE)) == NULL)
|
||||
return MMSYSERR_INVALHANDLE;
|
||||
|
@ -1150,7 +1150,7 @@ UINT WINAPI midiOutLongMsg(HMIDIOUT hMidiOut,
|
|||
{
|
||||
LPWINE_MLD wmld;
|
||||
|
||||
TRACE("(%04X, %p, %d)\n", hMidiOut, lpMidiOutHdr, uSize);
|
||||
TRACE("(%p, %p, %d)\n", hMidiOut, lpMidiOutHdr, uSize);
|
||||
|
||||
if ((wmld = MMDRV_Get(hMidiOut, MMDRV_MIDIOUT, FALSE)) == NULL)
|
||||
return MMSYSERR_INVALHANDLE;
|
||||
|
@ -1165,7 +1165,7 @@ UINT WINAPI midiOutReset(HMIDIOUT hMidiOut)
|
|||
{
|
||||
LPWINE_MLD wmld;
|
||||
|
||||
TRACE("(%04X)\n", hMidiOut);
|
||||
TRACE("(%p)\n", hMidiOut);
|
||||
|
||||
if ((wmld = MMDRV_Get(hMidiOut, MMDRV_MIDIOUT, FALSE)) == NULL)
|
||||
return MMSYSERR_INVALHANDLE;
|
||||
|
@ -1182,7 +1182,7 @@ UINT WINAPI midiOutGetVolume(UINT uDeviceID, DWORD* lpdwVolume)
|
|||
|
||||
TRACE("(%04X, %p);\n", uDeviceID, lpdwVolume);
|
||||
|
||||
if ((wmld = MMDRV_Get(uDeviceID, MMDRV_MIDIOUT, TRUE)) == NULL)
|
||||
if ((wmld = MMDRV_Get((HANDLE)uDeviceID, MMDRV_MIDIOUT, TRUE)) == NULL)
|
||||
return MMSYSERR_INVALHANDLE;
|
||||
|
||||
return MMDRV_Message(wmld, MODM_GETVOLUME, (DWORD)lpdwVolume, 0L, TRUE);
|
||||
|
@ -1197,7 +1197,7 @@ UINT WINAPI midiOutSetVolume(UINT uDeviceID, DWORD dwVolume)
|
|||
|
||||
TRACE("(%04X, %ld);\n", uDeviceID, dwVolume);
|
||||
|
||||
if ((wmld = MMDRV_Get(uDeviceID, MMDRV_MIDIOUT, TRUE)) == NULL)
|
||||
if ((wmld = MMDRV_Get((HANDLE)uDeviceID, MMDRV_MIDIOUT, TRUE)) == NULL)
|
||||
return MMSYSERR_INVALHANDLE;
|
||||
|
||||
return MMDRV_Message(wmld, MODM_SETVOLUME, dwVolume, 0L, TRUE);
|
||||
|
@ -1231,7 +1231,7 @@ UINT WINAPI midiOutGetID(HMIDIOUT hMidiOut, UINT* lpuDeviceID)
|
|||
{
|
||||
LPWINE_MLD wmld;
|
||||
|
||||
TRACE("(%04X, %p)\n", hMidiOut, lpuDeviceID);
|
||||
TRACE("(%p, %p)\n", hMidiOut, lpuDeviceID);
|
||||
|
||||
if (lpuDeviceID == NULL) return MMSYSERR_INVALPARAM;
|
||||
if ((wmld = MMDRV_Get(hMidiOut, MMDRV_MIDIOUT, FALSE)) == NULL)
|
||||
|
@ -1249,7 +1249,7 @@ DWORD WINAPI midiOutMessage(HMIDIOUT hMidiOut, UINT uMessage,
|
|||
{
|
||||
LPWINE_MLD wmld;
|
||||
|
||||
TRACE("(%04X, %04X, %08lX, %08lX)\n", hMidiOut, uMessage, dwParam1, dwParam2);
|
||||
TRACE("(%p, %04X, %08lX, %08lX)\n", hMidiOut, uMessage, dwParam1, dwParam2);
|
||||
|
||||
if ((wmld = MMDRV_Get(hMidiOut, MMDRV_MIDIOUT, FALSE)) == NULL) {
|
||||
/* HACK... */
|
||||
|
@ -1308,7 +1308,7 @@ UINT WINAPI midiInGetDevCapsA(UINT uDeviceID, LPMIDIINCAPSA lpCaps, UINT uSize)
|
|||
|
||||
TRACE("(%d, %p, %d);\n", uDeviceID, lpCaps, uSize);
|
||||
|
||||
if ((wmld = MMDRV_Get(uDeviceID, MMDRV_MIDIIN, TRUE)) == NULL)
|
||||
if ((wmld = MMDRV_Get((HANDLE)uDeviceID, MMDRV_MIDIIN, TRUE)) == NULL)
|
||||
return MMSYSERR_INVALHANDLE;
|
||||
|
||||
return MMDRV_Message(wmld, MIDM_GETDEVCAPS, (DWORD)lpCaps, uSize, TRUE);
|
||||
|
@ -1338,7 +1338,7 @@ UINT WINAPI midiInGetErrorTextA(UINT uError, LPSTR lpText, UINT uSize)
|
|||
UINT MIDI_InOpen(HMIDIIN* lphMidiIn, UINT uDeviceID, DWORD dwCallback,
|
||||
DWORD dwInstance, DWORD dwFlags, BOOL bFrom32)
|
||||
{
|
||||
HMIDIIN hMidiIn;
|
||||
HANDLE hMidiIn;
|
||||
LPWINE_MIDI lpwm;
|
||||
DWORD dwRet = 0;
|
||||
|
||||
|
@ -1365,7 +1365,7 @@ UINT MIDI_InOpen(HMIDIIN* lphMidiIn, UINT uDeviceID, DWORD dwCallback,
|
|||
hMidiIn = 0;
|
||||
}
|
||||
if (lphMidiIn != NULL) *lphMidiIn = hMidiIn;
|
||||
TRACE("=> %ld hMidi=%04x\n", dwRet, hMidiIn);
|
||||
TRACE("=> %ld hMidi=%p\n", dwRet, hMidiIn);
|
||||
|
||||
return dwRet;
|
||||
}
|
||||
|
@ -1387,7 +1387,7 @@ UINT WINAPI midiInClose(HMIDIIN hMidiIn)
|
|||
LPWINE_MLD wmld;
|
||||
DWORD dwRet;
|
||||
|
||||
TRACE("(%04X)\n", hMidiIn);
|
||||
TRACE("(%p)\n", hMidiIn);
|
||||
|
||||
if ((wmld = MMDRV_Get(hMidiIn, MMDRV_MIDIIN, FALSE)) == NULL)
|
||||
return MMSYSERR_INVALHANDLE;
|
||||
|
@ -1405,7 +1405,7 @@ UINT WINAPI midiInPrepareHeader(HMIDIIN hMidiIn,
|
|||
{
|
||||
LPWINE_MLD wmld;
|
||||
|
||||
TRACE("(%04X, %p, %d)\n", hMidiIn, lpMidiInHdr, uSize);
|
||||
TRACE("(%p, %p, %d)\n", hMidiIn, lpMidiInHdr, uSize);
|
||||
|
||||
if ((wmld = MMDRV_Get(hMidiIn, MMDRV_MIDIIN, FALSE)) == NULL)
|
||||
return MMSYSERR_INVALHANDLE;
|
||||
|
@ -1421,7 +1421,7 @@ UINT WINAPI midiInUnprepareHeader(HMIDIIN hMidiIn,
|
|||
{
|
||||
LPWINE_MLD wmld;
|
||||
|
||||
TRACE("(%04X, %p, %d)\n", hMidiIn, lpMidiInHdr, uSize);
|
||||
TRACE("(%p, %p, %d)\n", hMidiIn, lpMidiInHdr, uSize);
|
||||
|
||||
if (!(lpMidiInHdr->dwFlags & MHDR_PREPARED)) {
|
||||
return MMSYSERR_NOERROR;
|
||||
|
@ -1441,7 +1441,7 @@ UINT WINAPI midiInAddBuffer(HMIDIIN hMidiIn,
|
|||
{
|
||||
LPWINE_MLD wmld;
|
||||
|
||||
TRACE("(%04X, %p, %d)\n", hMidiIn, lpMidiInHdr, uSize);
|
||||
TRACE("(%p, %p, %d)\n", hMidiIn, lpMidiInHdr, uSize);
|
||||
|
||||
if ((wmld = MMDRV_Get(hMidiIn, MMDRV_MIDIIN, FALSE)) == NULL)
|
||||
return MMSYSERR_INVALHANDLE;
|
||||
|
@ -1456,7 +1456,7 @@ UINT WINAPI midiInStart(HMIDIIN hMidiIn)
|
|||
{
|
||||
LPWINE_MLD wmld;
|
||||
|
||||
TRACE("(%04X)\n", hMidiIn);
|
||||
TRACE("(%p)\n", hMidiIn);
|
||||
|
||||
if ((wmld = MMDRV_Get(hMidiIn, MMDRV_MIDIIN, FALSE)) == NULL)
|
||||
return MMSYSERR_INVALHANDLE;
|
||||
|
@ -1471,7 +1471,7 @@ UINT WINAPI midiInStop(HMIDIIN hMidiIn)
|
|||
{
|
||||
LPWINE_MLD wmld;
|
||||
|
||||
TRACE("(%04X)\n", hMidiIn);
|
||||
TRACE("(%p)\n", hMidiIn);
|
||||
|
||||
if ((wmld = MMDRV_Get(hMidiIn, MMDRV_MIDIIN, FALSE)) == NULL)
|
||||
return MMSYSERR_INVALHANDLE;
|
||||
|
@ -1486,7 +1486,7 @@ UINT WINAPI midiInReset(HMIDIIN hMidiIn)
|
|||
{
|
||||
LPWINE_MLD wmld;
|
||||
|
||||
TRACE("(%04X)\n", hMidiIn);
|
||||
TRACE("(%p)\n", hMidiIn);
|
||||
|
||||
if ((wmld = MMDRV_Get(hMidiIn, MMDRV_MIDIIN, FALSE)) == NULL)
|
||||
return MMSYSERR_INVALHANDLE;
|
||||
|
@ -1501,7 +1501,7 @@ UINT WINAPI midiInGetID(HMIDIIN hMidiIn, UINT* lpuDeviceID)
|
|||
{
|
||||
LPWINE_MLD wmld;
|
||||
|
||||
TRACE("(%04X, %p)\n", hMidiIn, lpuDeviceID);
|
||||
TRACE("(%p, %p)\n", hMidiIn, lpuDeviceID);
|
||||
|
||||
if (lpuDeviceID == NULL) return MMSYSERR_INVALPARAM;
|
||||
|
||||
|
@ -1521,7 +1521,7 @@ DWORD WINAPI midiInMessage(HMIDIIN hMidiIn, UINT uMessage,
|
|||
{
|
||||
LPWINE_MLD wmld;
|
||||
|
||||
TRACE("(%04X, %04X, %08lX, %08lX)\n", hMidiIn, uMessage, dwParam1, dwParam2);
|
||||
TRACE("(%p, %04X, %08lX, %08lX)\n", hMidiIn, uMessage, dwParam1, dwParam2);
|
||||
|
||||
if ((wmld = MMDRV_Get(hMidiIn, MMDRV_MIDIIN, FALSE)) == NULL)
|
||||
return MMSYSERR_INVALHANDLE;
|
||||
|
@ -1860,7 +1860,7 @@ MMRESULT WINAPI midiStreamClose(HMIDISTRM hMidiStrm)
|
|||
{
|
||||
WINE_MIDIStream* lpMidiStrm;
|
||||
|
||||
TRACE("(%08x)!\n", hMidiStrm);
|
||||
TRACE("(%p)!\n", hMidiStrm);
|
||||
|
||||
if (!MMSYSTEM_GetMidiStream(hMidiStrm, &lpMidiStrm, NULL))
|
||||
return MMSYSERR_INVALHANDLE;
|
||||
|
@ -1937,7 +1937,7 @@ MMRESULT MIDI_StreamOpen(HMIDISTRM* lphMidiStrm, LPUINT lpuDeviceID, DWORD cMidi
|
|||
RestoreThunkLock(count);
|
||||
}
|
||||
|
||||
TRACE("=> (%u/%d) hMidi=0x%04x ret=%d lpMidiStrm=%p\n",
|
||||
TRACE("=> (%u/%d) hMidi=%p ret=%d lpMidiStrm=%p\n",
|
||||
*lpuDeviceID, lpwm->mld.uDeviceID, *lphMidiStrm, ret, lpMidiStrm);
|
||||
return ret;
|
||||
}
|
||||
|
@ -1962,7 +1962,7 @@ MMRESULT WINAPI midiStreamOut(HMIDISTRM hMidiStrm, LPMIDIHDR lpMidiHdr,
|
|||
WINE_MIDIStream* lpMidiStrm;
|
||||
DWORD ret = MMSYSERR_NOERROR;
|
||||
|
||||
TRACE("(%08x, %p, %u)!\n", hMidiStrm, lpMidiHdr, cbMidiHdr);
|
||||
TRACE("(%p, %p, %u)!\n", hMidiStrm, lpMidiHdr, cbMidiHdr);
|
||||
|
||||
if (!MMSYSTEM_GetMidiStream(hMidiStrm, &lpMidiStrm, NULL)) {
|
||||
ret = MMSYSERR_INVALHANDLE;
|
||||
|
@ -1987,7 +1987,7 @@ MMRESULT WINAPI midiStreamPause(HMIDISTRM hMidiStrm)
|
|||
WINE_MIDIStream* lpMidiStrm;
|
||||
DWORD ret = MMSYSERR_NOERROR;
|
||||
|
||||
TRACE("(%08x)!\n", hMidiStrm);
|
||||
TRACE("(%p)!\n", hMidiStrm);
|
||||
|
||||
if (!MMSYSTEM_GetMidiStream(hMidiStrm, &lpMidiStrm, NULL)) {
|
||||
ret = MMSYSERR_INVALHANDLE;
|
||||
|
@ -2008,7 +2008,7 @@ MMRESULT WINAPI midiStreamPosition(HMIDISTRM hMidiStrm, LPMMTIME lpMMT, UINT cbm
|
|||
WINE_MIDIStream* lpMidiStrm;
|
||||
DWORD ret = MMSYSERR_NOERROR;
|
||||
|
||||
TRACE("(%08x, %p, %u)!\n", hMidiStrm, lpMMT, cbmmt);
|
||||
TRACE("(%p, %p, %u)!\n", hMidiStrm, lpMMT, cbmmt);
|
||||
|
||||
if (!MMSYSTEM_GetMidiStream(hMidiStrm, &lpMidiStrm, NULL)) {
|
||||
ret = MMSYSERR_INVALHANDLE;
|
||||
|
@ -2042,7 +2042,7 @@ MMRESULT WINAPI midiStreamProperty(HMIDISTRM hMidiStrm, LPBYTE lpPropData, DWORD
|
|||
WINE_MIDIStream* lpMidiStrm;
|
||||
MMRESULT ret = MMSYSERR_NOERROR;
|
||||
|
||||
TRACE("(%08x, %p, %lx)\n", hMidiStrm, lpPropData, dwProperty);
|
||||
TRACE("(%p, %p, %lx)\n", hMidiStrm, lpPropData, dwProperty);
|
||||
|
||||
if (!MMSYSTEM_GetMidiStream(hMidiStrm, &lpMidiStrm, NULL)) {
|
||||
ret = MMSYSERR_INVALHANDLE;
|
||||
|
@ -2087,7 +2087,7 @@ MMRESULT WINAPI midiStreamRestart(HMIDISTRM hMidiStrm)
|
|||
WINE_MIDIStream* lpMidiStrm;
|
||||
MMRESULT ret = MMSYSERR_NOERROR;
|
||||
|
||||
TRACE("(%08x)!\n", hMidiStrm);
|
||||
TRACE("(%p)!\n", hMidiStrm);
|
||||
|
||||
if (!MMSYSTEM_GetMidiStream(hMidiStrm, &lpMidiStrm, NULL)) {
|
||||
ret = MMSYSERR_INVALHANDLE;
|
||||
|
@ -2118,7 +2118,7 @@ MMRESULT WINAPI midiStreamStop(HMIDISTRM hMidiStrm)
|
|||
WINE_MIDIStream* lpMidiStrm;
|
||||
MMRESULT ret = MMSYSERR_NOERROR;
|
||||
|
||||
TRACE("(%08x)!\n", hMidiStrm);
|
||||
TRACE("(%p)!\n", hMidiStrm);
|
||||
|
||||
if (!MMSYSTEM_GetMidiStream(hMidiStrm, &lpMidiStrm, NULL)) {
|
||||
ret = MMSYSERR_INVALHANDLE;
|
||||
|
@ -2193,7 +2193,7 @@ UINT WAVE_Open(HANDLE* lphndl, UINT uDeviceID, UINT uType,
|
|||
}
|
||||
|
||||
if (lphndl != NULL) *lphndl = handle;
|
||||
TRACE("=> %ld hWave=%04x\n", dwRet, handle);
|
||||
TRACE("=> %ld hWave=%p\n", dwRet, handle);
|
||||
|
||||
return dwRet;
|
||||
}
|
||||
|
@ -2218,7 +2218,7 @@ UINT WINAPI waveOutGetDevCapsA(UINT uDeviceID, LPWAVEOUTCAPSA lpCaps,
|
|||
|
||||
if (lpCaps == NULL) return MMSYSERR_INVALPARAM;
|
||||
|
||||
if ((wmld = MMDRV_Get(uDeviceID, MMDRV_WAVEOUT, TRUE)) == NULL)
|
||||
if ((wmld = MMDRV_Get((HANDLE)uDeviceID, MMDRV_WAVEOUT, TRUE)) == NULL)
|
||||
return MMSYSERR_INVALHANDLE;
|
||||
|
||||
return MMDRV_Message(wmld, WODM_GETDEVCAPS, (DWORD)lpCaps, uSize, TRUE);
|
||||
|
@ -2305,7 +2305,7 @@ UINT WINAPI waveOutOpen(HWAVEOUT* lphWaveOut, UINT uDeviceID,
|
|||
const LPWAVEFORMATEX lpFormat, DWORD dwCallback,
|
||||
DWORD dwInstance, DWORD dwFlags)
|
||||
{
|
||||
return WAVE_Open(lphWaveOut, uDeviceID, MMDRV_WAVEOUT, lpFormat,
|
||||
return WAVE_Open((HANDLE*)lphWaveOut, uDeviceID, MMDRV_WAVEOUT, lpFormat,
|
||||
dwCallback, dwInstance, dwFlags, TRUE);
|
||||
}
|
||||
|
||||
|
@ -2317,7 +2317,7 @@ UINT WINAPI waveOutClose(HWAVEOUT hWaveOut)
|
|||
LPWINE_MLD wmld;
|
||||
DWORD dwRet;
|
||||
|
||||
TRACE("(%04X)\n", hWaveOut);
|
||||
TRACE("(%p)\n", hWaveOut);
|
||||
|
||||
if ((wmld = MMDRV_Get(hWaveOut, MMDRV_WAVEOUT, FALSE)) == NULL)
|
||||
return MMSYSERR_INVALHANDLE;
|
||||
|
@ -2336,7 +2336,7 @@ UINT WINAPI waveOutPrepareHeader(HWAVEOUT hWaveOut,
|
|||
{
|
||||
LPWINE_MLD wmld;
|
||||
|
||||
TRACE("(%04X, %p, %u);\n", hWaveOut, lpWaveOutHdr, uSize);
|
||||
TRACE("(%p, %p, %u);\n", hWaveOut, lpWaveOutHdr, uSize);
|
||||
|
||||
if (lpWaveOutHdr == NULL) return MMSYSERR_INVALPARAM;
|
||||
|
||||
|
@ -2354,7 +2354,7 @@ UINT WINAPI waveOutUnprepareHeader(HWAVEOUT hWaveOut,
|
|||
{
|
||||
LPWINE_MLD wmld;
|
||||
|
||||
TRACE("(%04X, %p, %u);\n", hWaveOut, lpWaveOutHdr, uSize);
|
||||
TRACE("(%p, %p, %u);\n", hWaveOut, lpWaveOutHdr, uSize);
|
||||
|
||||
if (!(lpWaveOutHdr->dwFlags & WHDR_PREPARED)) {
|
||||
return MMSYSERR_NOERROR;
|
||||
|
@ -2374,7 +2374,7 @@ UINT WINAPI waveOutWrite(HWAVEOUT hWaveOut, LPWAVEHDR lpWaveOutHdr,
|
|||
{
|
||||
LPWINE_MLD wmld;
|
||||
|
||||
TRACE("(%04X, %p, %u);\n", hWaveOut, lpWaveOutHdr, uSize);
|
||||
TRACE("(%p, %p, %u);\n", hWaveOut, lpWaveOutHdr, uSize);
|
||||
|
||||
if ((wmld = MMDRV_Get(hWaveOut, MMDRV_WAVEOUT, FALSE)) == NULL)
|
||||
return MMSYSERR_INVALHANDLE;
|
||||
|
@ -2389,7 +2389,7 @@ UINT WINAPI waveOutBreakLoop(HWAVEOUT hWaveOut)
|
|||
{
|
||||
LPWINE_MLD wmld;
|
||||
|
||||
TRACE("(%04X);\n", hWaveOut);
|
||||
TRACE("(%p);\n", hWaveOut);
|
||||
|
||||
if ((wmld = MMDRV_Get(hWaveOut, MMDRV_WAVEOUT, FALSE)) == NULL)
|
||||
return MMSYSERR_INVALHANDLE;
|
||||
|
@ -2403,7 +2403,7 @@ UINT WINAPI waveOutPause(HWAVEOUT hWaveOut)
|
|||
{
|
||||
LPWINE_MLD wmld;
|
||||
|
||||
TRACE("(%04X);\n", hWaveOut);
|
||||
TRACE("(%p);\n", hWaveOut);
|
||||
|
||||
if ((wmld = MMDRV_Get(hWaveOut, MMDRV_WAVEOUT, FALSE)) == NULL)
|
||||
return MMSYSERR_INVALHANDLE;
|
||||
|
@ -2417,7 +2417,7 @@ UINT WINAPI waveOutReset(HWAVEOUT hWaveOut)
|
|||
{
|
||||
LPWINE_MLD wmld;
|
||||
|
||||
TRACE("(%04X);\n", hWaveOut);
|
||||
TRACE("(%p);\n", hWaveOut);
|
||||
|
||||
if ((wmld = MMDRV_Get(hWaveOut, MMDRV_WAVEOUT, FALSE)) == NULL)
|
||||
return MMSYSERR_INVALHANDLE;
|
||||
|
@ -2431,7 +2431,7 @@ UINT WINAPI waveOutRestart(HWAVEOUT hWaveOut)
|
|||
{
|
||||
LPWINE_MLD wmld;
|
||||
|
||||
TRACE("(%04X);\n", hWaveOut);
|
||||
TRACE("(%p);\n", hWaveOut);
|
||||
|
||||
if ((wmld = MMDRV_Get(hWaveOut, MMDRV_WAVEOUT, FALSE)) == NULL)
|
||||
return MMSYSERR_INVALHANDLE;
|
||||
|
@ -2446,7 +2446,7 @@ UINT WINAPI waveOutGetPosition(HWAVEOUT hWaveOut, LPMMTIME lpTime,
|
|||
{
|
||||
LPWINE_MLD wmld;
|
||||
|
||||
TRACE("(%04X, %p, %u);\n", hWaveOut, lpTime, uSize);
|
||||
TRACE("(%p, %p, %u);\n", hWaveOut, lpTime, uSize);
|
||||
|
||||
if ((wmld = MMDRV_Get(hWaveOut, MMDRV_WAVEOUT, FALSE)) == NULL)
|
||||
return MMSYSERR_INVALHANDLE;
|
||||
|
@ -2461,7 +2461,7 @@ UINT WINAPI waveOutGetPitch(HWAVEOUT hWaveOut, LPDWORD lpdw)
|
|||
{
|
||||
LPWINE_MLD wmld;
|
||||
|
||||
TRACE("(%04X, %08lx);\n", hWaveOut, (DWORD)lpdw);
|
||||
TRACE("(%p, %08lx);\n", hWaveOut, (DWORD)lpdw);
|
||||
|
||||
if ((wmld = MMDRV_Get(hWaveOut, MMDRV_WAVEOUT, FALSE)) == NULL)
|
||||
return MMSYSERR_INVALHANDLE;
|
||||
|
@ -2475,7 +2475,7 @@ UINT WINAPI waveOutSetPitch(HWAVEOUT hWaveOut, DWORD dw)
|
|||
{
|
||||
LPWINE_MLD wmld;
|
||||
|
||||
TRACE("(%04X, %08lx);\n", hWaveOut, (DWORD)dw);
|
||||
TRACE("(%p, %08lx);\n", hWaveOut, (DWORD)dw);
|
||||
|
||||
if ((wmld = MMDRV_Get(hWaveOut, MMDRV_WAVEOUT, FALSE)) == NULL)
|
||||
return MMSYSERR_INVALHANDLE;
|
||||
|
@ -2489,7 +2489,7 @@ UINT WINAPI waveOutGetPlaybackRate(HWAVEOUT hWaveOut, LPDWORD lpdw)
|
|||
{
|
||||
LPWINE_MLD wmld;
|
||||
|
||||
TRACE("(%04X, %08lx);\n", hWaveOut, (DWORD)lpdw);
|
||||
TRACE("(%p, %08lx);\n", hWaveOut, (DWORD)lpdw);
|
||||
|
||||
if ((wmld = MMDRV_Get(hWaveOut, MMDRV_WAVEOUT, FALSE)) == NULL)
|
||||
return MMSYSERR_INVALHANDLE;
|
||||
|
@ -2503,7 +2503,7 @@ UINT WINAPI waveOutSetPlaybackRate(HWAVEOUT hWaveOut, DWORD dw)
|
|||
{
|
||||
LPWINE_MLD wmld;
|
||||
|
||||
TRACE("(%04X, %08lx);\n", hWaveOut, (DWORD)dw);
|
||||
TRACE("(%p, %08lx);\n", hWaveOut, (DWORD)dw);
|
||||
|
||||
if ((wmld = MMDRV_Get(hWaveOut, MMDRV_WAVEOUT, FALSE)) == NULL)
|
||||
return MMSYSERR_INVALHANDLE;
|
||||
|
@ -2519,7 +2519,7 @@ UINT WINAPI waveOutGetVolume(UINT devid, LPDWORD lpdw)
|
|||
|
||||
TRACE("(%04X, %08lx);\n", devid, (DWORD)lpdw);
|
||||
|
||||
if ((wmld = MMDRV_Get(devid, MMDRV_WAVEOUT, TRUE)) == NULL)
|
||||
if ((wmld = MMDRV_Get((HANDLE)devid, MMDRV_WAVEOUT, TRUE)) == NULL)
|
||||
return MMSYSERR_INVALHANDLE;
|
||||
|
||||
return MMDRV_Message(wmld, WODM_GETVOLUME, (DWORD)lpdw, 0L, TRUE);
|
||||
|
@ -2534,7 +2534,7 @@ UINT WINAPI waveOutSetVolume(UINT devid, DWORD dw)
|
|||
|
||||
TRACE("(%04X, %08lx);\n", devid, dw);
|
||||
|
||||
if ((wmld = MMDRV_Get(devid, MMDRV_WAVEOUT, TRUE)) == NULL)
|
||||
if ((wmld = MMDRV_Get((HANDLE)devid, MMDRV_WAVEOUT, TRUE)) == NULL)
|
||||
return MMSYSERR_INVALHANDLE;
|
||||
|
||||
return MMDRV_Message(wmld, WODM_SETVOLUME, dw, 0L, TRUE);
|
||||
|
@ -2547,7 +2547,7 @@ UINT WINAPI waveOutGetID(HWAVEOUT hWaveOut, UINT* lpuDeviceID)
|
|||
{
|
||||
LPWINE_MLD wmld;
|
||||
|
||||
TRACE("(%04X, %p);\n", hWaveOut, lpuDeviceID);
|
||||
TRACE("(%p, %p);\n", hWaveOut, lpuDeviceID);
|
||||
|
||||
if (lpuDeviceID == NULL) return MMSYSERR_INVALHANDLE;
|
||||
|
||||
|
@ -2566,7 +2566,7 @@ DWORD WINAPI waveOutMessage(HWAVEOUT hWaveOut, UINT uMessage,
|
|||
{
|
||||
LPWINE_MLD wmld;
|
||||
|
||||
TRACE("(%04x, %u, %ld, %ld)\n", hWaveOut, uMessage, dwParam1, dwParam2);
|
||||
TRACE("(%p, %u, %ld, %ld)\n", hWaveOut, uMessage, dwParam1, dwParam2);
|
||||
|
||||
if ((wmld = MMDRV_Get(hWaveOut, MMDRV_WAVEOUT, FALSE)) == NULL) {
|
||||
if ((wmld = MMDRV_Get(hWaveOut, MMDRV_WAVEOUT, TRUE)) != NULL) {
|
||||
|
@ -2620,7 +2620,7 @@ UINT WINAPI waveInGetDevCapsA(UINT uDeviceID, LPWAVEINCAPSA lpCaps, UINT uSize)
|
|||
|
||||
TRACE("(%u %p %u)!\n", uDeviceID, lpCaps, uSize);
|
||||
|
||||
if ((wmld = MMDRV_Get(uDeviceID, MMDRV_WAVEIN, TRUE)) == NULL)
|
||||
if ((wmld = MMDRV_Get((HANDLE)uDeviceID, MMDRV_WAVEIN, TRUE)) == NULL)
|
||||
return MMSYSERR_INVALHANDLE;
|
||||
|
||||
return MMDRV_Message(wmld, WIDM_GETDEVCAPS, (DWORD)lpCaps, uSize, TRUE);
|
||||
|
@ -2654,7 +2654,7 @@ UINT WINAPI waveInOpen(HWAVEIN* lphWaveIn, UINT uDeviceID,
|
|||
const LPWAVEFORMATEX lpFormat, DWORD dwCallback,
|
||||
DWORD dwInstance, DWORD dwFlags)
|
||||
{
|
||||
return WAVE_Open(lphWaveIn, uDeviceID, MMDRV_WAVEIN, lpFormat,
|
||||
return WAVE_Open((HANDLE*)lphWaveIn, uDeviceID, MMDRV_WAVEIN, lpFormat,
|
||||
dwCallback, dwInstance, dwFlags, TRUE);
|
||||
}
|
||||
|
||||
|
@ -2666,7 +2666,7 @@ UINT WINAPI waveInClose(HWAVEIN hWaveIn)
|
|||
LPWINE_MLD wmld;
|
||||
DWORD dwRet;
|
||||
|
||||
TRACE("(%04X)\n", hWaveIn);
|
||||
TRACE("(%p)\n", hWaveIn);
|
||||
|
||||
if ((wmld = MMDRV_Get(hWaveIn, MMDRV_WAVEIN, FALSE)) == NULL)
|
||||
return MMSYSERR_INVALHANDLE;
|
||||
|
@ -2684,7 +2684,7 @@ UINT WINAPI waveInPrepareHeader(HWAVEIN hWaveIn, WAVEHDR* lpWaveInHdr,
|
|||
{
|
||||
LPWINE_MLD wmld;
|
||||
|
||||
TRACE("(%04X, %p, %u);\n", hWaveIn, lpWaveInHdr, uSize);
|
||||
TRACE("(%p, %p, %u);\n", hWaveIn, lpWaveInHdr, uSize);
|
||||
|
||||
if (lpWaveInHdr == NULL) return MMSYSERR_INVALPARAM;
|
||||
if ((wmld = MMDRV_Get(hWaveIn, MMDRV_WAVEIN, FALSE)) == NULL)
|
||||
|
@ -2703,7 +2703,7 @@ UINT WINAPI waveInUnprepareHeader(HWAVEIN hWaveIn, WAVEHDR* lpWaveInHdr,
|
|||
{
|
||||
LPWINE_MLD wmld;
|
||||
|
||||
TRACE("(%04X, %p, %u);\n", hWaveIn, lpWaveInHdr, uSize);
|
||||
TRACE("(%p, %p, %u);\n", hWaveIn, lpWaveInHdr, uSize);
|
||||
|
||||
if (lpWaveInHdr == NULL) return MMSYSERR_INVALPARAM;
|
||||
if (!(lpWaveInHdr->dwFlags & WHDR_PREPARED)) {
|
||||
|
@ -2724,7 +2724,7 @@ UINT WINAPI waveInAddBuffer(HWAVEIN hWaveIn,
|
|||
{
|
||||
LPWINE_MLD wmld;
|
||||
|
||||
TRACE("(%04X, %p, %u);\n", hWaveIn, lpWaveInHdr, uSize);
|
||||
TRACE("(%p, %p, %u);\n", hWaveIn, lpWaveInHdr, uSize);
|
||||
|
||||
if (lpWaveInHdr == NULL) return MMSYSERR_INVALPARAM;
|
||||
if ((wmld = MMDRV_Get(hWaveIn, MMDRV_WAVEIN, FALSE)) == NULL)
|
||||
|
@ -2740,7 +2740,7 @@ UINT WINAPI waveInReset(HWAVEIN hWaveIn)
|
|||
{
|
||||
LPWINE_MLD wmld;
|
||||
|
||||
TRACE("(%04X);\n", hWaveIn);
|
||||
TRACE("(%p);\n", hWaveIn);
|
||||
|
||||
if ((wmld = MMDRV_Get(hWaveIn, MMDRV_WAVEIN, FALSE)) == NULL)
|
||||
return MMSYSERR_INVALHANDLE;
|
||||
|
@ -2755,7 +2755,7 @@ UINT WINAPI waveInStart(HWAVEIN hWaveIn)
|
|||
{
|
||||
LPWINE_MLD wmld;
|
||||
|
||||
TRACE("(%04X);\n", hWaveIn);
|
||||
TRACE("(%p);\n", hWaveIn);
|
||||
|
||||
if ((wmld = MMDRV_Get(hWaveIn, MMDRV_WAVEIN, FALSE)) == NULL)
|
||||
return MMSYSERR_INVALHANDLE;
|
||||
|
@ -2770,7 +2770,7 @@ UINT WINAPI waveInStop(HWAVEIN hWaveIn)
|
|||
{
|
||||
LPWINE_MLD wmld;
|
||||
|
||||
TRACE("(%04X);\n", hWaveIn);
|
||||
TRACE("(%p);\n", hWaveIn);
|
||||
|
||||
if ((wmld = MMDRV_Get(hWaveIn, MMDRV_WAVEIN, FALSE)) == NULL)
|
||||
return MMSYSERR_INVALHANDLE;
|
||||
|
@ -2786,7 +2786,7 @@ UINT WINAPI waveInGetPosition(HWAVEIN hWaveIn, LPMMTIME lpTime,
|
|||
{
|
||||
LPWINE_MLD wmld;
|
||||
|
||||
TRACE("(%04X, %p, %u);\n", hWaveIn, lpTime, uSize);
|
||||
TRACE("(%p, %p, %u);\n", hWaveIn, lpTime, uSize);
|
||||
|
||||
if ((wmld = MMDRV_Get(hWaveIn, MMDRV_WAVEIN, FALSE)) == NULL)
|
||||
return MMSYSERR_INVALHANDLE;
|
||||
|
@ -2801,7 +2801,7 @@ UINT WINAPI waveInGetID(HWAVEIN hWaveIn, UINT* lpuDeviceID)
|
|||
{
|
||||
LPWINE_MLD wmld;
|
||||
|
||||
TRACE("(%04X, %p);\n", hWaveIn, lpuDeviceID);
|
||||
TRACE("(%p, %p);\n", hWaveIn, lpuDeviceID);
|
||||
|
||||
if (lpuDeviceID == NULL) return MMSYSERR_INVALHANDLE;
|
||||
|
||||
|
@ -2820,7 +2820,7 @@ DWORD WINAPI waveInMessage(HWAVEIN hWaveIn, UINT uMessage,
|
|||
{
|
||||
LPWINE_MLD wmld;
|
||||
|
||||
TRACE("(%04x, %u, %ld, %ld)\n", hWaveIn, uMessage, dwParam1, dwParam2);
|
||||
TRACE("(%p, %u, %ld, %ld)\n", hWaveIn, uMessage, dwParam1, dwParam2);
|
||||
|
||||
/* from M$ KB */
|
||||
if (uMessage < DRVM_IOCTL || (uMessage >= DRVM_IOCTL_LAST && uMessage < DRVM_MAPPER))
|
||||
|
|
|
@ -497,7 +497,7 @@ void WINAPI mmTaskBlock16(HINSTANCE16 hInst);
|
|||
LRESULT WINAPI mmTaskSignal16(HTASK16 ht);
|
||||
void WINAPI mmTaskYield16(void);
|
||||
|
||||
LRESULT WINAPI mmThreadCreate16(FARPROC16 fpThreadAddr, LPHANDLE lpHndl,
|
||||
LRESULT WINAPI mmThreadCreate16(FARPROC16 fpThreadAddr, LPHANDLE16 lpHndl,
|
||||
DWORD dwPmt, DWORD dwFlags);
|
||||
void WINAPI mmThreadSignal16(HANDLE16 hndl);
|
||||
void WINAPI mmThreadBlock16(HANDLE16 hndl);
|
||||
|
|
Loading…
Reference in New Issue