diff options
Diffstat (limited to 'plugins/TabSRMM')
-rw-r--r-- | plugins/TabSRMM/src/msgdialog.cpp | 4 | ||||
-rw-r--r-- | plugins/TabSRMM/src/msgdlgother.cpp | 10 |
2 files changed, 4 insertions, 10 deletions
diff --git a/plugins/TabSRMM/src/msgdialog.cpp b/plugins/TabSRMM/src/msgdialog.cpp index 476d42eb5f..3d93d6d4a5 100644 --- a/plugins/TabSRMM/src/msgdialog.cpp +++ b/plugins/TabSRMM/src/msgdialog.cpp @@ -923,10 +923,8 @@ void CMsgDialog::onClick_Filter(CCtrlButton *pButton) if (m_bFilterEnabled && !g_chatApi.bRightClickFilter)
ShowFilterMenu();
else {
- if (m_hwndFilter) {
+ if (m_hwndFilter)
SendMessage(m_hwndFilter, WM_CLOSE, 0, 0);
- m_hwndFilter = nullptr;
- }
RedrawLog();
UpdateTitle();
diff --git a/plugins/TabSRMM/src/msgdlgother.cpp b/plugins/TabSRMM/src/msgdlgother.cpp index c2f2afd3e3..b7696c9658 100644 --- a/plugins/TabSRMM/src/msgdlgother.cpp +++ b/plugins/TabSRMM/src/msgdlgother.cpp @@ -1768,11 +1768,9 @@ static INT_PTR CALLBACK FilterWndProc(HWND hwndDlg, UINT uMsg, WPARAM wParam, LP Chat_SetFilters(pDlg->getChat());
pDlg->RedrawLog();
}
- DestroyWindow(hwndDlg);
- break;
- case WM_DESTROY:
- SetWindowLongPtr(hwndDlg, GWLP_USERDATA, 0);
+ pDlg->m_hwndFilter = nullptr;
+ DestroyWindow(hwndDlg);
break;
}
return FALSE;
@@ -2551,10 +2549,8 @@ void CMsgDialog::UpdateWindowState(UINT msg) RECT rcFilter;
GetWindowRect(m_hwndFilter, &rcFilter);
- if (!PtInRect(&rcFilter, pt)) {
+ if (!PtInRect(&rcFilter, pt))
SendMessage(m_hwndFilter, WM_CLOSE, 1, 1);
- m_hwndFilter = nullptr;
- }
}
if (m_bIsAutosizingInput && m_iInputAreaHeight == -1) {
|