From 9f61e31b9ccdfe93b693998cab1baa331f87cd97 Mon Sep 17 00:00:00 2001 From: George Hazan Date: Thu, 13 Apr 2017 14:44:28 +0300 Subject: two new functions: CDlgBase::Resize & Hide --- src/core/stdmsg/src/chat_window.cpp | 4 ++-- src/core/stdmsg/src/msgdialog.cpp | 8 ++++---- 2 files changed, 6 insertions(+), 6 deletions(-) (limited to 'src/core') diff --git a/src/core/stdmsg/src/chat_window.cpp b/src/core/stdmsg/src/chat_window.cpp index d9114da0ae..0d5ae4e629 100644 --- a/src/core/stdmsg/src/chat_window.cpp +++ b/src/core/stdmsg/src/chat_window.cpp @@ -112,7 +112,7 @@ void CChatRoomDlg::onClick_NickList(CCtrlButton *pButton) pButton->SendMsg(BM_SETIMAGE, IMAGE_ICON, (LPARAM)LoadIconEx(m_bNicklistEnabled ? "nicklist" : "nicklist2", FALSE)); ScrollToBottom(); - SendMessage(m_hwnd, WM_SIZE, 0, 0); + Resize(); } void CChatRoomDlg::onClick_Ok(CCtrlButton *pButton) @@ -321,7 +321,7 @@ void CChatRoomDlg::UpdateOptions() m_nickList.SendMsg(LB_SETITEMHEIGHT, 0, height > font ? height : font); InvalidateRect(m_nickList.GetHwnd(), nullptr, TRUE); - SendMessage(m_hwnd, WM_SIZE, 0, 0); + Resize(); RedrawLog2(); } diff --git a/src/core/stdmsg/src/msgdialog.cpp b/src/core/stdmsg/src/msgdialog.cpp index a39c109175..c3ed9caeee 100644 --- a/src/core/stdmsg/src/msgdialog.cpp +++ b/src/core/stdmsg/src/msgdialog.cpp @@ -387,7 +387,7 @@ void CSrmmWindow::OnOptionsApplied(bool bUpdateAvatar) if (m_avatarPic == nullptr || !g_dat.bShowAvatar) m_avatar.Hide(); SendMessage(m_hwnd, DM_UPDATETITLE, 0, 0); - SendMessage(m_hwnd, WM_SIZE, 0, 0); + Resize(); if (m_hBkgBrush) DeleteObject(m_hBkgBrush); @@ -964,7 +964,7 @@ INT_PTR CSrmmWindow::DlgProc(UINT uMsg, WPARAM wParam, LPARAM lParam) if (rc.bottom - rc.top < m_minEditBoxSize.cy) m_splitter.OnChange(&m_splitter); - SendMessage(m_hwnd, WM_SIZE, 0, 0); + Resize(); break; case DM_GETAVATAR: @@ -1063,14 +1063,14 @@ INT_PTR CSrmmWindow::DlgProc(UINT uMsg, WPARAM wParam, LPARAM lParam) GetWindowText(m_hwnd, oldtitle, _countof(oldtitle)); if (mir_wstrcmp(newtitle, oldtitle)) { //swt() flickers even if the title hasn't actually changed SetWindowText(m_pOwner->GetHwnd(), newtitle); - SendMessage(m_hwnd, WM_SIZE, 0, 0); + Resize(); } break; case DM_NEWTIMEZONE: m_hTimeZone = TimeZone_CreateByContact(m_hContact, 0, TZF_KNOWNONLY); m_wMinute = 61; - SendMessage(m_hwnd, WM_SIZE, 0, 0); + Resize(); break; case DM_CASCADENEWWINDOW: -- cgit v1.2.3