diff options
author | George Hazan <ghazan@miranda.im> | 2019-02-01 15:46:41 +0300 |
---|---|---|
committer | George Hazan <ghazan@miranda.im> | 2019-02-01 15:46:41 +0300 |
commit | c4f2f0a8c643304f73cdbea1299c00cf19e8986c (patch) | |
tree | cdff1f4fdfe4a16664a42f2dbf931a63c9e18c2a /src/core | |
parent | cf24ded29a5769680068cc46b5e99fe576c0efaa (diff) |
fixes #1762 (StdMsg: Text selection bug in the message log since 0.95.8)
Diffstat (limited to 'src/core')
-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);
|