Commit 5344d70c authored by Dmitry Timoshkov's avatar Dmitry Timoshkov Committed by Alexandre Julliard

Reset BUTTON_HASFOCUS state in WM_KILLFOCUS handler before calling

ReleaseCapture.
parent 7cdd584d
...@@ -364,11 +364,11 @@ static LRESULT WINAPI ButtonWndProc_common(HWND hWnd, UINT uMsg, ...@@ -364,11 +364,11 @@ static LRESULT WINAPI ButtonWndProc_common(HWND hWnd, UINT uMsg,
case WM_KILLFOCUS: case WM_KILLFOCUS:
state = get_button_state( hWnd ); state = get_button_state( hWnd );
if ((state & BUTTON_BTNPRESSED) && GetCapture() == hWnd)
ReleaseCapture();
set_button_state( hWnd, state & ~BUTTON_HASFOCUS ); set_button_state( hWnd, state & ~BUTTON_HASFOCUS );
paint_button( hWnd, btn_type, ODA_FOCUS ); paint_button( hWnd, btn_type, ODA_FOCUS );
if ((state & BUTTON_BTNPRESSED) && GetCapture() == hWnd)
ReleaseCapture();
break; break;
case WM_SYSCOLORCHANGE: case WM_SYSCOLORCHANGE:
......
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