diff options
author | George Hazan <ghazan@miranda.im> | 2021-02-27 17:12:48 +0300 |
---|---|---|
committer | George Hazan <ghazan@miranda.im> | 2021-02-27 17:12:48 +0300 |
commit | b8c8df44a68fe62575e46278ba10da3f91c60517 (patch) | |
tree | 48c4d0ea7a61f032352ef8837a1d3263b386f15b /src/mir_core | |
parent | f739848ff5ace0f3340b9b6e9977c649a0574293 (diff) |
fixes #2753 (by default only checkboxes should be notified about OnChange before OnInitDialog)
Diffstat (limited to 'src/mir_core')
-rw-r--r-- | src/mir_core/src/CCtrlCheck.cpp | 4 | ||||
-rw-r--r-- | src/mir_core/src/CDlgBase.cpp | 3 |
2 files changed, 5 insertions, 2 deletions
diff --git a/src/mir_core/src/CCtrlCheck.cpp b/src/mir_core/src/CCtrlCheck.cpp index a20a1a9275..210c6a1d03 100644 --- a/src/mir_core/src/CCtrlCheck.cpp +++ b/src/mir_core/src/CCtrlCheck.cpp @@ -27,7 +27,9 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. CCtrlCheck::CCtrlCheck(CDlgBase *dlg, int ctrlId) : CCtrlData(dlg, ctrlId) -{} +{ + m_bNotifiable = true; +} BOOL CCtrlCheck::OnCommand(HWND, WORD, WORD) { diff --git a/src/mir_core/src/CDlgBase.cpp b/src/mir_core/src/CDlgBase.cpp index dcfe15b292..95449c56a0 100644 --- a/src/mir_core/src/CDlgBase.cpp +++ b/src/mir_core/src/CDlgBase.cpp @@ -219,7 +219,8 @@ INT_PTR CDlgBase::DlgProc(UINT msg, WPARAM wParam, LPARAM lParam) return FALSE; for (auto &it : m_controls) - it->OnChange(it); + if (it->m_bNotifiable) + it->OnChange(it); m_bInitialized = true; return TRUE; |