mirror of
https://github.com/reactos/wine.git
synced 2025-01-31 09:01:59 +00:00
Fake MIDI_IO_STATUS support in midi in open
Fixed bug in midi in while reading data
This commit is contained in:
parent
6ff83ad45f
commit
29ebdb7690
@ -553,6 +553,7 @@ static VOID WINAPI midTimeCallback(HWND hwnd, UINT msg, UINT id, DWORD dwTime)
|
||||
|
||||
len = read(midiSeqFD, buffer, sizeof(buffer));
|
||||
|
||||
if (len < 0) return;
|
||||
if ((len % 4) != 0) {
|
||||
WARN("bad length %d (%d)\n", len, errno);
|
||||
return;
|
||||
@ -627,6 +628,7 @@ static DWORD midOpen(WORD wDevID, LPMIDIOPENDESC lpDesc, DWORD dwFlags)
|
||||
WARN("Invalid Parameter !\n");
|
||||
return MMSYSERR_INVALPARAM;
|
||||
}
|
||||
|
||||
/* FIXME :
|
||||
* how to check that content of lpDesc is correct ?
|
||||
*/
|
||||
@ -638,8 +640,12 @@ static DWORD midOpen(WORD wDevID, LPMIDIOPENDESC lpDesc, DWORD dwFlags)
|
||||
WARN("device already open !\n");
|
||||
return MMSYSERR_ALLOCATED;
|
||||
}
|
||||
if ((dwFlags & MIDI_IO_STATUS) != 0) {
|
||||
WARN("No support for MIDI_IO_STATUS in dwFlags yet, ignoring it\n");
|
||||
dwFlags &= ~MIDI_IO_STATUS;
|
||||
}
|
||||
if ((dwFlags & ~CALLBACK_TYPEMASK) != 0) {
|
||||
FIXME("No support for MIDI_IO_STATUS in dwFlags\n");
|
||||
FIXME("Bad dwFlags\n");
|
||||
return MMSYSERR_INVALFLAG;
|
||||
}
|
||||
|
||||
|
@ -114,6 +114,8 @@ typedef struct {
|
||||
#define MM_MOM_DONE 0x3C9
|
||||
#define MM_MOM_POSITIONCB 0x3CA
|
||||
|
||||
#define MM_MIM_MOREDATA 0x3CC
|
||||
|
||||
#define MMSYSERR_BASE 0
|
||||
#define WAVERR_BASE 32
|
||||
#define MIDIERR_BASE 64
|
||||
@ -471,6 +473,9 @@ typedef WORD *LPKEYARRAY;
|
||||
#define MIDIMAPPER (-1)
|
||||
#define MIDI_MAPPER (-1)
|
||||
|
||||
/* Only on Win95 and up */
|
||||
#define MIDI_IO_STATUS 0x00000020L
|
||||
|
||||
/* flags for wFlags parm of
|
||||
midiOutCachePatches(),
|
||||
midiOutCacheDrumPatches() */
|
||||
|
Loading…
x
Reference in New Issue
Block a user