1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
3 * This file is part of the LibreOffice project.
5 * This Source Code Form is subject to the terms of the Mozilla Public
6 * License, v. 2.0. If a copy of the MPL was not distributed with this
7 * file, You can obtain one at http://mozilla.org/MPL/2.0/.
9 * This file incorporates work covered by the following license notice:
11 * Licensed to the Apache Software Foundation (ASF) under one or more
12 * contributor license agreements. See the NOTICE file distributed
13 * with this work for additional information regarding copyright
14 * ownership. The ASF licenses this file to you under the Apache
15 * License, Version 2.0 (the "License"); you may not use this file
16 * except in compliance with the License. You may obtain a copy of
17 * the License at http://www.apache.org/licenses/LICENSE-2.0 .
20 #include <com/sun/star/util/XCloneable.hpp>
21 #include <com/sun/star/uno/XComponentContext.hpp>
22 #include <com/sun/star/lang/XServiceInfo.hpp>
23 #include <com/sun/star/lang/XTypeProvider.hpp>
24 #include <com/sun/star/animations/XAnimateColor.hpp>
25 #include <com/sun/star/animations/XAnimateSet.hpp>
26 #include <com/sun/star/animations/XAnimateMotion.hpp>
27 #include <com/sun/star/animations/XAnimateTransform.hpp>
28 #include <com/sun/star/animations/XParallelTimeContainer.hpp>
29 #include <com/sun/star/animations/XTransitionFilter.hpp>
30 #include <com/sun/star/animations/XTimeContainer.hpp>
31 #include <com/sun/star/animations/XIterateContainer.hpp>
32 #include <com/sun/star/animations/XAudio.hpp>
33 #include <com/sun/star/animations/XCommand.hpp>
34 #include <com/sun/star/animations/AnimationNodeType.hpp>
35 #include <com/sun/star/animations/AnimationCalcMode.hpp>
36 #include <com/sun/star/animations/AnimationFill.hpp>
37 #include <com/sun/star/animations/AnimationRestart.hpp>
38 #include <com/sun/star/animations/AnimationColorSpace.hpp>
39 #include <com/sun/star/animations/AnimationAdditiveMode.hpp>
40 #include <com/sun/star/animations/AnimationTransformType.hpp>
41 #include <com/sun/star/animations/TransitionType.hpp>
42 #include <com/sun/star/animations/TransitionSubType.hpp>
43 #include <com/sun/star/presentation/ShapeAnimationSubType.hpp>
44 #include <com/sun/star/container/XEnumerationAccess.hpp>
45 #include <com/sun/star/beans/NamedValue.hpp>
46 #include <com/sun/star/util/XChangesNotifier.hpp>
47 #include <com/sun/star/lang/XUnoTunnel.hpp>
48 #include <comphelper/servicehelper.hxx>
49 #include <cppuhelper/queryinterface.hxx>
50 #include <cppuhelper/interfacecontainer.hxx>
51 #include <cppuhelper/supportsservice.hxx>
52 #include <cppuhelper/weakref.hxx>
54 #include <cppuhelper/implbase1.hxx>
56 #include <osl/mutex.hxx>
63 using ::cppu::OInterfaceContainerHelper
;
64 using ::cppu::OInterfaceIteratorHelper
;
65 using ::com::sun::star::uno::Any
;
66 using ::com::sun::star::uno::UNO_QUERY
;
67 using ::com::sun::star::uno::XInterface
;
68 using ::com::sun::star::uno::RuntimeException
;
69 using ::com::sun::star::uno::Sequence
;
70 using ::com::sun::star::uno::Reference
;
71 using ::com::sun::star::uno::WeakReference
;
72 using ::com::sun::star::uno::XComponentContext
;
73 using ::com::sun::star::uno::Exception
;
74 using ::com::sun::star::uno::XWeak
;
75 using ::com::sun::star::uno::Type
;
76 using ::com::sun::star::uno::makeAny
;
77 using ::com::sun::star::lang::NoSupportException
;
78 using ::com::sun::star::lang::IllegalArgumentException
;
79 using ::com::sun::star::lang::WrappedTargetException
;
80 using ::com::sun::star::lang::XServiceInfo
;
81 using ::com::sun::star::lang::XTypeProvider
;
82 using ::com::sun::star::container::NoSuchElementException
;
83 using ::com::sun::star::container::ElementExistException
;
84 using ::com::sun::star::container::XEnumeration
;
85 using ::com::sun::star::container::XEnumerationAccess
;
86 using ::com::sun::star::beans::NamedValue
;
87 using ::com::sun::star::util::XCloneable
;
88 using ::com::sun::star::lang::XUnoTunnel
;
89 using ::com::sun::star::util::XChangesNotifier
;
90 using ::com::sun::star::util::XChangesListener
;
91 using ::com::sun::star::util::ElementChange
;
92 using ::com::sun::star::util::ChangesEvent
;
94 using ::cppu::OWeakObject
;
96 using namespace ::com::sun::star::animations
;
97 using namespace ::com::sun::star::animations::AnimationNodeType
;
104 typedef ::std::list
< Reference
< XAnimationNode
> > ChildList_t
;
108 class AnimationNodeBase
: public XAnimateMotion
,
109 public XAnimateColor
,
110 public XTransitionFilter
,
112 public XAnimateTransform
,
113 public XParallelTimeContainer
,
114 public XIterateContainer
,
116 public XTypeProvider
,
120 public XChangesNotifier
,
125 // our first, last and only protection from mutli-threads!
129 class AnimationNode
: public AnimationNodeBase
132 explicit AnimationNode(sal_Int16 nNodeType
);
133 explicit AnimationNode(const AnimationNode
& rNode
);
134 virtual ~AnimationNode();
137 virtual Any SAL_CALL
queryInterface( const Type
& aType
) throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
138 virtual void SAL_CALL
acquire() throw () SAL_OVERRIDE
;
139 virtual void SAL_CALL
release() throw () SAL_OVERRIDE
;
142 virtual Sequence
< Type
> SAL_CALL
getTypes() throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
143 virtual Sequence
< sal_Int8
> SAL_CALL
getImplementationId() throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
146 OUString SAL_CALL
getImplementationName() throw(std::exception
) SAL_OVERRIDE
;
147 Sequence
< OUString
> SAL_CALL
getSupportedServiceNames() throw(std::exception
) SAL_OVERRIDE
;
148 sal_Bool SAL_CALL
supportsService(const OUString
& ServiceName
) throw(std::exception
) SAL_OVERRIDE
;
151 virtual Reference
< XInterface
> SAL_CALL
getParent() throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
152 virtual void SAL_CALL
setParent( const Reference
< XInterface
>& Parent
) throw (NoSupportException
, RuntimeException
, std::exception
) SAL_OVERRIDE
;
155 virtual Reference
< XCloneable
> SAL_CALL
createClone() throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
158 virtual sal_Int16 SAL_CALL
getType() throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
159 virtual Any SAL_CALL
getBegin() throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
160 virtual void SAL_CALL
setBegin( const Any
& _begin
) throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
161 virtual Any SAL_CALL
getDuration() throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
162 virtual void SAL_CALL
setDuration( const Any
& _duration
) throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
163 virtual Any SAL_CALL
getEnd() throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
164 virtual void SAL_CALL
setEnd( const Any
& _end
) throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
165 virtual Any SAL_CALL
getEndSync() throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
166 virtual void SAL_CALL
setEndSync( const Any
& _endsync
) throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
167 virtual Any SAL_CALL
getRepeatCount() throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
168 virtual void SAL_CALL
setRepeatCount( const Any
& _repeatcount
) throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
169 virtual Any SAL_CALL
getRepeatDuration() throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
170 virtual void SAL_CALL
setRepeatDuration( const Any
& _repeatduration
) throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
171 virtual sal_Int16 SAL_CALL
getFill() throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
172 virtual void SAL_CALL
setFill( sal_Int16 _fill
) throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
173 virtual sal_Int16 SAL_CALL
getFillDefault() throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
174 virtual void SAL_CALL
setFillDefault( sal_Int16 _filldefault
) throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
175 virtual sal_Int16 SAL_CALL
getRestart() throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
176 virtual void SAL_CALL
setRestart( sal_Int16 _restart
) throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
177 virtual sal_Int16 SAL_CALL
getRestartDefault() throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
178 virtual void SAL_CALL
setRestartDefault( sal_Int16 _restartdefault
) throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
179 virtual double SAL_CALL
getAcceleration() throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
180 virtual void SAL_CALL
setAcceleration( double _acceleration
) throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
181 virtual double SAL_CALL
getDecelerate() throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
182 virtual void SAL_CALL
setDecelerate( double _decelerate
) throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
183 virtual sal_Bool SAL_CALL
getAutoReverse() throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
184 virtual void SAL_CALL
setAutoReverse( sal_Bool _autoreverse
) throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
185 virtual Sequence
< NamedValue
> SAL_CALL
getUserData() throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
186 virtual void SAL_CALL
setUserData( const Sequence
< NamedValue
>& _userdata
) throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
189 virtual Any SAL_CALL
getTarget() throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
190 virtual void SAL_CALL
setTarget( const Any
& _target
) throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
191 virtual sal_Int16 SAL_CALL
getSubItem() throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
192 virtual void SAL_CALL
setSubItem( sal_Int16 _subitem
) throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
193 virtual OUString SAL_CALL
getAttributeName() throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
194 virtual void SAL_CALL
setAttributeName( const OUString
& _attribute
) throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
195 virtual Sequence
< Any
> SAL_CALL
getValues() throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
196 virtual void SAL_CALL
setValues( const Sequence
< Any
>& _values
) throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
197 virtual Sequence
< double > SAL_CALL
getKeyTimes() throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
198 virtual void SAL_CALL
setKeyTimes( const Sequence
< double >& _keytimes
) throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
199 virtual sal_Int16 SAL_CALL
getValueType() throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
200 virtual void SAL_CALL
setValueType( sal_Int16 _valuetype
) throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
201 virtual sal_Int16 SAL_CALL
getCalcMode() throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
202 virtual void SAL_CALL
setCalcMode( sal_Int16 _calcmode
) throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
203 virtual sal_Bool SAL_CALL
getAccumulate() throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
204 virtual void SAL_CALL
setAccumulate( sal_Bool _accumulate
) throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
205 virtual sal_Int16 SAL_CALL
getAdditive() throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
206 virtual void SAL_CALL
setAdditive( sal_Int16 _additive
) throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
207 virtual Any SAL_CALL
getFrom() throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
208 virtual void SAL_CALL
setFrom( const Any
& _from
) throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
209 virtual Any SAL_CALL
getTo() throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
210 virtual void SAL_CALL
setTo( const Any
& _to
) throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
211 virtual Any SAL_CALL
getBy() throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
212 virtual void SAL_CALL
setBy( const Any
& _by
) throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
213 virtual Sequence
< TimeFilterPair
> SAL_CALL
getTimeFilter() throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
214 virtual void SAL_CALL
setTimeFilter( const Sequence
< TimeFilterPair
>& _timefilter
) throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
215 virtual OUString SAL_CALL
getFormula() throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
216 virtual void SAL_CALL
setFormula( const OUString
& _formula
) throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
219 virtual sal_Int16 SAL_CALL
getColorInterpolation() throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
220 virtual void SAL_CALL
setColorInterpolation( sal_Int16 _colorspace
) throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
221 virtual sal_Bool SAL_CALL
getDirection() throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
222 virtual void SAL_CALL
setDirection( sal_Bool _direction
) throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
225 virtual Any SAL_CALL
getPath() throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
226 virtual void SAL_CALL
setPath( const Any
& _path
) throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
227 virtual Any SAL_CALL
getOrigin() throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
228 virtual void SAL_CALL
setOrigin( const Any
& _origin
) throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
231 virtual sal_Int16 SAL_CALL
getTransformType() throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
232 virtual void SAL_CALL
setTransformType( sal_Int16 _transformtype
) throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
235 virtual sal_Int16 SAL_CALL
getTransition() throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
236 virtual void SAL_CALL
setTransition( sal_Int16 _transition
) throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
237 virtual sal_Int16 SAL_CALL
getSubtype() throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
238 virtual void SAL_CALL
setSubtype( sal_Int16 _subtype
) throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
239 virtual sal_Bool SAL_CALL
getMode() throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
240 virtual void SAL_CALL
setMode( sal_Bool _mode
) throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
241 virtual sal_Int32 SAL_CALL
getFadeColor() throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
242 virtual void SAL_CALL
setFadeColor( sal_Int32 _fadecolor
) throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
245 virtual Any SAL_CALL
getSource() throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
246 virtual void SAL_CALL
setSource( const Any
& _source
) throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
247 virtual double SAL_CALL
getVolume() throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
248 virtual void SAL_CALL
setVolume( double _volume
) throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
251 // XCommand - the following two shadowed by animate, unfortunately
252 // virtual Any SAL_CALL getTarget() throw (RuntimeException);
253 // virtual void SAL_CALL setTarget( const Any& _target ) throw (RuntimeException);
254 virtual sal_Int16 SAL_CALL
getCommand() throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
255 virtual void SAL_CALL
setCommand( sal_Int16 _command
) throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
256 virtual Any SAL_CALL
getParameter() throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
257 virtual void SAL_CALL
setParameter( const Any
& _parameter
) throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
260 virtual Type SAL_CALL
getElementType() throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
261 virtual sal_Bool SAL_CALL
hasElements() throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
263 // XEnumerationAccess
264 virtual Reference
< XEnumeration
> SAL_CALL
createEnumeration() throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
267 virtual Reference
< XAnimationNode
> SAL_CALL
insertBefore( const Reference
< XAnimationNode
>& newChild
, const Reference
< XAnimationNode
>& refChild
) throw (IllegalArgumentException
, NoSuchElementException
, ElementExistException
, WrappedTargetException
, RuntimeException
, std::exception
) SAL_OVERRIDE
;
268 virtual Reference
< XAnimationNode
> SAL_CALL
insertAfter( const Reference
< XAnimationNode
>& newChild
, const Reference
< XAnimationNode
>& refChild
) throw (IllegalArgumentException
, NoSuchElementException
, ElementExistException
, WrappedTargetException
, RuntimeException
, std::exception
) SAL_OVERRIDE
;
269 virtual Reference
< XAnimationNode
> SAL_CALL
replaceChild( const Reference
< XAnimationNode
>& newChild
, const Reference
< XAnimationNode
>& oldChild
) throw( IllegalArgumentException
, NoSuchElementException
, ElementExistException
, WrappedTargetException
, RuntimeException
, std::exception
) SAL_OVERRIDE
;
270 virtual Reference
< XAnimationNode
> SAL_CALL
removeChild( const Reference
< XAnimationNode
>& oldChild
) throw(IllegalArgumentException
, NoSuchElementException
, WrappedTargetException
, RuntimeException
, std::exception
) SAL_OVERRIDE
;
271 virtual Reference
< XAnimationNode
> SAL_CALL
appendChild( const Reference
< XAnimationNode
>& newChild
) throw(IllegalArgumentException
, ElementExistException
, WrappedTargetException
, RuntimeException
, std::exception
) SAL_OVERRIDE
;
274 virtual sal_Int16 SAL_CALL
getIterateType() throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
275 virtual void SAL_CALL
setIterateType( sal_Int16 _iteratetype
) throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
276 virtual double SAL_CALL
getIterateInterval() throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
277 virtual void SAL_CALL
setIterateInterval( double _iterateinterval
) throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
280 virtual void SAL_CALL
addChangesListener( const Reference
< XChangesListener
>& aListener
) throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
281 virtual void SAL_CALL
removeChangesListener( const Reference
< XChangesListener
>& aListener
) throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
284 virtual ::sal_Int64 SAL_CALL
getSomething( const Sequence
< ::sal_Int8
>& aIdentifier
) throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
286 static const Sequence
< sal_Int8
> & getUnoTunnelId();
287 void fireChangeListener();
290 OInterfaceContainerHelper maChangeListener
;
292 static void initTypeProvider( sal_Int16 nNodeType
) throw();
294 const sal_Int16 mnNodeType
;
297 static Sequence
< Type
>* mpTypes
[12];
299 // attributes for the XAnimationNode interface implementation
300 Any maBegin
, maDuration
, maEnd
, maEndSync
, maRepeatCount
, maRepeatDuration
;
301 sal_Int16 mnFill
, mnFillDefault
, mnRestart
, mnRestartDefault
;
302 double mfAcceleration
, mfDecelerate
;
304 Sequence
< NamedValue
> maUserData
;
306 // parent interface for XChild interface implementation
307 WeakReference
<XInterface
> mxParent
;
308 AnimationNode
* mpParent
;
310 // attributes for XAnimate
312 OUString maAttributeName
, maFormula
;
313 Sequence
< Any
> maValues
;
314 Sequence
< double > maKeyTimes
;
315 sal_Int16 mnValueType
, mnSubItem
;
316 sal_Int16 mnCalcMode
, mnAdditive
;
318 Any maFrom
, maTo
, maBy
;
319 Sequence
< TimeFilterPair
> maTimeFilter
;
321 // attributes for XAnimateColor
322 sal_Int16 mnColorSpace
;
325 // attributes for XAnimateMotion
326 Any maPath
, maOrigin
;
328 // attributes for XAnimateTransform
329 sal_Int16 mnTransformType
;
331 // attributes for XTransitionFilter
332 sal_Int16 mnTransition
;
335 sal_Int32 mnFadeColor
;
345 sal_Int16 mnIterateType
;
346 double mfIterateInterval
;
348 /** sorted list of child nodes for XTimeContainer*/
349 ChildList_t maChildren
;
354 class TimeContainerEnumeration
: public ::cppu::WeakImplHelper1
< XEnumeration
>
357 explicit TimeContainerEnumeration( const ChildList_t
&rChildren
);
358 virtual ~TimeContainerEnumeration();
361 virtual sal_Bool SAL_CALL
hasMoreElements() throw (RuntimeException
, std::exception
) SAL_OVERRIDE
;
362 virtual Any SAL_CALL
nextElement( ) throw (NoSuchElementException
, WrappedTargetException
, RuntimeException
, std::exception
) SAL_OVERRIDE
;
365 /** sorted list of child nodes */
366 ChildList_t maChildren
;
368 /** current iteration position */
369 ChildList_t::iterator maIter
;
371 /** our first, last and only protection from mutli-threads! */
375 TimeContainerEnumeration::TimeContainerEnumeration( const ChildList_t
&rChildren
)
376 : maChildren( rChildren
)
378 maIter
= maChildren
.begin();
381 TimeContainerEnumeration::~TimeContainerEnumeration()
386 sal_Bool SAL_CALL
TimeContainerEnumeration::hasMoreElements() throw (RuntimeException
, std::exception
)
388 Guard
< Mutex
> aGuard( maMutex
);
390 return maIter
!= maChildren
.end();
393 Any SAL_CALL
TimeContainerEnumeration::nextElement()
394 throw (NoSuchElementException
, WrappedTargetException
, RuntimeException
, std::exception
)
396 Guard
< Mutex
> aGuard( maMutex
);
398 if( maIter
== maChildren
.end() )
399 throw NoSuchElementException();
401 return makeAny( (*maIter
++) );
406 Sequence
< Type
>* AnimationNode::mpTypes
[] = { NULL
, NULL
, NULL
, NULL
, NULL
, NULL
, NULL
, NULL
, NULL
, NULL
, NULL
};
408 AnimationNode::AnimationNode( sal_Int16 nNodeType
)
409 : maChangeListener(maMutex
),
410 mnNodeType( nNodeType
),
411 mnFill( AnimationFill::DEFAULT
),
412 mnFillDefault( AnimationFill::INHERIT
),
413 mnRestart( AnimationRestart:: DEFAULT
),
414 mnRestartDefault( AnimationRestart:: INHERIT
),
415 mfAcceleration( 0.0 ),
417 mbAutoReverse( false ),
421 mnCalcMode( (nNodeType
== AnimationNodeType::ANIMATEMOTION
) ? AnimationCalcMode::PACED
: AnimationCalcMode::LINEAR
),
422 mnAdditive(AnimationAdditiveMode::REPLACE
),
424 mnColorSpace( AnimationColorSpace::RGB
),
426 mnTransformType( AnimationTransformType::TRANSLATE
),
427 mnTransition(TransitionType::BARWIPE
),
428 mnSubtype(TransitionSubType::DEFAULT
),
433 mnIterateType( ::com::sun::star::presentation::ShapeAnimationSubType::AS_WHOLE
),
434 mfIterateInterval(0.0)
436 OSL_ENSURE((sal_uInt32
)nNodeType
< sizeof(mpTypes
)/sizeof(Sequence
<Type
>*), "NodeType out of range");
439 AnimationNode::AnimationNode( const AnimationNode
& rNode
)
440 : AnimationNodeBase(),
441 maChangeListener(maMutex
),
442 mnNodeType( rNode
.mnNodeType
),
444 // attributes for the XAnimationNode interface implementation
445 maBegin( rNode
.maBegin
),
446 maDuration( rNode
.maDuration
),
447 maEnd( rNode
.maEnd
),
448 maEndSync( rNode
.maEndSync
),
449 maRepeatCount( rNode
.maRepeatCount
),
450 maRepeatDuration( rNode
.maRepeatDuration
),
451 mnFill( rNode
.mnFill
),
452 mnFillDefault( rNode
.mnFillDefault
),
453 mnRestart( rNode
.mnRestart
),
454 mnRestartDefault( rNode
.mnRestartDefault
),
455 mfAcceleration( rNode
.mfAcceleration
),
456 mfDecelerate( rNode
.mfDecelerate
),
457 mbAutoReverse( rNode
.mbAutoReverse
),
458 maUserData( rNode
.maUserData
),
461 // attributes for XAnimate
462 maTarget( rNode
.maTarget
),
463 maAttributeName( rNode
.maAttributeName
),
464 maFormula( rNode
.maFormula
),
465 maValues( rNode
.maValues
),
466 maKeyTimes( rNode
.maKeyTimes
),
467 mnValueType( rNode
.mnValueType
),
468 mnSubItem( rNode
.mnSubItem
),
469 mnCalcMode( rNode
.mnCalcMode
),
470 mnAdditive( rNode
.mnAdditive
),
471 mbAccumulate( rNode
.mbAccumulate
),
472 maFrom( rNode
.maFrom
),
475 maTimeFilter( rNode
.maTimeFilter
),
477 // attributes for XAnimateColor
478 mnColorSpace( rNode
.mnColorSpace
),
479 mbDirection( rNode
.mbDirection
),
481 // attributes for XAnimateMotion
482 maPath( rNode
.maPath
),
483 maOrigin( rNode
.maOrigin
),
485 // attributes for XAnimateTransform
486 mnTransformType( rNode
.mnTransformType
),
488 // attributes for XTransitionFilter
489 mnTransition( rNode
.mnTransition
),
490 mnSubtype( rNode
.mnSubtype
),
491 mbMode( rNode
.mbMode
),
492 mnFadeColor( rNode
.mnFadeColor
),
495 mfVolume( rNode
.mfVolume
),
498 mnCommand( rNode
.mnCommand
),
499 maParameter( rNode
.maParameter
),
502 mnIterateType( rNode
.mnIterateType
),
503 mfIterateInterval( rNode
.mfIterateInterval
)
507 AnimationNode::~AnimationNode()
511 Sequence
<OUString
> getSupportedServiceNames_PAR()
513 Sequence
<OUString
> aRet(1);
514 aRet
.getArray()[0] = "com.sun.star.animations.ParallelTimeContainer";
518 OUString
getImplementationName_PAR()
520 return OUString( "animcore::ParallelTimeContainer" );
523 Sequence
<OUString
> getSupportedServiceNames_SEQ()
525 Sequence
<OUString
> aRet(1);
526 aRet
.getArray()[0] = "com.sun.star.animations.SequenceTimeContainer";
530 OUString
getImplementationName_SEQ()
532 return OUString( "animcore::SequenceTimeContainer" );
535 Sequence
<OUString
> getSupportedServiceNames_ITERATE()
537 Sequence
<OUString
> aRet(1);
538 aRet
.getArray()[0] = "com.sun.star.animations.IterateContainer";
542 OUString
getImplementationName_ITERATE()
544 return OUString( "animcore::IterateContainer" );
547 Sequence
<OUString
> getSupportedServiceNames_ANIMATE()
549 Sequence
<OUString
> aRet(1);
550 aRet
.getArray()[0] = "com.sun.star.animations.Animate";
554 OUString
getImplementationName_ANIMATE()
556 return OUString( "animcore::Animate" );
559 Sequence
<OUString
> getSupportedServiceNames_SET()
561 Sequence
<OUString
> aRet(1);
562 aRet
.getArray()[0] = "com.sun.star.animations.AnimateSet";
566 OUString
getImplementationName_SET()
568 return OUString( "animcore::AnimateSet" );
571 Sequence
<OUString
> getSupportedServiceNames_ANIMATECOLOR()
573 Sequence
<OUString
> aRet(1);
574 aRet
.getArray()[0] = "com.sun.star.animations.AnimateColor";
578 OUString
getImplementationName_ANIMATECOLOR()
580 return OUString( "animcore::AnimateColor" );
583 Sequence
<OUString
> getSupportedServiceNames_ANIMATEMOTION()
585 Sequence
<OUString
> aRet(1);
586 aRet
.getArray()[0] = "com.sun.star.animations.AnimateMotion";
590 OUString
getImplementationName_ANIMATEMOTION()
592 return OUString( "animcore::AnimateMotion" );
595 Sequence
<OUString
> getSupportedServiceNames_ANIMATETRANSFORM()
597 Sequence
<OUString
> aRet(1);
598 aRet
.getArray()[0] = "com.sun.star.animations.AnimateTransform";
602 OUString
getImplementationName_ANIMATETRANSFORM()
604 return OUString( "animcore::AnimateTransform" );
607 Sequence
<OUString
> getSupportedServiceNames_TRANSITIONFILTER()
609 Sequence
<OUString
> aRet(1);
610 aRet
.getArray()[0] = "com.sun.star.animations.TransitionFilter";
614 OUString
getImplementationName_TRANSITIONFILTER()
616 return OUString( "animcore::TransitionFilter" );
619 Sequence
<OUString
> getSupportedServiceNames_AUDIO()
621 Sequence
<OUString
> aRet(1);
622 aRet
.getArray()[0] = "com.sun.star.animations.Audio";
626 OUString
getImplementationName_AUDIO()
628 return OUString( "animcore::Audio" );
631 Sequence
<OUString
> getSupportedServiceNames_COMMAND()
633 Sequence
<OUString
> aRet(1);
634 aRet
.getArray()[0] = "com.sun.star.animations.Command";
638 OUString
getImplementationName_COMMAND()
640 return OUString( "animcore::Command" );
644 Any SAL_CALL
AnimationNode::queryInterface( const Type
& aType
) throw (RuntimeException
, std::exception
)
646 Any
aRet( ::cppu::queryInterface(
648 static_cast< XServiceInfo
* >( this ),
649 static_cast< XTypeProvider
* >( this ),
650 static_cast< XChild
* >( static_cast< XTimeContainer
* >( static_cast< XIterateContainer
* >(this) ) ),
651 static_cast< XCloneable
* >( this ),
652 static_cast< XAnimationNode
* >( static_cast< XTimeContainer
* >( static_cast< XIterateContainer
* >(this) ) ),
653 static_cast< XInterface
* >(static_cast< OWeakObject
* >(this)),
654 static_cast< XWeak
* >(static_cast< OWeakObject
* >(this)),
655 static_cast< XChangesNotifier
* >( this ),
656 static_cast< XUnoTunnel
* >( this ) ) );
662 case AnimationNodeType::PAR
:
663 aRet
= ::cppu::queryInterface(
665 static_cast< XParallelTimeContainer
* >( this ),
666 static_cast< XTimeContainer
* >( static_cast< XIterateContainer
* >(this) ),
667 static_cast< XEnumerationAccess
* >( this ),
668 static_cast< XElementAccess
* >( this ) );
670 case AnimationNodeType::SEQ
:
671 aRet
= ::cppu::queryInterface(
673 static_cast< XTimeContainer
* >( static_cast< XIterateContainer
* >(this) ),
674 static_cast< XEnumerationAccess
* >( this ),
675 static_cast< XElementAccess
* >( this ) );
677 case AnimationNodeType::ITERATE
:
678 aRet
= ::cppu::queryInterface(
680 static_cast< XTimeContainer
* >( static_cast< XIterateContainer
* >(this) ),
681 static_cast< XIterateContainer
* >( this ),
682 static_cast< XEnumerationAccess
* >( this ),
683 static_cast< XElementAccess
* >( this ) );
685 case AnimationNodeType::ANIMATE
:
686 aRet
= ::cppu::queryInterface(
688 static_cast< XAnimate
* >( static_cast< XAnimateMotion
* >(this) ) );
690 case AnimationNodeType::ANIMATEMOTION
:
691 aRet
= ::cppu::queryInterface(
693 static_cast< XAnimate
* >( static_cast< XAnimateMotion
* >(this) ),
694 static_cast< XAnimateMotion
* >( this ) );
696 case AnimationNodeType::ANIMATECOLOR
:
697 aRet
= ::cppu::queryInterface(
699 static_cast< XAnimate
* >( static_cast< XAnimateColor
* >(this) ),
700 static_cast< XAnimateColor
* >( this ) );
702 case AnimationNodeType::SET
:
703 aRet
= ::cppu::queryInterface(
705 static_cast< XAnimate
* >( static_cast< XAnimateSet
* >(this) ),
706 static_cast< XAnimateSet
* >( this ) );
708 case AnimationNodeType::ANIMATETRANSFORM
:
709 aRet
= ::cppu::queryInterface(
711 static_cast< XAnimate
* >( static_cast< XAnimateTransform
* >(this) ),
712 static_cast< XAnimateTransform
* >( this ) );
714 case AnimationNodeType::AUDIO
:
715 aRet
= ::cppu::queryInterface(
717 static_cast< XAudio
* >( static_cast< XAudio
* >(this) ) );
719 case AnimationNodeType::COMMAND
:
720 aRet
= ::cppu::queryInterface(
722 static_cast< XCommand
* >( static_cast< XCommand
* >(this) ) );
724 case AnimationNodeType::TRANSITIONFILTER
:
725 aRet
= ::cppu::queryInterface(
727 static_cast< XAnimate
* >( static_cast< XTransitionFilter
* >(this) ),
728 static_cast< XTransitionFilter
* >( this ) );
733 return aRet
.hasValue() ? aRet
: OWeakObject::queryInterface( aType
);
738 void AnimationNode::initTypeProvider( sal_Int16 nNodeType
) throw()
740 ::osl::MutexGuard
aGuard( ::osl::Mutex::getGlobalMutex() );
742 if(! mpTypes
[nNodeType
] )
744 static const sal_Int32 type_numbers
[] =
754 8, // ANIMATETRANSFORM
755 8, // TRANSITIONFILTER
761 Sequence
< Type
> * types
= new Sequence
< Type
>( type_numbers
[nNodeType
] );
762 Type
* pTypeAr
= types
->getArray();
765 pTypeAr
[nPos
++] = cppu::UnoType
<XWeak
>::get();
766 pTypeAr
[nPos
++] = cppu::UnoType
<XChild
>::get();
767 pTypeAr
[nPos
++] = cppu::UnoType
<XCloneable
>::get();
768 pTypeAr
[nPos
++] = cppu::UnoType
<XTypeProvider
>::get();
769 pTypeAr
[nPos
++] = cppu::UnoType
<XServiceInfo
>::get();
770 pTypeAr
[nPos
++] = cppu::UnoType
<XUnoTunnel
>::get();
771 pTypeAr
[nPos
++] = cppu::UnoType
<XChangesNotifier
>::get();
775 case AnimationNodeType::PAR
:
776 case AnimationNodeType::SEQ
:
777 pTypeAr
[nPos
++] = cppu::UnoType
<XTimeContainer
>::get();
778 pTypeAr
[nPos
++] = cppu::UnoType
<XEnumerationAccess
>::get();
780 case AnimationNodeType::ITERATE
:
781 pTypeAr
[nPos
++] = cppu::UnoType
<XIterateContainer
>::get();
782 pTypeAr
[nPos
++] = cppu::UnoType
<XEnumerationAccess
>::get();
784 case AnimationNodeType::ANIMATE
:
785 pTypeAr
[nPos
++] = cppu::UnoType
<XAnimate
>::get();
787 case AnimationNodeType::ANIMATEMOTION
:
788 pTypeAr
[nPos
++] = cppu::UnoType
<XAnimateMotion
>::get();
790 case AnimationNodeType::ANIMATECOLOR
:
791 pTypeAr
[nPos
++] = cppu::UnoType
<XAnimateColor
>::get();
793 case AnimationNodeType::ANIMATETRANSFORM
:
794 pTypeAr
[nPos
++] = cppu::UnoType
<XAnimateTransform
>::get();
796 case AnimationNodeType::SET
:
797 pTypeAr
[nPos
++] = cppu::UnoType
<XAnimateSet
>::get();
799 case AnimationNodeType::TRANSITIONFILTER
:
800 pTypeAr
[nPos
++] = cppu::UnoType
<XTransitionFilter
>::get();
802 case AnimationNodeType::AUDIO
:
803 pTypeAr
[nPos
++] = cppu::UnoType
<XAudio
>::get();
805 case AnimationNodeType::COMMAND
:
806 pTypeAr
[nPos
++] = cppu::UnoType
<XCommand
>::get();
809 mpTypes
[nNodeType
] = types
;
815 Sequence
< Type
> AnimationNode::getTypes() throw (RuntimeException
, std::exception
)
817 if (! mpTypes
[mnNodeType
])
818 initTypeProvider(mnNodeType
);
819 return *mpTypes
[mnNodeType
];
823 Sequence
< sal_Int8
> AnimationNode::getImplementationId() throw (RuntimeException
, std::exception
)
825 return css::uno::Sequence
<sal_Int8
>();
831 void SAL_CALL
AnimationNode::acquire( ) throw ()
833 OWeakObject::acquire();
839 void SAL_CALL
AnimationNode::release( ) throw ()
841 OWeakObject::release();
847 OUString
AnimationNode::getImplementationName() throw(std::exception
)
851 case AnimationNodeType::PAR
:
852 return getImplementationName_PAR();
853 case AnimationNodeType::SEQ
:
854 return getImplementationName_SEQ();
855 case AnimationNodeType::ITERATE
:
856 return getImplementationName_ITERATE();
857 case AnimationNodeType::SET
:
858 return getImplementationName_SET();
859 case AnimationNodeType::ANIMATECOLOR
:
860 return getImplementationName_ANIMATECOLOR();
861 case AnimationNodeType::ANIMATEMOTION
:
862 return getImplementationName_ANIMATEMOTION();
863 case AnimationNodeType::TRANSITIONFILTER
:
864 return getImplementationName_TRANSITIONFILTER();
865 case AnimationNodeType::ANIMATETRANSFORM
:
866 return getImplementationName_ANIMATETRANSFORM();
867 case AnimationNodeType::AUDIO
:
868 return getImplementationName_AUDIO();
869 case AnimationNodeType::COMMAND
:
870 return getImplementationName_COMMAND();
871 case AnimationNodeType::ANIMATE
:
873 return getImplementationName_ANIMATE();
878 sal_Bool
AnimationNode::supportsService(const OUString
& ServiceName
) throw(std::exception
)
880 return cppu::supportsService(this, ServiceName
);
884 Sequence
< OUString
> AnimationNode::getSupportedServiceNames() throw(std::exception
)
888 case AnimationNodeType::PAR
:
889 return getSupportedServiceNames_PAR();
890 case AnimationNodeType::SEQ
:
891 return getSupportedServiceNames_SEQ();
892 case AnimationNodeType::ITERATE
:
893 return getSupportedServiceNames_ITERATE();
894 case AnimationNodeType::SET
:
895 return getSupportedServiceNames_SET();
896 case AnimationNodeType::ANIMATECOLOR
:
897 return getSupportedServiceNames_ANIMATECOLOR();
898 case AnimationNodeType::ANIMATEMOTION
:
899 return getSupportedServiceNames_ANIMATEMOTION();
900 case AnimationNodeType::TRANSITIONFILTER
:
901 return getSupportedServiceNames_TRANSITIONFILTER();
902 case AnimationNodeType::ANIMATETRANSFORM
:
903 return getSupportedServiceNames_ANIMATETRANSFORM();
904 case AnimationNodeType::AUDIO
:
905 return getSupportedServiceNames_AUDIO();
906 case AnimationNodeType::COMMAND
:
907 return getSupportedServiceNames_COMMAND();
908 case AnimationNodeType::ANIMATE
:
910 return getSupportedServiceNames_ANIMATE();
917 sal_Int16 SAL_CALL
AnimationNode::getType() throw (RuntimeException
, std::exception
)
919 Guard
< Mutex
> aGuard( maMutex
);
926 Any SAL_CALL
AnimationNode::getBegin() throw (RuntimeException
, std::exception
)
928 Guard
< Mutex
> aGuard( maMutex
);
935 void SAL_CALL
AnimationNode::setBegin( const Any
& _begin
) throw (RuntimeException
, std::exception
)
937 Guard
< Mutex
> aGuard( maMutex
);
938 if( _begin
!= maBegin
)
941 fireChangeListener();
948 Any SAL_CALL
AnimationNode::getDuration() throw (RuntimeException
, std::exception
)
950 Guard
< Mutex
> aGuard( maMutex
);
957 void SAL_CALL
AnimationNode::setDuration( const Any
& _duration
) throw (RuntimeException
, std::exception
)
959 Guard
< Mutex
> aGuard( maMutex
);
960 if( _duration
!= maDuration
)
962 maDuration
= _duration
;
963 fireChangeListener();
970 Any SAL_CALL
AnimationNode::getEnd() throw (RuntimeException
, std::exception
)
972 Guard
< Mutex
> aGuard( maMutex
);
979 void SAL_CALL
AnimationNode::setEnd( const Any
& _end
) throw (RuntimeException
, std::exception
)
981 Guard
< Mutex
> aGuard( maMutex
);
985 fireChangeListener();
992 Any SAL_CALL
AnimationNode::getEndSync() throw (RuntimeException
, std::exception
)
994 Guard
< Mutex
> aGuard( maMutex
);
1001 void SAL_CALL
AnimationNode::setEndSync( const Any
& _endsync
) throw (RuntimeException
, std::exception
)
1003 Guard
< Mutex
> aGuard( maMutex
);
1004 if( _endsync
!= maEndSync
)
1006 maEndSync
= _endsync
;
1007 fireChangeListener();
1014 Any SAL_CALL
AnimationNode::getRepeatCount() throw (RuntimeException
, std::exception
)
1016 Guard
< Mutex
> aGuard( maMutex
);
1017 return maRepeatCount
;
1023 void SAL_CALL
AnimationNode::setRepeatCount( const Any
& _repeatcount
) throw (RuntimeException
, std::exception
)
1025 Guard
< Mutex
> aGuard( maMutex
);
1026 if( _repeatcount
!= maRepeatCount
)
1028 maRepeatCount
= _repeatcount
;
1029 fireChangeListener();
1036 Any SAL_CALL
AnimationNode::getRepeatDuration() throw (RuntimeException
, std::exception
)
1038 Guard
< Mutex
> aGuard( maMutex
);
1039 return maRepeatDuration
;
1045 void SAL_CALL
AnimationNode::setRepeatDuration( const Any
& _repeatduration
) throw (RuntimeException
, std::exception
)
1047 Guard
< Mutex
> aGuard( maMutex
);
1048 if( _repeatduration
!= maRepeatDuration
)
1050 maRepeatDuration
= _repeatduration
;
1051 fireChangeListener();
1058 sal_Int16 SAL_CALL
AnimationNode::getFill() throw (RuntimeException
, std::exception
)
1060 Guard
< Mutex
> aGuard( maMutex
);
1067 void SAL_CALL
AnimationNode::setFill( sal_Int16 _fill
) throw (RuntimeException
, std::exception
)
1069 Guard
< Mutex
> aGuard( maMutex
);
1070 if( _fill
!= mnFill
)
1073 fireChangeListener();
1080 sal_Int16 SAL_CALL
AnimationNode::getFillDefault() throw (RuntimeException
, std::exception
)
1082 Guard
< Mutex
> aGuard( maMutex
);
1083 return mnFillDefault
;
1089 void SAL_CALL
AnimationNode::setFillDefault( sal_Int16 _filldefault
) throw (RuntimeException
, std::exception
)
1091 Guard
< Mutex
> aGuard( maMutex
);
1092 if( _filldefault
!= mnFillDefault
)
1094 mnFillDefault
= _filldefault
;
1095 fireChangeListener();
1102 sal_Int16 SAL_CALL
AnimationNode::getRestart() throw (RuntimeException
, std::exception
)
1104 Guard
< Mutex
> aGuard( maMutex
);
1111 void SAL_CALL
AnimationNode::setRestart( sal_Int16 _restart
) throw (RuntimeException
, std::exception
)
1113 Guard
< Mutex
> aGuard( maMutex
);
1114 if( _restart
!= mnRestart
)
1116 mnRestart
= _restart
;
1117 fireChangeListener();
1124 sal_Int16 SAL_CALL
AnimationNode::getRestartDefault() throw (RuntimeException
, std::exception
)
1126 Guard
< Mutex
> aGuard( maMutex
);
1127 return mnRestartDefault
;
1133 void SAL_CALL
AnimationNode::setRestartDefault( sal_Int16 _restartdefault
) throw (RuntimeException
, std::exception
)
1135 Guard
< Mutex
> aGuard( maMutex
);
1136 if( _restartdefault
!= mnRestartDefault
)
1138 mnRestartDefault
= _restartdefault
;
1139 fireChangeListener();
1146 double SAL_CALL
AnimationNode::getAcceleration() throw (RuntimeException
, std::exception
)
1148 Guard
< Mutex
> aGuard( maMutex
);
1149 return mfAcceleration
;
1155 void SAL_CALL
AnimationNode::setAcceleration( double _acceleration
) throw (RuntimeException
, std::exception
)
1157 Guard
< Mutex
> aGuard( maMutex
);
1158 if( _acceleration
!= mfAcceleration
)
1160 mfAcceleration
= _acceleration
;
1161 fireChangeListener();
1168 double SAL_CALL
AnimationNode::getDecelerate() throw (RuntimeException
, std::exception
)
1170 Guard
< Mutex
> aGuard( maMutex
);
1171 return mfDecelerate
;
1177 void SAL_CALL
AnimationNode::setDecelerate( double _decelerate
) throw (RuntimeException
, std::exception
)
1179 Guard
< Mutex
> aGuard( maMutex
);
1180 if( _decelerate
!= mfDecelerate
)
1182 mfDecelerate
= _decelerate
;
1183 fireChangeListener();
1190 sal_Bool SAL_CALL
AnimationNode::getAutoReverse() throw (RuntimeException
, std::exception
)
1192 Guard
< Mutex
> aGuard( maMutex
);
1193 return mbAutoReverse
;
1199 void SAL_CALL
AnimationNode::setAutoReverse( sal_Bool _autoreverse
) throw (RuntimeException
, std::exception
)
1201 Guard
< Mutex
> aGuard( maMutex
);
1202 if( bool(_autoreverse
) != mbAutoReverse
)
1204 mbAutoReverse
= _autoreverse
;
1205 fireChangeListener();
1211 Sequence
< NamedValue
> SAL_CALL
AnimationNode::getUserData() throw (RuntimeException
, std::exception
)
1213 Guard
< Mutex
> aGuard( maMutex
);
1219 void SAL_CALL
AnimationNode::setUserData( const Sequence
< NamedValue
>& _userdata
) throw (RuntimeException
, std::exception
)
1221 Guard
< Mutex
> aGuard( maMutex
);
1222 maUserData
= _userdata
;
1223 fireChangeListener();
1229 Reference
< XInterface
> SAL_CALL
AnimationNode::getParent() throw (RuntimeException
, std::exception
)
1231 Guard
< Mutex
> aGuard( maMutex
);
1232 return mxParent
.get();
1238 void SAL_CALL
AnimationNode::setParent( const Reference
< XInterface
>& Parent
) throw (NoSupportException
, RuntimeException
, std::exception
)
1240 Guard
< Mutex
> aGuard( maMutex
);
1241 if( Parent
!= mxParent
.get() )
1246 Reference
< XUnoTunnel
> xTunnel( mxParent
.get(), UNO_QUERY
);
1248 mpParent
= reinterpret_cast< AnimationNode
* >( sal::static_int_cast
< sal_IntPtr
>(xTunnel
->getSomething( getUnoTunnelId() )));
1250 fireChangeListener();
1257 Reference
< XCloneable
> SAL_CALL
AnimationNode::createClone() throw (RuntimeException
, std::exception
)
1259 Guard
< Mutex
> aGuard( maMutex
);
1261 Reference
< XCloneable
> xNewNode
;
1264 xNewNode
= new AnimationNode( *this );
1266 if( !maChildren
.empty() )
1268 Reference
< XTimeContainer
> xContainer( xNewNode
, UNO_QUERY
);
1269 if( xContainer
.is() )
1271 ChildList_t::iterator
aIter( maChildren
.begin() );
1272 ChildList_t::iterator
aEnd( maChildren
.end() );
1273 while( aIter
!= aEnd
)
1275 Reference
< XCloneable
> xCloneable((*aIter
++), UNO_QUERY
);
1276 if( xCloneable
.is() ) try
1278 Reference
< XAnimationNode
> xNewChildNode( xCloneable
->createClone(), UNO_QUERY
);
1279 if( xNewChildNode
.is() )
1280 xContainer
->appendChild( xNewChildNode
);
1282 catch(const Exception
&)
1284 OSL_TRACE( "animations::AnimationNode::createClone(), exception caught!" );
1290 catch(const Exception
&)
1292 OSL_TRACE( "animations::AnimationNode::createClone(), exception caught!" );
1301 Any SAL_CALL
AnimationNode::getTarget()
1302 throw (RuntimeException
, std::exception
)
1304 Guard
< Mutex
> aGuard( maMutex
);
1311 void SAL_CALL
AnimationNode::setTarget( const Any
& _target
)
1312 throw (RuntimeException
, std::exception
)
1314 Guard
< Mutex
> aGuard( maMutex
);
1315 if( _target
!= maTarget
)
1318 fireChangeListener();
1325 OUString SAL_CALL
AnimationNode::getAttributeName() throw (RuntimeException
, std::exception
)
1327 Guard
< Mutex
> aGuard( maMutex
);
1328 return maAttributeName
;
1334 void SAL_CALL
AnimationNode::setAttributeName( const OUString
& _attribute
)
1335 throw (RuntimeException
, std::exception
)
1337 Guard
< Mutex
> aGuard( maMutex
);
1338 if( _attribute
!= maAttributeName
)
1340 maAttributeName
= _attribute
;
1341 fireChangeListener();
1348 Sequence
< Any
> SAL_CALL
AnimationNode::getValues()
1349 throw (RuntimeException
, std::exception
)
1351 Guard
< Mutex
> aGuard( maMutex
);
1358 void SAL_CALL
AnimationNode::setValues( const Sequence
< Any
>& _values
)
1359 throw (RuntimeException
, std::exception
)
1361 Guard
< Mutex
> aGuard( maMutex
);
1363 fireChangeListener();
1369 sal_Int16 SAL_CALL
AnimationNode::getSubItem() throw (RuntimeException
, std::exception
)
1371 Guard
< Mutex
> aGuard( maMutex
);
1378 void SAL_CALL
AnimationNode::setSubItem( sal_Int16 _subitem
) throw (RuntimeException
, std::exception
)
1380 Guard
< Mutex
> aGuard( maMutex
);
1381 if( _subitem
!= mnSubItem
)
1383 mnSubItem
= _subitem
;
1384 fireChangeListener();
1391 Sequence
< double > SAL_CALL
AnimationNode::getKeyTimes() throw (RuntimeException
, std::exception
)
1393 Guard
< Mutex
> aGuard( maMutex
);
1400 void SAL_CALL
AnimationNode::setKeyTimes( const Sequence
< double >& _keytimes
) throw (RuntimeException
, std::exception
)
1402 Guard
< Mutex
> aGuard( maMutex
);
1403 maKeyTimes
= _keytimes
;
1404 fireChangeListener();
1410 sal_Int16 SAL_CALL
AnimationNode::getValueType() throw (RuntimeException
, std::exception
)
1412 Guard
< Mutex
> aGuard( maMutex
);
1418 void SAL_CALL
AnimationNode::setValueType( sal_Int16 _valuetype
) throw (RuntimeException
, std::exception
)
1420 Guard
< Mutex
> aGuard( maMutex
);
1421 if( _valuetype
!= mnValueType
)
1423 mnValueType
= _valuetype
;
1424 fireChangeListener();
1431 sal_Int16 SAL_CALL
AnimationNode::getCalcMode()
1432 throw (RuntimeException
, std::exception
)
1434 Guard
< Mutex
> aGuard( maMutex
);
1441 void SAL_CALL
AnimationNode::setCalcMode( sal_Int16 _calcmode
)
1442 throw (RuntimeException
, std::exception
)
1444 Guard
< Mutex
> aGuard( maMutex
);
1445 if( _calcmode
!= mnCalcMode
)
1447 mnCalcMode
= _calcmode
;
1448 fireChangeListener();
1455 sal_Bool SAL_CALL
AnimationNode::getAccumulate()
1456 throw (RuntimeException
, std::exception
)
1458 Guard
< Mutex
> aGuard( maMutex
);
1459 return mbAccumulate
;
1465 void SAL_CALL
AnimationNode::setAccumulate( sal_Bool _accumulate
)
1466 throw (RuntimeException
, std::exception
)
1468 Guard
< Mutex
> aGuard( maMutex
);
1469 if( bool(_accumulate
) != mbAccumulate
)
1471 mbAccumulate
= _accumulate
;
1472 fireChangeListener();
1479 sal_Int16 SAL_CALL
AnimationNode::getAdditive()
1480 throw (RuntimeException
, std::exception
)
1482 Guard
< Mutex
> aGuard( maMutex
);
1489 void SAL_CALL
AnimationNode::setAdditive( sal_Int16 _additive
)
1490 throw (RuntimeException
, std::exception
)
1492 Guard
< Mutex
> aGuard( maMutex
);
1493 if( _additive
!= mnAdditive
)
1495 mnAdditive
= _additive
;
1496 fireChangeListener();
1503 Any SAL_CALL
AnimationNode::getFrom()
1504 throw (RuntimeException
, std::exception
)
1506 Guard
< Mutex
> aGuard( maMutex
);
1513 void SAL_CALL
AnimationNode::setFrom( const Any
& _from
)
1514 throw (RuntimeException
, std::exception
)
1516 Guard
< Mutex
> aGuard( maMutex
);
1517 if( _from
!= maFrom
)
1520 fireChangeListener();
1527 Any SAL_CALL
AnimationNode::getTo()
1528 throw (RuntimeException
, std::exception
)
1530 Guard
< Mutex
> aGuard( maMutex
);
1537 void SAL_CALL
AnimationNode::setTo( const Any
& _to
)
1538 throw (RuntimeException
, std::exception
)
1540 Guard
< Mutex
> aGuard( maMutex
);
1544 fireChangeListener();
1551 Any SAL_CALL
AnimationNode::getBy()
1552 throw (RuntimeException
, std::exception
)
1554 Guard
< Mutex
> aGuard( maMutex
);
1561 void SAL_CALL
AnimationNode::setBy( const Any
& _by
)
1562 throw (RuntimeException
, std::exception
)
1564 Guard
< Mutex
> aGuard( maMutex
);
1568 fireChangeListener();
1575 Sequence
< TimeFilterPair
> SAL_CALL
AnimationNode::getTimeFilter()
1576 throw (RuntimeException
, std::exception
)
1578 Guard
< Mutex
> aGuard( maMutex
);
1579 return maTimeFilter
;
1585 void SAL_CALL
AnimationNode::setTimeFilter( const Sequence
< TimeFilterPair
>& _timefilter
)
1586 throw (RuntimeException
, std::exception
)
1588 Guard
< Mutex
> aGuard( maMutex
);
1589 maTimeFilter
= _timefilter
;
1590 fireChangeListener();
1595 OUString SAL_CALL
AnimationNode::getFormula() throw (RuntimeException
, std::exception
)
1597 Guard
< Mutex
> aGuard( maMutex
);
1603 void SAL_CALL
AnimationNode::setFormula( const OUString
& _formula
) throw (RuntimeException
, std::exception
)
1605 Guard
< Mutex
> aGuard( maMutex
);
1606 if( _formula
!= maFormula
)
1608 maFormula
= _formula
;
1609 fireChangeListener();
1616 sal_Int16 SAL_CALL
AnimationNode::getColorInterpolation() throw (RuntimeException
, std::exception
)
1618 Guard
< Mutex
> aGuard( maMutex
);
1619 return mnColorSpace
;
1625 void SAL_CALL
AnimationNode::setColorInterpolation( sal_Int16 _colorspace
) throw (RuntimeException
, std::exception
)
1627 Guard
< Mutex
> aGuard( maMutex
);
1628 if( _colorspace
!= mnColorSpace
)
1630 mnColorSpace
= _colorspace
;
1631 fireChangeListener();
1638 sal_Bool SAL_CALL
AnimationNode::getDirection() throw (RuntimeException
, std::exception
)
1640 Guard
< Mutex
> aGuard( maMutex
);
1647 void SAL_CALL
AnimationNode::setDirection( sal_Bool _direction
) throw (RuntimeException
, std::exception
)
1649 Guard
< Mutex
> aGuard( maMutex
);
1650 if( bool(_direction
) != mbDirection
)
1652 mbDirection
= _direction
;
1653 fireChangeListener();
1660 Any SAL_CALL
AnimationNode::getPath() throw (RuntimeException
, std::exception
)
1662 Guard
< Mutex
> aGuard( maMutex
);
1669 void SAL_CALL
AnimationNode::setPath( const Any
& _path
) throw (RuntimeException
, std::exception
)
1671 Guard
< Mutex
> aGuard( maMutex
);
1673 fireChangeListener();
1679 Any SAL_CALL
AnimationNode::getOrigin() throw (RuntimeException
, std::exception
)
1681 Guard
< Mutex
> aGuard( maMutex
);
1688 void SAL_CALL
AnimationNode::setOrigin( const Any
& _origin
) throw (RuntimeException
, std::exception
)
1690 Guard
< Mutex
> aGuard( maMutex
);
1692 fireChangeListener();
1697 // XAnimateTransform
1698 sal_Int16 SAL_CALL
AnimationNode::getTransformType() throw (RuntimeException
, std::exception
)
1700 Guard
< Mutex
> aGuard( maMutex
);
1701 return mnTransformType
;
1706 // XAnimateTransform
1707 void SAL_CALL
AnimationNode::setTransformType( sal_Int16 _transformtype
) throw (RuntimeException
, std::exception
)
1709 Guard
< Mutex
> aGuard( maMutex
);
1710 if( _transformtype
!= mnTransformType
)
1712 mnTransformType
= _transformtype
;
1713 fireChangeListener();
1719 // XTransitionFilter
1720 sal_Int16 SAL_CALL
AnimationNode::getTransition() throw (RuntimeException
, std::exception
)
1722 Guard
< Mutex
> aGuard( maMutex
);
1723 return mnTransition
;
1728 // XTransitionFilter
1729 void SAL_CALL
AnimationNode::setTransition( sal_Int16 _transition
) throw (RuntimeException
, std::exception
)
1731 Guard
< Mutex
> aGuard( maMutex
);
1732 if( _transition
!= mnTransition
)
1734 mnTransition
= _transition
;
1735 fireChangeListener();
1741 // XTransitionFilter
1742 sal_Int16 SAL_CALL
AnimationNode::getSubtype() throw (RuntimeException
, std::exception
)
1744 Guard
< Mutex
> aGuard( maMutex
);
1750 // XTransitionFilter
1751 void SAL_CALL
AnimationNode::setSubtype( sal_Int16 _subtype
) throw (RuntimeException
, std::exception
)
1753 Guard
< Mutex
> aGuard( maMutex
);
1754 if( _subtype
!= mnSubtype
)
1756 mnSubtype
= _subtype
;
1757 fireChangeListener();
1763 // XTransitionFilter
1764 sal_Bool SAL_CALL
AnimationNode::getMode() throw (RuntimeException
, std::exception
)
1766 Guard
< Mutex
> aGuard( maMutex
);
1772 // XTransitionFilter
1773 void SAL_CALL
AnimationNode::setMode( sal_Bool _mode
) throw (RuntimeException
, std::exception
)
1775 Guard
< Mutex
> aGuard( maMutex
);
1776 if( bool(_mode
) != mbMode
)
1779 fireChangeListener();
1785 // XTransitionFilter
1786 sal_Int32 SAL_CALL
AnimationNode::getFadeColor() throw (RuntimeException
, std::exception
)
1788 Guard
< Mutex
> aGuard( maMutex
);
1794 // XTransitionFilter
1795 void SAL_CALL
AnimationNode::setFadeColor( sal_Int32 _fadecolor
) throw (RuntimeException
, std::exception
)
1797 Guard
< Mutex
> aGuard( maMutex
);
1798 if( _fadecolor
!= mnFadeColor
)
1800 mnFadeColor
= _fadecolor
;
1801 fireChangeListener();
1808 Any SAL_CALL
AnimationNode::getSource() throw (RuntimeException
, std::exception
)
1810 Guard
< Mutex
> aGuard( maMutex
);
1817 void SAL_CALL
AnimationNode::setSource( const Any
& _source
) throw (RuntimeException
, std::exception
)
1819 Guard
< Mutex
> aGuard( maMutex
);
1821 fireChangeListener();
1827 double SAL_CALL
AnimationNode::getVolume() throw (RuntimeException
, std::exception
)
1829 Guard
< Mutex
> aGuard( maMutex
);
1836 void SAL_CALL
AnimationNode::setVolume( double _volume
) throw (RuntimeException
, std::exception
)
1838 Guard
< Mutex
> aGuard( maMutex
);
1839 if( _volume
!= mfVolume
)
1842 fireChangeListener();
1849 sal_Int16 SAL_CALL
AnimationNode::getCommand() throw (RuntimeException
, std::exception
)
1851 Guard
< Mutex
> aGuard( maMutex
);
1858 void SAL_CALL
AnimationNode::setCommand( sal_Int16 _command
) throw (RuntimeException
, std::exception
)
1860 Guard
< Mutex
> aGuard( maMutex
);
1861 if( _command
!= mnCommand
)
1863 mnCommand
= _command
;
1864 fireChangeListener();
1871 Any SAL_CALL
AnimationNode::getParameter() throw (RuntimeException
, std::exception
)
1873 Guard
< Mutex
> aGuard( maMutex
);
1880 void SAL_CALL
AnimationNode::setParameter( const Any
& _parameter
) throw (RuntimeException
, std::exception
)
1882 Guard
< Mutex
> aGuard( maMutex
);
1883 maParameter
= _parameter
;
1884 fireChangeListener();
1890 Type SAL_CALL
AnimationNode::getElementType() throw (RuntimeException
, std::exception
)
1892 return cppu::UnoType
<XAnimationNode
>::get();
1898 sal_Bool SAL_CALL
AnimationNode::hasElements() throw (RuntimeException
, std::exception
)
1900 Guard
< Mutex
> aGuard( maMutex
);
1901 return !maChildren
.empty();
1906 // XEnumerationAccess
1907 Reference
< XEnumeration
> SAL_CALL
AnimationNode::createEnumeration()
1908 throw (RuntimeException
, std::exception
)
1910 Guard
< Mutex
> aGuard( maMutex
);
1912 return new TimeContainerEnumeration( maChildren
);
1919 Reference
< XAnimationNode
> SAL_CALL
AnimationNode::insertBefore( const Reference
< XAnimationNode
>& newChild
, const Reference
< XAnimationNode
>& refChild
)
1920 throw (IllegalArgumentException
, NoSuchElementException
, ElementExistException
, WrappedTargetException
, RuntimeException
, std::exception
)
1922 Guard
< Mutex
> aGuard( maMutex
);
1924 if( !newChild
.is() || !refChild
.is() )
1925 throw IllegalArgumentException();
1927 ChildList_t::iterator before
= ::std::find(maChildren
.begin(), maChildren
.end(), refChild
);
1928 if( before
== maChildren
.end() )
1929 throw NoSuchElementException();
1931 if( ::std::find(maChildren
.begin(), maChildren
.end(), newChild
) != maChildren
.end() )
1932 throw ElementExistException();
1934 maChildren
.insert( before
, newChild
);
1936 Reference
< XInterface
> xThis( static_cast< OWeakObject
* >(this) );
1937 newChild
->setParent( xThis
);
1945 Reference
< XAnimationNode
> SAL_CALL
AnimationNode::insertAfter( const Reference
< XAnimationNode
>& newChild
, const Reference
< XAnimationNode
>& refChild
)
1946 throw (IllegalArgumentException
, NoSuchElementException
, ElementExistException
, WrappedTargetException
, RuntimeException
, std::exception
)
1948 Guard
< Mutex
> aGuard( maMutex
);
1950 if( !newChild
.is() || !refChild
.is() )
1951 throw IllegalArgumentException();
1953 ChildList_t::iterator before
= ::std::find(maChildren
.begin(), maChildren
.end(), refChild
);
1954 if( before
== maChildren
.end() )
1955 throw NoSuchElementException();
1957 if( ::std::find(maChildren
.begin(), maChildren
.end(), newChild
) != maChildren
.end() )
1958 throw ElementExistException();
1961 if( before
!= maChildren
.end() )
1962 maChildren
.insert( before
, newChild
);
1964 maChildren
.push_back( newChild
);
1966 Reference
< XInterface
> xThis( static_cast< OWeakObject
* >(this) );
1967 newChild
->setParent( xThis
);
1975 Reference
< XAnimationNode
> SAL_CALL
AnimationNode::replaceChild( const Reference
< XAnimationNode
>& newChild
, const Reference
< XAnimationNode
>& oldChild
)
1976 throw( IllegalArgumentException
, NoSuchElementException
, ElementExistException
, WrappedTargetException
, RuntimeException
, std::exception
)
1978 Guard
< Mutex
> aGuard( maMutex
);
1980 if( !newChild
.is() || !oldChild
.is() )
1981 throw IllegalArgumentException();
1983 ChildList_t::iterator replace
= ::std::find(maChildren
.begin(), maChildren
.end(), oldChild
);
1984 if( replace
== maChildren
.end() )
1985 throw NoSuchElementException();
1987 if( ::std::find(maChildren
.begin(), maChildren
.end(), newChild
) != maChildren
.end() )
1988 throw ElementExistException();
1990 Reference
< XInterface
> xNull( 0 );
1991 oldChild
->setParent( xNull
);
1993 (*replace
) = newChild
;
1995 Reference
< XInterface
> xThis( static_cast< OWeakObject
* >(this) );
1996 newChild
->setParent( xThis
);
2004 Reference
< XAnimationNode
> SAL_CALL
AnimationNode::removeChild( const Reference
< XAnimationNode
>& oldChild
)
2005 throw(IllegalArgumentException
, NoSuchElementException
, WrappedTargetException
, RuntimeException
, std::exception
)
2007 Guard
< Mutex
> aGuard( maMutex
);
2009 if( !oldChild
.is() )
2010 throw IllegalArgumentException();
2012 ChildList_t::iterator old
= ::std::find(maChildren
.begin(), maChildren
.end(), oldChild
);
2013 if( old
== maChildren
.end() )
2014 throw NoSuchElementException();
2016 Reference
< XInterface
> xNull( 0 );
2017 oldChild
->setParent( xNull
);
2019 maChildren
.erase( old
);
2027 Reference
< XAnimationNode
> SAL_CALL
AnimationNode::appendChild( const Reference
< XAnimationNode
>& newChild
)
2028 throw(IllegalArgumentException
, ElementExistException
, WrappedTargetException
, RuntimeException
, std::exception
)
2030 Guard
< Mutex
> aGuard( maMutex
);
2032 if( !newChild
.is() )
2033 throw IllegalArgumentException();
2035 if( ::std::find(maChildren
.begin(), maChildren
.end(), newChild
) != maChildren
.end() )
2036 throw ElementExistException();
2038 Reference
< XInterface
> xThis( static_cast< OWeakObject
* >(this) );
2039 Reference
< XInterface
> xChild( newChild
);
2041 if( xThis
== xChild
)
2042 throw IllegalArgumentException();
2044 maChildren
.push_back( newChild
);
2046 newChild
->setParent( xThis
);
2053 // XIterateContainer
2054 sal_Int16 SAL_CALL
AnimationNode::getIterateType() throw (RuntimeException
, std::exception
)
2056 Guard
< Mutex
> aGuard( maMutex
);
2057 return mnIterateType
;
2062 // XIterateContainer
2063 void SAL_CALL
AnimationNode::setIterateType( sal_Int16 _iteratetype
) throw (RuntimeException
, std::exception
)
2065 Guard
< Mutex
> aGuard( maMutex
);
2066 if( _iteratetype
!= mnIterateType
)
2068 mnIterateType
= _iteratetype
;
2069 fireChangeListener();
2075 // XIterateContainer
2076 double SAL_CALL
AnimationNode::getIterateInterval() throw (RuntimeException
, std::exception
)
2078 Guard
< Mutex
> aGuard( maMutex
);
2079 return mfIterateInterval
;
2084 // XIterateContainer
2085 void SAL_CALL
AnimationNode::setIterateInterval( double _iterateinterval
) throw (RuntimeException
, std::exception
)
2087 Guard
< Mutex
> aGuard( maMutex
);
2088 if( _iterateinterval
!= mfIterateInterval
)
2090 mfIterateInterval
= _iterateinterval
;
2091 fireChangeListener();
2098 void SAL_CALL
AnimationNode::addChangesListener( const Reference
< XChangesListener
>& aListener
) throw (RuntimeException
, std::exception
)
2100 maChangeListener
.addInterface( aListener
);
2106 void SAL_CALL
AnimationNode::removeChangesListener( const Reference
< XChangesListener
>& aListener
) throw (RuntimeException
, std::exception
)
2108 maChangeListener
.removeInterface(aListener
);
2114 ::sal_Int64 SAL_CALL
AnimationNode::getSomething( const Sequence
< ::sal_Int8
>& rId
) throw (RuntimeException
, std::exception
)
2116 if( rId
.getLength() == 16 && 0 == memcmp( getUnoTunnelId().getConstArray(), rId
.getConstArray(), 16 ) )
2118 return sal::static_int_cast
< sal_Int64
>(reinterpret_cast< sal_IntPtr
>(this));
2129 class theAnimationNodeUnoTunnelId
: public rtl::Static
< UnoTunnelIdInit
, theAnimationNodeUnoTunnelId
> {};
2132 const ::com::sun::star::uno::Sequence
< sal_Int8
> & AnimationNode::getUnoTunnelId()
2134 return theAnimationNodeUnoTunnelId::get().getSeq();
2139 void AnimationNode::fireChangeListener()
2141 Guard
< Mutex
> aGuard( maMutex
);
2143 OInterfaceIteratorHelper
aIterator( maChangeListener
);
2144 if( aIterator
.hasMoreElements() )
2146 Reference
< XInterface
> xSource( static_cast<OWeakObject
*>(this), UNO_QUERY
);
2147 Sequence
< ElementChange
> aChanges
;
2148 const ChangesEvent
aEvent( xSource
, makeAny( mxParent
.get() ), aChanges
);
2149 while( aIterator
.hasMoreElements() )
2151 Reference
< XChangesListener
> xListener( aIterator
.next(), UNO_QUERY
);
2152 if( xListener
.is() )
2153 xListener
->changesOccurred( aEvent
);
2157 //fdo#69645 use WeakReference of mxParent to test if mpParent is still valid
2160 Reference
<XInterface
> xGuard(mxParent
);
2162 mpParent
->fireChangeListener();
2168 } // namespace animcore
2171 extern "C" SAL_DLLPUBLIC_EXPORT ::com::sun::star::uno::XInterface
* SAL_CALL
2172 com_sun_star_animations_ParallelTimeContainer_get_implementation(::com::sun::star::uno::XComponentContext
*,
2173 ::com::sun::star::uno::Sequence
<css::uno::Any
> const &)
2175 return cppu::acquire(new animcore::AnimationNode(PAR
));
2178 extern "C" SAL_DLLPUBLIC_EXPORT ::com::sun::star::uno::XInterface
* SAL_CALL
2179 com_sun_star_animations_SequenceTimeContainer_get_implementation(::com::sun::star::uno::XComponentContext
*,
2180 ::com::sun::star::uno::Sequence
<css::uno::Any
> const &)
2182 return cppu::acquire(new animcore::AnimationNode(SEQ
));
2185 extern "C" SAL_DLLPUBLIC_EXPORT ::com::sun::star::uno::XInterface
* SAL_CALL
2186 com_sun_star_animations_IterateContainer_get_implementation(::com::sun::star::uno::XComponentContext
*,
2187 ::com::sun::star::uno::Sequence
<css::uno::Any
> const &)
2189 return cppu::acquire(new animcore::AnimationNode(ITERATE
));
2192 extern "C" SAL_DLLPUBLIC_EXPORT ::com::sun::star::uno::XInterface
* SAL_CALL
2193 com_sun_star_animations_Animate_get_implementation(::com::sun::star::uno::XComponentContext
*,
2194 ::com::sun::star::uno::Sequence
<css::uno::Any
> const &)
2196 return cppu::acquire(new animcore::AnimationNode(ANIMATE
));
2199 extern "C" SAL_DLLPUBLIC_EXPORT ::com::sun::star::uno::XInterface
* SAL_CALL
2200 com_sun_star_animations_AnimateSet_get_implementation(::com::sun::star::uno::XComponentContext
*,
2201 ::com::sun::star::uno::Sequence
<css::uno::Any
> const &)
2203 return cppu::acquire(new animcore::AnimationNode(SET
));
2206 extern "C" SAL_DLLPUBLIC_EXPORT ::com::sun::star::uno::XInterface
* SAL_CALL
2207 com_sun_star_animations_AnimateColor_get_implementation(::com::sun::star::uno::XComponentContext
*,
2208 ::com::sun::star::uno::Sequence
<css::uno::Any
> const &)
2210 return cppu::acquire(new animcore::AnimationNode(ANIMATECOLOR
));
2213 extern "C" SAL_DLLPUBLIC_EXPORT ::com::sun::star::uno::XInterface
* SAL_CALL
2214 com_sun_star_animations_AnimateMotion_get_implementation(::com::sun::star::uno::XComponentContext
*,
2215 ::com::sun::star::uno::Sequence
<css::uno::Any
> const &)
2217 return cppu::acquire(new animcore::AnimationNode(ANIMATEMOTION
));
2220 extern "C" SAL_DLLPUBLIC_EXPORT ::com::sun::star::uno::XInterface
* SAL_CALL
2221 com_sun_star_animations_AnimateTransform_get_implementation(::com::sun::star::uno::XComponentContext
*,
2222 ::com::sun::star::uno::Sequence
<css::uno::Any
> const &)
2224 return cppu::acquire(new animcore::AnimationNode(ANIMATETRANSFORM
));
2227 extern "C" SAL_DLLPUBLIC_EXPORT ::com::sun::star::uno::XInterface
* SAL_CALL
2228 com_sun_star_animations_TransitionFilter_get_implementation(::com::sun::star::uno::XComponentContext
*,
2229 ::com::sun::star::uno::Sequence
<css::uno::Any
> const &)
2231 return cppu::acquire(new animcore::AnimationNode(TRANSITIONFILTER
));
2234 extern "C" SAL_DLLPUBLIC_EXPORT ::com::sun::star::uno::XInterface
* SAL_CALL
2235 com_sun_star_animations_Audio_get_implementation(::com::sun::star::uno::XComponentContext
*,
2236 ::com::sun::star::uno::Sequence
<css::uno::Any
> const &)
2238 return cppu::acquire(new animcore::AnimationNode(AUDIO
));
2241 extern "C" SAL_DLLPUBLIC_EXPORT ::com::sun::star::uno::XInterface
* SAL_CALL
2242 com_sun_star_animations_Command_get_implementation(::com::sun::star::uno::XComponentContext
*,
2243 ::com::sun::star::uno::Sequence
<css::uno::Any
> const &)
2245 return cppu::acquire(new animcore::AnimationNode(COMMAND
));
2248 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */