diff options
Diffstat (limited to 'sfx2/source/control')
-rw-r--r-- | sfx2/source/control/bindings.cxx | 64 | ||||
-rw-r--r-- | sfx2/source/control/ctrlitem.cxx | 16 | ||||
-rw-r--r-- | sfx2/source/control/dispatch.cxx | 12 | ||||
-rw-r--r-- | sfx2/source/control/querystatus.cxx | 10 | ||||
-rw-r--r-- | sfx2/source/control/request.cxx | 8 | ||||
-rw-r--r-- | sfx2/source/control/sfxstatuslistener.cxx | 6 | ||||
-rw-r--r-- | sfx2/source/control/shell.cxx | 16 | ||||
-rw-r--r-- | sfx2/source/control/statcach.cxx | 10 | ||||
-rw-r--r-- | sfx2/source/control/unoctitm.cxx | 18 |
9 files changed, 80 insertions, 80 deletions
diff --git a/sfx2/source/control/bindings.cxx b/sfx2/source/control/bindings.cxx index 0b95c9bc368a..4184c34b10fd 100644 --- a/sfx2/source/control/bindings.cxx +++ b/sfx2/source/control/bindings.cxx @@ -382,7 +382,7 @@ void SfxBindings::Update_Impl sal_uInt16 nWhich = pFound->nWhichId; const SfxPoolItem *pItem = 0; SfxItemState eState = pSet->GetItemState(nWhich, true, &pItem); - if ( eState == SFX_ITEM_DEFAULT && SfxItemPool::IsWhich(nWhich) ) + if ( eState == SfxItemState::DEFAULT && SfxItemPool::IsWhich(nWhich) ) pItem = &pSet->Get(nWhich); UpdateControllers_Impl( pInterface, aFound[nPos], pItem, eState ); } @@ -400,7 +400,7 @@ void SfxBindings::Update_Impl SfxFoundCache_Impl aFoundCache( pCache->GetId(), 0, pRealSlot, pCache ); - UpdateControllers_Impl( 0, &aFoundCache, 0, SFX_ITEM_DISABLED); + UpdateControllers_Impl( 0, &aFoundCache, 0, SfxItemState::DISABLED); } } @@ -472,7 +472,7 @@ void SfxBindings::Update } if (!pMsgServer) { - pCache->SetState(SFX_ITEM_DISABLED, 0); + pCache->SetState(SfxItemState::DISABLED, 0); pImp->bInUpdate = false; InvalidateSlotsInMap_Impl(); return; @@ -549,7 +549,7 @@ void SfxBindings::SetState // Update status if ( !pCache->IsControllerDirty() ) pCache->Invalidate(false); - pCache->SetState( SFX_ITEM_DEFAULT, pItem ); + pCache->SetState( SfxItemState::DEFAULT, pItem ); //! Not implemented: Updates from EnumSlots via master slots } @@ -583,7 +583,7 @@ void SfxBindings::SetState // Update Status if ( !pCache->IsControllerDirty() ) pCache->Invalidate(false); - pCache->SetState( SFX_ITEM_DEFAULT, &rItem ); + pCache->SetState( SfxItemState::DEFAULT, &rItem ); //! Not implemented: Updates from EnumSlots via master slots } @@ -1168,14 +1168,14 @@ void SfxBindings::Execute_Impl( SfxRequest& aReq, const SfxSlot* pSlot, SfxShell pShell->CallState( aFunc, aSet ); const SfxPoolItem *pOldItem; SfxItemState eState = aSet.GetItemState(nWhich, true, &pOldItem); - if ( eState == SFX_ITEM_DISABLED ) + if ( eState == SfxItemState::DISABLED ) return; - if ( SFX_ITEM_DEFAULT == eState && SfxItemPool::IsWhich(nWhich) ) + if ( SfxItemState::DEFAULT == eState && SfxItemPool::IsWhich(nWhich) ) pOldItem = &aSet.Get(nWhich); - if ( SFX_ITEM_SET == eState || - ( SFX_ITEM_DEFAULT == eState && + if ( SfxItemState::SET == eState || + ( SfxItemState::DEFAULT == eState && SfxItemPool::IsWhich(nWhich) && pOldItem ) ) { @@ -1202,7 +1202,7 @@ void SfxBindings::Execute_Impl( SfxRequest& aReq, const SfxSlot* pSlot, SfxShell OSL_FAIL( "Toggle only for Enums and Bools allowed" ); } } - else if ( SFX_ITEM_DONTCARE == eState ) + else if ( SfxItemState::DONTCARE == eState ) { // Create one Status-Item for each Factory SfxPoolItem *pNewItem = pSlot->GetType()->CreateItem(); @@ -1423,22 +1423,22 @@ void SfxBindings::UpdateControllers_Impl // bound until now, the Controller to update the Slot. if ( pCache && pCache->IsControllerDirty() ) { - if ( SFX_ITEM_DONTCARE == eState ) + if ( SfxItemState::DONTCARE == eState ) { // ambiguous - pCache->SetState( SFX_ITEM_DONTCARE, (SfxPoolItem *)-1 ); + pCache->SetState( SfxItemState::DONTCARE, (SfxPoolItem *)-1 ); } - else if ( SFX_ITEM_DEFAULT == eState && + else if ( SfxItemState::DEFAULT == eState && pFound->nWhichId > SFX_WHICH_MAX ) { // no Status or Default but without Pool SfxVoidItem aVoid(0); - pCache->SetState( SFX_ITEM_UNKNOWN, &aVoid ); + pCache->SetState( SfxItemState::UNKNOWN, &aVoid ); } - else if ( SFX_ITEM_DISABLED == eState ) - pCache->SetState(SFX_ITEM_DISABLED, 0); + else if ( SfxItemState::DISABLED == eState ) + pCache->SetState(SfxItemState::DISABLED, 0); else - pCache->SetState(SFX_ITEM_DEFAULT, pItem); + pCache->SetState(SfxItemState::DEFAULT, pItem); } // Update the slots for so far available and bound Controllers for @@ -1452,8 +1452,8 @@ void SfxBindings::UpdateControllers_Impl // Items cast on EnumItem const SfxEnumItemInterface *pEnumItem = PTR_CAST(SfxEnumItemInterface,pItem); - if ( eState == SFX_ITEM_DEFAULT && !pEnumItem ) - eState = SFX_ITEM_DONTCARE; + if ( eState == SfxItemState::DEFAULT && !pEnumItem ) + eState = SfxItemState::DONTCARE; else eState = SfxControllerItem::GetItemState( pEnumItem ); @@ -1471,10 +1471,10 @@ void SfxBindings::UpdateControllers_Impl pEnumCache->Invalidate(false); // HACK(CONTROL/SELECT Kram) ??? - if ( eState == SFX_ITEM_DONTCARE && pFound->nWhichId == 10144 ) + if ( eState == SfxItemState::DONTCARE && pFound->nWhichId == 10144 ) { SfxVoidItem aVoid(0); - pEnumCache->SetState( SFX_ITEM_UNKNOWN, &aVoid ); + pEnumCache->SetState( SfxItemState::UNKNOWN, &aVoid ); if (pSlave->GetNextSlot() == pFirstSlave) break; @@ -1482,22 +1482,22 @@ void SfxBindings::UpdateControllers_Impl continue; } - if ( SFX_ITEM_DISABLED == eState || (pEnumItem && !pEnumItem->IsEnabled( pSlave->GetSlotId())) ) + if ( SfxItemState::DISABLED == eState || (pEnumItem && !pEnumItem->IsEnabled( pSlave->GetSlotId())) ) { // disabled - pEnumCache->SetState(SFX_ITEM_DISABLED, 0); + pEnumCache->SetState(SfxItemState::DISABLED, 0); } - else if ( SFX_ITEM_DEFAULT == eState && pEnumItem ) + else if ( SfxItemState::DEFAULT == eState && pEnumItem ) { // Determine enum value sal_uInt16 nValue = pEnumItem->GetEnumValue(); SfxBoolItem aBool( pFound->nWhichId, pSlave->GetValue() == nValue ); - pEnumCache->SetState(SFX_ITEM_DEFAULT, &aBool); + pEnumCache->SetState(SfxItemState::DEFAULT, &aBool); } else { // ambiguous - pEnumCache->SetState( SFX_ITEM_DONTCARE, (SfxPoolItem *)-1 ); + pEnumCache->SetState( SfxItemState::DONTCARE, (SfxPoolItem *)-1 ); } } @@ -1848,7 +1848,7 @@ SfxItemState SfxBindings::QueryState( sal_uInt16 nSlot, SfxPoolItem* &rpState ) { const SfxSlot* pSlot = SfxSlotPool::GetSlotPool( pDispatcher->GetFrame() ).GetSlot( nSlot ); if ( !pSlot || !pSlot->pUnoName ) - return SFX_ITEM_DISABLED; + return SfxItemState::DISABLED; ::com::sun::star::util::URL aURL; OUString aCmd( ".uno:" ); @@ -1881,14 +1881,14 @@ SfxItemState SfxBindings::QueryState( sal_uInt16 nSlot, SfxPoolItem* &rpState ) bDeleteCache = true; } - SfxItemState eState = SFX_ITEM_SET; + SfxItemState eState = SfxItemState::SET; SfxPoolItem *pItem=NULL; BindDispatch_Impl *pBind = new BindDispatch_Impl( xDisp, aURL, pCache, pSlot ); pBind->acquire(); xDisp->addStatusListener( pBind, aURL ); if ( !pBind->GetStatus().IsEnabled ) { - eState = SFX_ITEM_DISABLED; + eState = SfxItemState::DISABLED; } else { @@ -1938,13 +1938,13 @@ SfxItemState SfxBindings::QueryState( sal_uInt16 nSlot, SfxPoolItem* &rpState ) // order to allow for transition of ownership. const SfxPoolItem *pItem = NULL; SfxItemState eState = pDispatcher->QueryState( nSlot, pItem ); - if ( eState == SFX_ITEM_SET ) + if ( eState == SfxItemState::SET ) { - DBG_ASSERT( pItem, "SFX_ITEM_SET but no item!" ); + DBG_ASSERT( pItem, "SfxItemState::SET but no item!" ); if ( pItem ) rpState = pItem->Clone(); } - else if ( eState == SFX_ITEM_DEFAULT && pItem ) + else if ( eState == SfxItemState::DEFAULT && pItem ) { rpState = pItem->Clone(); } diff --git a/sfx2/source/control/ctrlitem.cxx b/sfx2/source/control/ctrlitem.cxx index f28ba9883dac..dcc788ea5c7e 100644 --- a/sfx2/source/control/ctrlitem.cxx +++ b/sfx2/source/control/ctrlitem.cxx @@ -302,21 +302,21 @@ SfxItemState SfxControllerItem::GetItemState [Return value] - SfxItemState SFX_ITEM_UNKNOWN + SfxItemState SfxItemState::UNKNOWN Enabled, but no further status information available. Typical for <Slot>s, which anyway are sometimes disabled, but otherwise do not change their appearance. - SFX_ITEM_DISABLED + SfxItemState::DISABLED Disabled and no further status information available. All other values that may appear should be reset to default. - SFX_ITEM_DONTCARE + SfxItemState::DONTCARE Enabled but there were only ambiguous values available (i.e. non that can be queried). - SFX_ITEM_DEFAULT + SfxItemState::DEFAULT Enabled and with available values, which are queried by 'pState'. The Type is thus clearly defined in the entire Program and specified through the Slot. @@ -324,12 +324,12 @@ SfxItemState SfxControllerItem::GetItemState { return !pState - ? SFX_ITEM_DISABLED + ? SfxItemState::DISABLED : IsInvalidItem(pState) - ? SFX_ITEM_DONTCARE + ? SfxItemState::DONTCARE : pState->ISA(SfxVoidItem) && !pState->Which() - ? SFX_ITEM_UNKNOWN - : SFX_ITEM_DEFAULT; + ? SfxItemState::UNKNOWN + : SfxItemState::DEFAULT; } diff --git a/sfx2/source/control/dispatch.cxx b/sfx2/source/control/dispatch.cxx index d04075e41fb8..bbd0d20698e1 100644 --- a/sfx2/source/control/dispatch.cxx +++ b/sfx2/source/control/dispatch.cxx @@ -2056,12 +2056,12 @@ SfxItemState SfxDispatcher::QueryState( sal_uInt16 nSlot, const SfxPoolItem* &rp { rpState = pShell->GetSlotState(nSlot); if ( !rpState ) - return SFX_ITEM_DISABLED; + return SfxItemState::DISABLED; else - return SFX_ITEM_DEFAULT; + return SfxItemState::DEFAULT; } - return SFX_ITEM_DISABLED; + return SfxItemState::DISABLED; } SfxItemState SfxDispatcher::QueryState( sal_uInt16 nSID, ::com::sun::star::uno::Any& rAny ) @@ -2074,7 +2074,7 @@ SfxItemState SfxDispatcher::QueryState( sal_uInt16 nSID, ::com::sun::star::uno:: pItem = pShell->GetSlotState( nSID ); if ( !pItem ) - return SFX_ITEM_DISABLED; + return SfxItemState::DISABLED; else { ::com::sun::star::uno::Any aState; @@ -2089,11 +2089,11 @@ SfxItemState SfxDispatcher::QueryState( sal_uInt16 nSID, ::com::sun::star::uno:: } rAny = aState; - return SFX_ITEM_DEFAULT; + return SfxItemState::DEFAULT; } } - return SFX_ITEM_DISABLED; + return SfxItemState::DISABLED; } bool SfxDispatcher::IsReadOnlyShell_Impl( sal_uInt16 nShell ) const diff --git a/sfx2/source/control/querystatus.cxx b/sfx2/source/control/querystatus.cxx index e97616a68237..751614ce9f1c 100644 --- a/sfx2/source/control/querystatus.cxx +++ b/sfx2/source/control/querystatus.cxx @@ -75,7 +75,7 @@ class SfxQueryStatus_Impl: SfxQueryStatus_Impl::SfxQueryStatus_Impl( const Reference< XDispatchProvider >& rDispatchProvider, sal_uInt16 nSlotId, const OUString& rCommand ) : m_bQueryInProgress( false ), - m_eState( SFX_ITEM_DISABLED ), + m_eState( SfxItemState::DISABLED ), m_pItem( 0 ), m_nSlotID( nSlotId ) { @@ -104,11 +104,11 @@ throw( RuntimeException, std::exception ) SolarMutexGuard aGuard; m_pItem = NULL; - m_eState = SFX_ITEM_DISABLED; + m_eState = SfxItemState::DISABLED; if ( rEvent.IsEnabled ) { - m_eState = SFX_ITEM_DEFAULT; + m_eState = SfxItemState::DEFAULT; ::com::sun::star::uno::Type pType = rEvent.State.getValueType(); if ( pType == ::getBooleanCppuType() ) @@ -150,7 +150,7 @@ throw( RuntimeException, std::exception ) } else { - m_eState = SFX_ITEM_UNKNOWN; + m_eState = SfxItemState::UNKNOWN; m_pItem = new SfxVoidItem( m_nSlotID ); } } @@ -176,7 +176,7 @@ SfxItemState SfxQueryStatus_Impl::QueryState( SfxPoolItem*& rpPoolItem ) if ( !m_bQueryInProgress ) { m_pItem = NULL; - m_eState = SFX_ITEM_DISABLED; + m_eState = SfxItemState::DISABLED; if ( m_xDispatch.is() ) { diff --git a/sfx2/source/control/request.cxx b/sfx2/source/control/request.cxx index fed4e29738b0..b3d8b0d79c1e 100644 --- a/sfx2/source/control/request.cxx +++ b/sfx2/source/control/request.cxx @@ -489,7 +489,7 @@ const SfxPoolItem* SfxRequest::GetItem // Is the item set or available at bDeep == sal_True? const SfxPoolItem *pItem = 0; - if ( ( bDeep ? SFX_ITEM_DEFAULT : SFX_ITEM_SET ) + if ( ( bDeep ? SfxItemState::DEFAULT : SfxItemState::SET ) <= pArgs->GetItemState( nWhich, bDeep, &pItem ) ) { // Compare type @@ -703,9 +703,9 @@ void SfxRequest::Done_Impl // get the property as SfxPoolItem const SfxPoolItem *pItem; sal_uInt16 nWhich = rPool.GetWhich(pImp->pSlot->GetSlotId()); - SfxItemState eState = pSet ? pSet->GetItemState( nWhich, false, &pItem ) : SFX_ITEM_UNKNOWN; + SfxItemState eState = pSet ? pSet->GetItemState( nWhich, false, &pItem ) : SfxItemState::UNKNOWN; #ifdef DBG_UTIL - if ( SFX_ITEM_SET != eState ) + if ( SfxItemState::SET != eState ) { OStringBuffer aStr("Recording property not available: "); aStr.append(static_cast<sal_Int32>(pImp->pSlot->GetSlotId())); @@ -713,7 +713,7 @@ void SfxRequest::Done_Impl } #endif uno::Sequence < beans::PropertyValue > aSeq; - if ( eState == SFX_ITEM_SET ) + if ( eState == SfxItemState::SET ) TransformItems( pImp->pSlot->GetSlotId(), *pSet, aSeq, pImp->pSlot ); pImp->Record( aSeq ); } diff --git a/sfx2/source/control/sfxstatuslistener.cxx b/sfx2/source/control/sfxstatuslistener.cxx index 96c77e4565d1..56b9aecdc6a5 100644 --- a/sfx2/source/control/sfxstatuslistener.cxx +++ b/sfx2/source/control/sfxstatuslistener.cxx @@ -163,17 +163,17 @@ throw( RuntimeException, std::exception ) SfxSlotPool& rPool = SfxSlotPool::GetSlotPool( pViewFrame ); const SfxSlot* pSlot = rPool.GetSlot( m_nSlotID ); - SfxItemState eState = SFX_ITEM_DISABLED; + SfxItemState eState = SfxItemState::DISABLED; SfxPoolItem* pItem = NULL; if ( rEvent.IsEnabled ) { - eState = SFX_ITEM_DEFAULT; + eState = SfxItemState::DEFAULT; ::com::sun::star::uno::Type pType = rEvent.State.getValueType(); if ( pType == ::cppu::UnoType< ::cppu::UnoVoidType >::get() ) { pItem = new SfxVoidItem( m_nSlotID ); - eState = SFX_ITEM_UNKNOWN; + eState = SfxItemState::UNKNOWN; } else if ( pType == cppu::UnoType< bool >::get() ) { diff --git a/sfx2/source/control/shell.cxx b/sfx2/source/control/shell.cxx index 140726e2e189..808c0b439a3f 100644 --- a/sfx2/source/control/shell.cxx +++ b/sfx2/source/control/shell.cxx @@ -210,7 +210,7 @@ void SfxShell::PutItem SfxStateCache* pCache = pBindings->GetStateCache( nSlotId ); if ( pCache ) { - pCache->SetState( SFX_ITEM_DEFAULT, pItem->Clone(), true ); + pCache->SetState( SfxItemState::DEFAULT, pItem->Clone(), true ); pCache->SetCachedState( true ); } } @@ -424,7 +424,7 @@ bool SfxShell::CanExecuteSlot_Impl( const SfxSlot &rSlot ) SfxItemSet aSet(rPool, nId, nId); SfxStateFunc pFunc = rSlot.GetStateFnc(); CallState( pFunc, aSet ); - return aSet.GetItemState(nId) != SFX_ITEM_DISABLED; + return aSet.GetItemState(nId) != SfxItemState::DISABLED; } long ShellCall_Impl( void* pObj, void* pArg ) @@ -481,7 +481,7 @@ const SfxPoolItem* SfxShell::GetSlotState // Get Slot on the given Interface if ( !pIF ) pIF = GetInterface(); - SfxItemState eState = SFX_ITEM_UNKNOWN; + SfxItemState eState = SfxItemState::UNKNOWN; SfxItemPool &rPool = GetPool(); const SfxSlot* pSlot = NULL; @@ -505,26 +505,26 @@ const SfxPoolItem* SfxShell::GetSlotState eState = aSet.GetItemState( nSlotId, true, &pItem ); // get default Item if possible - if ( eState == SFX_ITEM_DEFAULT ) + if ( eState == SfxItemState::DEFAULT ) { if ( SfxItemPool::IsWhich(nSlotId) ) pItem = &rPool.GetDefaultItem(nSlotId); else - eState = SFX_ITEM_DONTCARE; + eState = SfxItemState::DONTCARE; } } else - eState = SFX_ITEM_UNKNOWN; + eState = SfxItemState::UNKNOWN; // Evaluate Item and item status and possibly maintain them in pStateSet SfxPoolItem *pRetItem = 0; - if ( eState <= SFX_ITEM_DISABLED ) + if ( eState <= SfxItemState::DISABLED ) { if ( pStateSet ) pStateSet->DisableItem(nSlotId); return 0; } - else if ( eState == SFX_ITEM_DONTCARE ) + else if ( eState == SfxItemState::DONTCARE ) { if ( pStateSet ) pStateSet->ClearItem(nSlotId); diff --git a/sfx2/source/control/statcach.cxx b/sfx2/source/control/statcach.cxx index ec2b36c70a63..61d65b499d6b 100644 --- a/sfx2/source/control/statcach.cxx +++ b/sfx2/source/control/statcach.cxx @@ -85,14 +85,14 @@ void SAL_CALL BindDispatch_Impl::statusChanged( const ::com::sun::star::frame:: { SfxPoolItem *pItem=NULL; sal_uInt16 nId = pCache->GetId(); - SfxItemState eState = SFX_ITEM_DISABLED; + SfxItemState eState = SfxItemState::DISABLED; if ( !aStatus.IsEnabled ) { // default } else if (aStatus.State.hasValue()) { - eState = SFX_ITEM_DEFAULT; + eState = SfxItemState::DEFAULT; ::com::sun::star::uno::Any aAny = aStatus.State; ::com::sun::star::uno::Type pType = aAny.getValueType(); @@ -137,7 +137,7 @@ void SAL_CALL BindDispatch_Impl::statusChanged( const ::com::sun::star::frame:: { // DONTCARE status pItem = new SfxVoidItem(0); - eState = SFX_ITEM_UNKNOWN; + eState = SfxItemState::UNKNOWN; } for ( SfxControllerItem *pCtrl = pCache->GetItemLink(); @@ -184,7 +184,7 @@ SfxStateCache::SfxStateCache( sal_uInt16 nFuncId ): pInternalController(0), pController(0), pLastItem( 0 ), - eLastState( SFX_ITEM_UNKNOWN ), + eLastState( SfxItemState::UNKNOWN ), bItemVisible( true ) { bCtrlDirty = true; @@ -343,7 +343,7 @@ void SfxStateCache::SetState void SfxStateCache::SetVisibleState( bool bShow ) { - SfxItemState eState( SFX_ITEM_DEFAULT ); + SfxItemState eState( SfxItemState::DEFAULT ); const SfxPoolItem* pState( NULL ); bool bDeleteItem( false ); diff --git a/sfx2/source/control/unoctitm.cxx b/sfx2/source/control/unoctitm.cxx index f25c0e6755e0..9086313fd26a 100644 --- a/sfx2/source/control/unoctitm.cxx +++ b/sfx2/source/control/unoctitm.cxx @@ -134,11 +134,11 @@ void SAL_CALL SfxUnoControllerItem::statusChanged(const ::com::sun::star::frame: } else if ( pCtrlItem ) { - SfxItemState eState = SFX_ITEM_DISABLED; + SfxItemState eState = SfxItemState::DISABLED; SfxPoolItem* pItem = NULL; if ( rEvent.IsEnabled ) { - eState = SFX_ITEM_DEFAULT; + eState = SfxItemState::DEFAULT; ::com::sun::star::uno::Type pType = rEvent.State.getValueType(); if ( pType == cppu::UnoType< bool >::get() ) @@ -223,7 +223,7 @@ void SfxUnoControllerItem::GetNewDispatch() if ( xDispatch.is() ) xDispatch->addStatusListener( (::com::sun::star::frame::XStatusListener*) this, aCommand ); else if ( pCtrlItem ) - pCtrlItem->StateChanged( pCtrlItem->GetId(), SFX_ITEM_DISABLED, NULL ); + pCtrlItem->StateChanged( pCtrlItem->GetId(), SfxItemState::DISABLED, NULL ); } ::com::sun::star::uno::Reference< ::com::sun::star::frame::XDispatch > SfxUnoControllerItem::TryGetDispatch( SfxFrame *pFrame ) @@ -808,9 +808,9 @@ void SAL_CALL SfxDispatchController_Impl::addStatusListener(const ::com::sun::st ::com::sun::star::uno::Any aState; if ( !pDispatcher && pBindings ) pDispatcher = GetBindings().GetDispatcher_Impl(); - SfxItemState eState = pDispatcher ? pDispatcher->QueryState( GetId(), aState ) : SFX_ITEM_DONTCARE; + SfxItemState eState = pDispatcher ? pDispatcher->QueryState( GetId(), aState ) : SfxItemState::DONTCARE; - if ( eState == SFX_ITEM_DONTCARE ) + if ( eState == SfxItemState::DONTCARE ) { // Use special uno struct to transport don't care state ::com::sun::star::frame::status::ItemStatus aItemStatus; @@ -824,7 +824,7 @@ void SAL_CALL SfxDispatchController_Impl::addStatusListener(const ::com::sun::st aEvent.Requery = sal_False; if ( bVisible ) { - aEvent.IsEnabled = eState != SFX_ITEM_DISABLED; + aEvent.IsEnabled = eState != SfxItemState::DISABLED; aEvent.State = aState; } else @@ -876,7 +876,7 @@ void SfxDispatchController_Impl::StateChanged( sal_uInt16 nSID, SfxItemState eSt if ( bNotify && pContnr ) { ::com::sun::star::uno::Any aState; - if ( ( eState >= SFX_ITEM_DEFAULT ) && pState && !IsInvalidItem( pState ) && !pState->ISA(SfxVoidItem) ) + if ( ( eState >= SfxItemState::DEFAULT ) && pState && !IsInvalidItem( pState ) && !pState->ISA(SfxVoidItem) ) { // Retrieve metric from pool to have correct sub ID when calling QueryValue sal_uInt16 nSubId( 0 ); @@ -899,7 +899,7 @@ void SfxDispatchController_Impl::StateChanged( sal_uInt16 nSID, SfxItemState eSt pState->QueryValue( aState, (sal_uInt8)nSubId ); } - else if ( eState == SFX_ITEM_DONTCARE ) + else if ( eState == SfxItemState::DONTCARE ) { // Use special uno struct to transport don't care state ::com::sun::star::frame::status::ItemStatus aItemStatus; @@ -910,7 +910,7 @@ void SfxDispatchController_Impl::StateChanged( sal_uInt16 nSID, SfxItemState eSt ::com::sun::star::frame::FeatureStateEvent aEvent; aEvent.FeatureURL = aDispatchURL; aEvent.Source = (::com::sun::star::frame::XDispatch*) pDispatch; - aEvent.IsEnabled = eState != SFX_ITEM_DISABLED; + aEvent.IsEnabled = eState != SfxItemState::DISABLED; aEvent.Requery = sal_False; aEvent.State = aState; |