diff options
-rw-r--r-- | src/core/stdmsg/src/msgdialog.cpp | 1 | ||||
-rw-r--r-- | src/core/stdmsg/src/msgs.cpp | 15 |
2 files changed, 8 insertions, 8 deletions
diff --git a/src/core/stdmsg/src/msgdialog.cpp b/src/core/stdmsg/src/msgdialog.cpp index 7007811647..3702f21c0c 100644 --- a/src/core/stdmsg/src/msgdialog.cpp +++ b/src/core/stdmsg/src/msgdialog.cpp @@ -311,7 +311,6 @@ void CSrmmWindow::OnDestroy() void CSrmmWindow::OnActivate()
{
SetupStatusBar();
- SetFocus(m_message.GetHwnd());
UpdateTitle();
UpdateLastMessage();
StopFlash();
diff --git a/src/core/stdmsg/src/msgs.cpp b/src/core/stdmsg/src/msgs.cpp index a2c979839c..ac88cf3e9c 100644 --- a/src/core/stdmsg/src/msgs.cpp +++ b/src/core/stdmsg/src/msgs.cpp @@ -46,8 +46,14 @@ INT_PTR CMsgDialog::DlgProc(UINT uMsg, WPARAM wParam, LPARAM lParam) {
switch (uMsg) {
case WM_ACTIVATE:
- if (LOWORD(wParam) == WA_ACTIVE)
- OnActivate();
+ if (LOWORD(wParam) != WA_ACTIVE)
+ break;
+
+ SetFocus(m_message.GetHwnd());
+ __fallthrough;
+
+ case WM_MOUSEACTIVATE:
+ OnActivate();
break;
case WM_TIMER:
@@ -58,11 +64,6 @@ INT_PTR CMsgDialog::DlgProc(UINT uMsg, WPARAM wParam, LPARAM lParam) m_nFlash++;
}
break;
-
- case WM_MOUSEACTIVATE:
- OnActivate();
- SetFocus(m_message.GetHwnd());
- break;
}
return CSuper::DlgProc(uMsg, wParam, lParam);
|