diff options
author | George Hazan <george.hazan@gmail.com> | 2024-03-10 19:17:00 +0300 |
---|---|---|
committer | George Hazan <george.hazan@gmail.com> | 2024-03-10 19:17:00 +0300 |
commit | d43ae9445d4457b01513c14f5574d97cbbe6dc05 (patch) | |
tree | 0608d93fc9265cfe3c93fa947bc83a7060a64d02 | |
parent | 75e084b3950dc3bdba33e6b611b4c4a3f370dc72 (diff) |
tabSRMM: fix for the tabs activation detection
-rw-r--r-- | src/mir_app/src/srmm_base.cpp | 18 |
1 files changed, 11 insertions, 7 deletions
diff --git a/src/mir_app/src/srmm_base.cpp b/src/mir_app/src/srmm_base.cpp index cdb5cc4c06..a6b1d8554a 100644 --- a/src/mir_app/src/srmm_base.cpp +++ b/src/mir_app/src/srmm_base.cpp @@ -598,6 +598,16 @@ INT_PTR CSrmmBaseDialog::DlgProc(UINT msg, WPARAM wParam, LPARAM lParam) OnOptionsApplied();
return 0;
+ case WM_SHOWWINDOW:
+ if (wParam) {
+ m_bActive = true;
+ for (auto &it : m_arDisplayedEvents)
+ doMarkEventRead(m_hContact, it);
+ m_arDisplayedEvents.clear();
+ }
+ else m_bActive = false;
+ break;
+
case WM_COMMAND:
if (!lParam && Clist_MenuProcessCommand(LOWORD(wParam), MPCF_CONTACTMENU, m_hContact))
return 0;
@@ -609,13 +619,7 @@ INT_PTR CSrmmBaseDialog::DlgProc(UINT msg, WPARAM wParam, LPARAM lParam) break;
case WM_ACTIVATE:
- m_bActive = LOWORD(wParam) != WA_INACTIVE;
- if (m_bActive) {
- for (auto &it : m_arDisplayedEvents)
- doMarkEventRead(m_hContact, it);
- m_arDisplayedEvents.clear();
- }
- else if (m_si) {
+ if (m_si && LOWORD(wParam) == WA_INACTIVE) {
m_si->wState &= ~GC_EVENT_HIGHLIGHT;
m_si->wState &= ~STATE_TALK;
}
|