mirror of
https://github.com/reactos/reactos.git
synced 2025-01-05 22:12:46 +00:00
[MPLAY32] Give a valid pointer to a MCI_SEEK_PARMS structure when using MCI_SEEK_TO_START flag. By Ricardo Hanke. CORE-9408
svn path=/trunk/; revision=66856
This commit is contained in:
parent
40da1525c9
commit
89656789aa
1 changed files with 4 additions and 2 deletions
|
@ -640,6 +640,7 @@ StopPlayback(HWND hwnd)
|
||||||
{
|
{
|
||||||
MCIERROR mciError;
|
MCIERROR mciError;
|
||||||
MCI_GENERIC_PARMS mciGeneric;
|
MCI_GENERIC_PARMS mciGeneric;
|
||||||
|
MCI_SEEK_PARMS mciSeek;
|
||||||
|
|
||||||
if (wDeviceId == 0) return;
|
if (wDeviceId == 0) return;
|
||||||
|
|
||||||
|
@ -654,7 +655,7 @@ StopPlayback(HWND hwnd)
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
mciSendCommand(wDeviceId, MCI_SEEK, MCI_WAIT | MCI_SEEK_TO_START, 0);
|
mciSendCommand(wDeviceId, MCI_SEEK, MCI_WAIT | MCI_SEEK_TO_START, (DWORD_PTR)&mciSeek);
|
||||||
|
|
||||||
UpdateTimeDisplay(hTimeDisplay);
|
UpdateTimeDisplay(hTimeDisplay);
|
||||||
UpdateWindowCaption(hwnd);
|
UpdateWindowCaption(hwnd);
|
||||||
|
@ -777,10 +778,11 @@ StartPlayback(HWND hwnd)
|
||||||
{
|
{
|
||||||
MCIERROR mciError;
|
MCIERROR mciError;
|
||||||
MCI_PLAY_PARMS mciPlay;
|
MCI_PLAY_PARMS mciPlay;
|
||||||
|
MCI_SEEK_PARMS mciSeek;
|
||||||
|
|
||||||
SetTimer(hwnd, IDT_PLAYTIMER, 100, (TIMERPROC)PlayTimerProc);
|
SetTimer(hwnd, IDT_PLAYTIMER, 100, (TIMERPROC)PlayTimerProc);
|
||||||
|
|
||||||
mciSendCommand(wDeviceId, MCI_SEEK, MCI_WAIT | MCI_SEEK_TO_START, 0);
|
mciSendCommand(wDeviceId, MCI_SEEK, MCI_WAIT | MCI_SEEK_TO_START, (DWORD_PTR)&mciSeek);
|
||||||
|
|
||||||
mciPlay.dwCallback = (DWORD_PTR)hwnd;
|
mciPlay.dwCallback = (DWORD_PTR)hwnd;
|
||||||
mciPlay.dwFrom = 0;
|
mciPlay.dwFrom = 0;
|
||||||
|
|
Loading…
Reference in a new issue