diff options
author | Noel Grandin <noel@peralex.com> | 2016-04-25 09:59:16 +0200 |
---|---|---|
committer | Ashod Nakashian <ashod.nakashian@collabora.co.uk> | 2016-07-12 22:06:19 -0400 |
commit | c5cdfe39d3afca716e7b11f8f8e169ce378861ea (patch) | |
tree | 5b804fa2e78405afe16db734f88f24a7b9714209 /sfx2/source/control/sfxstatuslistener.cxx | |
parent | 0c4c31576fe03b3b59217bf9990b75f32d193d0d (diff) |
update loplugin stylepolice to check local pointers vars
are actually pointer vars.
Also convert from regex to normal code, so we can enable this
plugin all the time.
Reviewed-on: https://gerrit.libreoffice.org/24391
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
(cherry picked from commit e8fd5a07eca70912ddee45aaa34d434809b59fb7)
Change-Id: Ie36a25ecba61c18f99c77c77646d6459a443cbd1
Diffstat (limited to 'sfx2/source/control/sfxstatuslistener.cxx')
-rw-r--r-- | sfx2/source/control/sfxstatuslistener.cxx | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/sfx2/source/control/sfxstatuslistener.cxx b/sfx2/source/control/sfxstatuslistener.cxx index 4e6567ecb186..dab426adf6b2 100644 --- a/sfx2/source/control/sfxstatuslistener.cxx +++ b/sfx2/source/control/sfxstatuslistener.cxx @@ -168,45 +168,45 @@ throw( RuntimeException, std::exception ) if ( rEvent.IsEnabled ) { eState = SfxItemState::DEFAULT; - css::uno::Type pType = rEvent.State.getValueType(); + css::uno::Type aType = rEvent.State.getValueType(); - if ( pType == ::cppu::UnoType<void>::get() ) + if ( aType == ::cppu::UnoType<void>::get() ) { pItem = new SfxVoidItem( m_nSlotID ); eState = SfxItemState::UNKNOWN; } - else if ( pType == cppu::UnoType< bool >::get() ) + else if ( aType == cppu::UnoType< bool >::get() ) { bool bTemp = false; rEvent.State >>= bTemp ; pItem = new SfxBoolItem( m_nSlotID, bTemp ); } - else if ( pType == cppu::UnoType< ::cppu::UnoUnsignedShortType >::get() ) + else if ( aType == cppu::UnoType< ::cppu::UnoUnsignedShortType >::get() ) { sal_uInt16 nTemp = 0; rEvent.State >>= nTemp ; pItem = new SfxUInt16Item( m_nSlotID, nTemp ); } - else if ( pType == cppu::UnoType<sal_uInt32>::get() ) + else if ( aType == cppu::UnoType<sal_uInt32>::get() ) { sal_uInt32 nTemp = 0; rEvent.State >>= nTemp ; pItem = new SfxUInt32Item( m_nSlotID, nTemp ); } - else if ( pType == cppu::UnoType<OUString>::get() ) + else if ( aType == cppu::UnoType<OUString>::get() ) { OUString sTemp ; rEvent.State >>= sTemp ; pItem = new SfxStringItem( m_nSlotID, sTemp ); } - else if ( pType == cppu::UnoType< css::frame::status::ItemStatus >::get() ) + else if ( aType == cppu::UnoType< css::frame::status::ItemStatus >::get() ) { ItemStatus aItemStatus; rEvent.State >>= aItemStatus; eState = (SfxItemState) aItemStatus.State; pItem = new SfxVoidItem( m_nSlotID ); } - else if ( pType == cppu::UnoType< css::frame::status::Visibility >::get() ) + else if ( aType == cppu::UnoType< css::frame::status::Visibility >::get() ) { Visibility aVisibilityStatus; rEvent.State >>= aVisibilityStatus; |