diff options
Diffstat (limited to 'plugins/HistoryStats/src/optionsctrlimpl_check.cpp')
-rw-r--r-- | plugins/HistoryStats/src/optionsctrlimpl_check.cpp | 13 |
1 files changed, 3 insertions, 10 deletions
diff --git a/plugins/HistoryStats/src/optionsctrlimpl_check.cpp b/plugins/HistoryStats/src/optionsctrlimpl_check.cpp index 21d9677636..b70ebcc0e8 100644 --- a/plugins/HistoryStats/src/optionsctrlimpl_check.cpp +++ b/plugins/HistoryStats/src/optionsctrlimpl_check.cpp @@ -22,13 +22,11 @@ void OptionsCtrlImpl::Check::updateItem() m_pCtrl->setStateImage(m_hItem, m_bEnabled ? (m_bChecked ? siCheckC : siCheckU) : (m_bChecked ? siCheckCG : siCheckUG));
if (m_bDisableChilds || m_bDisableChildsOnUncheck)
- {
enableChilds(getChildEnable());
- }
}
-OptionsCtrlImpl::Check::Check(OptionsCtrlImpl* pCtrl, Item* pParent, const TCHAR* szLabel, DWORD dwFlags, DWORD dwData)
- : Item(pCtrl, itCheck, szLabel, dwFlags, dwData)
+OptionsCtrlImpl::Check::Check(OptionsCtrlImpl* pCtrl, Item* pParent, const TCHAR* szLabel, DWORD dwFlags, INT_PTR dwData) :
+ Item(pCtrl, itCheck, szLabel, dwFlags, dwData)
{
m_bChecked = bool_(dwFlags & OCF_CHECKED);
m_bDisableChildsOnUncheck = bool_(dwFlags & OCF_DISABLECHILDSONUNCHECK);
@@ -36,15 +34,12 @@ OptionsCtrlImpl::Check::Check(OptionsCtrlImpl* pCtrl, Item* pParent, const TCHAR pCtrl->insertItem(pParent, this, szLabel, dwFlags, getStateImage());
if (pParent)
- {
pParent->childAdded(this);
- }
}
void OptionsCtrlImpl::Check::onToggle()
{
- if (m_bEnabled)
- {
+ if (m_bEnabled) {
setChecked(!m_bChecked);
m_pCtrl->setModified(this);
}
@@ -53,7 +48,5 @@ void OptionsCtrlImpl::Check::onToggle() void OptionsCtrlImpl::Check::childAdded(Item* pChild)
{
if (m_bDisableChilds || m_bDisableChildsOnUncheck)
- {
pChild->setEnabled(getChildEnable());
- }
}
|