summaryrefslogtreecommitdiff
path: root/idl
diff options
context:
space:
mode:
authorNoel Grandin <noel@peralex.com>2016-02-08 11:13:50 +0200
committerNoel Grandin <noel@peralex.com>2016-02-08 14:00:38 +0200
commit760b86a75746968f8cd77c6aaae871af09aec47c (patch)
tree08e7b080a9dc65a7a57becd36b892a3771a4d0bc /idl
parent1795bb2fefe29ff0a46497918b5c571f9d541e5a (diff)
Export attribute only applies to SvMetaSlot, so move it down
Change-Id: I686fd2148d4cf03acbef892223c3ed2b1966e73a
Diffstat (limited to 'idl')
-rw-r--r--idl/inc/slot.hxx5
-rw-r--r--idl/inc/types.hxx3
-rw-r--r--idl/source/objects/slot.cxx20
-rw-r--r--idl/source/objects/types.cxx20
4 files changed, 24 insertions, 24 deletions
diff --git a/idl/inc/slot.hxx b/idl/inc/slot.hxx
index 94fef1c99696..a8d98355c0ff 100644
--- a/idl/inc/slot.hxx
+++ b/idl/inc/slot.hxx
@@ -55,7 +55,8 @@ class SvMetaSlot : public SvMetaAttribute
SvMetaSlot* pNextSlot;
sal_uLong nListPos;
SvMetaEnumValue* pEnumValue;
- SvBOOL aReadOnlyDoc;
+ SvBOOL aReadOnlyDoc;
+ SvBOOL aExport;
void WriteSlot( const OString& rShellName,
sal_uInt16 nCount, const OString& rSlotId,
@@ -138,6 +139,8 @@ public:
bool GetImageRotation() const;
bool GetImageReflection() const;
bool GetReadOnlyDoc() const;
+ bool GetExport() const;
+ bool GetHidden() const;
sal_uLong GetListPos() const
{ return nListPos; }
diff --git a/idl/inc/types.hxx b/idl/inc/types.hxx
index 1f30f90f4791..7044e00ac643 100644
--- a/idl/inc/types.hxx
+++ b/idl/inc/types.hxx
@@ -35,7 +35,6 @@ class SvMetaAttribute : public SvMetaReference
{
tools::SvRef<SvMetaType> aType;
SvIdentifier aSlotId;
- SvBOOL aExport;
protected:
virtual void ReadAttributesSvIdl( SvIdlDataBase & rBase,
@@ -47,8 +46,6 @@ public:
void SetSlotId( const SvIdentifier & rId )
{ aSlotId = rId; }
const SvIdentifier & GetSlotId() const;
- bool GetExport() const;
- bool GetHidden() const;
SvMetaType * GetType() const;
virtual bool IsMethod() const;
diff --git a/idl/source/objects/slot.cxx b/idl/source/objects/slot.cxx
index 7ac6c72c3987..f94ad2c4877b 100644
--- a/idl/source/objects/slot.cxx
+++ b/idl/source/objects/slot.cxx
@@ -41,6 +41,7 @@ SvMetaSlot::SvMetaSlot()
, nListPos(0)
, pEnumValue(nullptr)
, aReadOnlyDoc ( true, false )
+ , aExport( true, false )
{
}
@@ -53,6 +54,7 @@ SvMetaSlot::SvMetaSlot( SvMetaType * pType )
, nListPos(0)
, pEnumValue(nullptr)
, aReadOnlyDoc ( true, false )
+ , aExport( true, false )
{
}
@@ -62,6 +64,23 @@ bool SvMetaSlot::GetReadOnlyDoc() const
return static_cast<SvMetaSlot *>(GetRef())->GetReadOnlyDoc();
}
+bool SvMetaSlot::GetExport() const
+{
+ if( aExport.IsSet() || !GetRef() ) return aExport;
+ return static_cast<SvMetaSlot *>(GetRef())->GetExport();
+}
+
+bool SvMetaSlot::GetHidden() const
+{
+ // when export is set, but hidden is not the default is used
+ if ( aExport.IsSet() )
+ return !aExport;
+ else if( !GetRef() )
+ return false;
+ else
+ return static_cast<SvMetaSlot *>(GetRef())->GetHidden();
+}
+
bool SvMetaSlot::IsVariable() const
{
return SvMetaAttribute::IsVariable();
@@ -229,6 +248,7 @@ void SvMetaSlot::ReadAttributesSvIdl( SvIdlDataBase & rBase,
bOk |= aStateMethod.ReadSvIdl( SvHash_StateMethod(), rInStm );
bOk |= aDisableFlags.ReadSvIdl( SvHash_DisableFlags(), rInStm );
bOk |= aReadOnlyDoc.ReadSvIdl( SvHash_ReadOnlyDoc(), rInStm );
+ bOk |= aExport.ReadSvIdl( SvHash_Export(), rInStm );
if( aToggle.ReadSvIdl( SvHash_Toggle(), rInStm ) )
SetToggle( aToggle ), bOk = true;
diff --git a/idl/source/objects/types.cxx b/idl/source/objects/types.cxx
index 84f6e55cd715..42deae19d378 100644
--- a/idl/source/objects/types.cxx
+++ b/idl/source/objects/types.cxx
@@ -30,13 +30,11 @@
#include <database.hxx>
SvMetaAttribute::SvMetaAttribute()
- : aExport( true, false )
{
}
SvMetaAttribute::SvMetaAttribute( SvMetaType * pType )
: aType( pType )
- , aExport( true, false )
{
}
@@ -52,23 +50,6 @@ const SvIdentifier & SvMetaAttribute::GetSlotId() const
return static_cast<SvMetaAttribute *>(GetRef())->GetSlotId();
}
-bool SvMetaAttribute::GetExport() const
-{
- if( aExport.IsSet() || !GetRef() ) return aExport;
- return static_cast<SvMetaAttribute *>(GetRef())->GetExport();
-}
-
-bool SvMetaAttribute::GetHidden() const
-{
- // when export is set, but hidden is not the default is used
- if ( aExport.IsSet() )
- return !aExport;
- else if( !GetRef() )
- return false;
- else
- return static_cast<SvMetaAttribute *>(GetRef())->GetHidden();
-}
-
bool SvMetaAttribute::IsMethod() const
{
SvMetaType * pType = GetType();
@@ -143,7 +124,6 @@ void SvMetaAttribute::ReadAttributesSvIdl( SvIdlDataBase & rBase,
SvTokenStream & rInStm )
{
SvMetaReference::ReadAttributesSvIdl( rBase, rInStm );
- aExport.ReadSvIdl( SvHash_Export(), rInStm );
}
sal_uLong SvMetaAttribute::MakeSfx( OStringBuffer& rAttrArray )