Commit b6c4beda authored by Dmitry Timoshkov's avatar Dmitry Timoshkov Committed by Alexandre Julliard

msvideo: Handle ESC key press in the MCIWND class as an alias to stop command.

parent 180326bb
......@@ -429,6 +429,21 @@ static LRESULT mci_get_devcaps(MCIWndInfo *mwi, UINT cap)
return mci_devcaps.dwReturn;
}
static LRESULT MCIWND_KeyDown(MCIWndInfo *mwi, UINT key)
{
TRACE("%p, key %04x\n", mwi->hWnd, key);
switch(key)
{
case VK_ESCAPE:
SendMessageW(mwi->hWnd, MCI_STOP, 0, 0);
return 0;
default:
return 0;
}
}
static LRESULT WINAPI MCIWndProc(HWND hWnd, UINT wMsg, WPARAM wParam, LPARAM lParam)
{
MCIWndInfo *mwi;
......@@ -477,6 +492,9 @@ static LRESULT WINAPI MCIWndProc(HWND hWnd, UINT wMsg, WPARAM wParam, LPARAM lPa
case WM_COMMAND:
return MCIWND_Command(mwi, wParam, lParam);
case WM_KEYDOWN:
return MCIWND_KeyDown(mwi, wParam);
case WM_NCACTIVATE:
if (mwi->uTimer)
{
......
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