diff options
Diffstat (limited to 'src/mir_app')
-rw-r--r-- | src/mir_app/src/chat_clist.cpp | 2 | ||||
-rw-r--r-- | src/mir_app/src/chat_manager.cpp | 2 | ||||
-rw-r--r-- | src/mir_app/src/chat_svc.cpp | 4 |
3 files changed, 3 insertions, 5 deletions
diff --git a/src/mir_app/src/chat_clist.cpp b/src/mir_app/src/chat_clist.cpp index c197c92f33..43b6c7791a 100644 --- a/src/mir_app/src/chat_clist.cpp +++ b/src/mir_app/src/chat_clist.cpp @@ -118,7 +118,7 @@ int RoomDoubleclicked(WPARAM hContact, LPARAM) if (si) {
// is the "toggle visibility option set, so we need to close the window?
if (si->pDlg != nullptr && db_get_b(0, CHAT_MODULE, "ToggleVisibility", 0) == 1 && !cli.pfnGetEvent(hContact, 0) && IsWindowVisible(si->pDlg->GetHwnd()) && !IsIconic(si->pDlg->GetHwnd())) {
- PostMessage(si->pDlg->GetHwnd(), GC_CLOSEWINDOW, 0, 0);
+ si->pDlg->CloseTab();
return 1;
}
chatApi.ShowRoom(si);
diff --git a/src/mir_app/src/chat_manager.cpp b/src/mir_app/src/chat_manager.cpp index b3ffd8fe09..d8cfe40999 100644 --- a/src/mir_app/src/chat_manager.cpp +++ b/src/mir_app/src/chat_manager.cpp @@ -73,7 +73,7 @@ static void SM_FreeSession(SESSION_INFO *si, bool bRemoveContact = false) db_set_w(si->hContact, si->pszModule, "ApparentMode", 0);
if (si->pDlg)
- SendMessage(si->pDlg->GetHwnd(), GC_CLOSEWINDOW, 0, 1);
+ si->pDlg->CloseTab(true);
DoEventHook(si, GC_SESSION_TERMINATE, nullptr, nullptr, (INT_PTR)si->pItemData);
diff --git a/src/mir_app/src/chat_svc.cpp b/src/mir_app/src/chat_svc.cpp index 2becb12910..d7ac64cd01 100644 --- a/src/mir_app/src/chat_svc.cpp +++ b/src/mir_app/src/chat_svc.cpp @@ -102,8 +102,6 @@ static int IconsChanged(WPARAM, LPARAM) static int PreShutdown(WPARAM, LPARAM)
{
if (g_Settings != nullptr) {
- chatApi.SM_BroadcastMessage(nullptr, GC_CLOSEWINDOW, 0, 1, FALSE);
-
SM_RemoveAll();
chatApi.MM_RemoveAll();
@@ -284,7 +282,7 @@ static INT_PTR __stdcall stubRoomControl(void *param) SetInitDone(si);
chatApi.SetActiveSession(si);
if (si->pDlg)
- ::SendMessage(si->pDlg->GetHwnd(), GC_CLOSEWINDOW, 0, 0);
+ si->pDlg->CloseTab();
break;
case WINDOW_VISIBLE:
|