Commit 2c8802f2 authored by Eric Pouech's avatar Eric Pouech Committed by Alexandre Julliard

mmsystem.dll16: Enable compilation with long types.

parent 92263371
EXTRADEFS = -DWINE_NO_LONG_TYPES
MODULE = mmsystem.dll16 MODULE = mmsystem.dll16
IMPORTS = winmm user32 IMPORTS = winmm user32
......
...@@ -97,7 +97,7 @@ static inline LRESULT DRIVER_SendMessage(LPWINE_DRIVER lpDrv, UINT16 msg, ...@@ -97,7 +97,7 @@ static inline LRESULT DRIVER_SendMessage(LPWINE_DRIVER lpDrv, UINT16 msg,
WORD args[8]; WORD args[8];
DWORD ret; DWORD ret;
TRACE("Before CallDriverProc proc=%p driverID=%08x wMsg=%04x p1=%08lx p2=%08lx\n", TRACE("Before CallDriverProc proc=%p driverID=%08lx wMsg=%04x p1=%08lx p2=%08lx\n",
lpDrv->lpDrvProc, lpDrv->dwDriverID, msg, lParam1, lParam2); lpDrv->lpDrvProc, lpDrv->dwDriverID, msg, lParam1, lParam2);
args[7] = HIWORD(lpDrv->dwDriverID); args[7] = HIWORD(lpDrv->dwDriverID);
...@@ -321,7 +321,7 @@ HMODULE16 WINAPI DrvGetModuleHandle16(HDRVR16 hDrvr) ...@@ -321,7 +321,7 @@ HMODULE16 WINAPI DrvGetModuleHandle16(HDRVR16 hDrvr)
LRESULT WINAPI DrvDefDriverProc16(DWORD dwDevID, HDRVR16 hDriv, UINT16 wMsg, LRESULT WINAPI DrvDefDriverProc16(DWORD dwDevID, HDRVR16 hDriv, UINT16 wMsg,
LPARAM lParam1, LPARAM lParam2) LPARAM lParam1, LPARAM lParam2)
{ {
TRACE("devID=0x%08x hDrv=0x%04x wMsg=%04x lP1=0x%08lx lP2=0x%08lx\n", TRACE("devID=0x%08lx hDrv=0x%04x wMsg=%04x lP1=0x%08lx lP2=0x%08lx\n",
dwDevID, hDriv, wMsg, lParam1, lParam2); dwDevID, hDriv, wMsg, lParam1, lParam2);
switch(wMsg) { switch(wMsg) {
......
...@@ -610,7 +610,7 @@ BOOL16 WINAPI mciSetYieldProc16(UINT16 uDeviceID, YIELDPROC16 fpYieldProc, DWORD ...@@ -610,7 +610,7 @@ BOOL16 WINAPI mciSetYieldProc16(UINT16 uDeviceID, YIELDPROC16 fpYieldProc, DWORD
struct mci_thunk* thunk; struct mci_thunk* thunk;
BOOL ret; BOOL ret;
TRACE("(%u, %p, %08x)\n", uDeviceID, fpYieldProc, dwYieldData); TRACE("(%u, %p, %08lx)\n", uDeviceID, fpYieldProc, dwYieldData);
if (!(thunk = MCI_AddThunk(uDeviceID, fpYieldProc))) if (!(thunk = MCI_AddThunk(uDeviceID, fpYieldProc)))
return FALSE; return FALSE;
...@@ -680,7 +680,7 @@ DWORD WINAPI mciSendCommand16(UINT16 wDevID, UINT16 wMsg, DWORD dwParam1, DWORD ...@@ -680,7 +680,7 @@ DWORD WINAPI mciSendCommand16(UINT16 wDevID, UINT16 wMsg, DWORD dwParam1, DWORD
BOOL to32; BOOL to32;
DWORD_PTR dwParam2 = p2; DWORD_PTR dwParam2 = p2;
TRACE("(%04X, %s, %08X, %08lX)\n", wDevID, MCI_MessageToString(wMsg), dwParam1, dwParam2); TRACE("(%04X, %s, %08lX, %08lX)\n", wDevID, MCI_MessageToString(wMsg), dwParam1, dwParam2);
switch (wMsg) { switch (wMsg) {
case MCI_CLOSE: case MCI_CLOSE:
......
...@@ -127,7 +127,7 @@ static void MMSYSTDRV_MidiIn_MapCB(DWORD uMsg, DWORD_PTR* dwUser, D ...@@ -127,7 +127,7 @@ static void MMSYSTDRV_MidiIn_MapCB(DWORD uMsg, DWORD_PTR* dwUser, D
} }
break; break;
default: default:
ERR("Unknown msg %u\n", uMsg); ERR("Unknown msg %lu\n", uMsg);
} }
} }
...@@ -206,7 +206,7 @@ static MMSYSTEM_MapType MMSYSTDRV_MidiOut_Map16To32W (DWORD wMsg, DWORD_PTR* lp ...@@ -206,7 +206,7 @@ static MMSYSTEM_MapType MMSYSTDRV_MidiOut_Map16To32W (DWORD wMsg, DWORD_PTR* lp
*lpParam2 = offsetof(MIDIHDR,dwOffset); *lpParam2 = offsetof(MIDIHDR,dwOffset);
/* dwBufferLength can be reduced between prepare & write */ /* dwBufferLength can be reduced between prepare & write */
if (wMsg == MODM_LONGDATA && mh32->dwBufferLength < mh16->dwBufferLength) { if (wMsg == MODM_LONGDATA && mh32->dwBufferLength < mh16->dwBufferLength) {
ERR("Size of buffer has been increased from %d to %d, keeping initial value\n", ERR("Size of buffer has been increased from %ld to %ld, keeping initial value\n",
mh32->dwBufferLength, mh16->dwBufferLength); mh32->dwBufferLength, mh16->dwBufferLength);
} else } else
mh32->dwBufferLength = mh16->dwBufferLength; mh32->dwBufferLength = mh16->dwBufferLength;
...@@ -217,7 +217,7 @@ static MMSYSTEM_MapType MMSYSTDRV_MidiOut_Map16To32W (DWORD wMsg, DWORD_PTR* lp ...@@ -217,7 +217,7 @@ static MMSYSTEM_MapType MMSYSTDRV_MidiOut_Map16To32W (DWORD wMsg, DWORD_PTR* lp
case MODM_CACHEPATCHES: case MODM_CACHEPATCHES:
case MODM_CACHEDRUMPATCHES: case MODM_CACHEDRUMPATCHES:
default: default:
FIXME("NIY: no conversion yet for %u [%lx,%lx]\n", wMsg, *lpParam1, *lpParam2); FIXME("NIY: no conversion yet for %lu [%lx,%lx]\n", wMsg, *lpParam1, *lpParam2);
break; break;
} }
return ret; return ret;
...@@ -284,7 +284,7 @@ static MMSYSTEM_MapType MMSYSTDRV_MidiOut_UnMap16To32W(DWORD wMsg, DWORD_PTR* l ...@@ -284,7 +284,7 @@ static MMSYSTEM_MapType MMSYSTDRV_MidiOut_UnMap16To32W(DWORD wMsg, DWORD_PTR* l
case MODM_CACHEPATCHES: case MODM_CACHEPATCHES:
case MODM_CACHEDRUMPATCHES: case MODM_CACHEDRUMPATCHES:
default: default:
FIXME("NIY: no conversion yet for %u [%lx,%lx]\n", wMsg, *lpParam1, *lpParam2); FIXME("NIY: no conversion yet for %lu [%lx,%lx]\n", wMsg, *lpParam1, *lpParam2);
break; break;
} }
return ret; return ret;
...@@ -316,7 +316,7 @@ static void MMSYSTDRV_MidiOut_MapCB(DWORD uMsg, DWORD_PTR* dwUser, DWORD_PTR* d ...@@ -316,7 +316,7 @@ static void MMSYSTDRV_MidiOut_MapCB(DWORD uMsg, DWORD_PTR* dwUser, DWORD_PTR* d
} }
break; break;
default: default:
ERR("Unknown msg %u\n", uMsg); ERR("Unknown msg %lu\n", uMsg);
} }
} }
...@@ -414,7 +414,7 @@ static MMSYSTEM_MapType MMSYSTDRV_WaveIn_Map16To32W (DWORD wMsg, DWORD_PTR* lp ...@@ -414,7 +414,7 @@ static MMSYSTEM_MapType MMSYSTDRV_WaveIn_Map16To32W (DWORD wMsg, DWORD_PTR* lp
*lpParam2 = sizeof(WAVEHDR); *lpParam2 = sizeof(WAVEHDR);
/* dwBufferLength can be reduced between prepare & write */ /* dwBufferLength can be reduced between prepare & write */
if (wMsg == WIDM_ADDBUFFER && wh32->dwBufferLength < wh16->dwBufferLength) { if (wMsg == WIDM_ADDBUFFER && wh32->dwBufferLength < wh16->dwBufferLength) {
ERR("Size of buffer has been increased from %d to %d, keeping initial value\n", ERR("Size of buffer has been increased from %ld to %ld, keeping initial value\n",
wh32->dwBufferLength, wh16->dwBufferLength); wh32->dwBufferLength, wh16->dwBufferLength);
} else } else
wh32->dwBufferLength = wh16->dwBufferLength; wh32->dwBufferLength = wh16->dwBufferLength;
...@@ -427,7 +427,7 @@ static MMSYSTEM_MapType MMSYSTDRV_WaveIn_Map16To32W (DWORD wMsg, DWORD_PTR* lp ...@@ -427,7 +427,7 @@ static MMSYSTEM_MapType MMSYSTDRV_WaveIn_Map16To32W (DWORD wMsg, DWORD_PTR* lp
ret = MMSYSTEM_MAP_OK; ret = MMSYSTEM_MAP_OK;
break; break;
default: default:
FIXME("NIY: no conversion yet for %u [%lx,%lx]\n", wMsg, *lpParam1, *lpParam2); FIXME("NIY: no conversion yet for %lu [%lx,%lx]\n", wMsg, *lpParam1, *lpParam2);
break; break;
} }
return ret; return ret;
...@@ -497,7 +497,7 @@ static MMSYSTEM_MapType MMSYSTDRV_WaveIn_UnMap16To32W(DWORD wMsg, DWORD_PTR* lp ...@@ -497,7 +497,7 @@ static MMSYSTEM_MapType MMSYSTDRV_WaveIn_UnMap16To32W(DWORD wMsg, DWORD_PTR* lp
} }
break; break;
default: default:
FIXME("NIY: no conversion yet for %u [%lx,%lx]\n", wMsg, *lpParam1, *lpParam2); FIXME("NIY: no conversion yet for %lu [%lx,%lx]\n", wMsg, *lpParam1, *lpParam2);
break; break;
} }
return ret; return ret;
...@@ -526,7 +526,7 @@ static void MMSYSTDRV_WaveIn_MapCB(DWORD uMsg, DWORD_PTR* dwUser, DWORD_PTR* ...@@ -526,7 +526,7 @@ static void MMSYSTDRV_WaveIn_MapCB(DWORD uMsg, DWORD_PTR* dwUser, DWORD_PTR*
} }
break; break;
default: default:
ERR("Unknown msg %u\n", uMsg); ERR("Unknown msg %lu\n", uMsg);
} }
} }
...@@ -634,7 +634,7 @@ static MMSYSTEM_MapType MMSYSTDRV_WaveOut_Map16To32W (DWORD wMsg, DWORD_PTR* l ...@@ -634,7 +634,7 @@ static MMSYSTEM_MapType MMSYSTDRV_WaveOut_Map16To32W (DWORD wMsg, DWORD_PTR* l
*lpParam2 = sizeof(WAVEHDR); *lpParam2 = sizeof(WAVEHDR);
/* dwBufferLength can be reduced between prepare & write */ /* dwBufferLength can be reduced between prepare & write */
if (wMsg == WODM_WRITE && wh32->dwBufferLength < wh16->dwBufferLength) { if (wMsg == WODM_WRITE && wh32->dwBufferLength < wh16->dwBufferLength) {
ERR("Size of buffer has been increased from %d to %d, keeping initial value\n", ERR("Size of buffer has been increased from %ld to %ld, keeping initial value\n",
wh32->dwBufferLength, wh16->dwBufferLength); wh32->dwBufferLength, wh16->dwBufferLength);
} else } else
wh32->dwBufferLength = wh16->dwBufferLength; wh32->dwBufferLength = wh16->dwBufferLength;
...@@ -646,7 +646,7 @@ static MMSYSTEM_MapType MMSYSTDRV_WaveOut_Map16To32W (DWORD wMsg, DWORD_PTR* l ...@@ -646,7 +646,7 @@ static MMSYSTEM_MapType MMSYSTDRV_WaveOut_Map16To32W (DWORD wMsg, DWORD_PTR* l
ret = MMSYSTEM_MAP_OK; ret = MMSYSTEM_MAP_OK;
break; break;
default: default:
FIXME("NIY: no conversion yet for %u [%lx,%lx]\n", wMsg, *lpParam1, *lpParam2); FIXME("NIY: no conversion yet for %lu [%lx,%lx]\n", wMsg, *lpParam1, *lpParam2);
break; break;
} }
return ret; return ret;
...@@ -726,7 +726,7 @@ static MMSYSTEM_MapType MMSYSTDRV_WaveOut_UnMap16To32W(DWORD wMsg, DWORD_PTR* l ...@@ -726,7 +726,7 @@ static MMSYSTEM_MapType MMSYSTDRV_WaveOut_UnMap16To32W(DWORD wMsg, DWORD_PTR* l
} }
break; break;
default: default:
FIXME("NIY: no conversion yet for %u [%lx,%lx]\n", wMsg, *lpParam1, *lpParam2); FIXME("NIY: no conversion yet for %lu [%lx,%lx]\n", wMsg, *lpParam1, *lpParam2);
break; break;
} }
return ret; return ret;
...@@ -754,7 +754,7 @@ static void MMSYSTDRV_WaveOut_MapCB(DWORD uMsg, DWORD_PTR* dwUser, DWORD_PTR* d ...@@ -754,7 +754,7 @@ static void MMSYSTDRV_WaveOut_MapCB(DWORD uMsg, DWORD_PTR* dwUser, DWORD_PTR* d
} }
break; break;
default: default:
ERR("Unknown msg %u\n", uMsg); ERR("Unknown msg %lu\n", uMsg);
} }
} }
...@@ -819,16 +819,16 @@ static LRESULT CALLBACK MMSYSTDRV_Callback3216(struct mmsystdrv_thunk* thunk, HD ...@@ -819,16 +819,16 @@ static LRESULT CALLBACK MMSYSTDRV_Callback3216(struct mmsystdrv_thunk* thunk, HD
TRACE("Null !\n"); TRACE("Null !\n");
break; break;
case CALLBACK_WINDOW: case CALLBACK_WINDOW:
TRACE("Window(%04X) handle=%p!\n", thunk->callback, hDev); TRACE("Window(%04lX) handle=%p!\n", thunk->callback, hDev);
PostMessageA((HWND)thunk->callback, wMsg, (WPARAM)hDev, dwParam1); PostMessageA((HWND)thunk->callback, wMsg, (WPARAM)hDev, dwParam1);
break; break;
case CALLBACK_TASK: /* aka CALLBACK_THREAD */ case CALLBACK_TASK: /* aka CALLBACK_THREAD */
TRACE("Task(%04x) !\n", thunk->callback); TRACE("Task(%04lx) !\n", thunk->callback);
PostThreadMessageA(thunk->callback, wMsg, (WPARAM)hDev, dwParam1); PostThreadMessageA(thunk->callback, wMsg, (WPARAM)hDev, dwParam1);
break; break;
case CALLBACK_FUNCTION: case CALLBACK_FUNCTION:
/* 16 bit func, call it */ /* 16 bit func, call it */
TRACE("Function (16 bit) %x!\n", thunk->callback); TRACE("Function (16 bit) %lx!\n", thunk->callback);
args[7] = HDRVR_16(hDev); args[7] = HDRVR_16(hDev);
args[6] = wMsg; args[6] = wMsg;
...@@ -840,11 +840,11 @@ static LRESULT CALLBACK MMSYSTDRV_Callback3216(struct mmsystdrv_thunk* thunk, HD ...@@ -840,11 +840,11 @@ static LRESULT CALLBACK MMSYSTDRV_Callback3216(struct mmsystdrv_thunk* thunk, HD
args[0] = LOWORD(dwParam2); args[0] = LOWORD(dwParam2);
return WOWCallback16Ex(thunk->callback, WCB16_PASCAL, sizeof(args), args, NULL); return WOWCallback16Ex(thunk->callback, WCB16_PASCAL, sizeof(args), args, NULL);
case CALLBACK_EVENT: case CALLBACK_EVENT:
TRACE("Event(%08x) !\n", thunk->callback); TRACE("Event(%08lx) !\n", thunk->callback);
SetEvent((HANDLE)thunk->callback); SetEvent((HANDLE)thunk->callback);
break; break;
default: default:
WARN("Unknown callback type %x\n", thunk->flags); WARN("Unknown callback type %lx\n", thunk->flags);
return FALSE; return FALSE;
} }
TRACE("Done\n"); TRACE("Done\n");
......
...@@ -88,7 +88,7 @@ static LRESULT MMIO_Map32To16(DWORD wMsg, LPARAM* lp1, LPARAM* lp2) ...@@ -88,7 +88,7 @@ static LRESULT MMIO_Map32To16(DWORD wMsg, LPARAM* lp1, LPARAM* lp2)
break; break;
default: default:
if (wMsg < MMIOM_USER) if (wMsg < MMIOM_USER)
TRACE("Not a mappable message (%d)\n", wMsg); TRACE("Not a mappable message (%ld)\n", wMsg);
} }
return MMSYSERR_NOERROR; return MMSYSERR_NOERROR;
} }
...@@ -116,7 +116,7 @@ static LRESULT MMIO_UnMap32To16(DWORD wMsg, LPARAM lParam1, LPARAM lParam2, ...@@ -116,7 +116,7 @@ static LRESULT MMIO_UnMap32To16(DWORD wMsg, LPARAM lParam1, LPARAM lParam2,
break; break;
default: default:
if (wMsg < MMIOM_USER) if (wMsg < MMIOM_USER)
TRACE("Not a mappable message (%d)\n", wMsg); TRACE("Not a mappable message (%ld)\n", wMsg);
} }
return MMSYSERR_NOERROR; return MMSYSERR_NOERROR;
} }
...@@ -552,7 +552,7 @@ LPMMIOPROC16 WINAPI mmioInstallIOProc16(FOURCC fccIOProc, LPMMIOPROC16 pIOProc, ...@@ -552,7 +552,7 @@ LPMMIOPROC16 WINAPI mmioInstallIOProc16(FOURCC fccIOProc, LPMMIOPROC16 pIOProc,
} }
break; break;
default: default:
FIXME("Unsupported flags %08x\n", dwFlags); FIXME("Unsupported flags %08lx\n", dwFlags);
pIOProc = NULL; pIOProc = NULL;
} }
LeaveCriticalSection(&mmio_cs); LeaveCriticalSection(&mmio_cs);
......
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