mirror of https://github.com/buggins/dlangui.git
win32 backend: fix keyboard focus issue when returning back to dlangui window from another app with mouse instead of Alt+Tab (dlangide issue 26)
This commit is contained in:
parent
dabc76390b
commit
4ed1efd75b
|
@ -558,16 +558,19 @@ class Win32Window : Window {
|
||||||
action = MouseAction.ButtonDown;
|
action = MouseAction.ButtonDown;
|
||||||
button = MouseButton.Left;
|
button = MouseButton.Left;
|
||||||
pbuttonDetails = &_lbutton;
|
pbuttonDetails = &_lbutton;
|
||||||
|
SetFocus(_hwnd);
|
||||||
break;
|
break;
|
||||||
case WM_RBUTTONDOWN:
|
case WM_RBUTTONDOWN:
|
||||||
action = MouseAction.ButtonDown;
|
action = MouseAction.ButtonDown;
|
||||||
button = MouseButton.Right;
|
button = MouseButton.Right;
|
||||||
pbuttonDetails = &_rbutton;
|
pbuttonDetails = &_rbutton;
|
||||||
|
SetFocus(_hwnd);
|
||||||
break;
|
break;
|
||||||
case WM_MBUTTONDOWN:
|
case WM_MBUTTONDOWN:
|
||||||
action = MouseAction.ButtonDown;
|
action = MouseAction.ButtonDown;
|
||||||
button = MouseButton.Middle;
|
button = MouseButton.Middle;
|
||||||
pbuttonDetails = &_mbutton;
|
pbuttonDetails = &_mbutton;
|
||||||
|
SetFocus(_hwnd);
|
||||||
break;
|
break;
|
||||||
case WM_LBUTTONUP:
|
case WM_LBUTTONUP:
|
||||||
action = MouseAction.ButtonUp;
|
action = MouseAction.ButtonUp;
|
||||||
|
|
Loading…
Reference in New Issue