diff options
author | Noel Grandin <noel.grandin@collabora.co.uk> | 2018-12-08 14:59:51 +0200 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2018-12-09 07:18:17 +0100 |
commit | 0d43b791e60aa75eb7f769d0f9b3177f93e1591c (patch) | |
tree | 0f22f0ab1972013ff6c7cce91895d1b69c236dfb /cui/source/tabpages | |
parent | 145280ffd1dabdc629c14c8162beef668741bcef (diff) |
loplugin:unusedmethods
Change-Id: I4f2635d468c9ad83b3ac93733529e01a4d03f38e
Reviewed-on: https://gerrit.libreoffice.org/64805
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'cui/source/tabpages')
-rw-r--r-- | cui/source/tabpages/autocdlg.cxx | 102 |
1 files changed, 0 insertions, 102 deletions
diff --git a/cui/source/tabpages/autocdlg.cxx b/cui/source/tabpages/autocdlg.cxx index 153d9af05823..add6fb72f3cf 100644 --- a/cui/source/tabpages/autocdlg.cxx +++ b/cui/source/tabpages/autocdlg.cxx @@ -654,108 +654,6 @@ IMPL_LINK_NOARG(OfaSwAutoFmtOptionsPage, EditHdl, weld::Button&, void) } } -void OfaACorrCheckListBox::SetTabs() -{ - SvSimpleTable::SetTabs(); - SvLBoxTabFlags nAdjust = SvLBoxTabFlags::ADJUST_RIGHT|SvLBoxTabFlags::ADJUST_LEFT|SvLBoxTabFlags::ADJUST_CENTER|SvLBoxTabFlags::FORCE; - - if( aTabs.size() > 1 ) - { - SvLBoxTab* pTab = aTabs[1].get(); - pTab->nFlags &= ~nAdjust; - pTab->nFlags |= SvLBoxTabFlags::ADJUST_CENTER|SvLBoxTabFlags::FORCE; - } - if( aTabs.size() > 2 ) - { - SvLBoxTab* pTab = aTabs[2].get(); - pTab->nFlags &= ~nAdjust; - pTab->nFlags |= SvLBoxTabFlags::ADJUST_CENTER|SvLBoxTabFlags::FORCE; - } -} - -void OfaACorrCheckListBox::CheckEntryPos(sal_uLong nPos, sal_uInt16 nCol, bool bChecked) -{ - if ( nPos < GetEntryCount() ) - SetCheckButtonState( - GetEntry(nPos), - nCol, - bChecked ? SvButtonState::Checked : SvButtonState::Unchecked ); -} - -bool OfaACorrCheckListBox::IsChecked(sal_uLong nPos, sal_uInt16 nCol) -{ - return GetCheckButtonState( GetEntry(nPos), nCol ) == SvButtonState::Checked; -} - -void OfaACorrCheckListBox::SetCheckButtonState( SvTreeListEntry* pEntry, sal_uInt16 nCol, SvButtonState eState) -{ - SvLBoxButton& rItem = static_cast<SvLBoxButton&>(pEntry->GetItem(nCol + 1)); - - if (rItem.GetType() == SvLBoxItemType::Button) - { - switch( eState ) - { - case SvButtonState::Checked: - rItem.SetStateChecked(); - break; - - case SvButtonState::Unchecked: - rItem.SetStateUnchecked(); - break; - - case SvButtonState::Tristate: - rItem.SetStateTristate(); - break; - } - InvalidateEntry( pEntry ); - } -} - -SvButtonState OfaACorrCheckListBox::GetCheckButtonState( SvTreeListEntry* pEntry, sal_uInt16 nCol ) -{ - SvButtonState eState = SvButtonState::Unchecked; - SvLBoxButton& rItem = static_cast<SvLBoxButton&>(pEntry->GetItem(nCol + 1)); - - if (rItem.GetType() == SvLBoxItemType::Button) - { - SvItemStateFlags nButtonFlags = rItem.GetButtonFlags(); - eState = SvLBoxButtonData::ConvertToButtonState( nButtonFlags ); - } - - return eState; -} - -void OfaACorrCheckListBox::HBarClick() -{ - // sorting is stopped by this override -} - -void OfaACorrCheckListBox::KeyInput( const KeyEvent& rKEvt ) -{ - if(!rKEvt.GetKeyCode().GetModifier() && - KEY_SPACE == rKEvt.GetKeyCode().GetCode()) - { - sal_uLong nSelPos = GetSelectedEntryPos(); - sal_uInt16 nCol = GetCurrentTabPos() - 1; - if ( nCol < 2 ) - { - CheckEntryPos( nSelPos, nCol, !IsChecked( nSelPos, nCol ) ); - CallImplEventListeners( VclEventId::CheckboxToggle, static_cast<void*>(GetEntry( nSelPos )) ); - } - else - { - sal_uInt16 nCheck = IsChecked(nSelPos, 1) ? 1 : 0; - if(IsChecked(nSelPos)) - nCheck += 2; - nCheck--; - nCheck &= 3; - CheckEntryPos(nSelPos, 1, 0 != (nCheck & 1)); - CheckEntryPos(nSelPos, 0, 0 != (nCheck & 2)); - } - } - else - SvSimpleTable::KeyInput(rKEvt); -} OfaAutocorrReplacePage::OfaAutocorrReplacePage(TabPageParent pParent, const SfxItemSet& rSet) |