diff options
author | Vladimir Glazounov <vg@openoffice.org> | 2008-03-19 06:45:11 +0000 |
---|---|---|
committer | Vladimir Glazounov <vg@openoffice.org> | 2008-03-19 06:45:11 +0000 |
commit | b114f66e32c336fe311ba63049fa2132d362ee60 (patch) | |
tree | f1f2dc05821f7de337db0d748b14095db3b35895 /svx | |
parent | f5fddf97cf351c7348ffc0e3f5cbfc45877e9de0 (diff) |
INTEGRATION: CWS impress138_DEV300 (1.165.16); FILE MERGED
2008/02/18 12:53:05 sj 1.165.16.2: RESYNC: (1.165-1.166); FILE MERGED
2008/01/31 10:27:16 sj 1.165.16.1: #i85724# added XEnhancedCustomShapeDefaulter to TypeSequence
Diffstat (limited to 'svx')
-rw-r--r-- | svx/source/unodraw/unoshape.cxx | 42 |
1 files changed, 39 insertions, 3 deletions
diff --git a/svx/source/unodraw/unoshape.cxx b/svx/source/unodraw/unoshape.cxx index 3d59296ec27b..0eced865d70f 100644 --- a/svx/source/unodraw/unoshape.cxx +++ b/svx/source/unodraw/unoshape.cxx @@ -4,9 +4,9 @@ * * $RCSfile: unoshape.cxx,v $ * - * $Revision: 1.169 $ + * $Revision: 1.170 $ * - * last change: $Author: rt $ $Date: 2008-03-12 10:13:05 $ + * last change: $Author: vg $ $Date: 2008-03-19 07:45:11 $ * * The Contents of this file are made available subject to * the terms of GNU Lesser General Public License Version 2.1. @@ -942,6 +942,43 @@ uno::Sequence< uno::Type > SAL_CALL SvxShape::_getTypes() } return aTypeSequence; } + case OBJ_CUSTOMSHAPE: + { + static ::com::sun::star::uno::Sequence< ::com::sun::star::uno::Type > aTypeSequence; + + if( aTypeSequence.getLength() == 0 ) + { + // Ready for multithreading; get global mutex for first call of this method only! see before + MutexGuard aGuard( osl::Mutex::getGlobalMutex() ) ; + + // Control these pointer again ... it can be, that another instance will be faster then these! + if( aTypeSequence.getLength() == 0 ) + { + aTypeSequence.realloc( 16 ); + uno::Type* pTypes = aTypeSequence.getArray(); + + *pTypes++ = ::getCppuType((const uno::Reference< drawing::XShape >*)0); + *pTypes++ = ::getCppuType((const uno::Reference< lang::XComponent >*)0); + *pTypes++ = ::getCppuType((const uno::Reference< beans::XPropertySet >*)0); + *pTypes++ = ::getCppuType((const uno::Reference< beans::XMultiPropertySet >*)0); +// *pTypes++ = ::getCppuType((const uno::Reference< beans::XTolerantMultiPropertySet >*)0); + *pTypes++ = ::getCppuType((const uno::Reference< beans::XPropertyState >*)0); + *pTypes++ = beans::XMultiPropertyStates::static_type(); + *pTypes++ = ::getCppuType((const uno::Reference< drawing::XGluePointsSupplier >*)0); + *pTypes++ = ::getCppuType((const uno::Reference< container::XChild >*)0); + *pTypes++ = ::getCppuType((const uno::Reference< lang::XServiceInfo >*)0); + *pTypes++ = ::getCppuType((const uno::Reference< lang::XTypeProvider >*)0); + *pTypes++ = ::getCppuType((const uno::Reference< lang::XUnoTunnel >*)0); + *pTypes++ = ::getCppuType((const uno::Reference< container::XNamed >*)0); + // from SvxUnoTextBase::getTypes() + *pTypes++ = ::getCppuType(( const uno::Reference< text::XText >*)0); + *pTypes++ = ::getCppuType(( const uno::Reference< container::XEnumerationAccess >*)0); + *pTypes++ = ::getCppuType(( const uno::Reference< text::XTextRangeMover >*)0); + *pTypes++ = ::getCppuType(( const uno::Reference< drawing::XEnhancedCustomShapeDefaulter >*)0); + } + } + return aTypeSequence; + } // shapes with text case OBJ_RECT: case OBJ_CIRC: @@ -959,7 +996,6 @@ uno::Sequence< uno::Type > SAL_CALL SvxShape::_getTypes() case OBJ_TEXT: case OBJ_CAPTION: case OBJ_TABLE: - case OBJ_CUSTOMSHAPE: default: { static ::com::sun::star::uno::Sequence< ::com::sun::star::uno::Type > aTypeSequence; |