Kaydet (Commit) 8cb1c1ec authored tarafından Noel Grandin's avatar Noel Grandin

remove unused SlotId/Volatile from .SDI files

Change-Id: I29f039c2fec8433fa062c603b64afffa60e7b0d0
üst 353b9b43
...@@ -32,8 +32,6 @@ struct SvGlobalHashNames ...@@ -32,8 +32,6 @@ struct SvGlobalHashNames
SvStringHashEntryRef MM_HelpText; SvStringHashEntryRef MM_HelpText;
SvStringHashEntryRef MM_void; SvStringHashEntryRef MM_void;
SvStringHashEntryRef MM_shell; SvStringHashEntryRef MM_shell;
SvStringHashEntryRef MM_SlotId;
SvStringHashEntryRef MM_Volatile;
SvStringHashEntryRef MM_Toggle; SvStringHashEntryRef MM_Toggle;
SvStringHashEntryRef MM_AutoUpdate; SvStringHashEntryRef MM_AutoUpdate;
SvStringHashEntryRef MM_Asynchron; SvStringHashEntryRef MM_Asynchron;
...@@ -112,8 +110,6 @@ HASH_INLINE(module) ...@@ -112,8 +110,6 @@ HASH_INLINE(module)
HASH_INLINE(interface) HASH_INLINE(interface)
HASH_INLINE(HelpText) HASH_INLINE(HelpText)
HASH_INLINE(shell) HASH_INLINE(shell)
HASH_INLINE(SlotId)
HASH_INLINE(Volatile)
HASH_INLINE(Toggle) HASH_INLINE(Toggle)
HASH_INLINE(AutoUpdate) HASH_INLINE(AutoUpdate)
HASH_INLINE(Asynchron) HASH_INLINE(Asynchron)
......
...@@ -33,7 +33,6 @@ class SvMetaSlot : public SvMetaAttribute ...@@ -33,7 +33,6 @@ class SvMetaSlot : public SvMetaAttribute
SvIdentifier aStateMethod; SvIdentifier aStateMethod;
SvBOOL aPseudoSlots; SvBOOL aPseudoSlots;
SvBOOL aVolatile;
SvBOOL aToggle; SvBOOL aToggle;
SvBOOL aAutoUpdate; SvBOOL aAutoUpdate;
...@@ -68,10 +67,6 @@ class SvMetaSlot : public SvMetaAttribute ...@@ -68,10 +67,6 @@ class SvMetaSlot : public SvMetaAttribute
void SetEnumValue(SvMetaEnumValue *p) void SetEnumValue(SvMetaEnumValue *p)
{ pEnumValue = p; } { pEnumValue = p; }
protected: protected:
void SetVolatile( bool bSet )
{
aVolatile = bSet;
}
void SetToggle( bool bSet ) void SetToggle( bool bSet )
{ {
aToggle = bSet; aToggle = bSet;
......
...@@ -124,13 +124,6 @@ bool SvMetaSlot::GetPseudoSlots() const ...@@ -124,13 +124,6 @@ bool SvMetaSlot::GetPseudoSlots() const
if( aPseudoSlots.IsSet() || !GetRef() ) return aPseudoSlots; if( aPseudoSlots.IsSet() || !GetRef() ) return aPseudoSlots;
return static_cast<SvMetaSlot *>(GetRef())->GetPseudoSlots(); return static_cast<SvMetaSlot *>(GetRef())->GetPseudoSlots();
} }
bool SvMetaSlot::GetVolatile() const
{
// Cachable and Volatile are exclusive
if( !GetRef() || aVolatile.IsSet() )
return aVolatile;
return static_cast<SvMetaSlot *>(GetRef())->GetVolatile();
}
bool SvMetaSlot::GetToggle() const bool SvMetaSlot::GetToggle() const
{ {
if( aToggle.IsSet() || !GetRef() ) return aToggle; if( aToggle.IsSet() || !GetRef() ) return aToggle;
...@@ -239,8 +232,6 @@ void SvMetaSlot::ReadAttributesSvIdl( SvIdlDataBase & rBase, ...@@ -239,8 +232,6 @@ void SvMetaSlot::ReadAttributesSvIdl( SvIdlDataBase & rBase,
bOk |= aStateMethod.ReadSvIdl( SvHash_StateMethod(), rInStm ); bOk |= aStateMethod.ReadSvIdl( SvHash_StateMethod(), rInStm );
bOk |= aDisableFlags.ReadSvIdl( SvHash_DisableFlags(), rInStm ); bOk |= aDisableFlags.ReadSvIdl( SvHash_DisableFlags(), rInStm );
if( aVolatile.ReadSvIdl( SvHash_Volatile(), rInStm ) )
SetVolatile( aVolatile ), bOk = true;
if( aToggle.ReadSvIdl( SvHash_Toggle(), rInStm ) ) if( aToggle.ReadSvIdl( SvHash_Toggle(), rInStm ) )
SetToggle( aToggle ), bOk = true; SetToggle( aToggle ), bOk = true;
if( aAutoUpdate.ReadSvIdl( SvHash_AutoUpdate(), rInStm ) ) if( aAutoUpdate.ReadSvIdl( SvHash_AutoUpdate(), rInStm ) )
...@@ -762,8 +753,6 @@ void SvMetaSlot::WriteSlot( const OString& rShellName, sal_uInt16 nCount, ...@@ -762,8 +753,6 @@ void SvMetaSlot::WriteSlot( const OString& rShellName, sal_uInt16 nCount,
WriteTab( rOutStm, 4 ); WriteTab( rOutStm, 4 );
// write flags // write flags
if( GetVolatile() )
rOutStm.WriteCharPtr( MakeSlotName( SvHash_Volatile() ).getStr() ).WriteChar( '|' );
if( GetToggle() ) if( GetToggle() )
rOutStm.WriteCharPtr( MakeSlotName( SvHash_Toggle() ).getStr() ).WriteChar( '|' ); rOutStm.WriteCharPtr( MakeSlotName( SvHash_Toggle() ).getStr() ).WriteChar( '|' );
if( GetAutoUpdate() ) if( GetAutoUpdate() )
......
...@@ -155,7 +155,6 @@ void SvMetaAttribute::ReadAttributesSvIdl( SvIdlDataBase & rBase, ...@@ -155,7 +155,6 @@ void SvMetaAttribute::ReadAttributesSvIdl( SvIdlDataBase & rBase,
SvTokenStream & rInStm ) SvTokenStream & rInStm )
{ {
SvMetaReference::ReadAttributesSvIdl( rBase, rInStm ); SvMetaReference::ReadAttributesSvIdl( rBase, rInStm );
aSlotId.ReadSvIdl( rBase, SvHash_SlotId(), rInStm );
aExport.ReadSvIdl( SvHash_Export(), rInStm ); aExport.ReadSvIdl( SvHash_Export(), rInStm );
aHidden.ReadSvIdl( SvHash_Hidden(), rInStm ); aHidden.ReadSvIdl( SvHash_Hidden(), rInStm );
aReadOnlyDoc.ReadSvIdl( SvHash_ReadOnlyDoc(), rInStm ); aReadOnlyDoc.ReadSvIdl( SvHash_ReadOnlyDoc(), rInStm );
......
...@@ -60,7 +60,6 @@ SvGlobalHashNames::SvGlobalHashNames() ...@@ -60,7 +60,6 @@ SvGlobalHashNames::SvGlobalHashNames()
, MM_HelpText( INS( "HelpText" ) ) , MM_HelpText( INS( "HelpText" ) )
, MM_void( INS( "void" ) ) , MM_void( INS( "void" ) )
, MM_shell( INS( "shell" ) ) , MM_shell( INS( "shell" ) )
, MM_SlotId( INS( "SlotId" ) )
, MM_Toggle( INS( "Toggle" ) ) , MM_Toggle( INS( "Toggle" ) )
, MM_AutoUpdate( INS( "AutoUpdate" ) ) , MM_AutoUpdate( INS( "AutoUpdate" ) )
, MM_Asynchron( INS( "Asynchron" ) ) , MM_Asynchron( INS( "Asynchron" ) )
......
...@@ -29,7 +29,6 @@ ...@@ -29,7 +29,6 @@
enum class SfxSlotMode { enum class SfxSlotMode {
NONE = 0x0000L, // default NONE = 0x0000L, // default
VOLATILE = 0x0002L, // per Timer every 2s get new,
TOGGLE = 0x0004L, // inverted for Execute old value TOGGLE = 0x0004L, // inverted for Execute old value
AUTOUPDATE = 0x0008L, // invalidated the status automatically after execute AUTOUPDATE = 0x0008L, // invalidated the status automatically after execute
...@@ -57,7 +56,7 @@ enum class SfxSlotMode { ...@@ -57,7 +56,7 @@ enum class SfxSlotMode {
namespace o3tl namespace o3tl
{ {
template<> struct typed_flags<SfxSlotMode> : is_typed_flags<SfxSlotMode, 0x1fec72eL> {}; template<> struct typed_flags<SfxSlotMode> : is_typed_flags<SfxSlotMode, 0x1fec72cL> {};
} }
......
...@@ -75,7 +75,6 @@ static sal_uInt16 nTimeOut = 300; ...@@ -75,7 +75,6 @@ static sal_uInt16 nTimeOut = 300;
#define TIMEOUT_FIRST nTimeOut #define TIMEOUT_FIRST nTimeOut
#define TIMEOUT_UPDATING 20 #define TIMEOUT_UPDATING 20
#define TIMEOUT_IDLE 2500
typedef std::unordered_map< sal_uInt16, bool > InvalidateSlotMap; typedef std::unordered_map< sal_uInt16, bool > InvalidateSlotMap;
...@@ -505,9 +504,7 @@ void SfxBindings::Update ...@@ -505,9 +504,7 @@ void SfxBindings::Update
{ {
// Query Status // Query Status
const SfxSlotServer* pMsgServer = pDispatcher ? pCache->GetSlotServer(*pDispatcher, pImp->xProv) : nullptr; const SfxSlotServer* pMsgServer = pDispatcher ? pCache->GetSlotServer(*pDispatcher, pImp->xProv) : nullptr;
if ( !pCache->IsControllerDirty() && if ( !pCache->IsControllerDirty() )
( !pMsgServer ||
!pMsgServer->GetSlot()->IsMode(SfxSlotMode::VOLATILE) ) )
{ {
pImp->bInUpdate = false; pImp->bInUpdate = false;
InvalidateSlotsInMap_Impl(); InvalidateSlotsInMap_Impl();
...@@ -1644,22 +1641,6 @@ bool SfxBindings::NextJob_Impl(Timer * pTimer) ...@@ -1644,22 +1641,6 @@ bool SfxBindings::NextJob_Impl(Timer * pTimer)
pImp->nMsgPos = 0; pImp->nMsgPos = 0;
// check for volatile slots
bool bVolatileSlotsPresent = false;
for ( sal_uInt16 n = 0; n < nCount; ++n )
{
SfxStateCache* pCache = (*pImp->pCaches)[n];
const SfxSlotServer *pSlotServer = pCache->GetSlotServer(*pDispatcher, pImp->xProv);
if ( pSlotServer && pSlotServer->GetSlot()->IsMode(SfxSlotMode::VOLATILE) )
{
pCache->Invalidate(false);
bVolatileSlotsPresent = true;
}
}
if (bVolatileSlotsPresent)
pImp->aTimer.SetTimeout(TIMEOUT_IDLE);
else
pImp->aTimer.Stop(); pImp->aTimer.Stop();
// Update round is finished // Update round is finished
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment