Branch data Line data Source code
1 : : /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2 : : /*************************************************************************
3 : : *
4 : : * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
5 : : *
6 : : * Copyright 2000, 2010 Oracle and/or its affiliates.
7 : : *
8 : : * OpenOffice.org - a multi-platform office productivity suite
9 : : *
10 : : * This file is part of OpenOffice.org.
11 : : *
12 : : * OpenOffice.org is free software: you can redistribute it and/or modify
13 : : * it under the terms of the GNU Lesser General Public License version 3
14 : : * only, as published by the Free Software Foundation.
15 : : *
16 : : * OpenOffice.org is distributed in the hope that it will be useful,
17 : : * but WITHOUT ANY WARRANTY; without even the implied warranty of
18 : : * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
19 : : * GNU Lesser General Public License version 3 for more details
20 : : * (a copy is included in the LICENSE file that accompanied this code).
21 : : *
22 : : * You should have received a copy of the GNU Lesser General Public License
23 : : * version 3 along with OpenOffice.org. If not, see
24 : : * <http://www.openoffice.org/license.html>
25 : : * for a copy of the LGPLv3 License.
26 : : *
27 : : ************************************************************************/
28 : :
29 : : #ifndef _SD_CUSTOMANIMATIONEFFECT_HXX
30 : : #define _SD_CUSTOMANIMATIONEFFECT_HXX
31 : :
32 : : #include <com/sun/star/animations/XAnimationNode.hpp>
33 : : #include <com/sun/star/animations/XTimeContainer.hpp>
34 : : #include <com/sun/star/animations/XAudio.hpp>
35 : : #include <com/sun/star/drawing/XShape.hpp>
36 : : #include <com/sun/star/util/XChangesListener.hpp>
37 : : #include <tools/string.hxx>
38 : :
39 : : #include <boost/shared_ptr.hpp>
40 : :
41 : : #include <comphelper/stl_types.hxx>
42 : : #include <vcl/timer.hxx>
43 : :
44 : : #include <sddllapi.h>
45 : :
46 : : #include <list>
47 : : #include <map>
48 : :
49 : : class SdrPathObj;
50 : :
51 : : namespace sd {
52 : :
53 : : // --------------------------------------------------------------------
54 : :
55 : : enum EValue { VALUE_FROM, VALUE_TO, VALUE_BY, VALUE_FIRST, VALUE_LAST };
56 : :
57 : : class CustomAnimationEffect;
58 : :
59 : : class CustomAnimationPreset;
60 : : typedef boost::shared_ptr< CustomAnimationPreset > CustomAnimationPresetPtr;
61 : :
62 : : typedef boost::shared_ptr< CustomAnimationEffect > CustomAnimationEffectPtr;
63 : :
64 : : typedef std::list< CustomAnimationEffectPtr > EffectSequence;
65 : :
66 : : class EffectSequenceHelper;
67 : :
68 : : class CustomAnimationEffect
69 : : {
70 : : friend class MainSequence;
71 : : friend class EffectSequenceHelper;
72 : :
73 : : public:
74 : : SD_DLLPUBLIC CustomAnimationEffect( const ::com::sun::star::uno::Reference< ::com::sun::star::animations::XAnimationNode >& xNode );
75 : : SD_DLLPUBLIC virtual ~CustomAnimationEffect();
76 : :
77 : 0 : const ::com::sun::star::uno::Reference< ::com::sun::star::animations::XAnimationNode >& getNode() const { return mxNode; }
78 : : void setNode( const ::com::sun::star::uno::Reference< ::com::sun::star::animations::XAnimationNode >& xNode );
79 : : void replaceNode( const ::com::sun::star::uno::Reference< ::com::sun::star::animations::XAnimationNode >& xNode );
80 : :
81 : : CustomAnimationEffectPtr clone() const;
82 : :
83 : : // attributes
84 : 0 : const rtl::OUString& getPresetId() const { return maPresetId; }
85 : 0 : const rtl::OUString& getPresetSubType() const { return maPresetSubType; }
86 : 0 : const rtl::OUString& getProperty() const { return maProperty; }
87 : :
88 : 0 : sal_Int16 getPresetClass() const { return mnPresetClass; }
89 : : void setPresetClass( sal_Int16 nPresetClass );
90 : :
91 : 0 : sal_Int16 getNodeType() const { return mnNodeType; }
92 : : SD_DLLPUBLIC void setNodeType( sal_Int16 nNodeType );
93 : :
94 : : ::com::sun::star::uno::Any getRepeatCount() const;
95 : : void setRepeatCount( const ::com::sun::star::uno::Any& rRepeatCount );
96 : :
97 : : ::com::sun::star::uno::Any getEnd() const;
98 : : void setEnd( const ::com::sun::star::uno::Any& rEnd );
99 : :
100 : : sal_Int16 getFill() const;
101 : : void setFill( sal_Int16 nFill );
102 : :
103 : 0 : double getBegin() const { return mfBegin; }
104 : : SD_DLLPUBLIC void setBegin( double fBegin );
105 : :
106 : 0 : double getDuration() const { return mfDuration; }
107 : : SD_DLLPUBLIC void setDuration( double fDuration );
108 : :
109 : 0 : double getAbsoluteDuration() const { return mfAbsoluteDuration; }
110 : :
111 : : const String& getName() const { return maName; }
112 : : void setName( const String& rName ) { maName = rName; }
113 : :
114 : 0 : sal_Int16 getIterateType() const { return mnIterateType; }
115 : : SD_DLLPUBLIC void setIterateType( sal_Int16 nIterateType );
116 : :
117 : 0 : double getIterateInterval() const { return mfIterateInterval; }
118 : : SD_DLLPUBLIC void setIterateInterval( double fIterateInterval );
119 : :
120 : 0 : ::com::sun::star::uno::Any getTarget() const { return maTarget; }
121 : : SD_DLLPUBLIC void setTarget( const ::com::sun::star::uno::Any& rTarget );
122 : :
123 : 0 : sal_Bool hasAfterEffect() const { return mbHasAfterEffect; }
124 : 0 : void setHasAfterEffect( sal_Bool bHasAfterEffect ) { mbHasAfterEffect = bHasAfterEffect; }
125 : :
126 : 0 : ::com::sun::star::uno::Any getDimColor() const { return maDimColor; }
127 : 0 : void setDimColor( ::com::sun::star::uno::Any aDimColor ) { maDimColor = aDimColor; }
128 : :
129 : 0 : bool IsAfterEffectOnNext() const { return mbAfterEffectOnNextEffect; }
130 : 0 : void setAfterEffectOnNext( bool bOnNextEffect ) { mbAfterEffectOnNextEffect = bOnNextEffect; }
131 : :
132 : 0 : sal_Int32 getParaDepth() const { return mnParaDepth; }
133 : :
134 : 0 : sal_Bool hasText() const { return mbHasText; }
135 : :
136 : 0 : sal_Int16 getCommand() const { return mnCommand; }
137 : :
138 : 0 : double getAcceleration() const { return mfAcceleration; }
139 : : void setAcceleration( double fAcceleration );
140 : :
141 : 0 : double getDecelerate() const { return mfDecelerate; }
142 : : void setDecelerate( double fDecelerate );
143 : :
144 : 0 : sal_Bool getAutoReverse() const { return mbAutoReverse; }
145 : : void setAutoReverse( sal_Bool bAutoReverse );
146 : :
147 : : ::com::sun::star::uno::Any getProperty( sal_Int32 nNodeType, const rtl::OUString& rAttributeName, EValue eValue );
148 : : bool setProperty( sal_Int32 nNodeType, const rtl::OUString& rAttributeName, EValue eValue, const ::com::sun::star::uno::Any& rValue );
149 : :
150 : : ::com::sun::star::uno::Any getTransformationProperty( sal_Int32 nTransformType, EValue eValue );
151 : : bool setTransformationProperty( sal_Int32 nTransformType, EValue eValue, const ::com::sun::star::uno::Any& rValue );
152 : :
153 : : ::com::sun::star::uno::Any getColor( sal_Int32 nIndex );
154 : : void setColor( sal_Int32 nIndex, const ::com::sun::star::uno::Any& rColor );
155 : :
156 : : ::com::sun::star::uno::Any getRotation();
157 : : void setRotation( const ::com::sun::star::uno::Any& rRotation );
158 : :
159 : 0 : sal_Int32 getGroupId() const { return mnGroupId; }
160 : : void setGroupId( sal_Int32 nGroupId );
161 : :
162 : 0 : sal_Int16 getTargetSubItem() const { return mnTargetSubItem; }
163 : : SD_DLLPUBLIC void setTargetSubItem( sal_Int16 nSubItem );
164 : :
165 : : ::rtl::OUString getPath() const;
166 : : void setPath( const ::rtl::OUString& rPath );
167 : :
168 : : bool checkForText();
169 : : bool calculateIterateDuration();
170 : :
171 : : void setAudio( const ::com::sun::star::uno::Reference< ::com::sun::star::animations::XAudio >& xAudio );
172 : : bool getStopAudio() const;
173 : : SD_DLLPUBLIC void setStopAudio();
174 : : SD_DLLPUBLIC void createAudio( const ::com::sun::star::uno::Any& rSource, double fVolume = 1.0 );
175 : : void removeAudio();
176 : 0 : const ::com::sun::star::uno::Reference< ::com::sun::star::animations::XAudio >& getAudio() const { return mxAudio; }
177 : :
178 : 0 : EffectSequenceHelper* getEffectSequence() const { return mpEffectSequence; }
179 : :
180 : : // helper
181 : : ::com::sun::star::uno::Reference< ::com::sun::star::animations::XAnimationNode > createAfterEffectNode() const throw (com::sun::star::uno::Exception);
182 : : ::com::sun::star::uno::Reference< ::com::sun::star::drawing::XShape > getTargetShape() const;
183 : :
184 : : // static helpers
185 : : static sal_Int32 get_node_type( const ::com::sun::star::uno::Reference< ::com::sun::star::animations::XAnimationNode >& xNode );
186 : : static sal_Int32 getNumberOfSubitems( const ::com::sun::star::uno::Any& aTarget, sal_Int16 nIterateType );
187 : :
188 : : SdrPathObj* createSdrPathObjFromPath();
189 : : void updateSdrPathObjFromPath( SdrPathObj& rPathObj );
190 : : void updatePathFromSdrPathObj( const SdrPathObj& rPathObj );
191 : :
192 : : protected:
193 : 0 : void setEffectSequence( EffectSequenceHelper* pSequence ) { mpEffectSequence = pSequence; }
194 : :
195 : : private:
196 : : sal_Int16 mnNodeType;
197 : : rtl::OUString maPresetId;
198 : : rtl::OUString maPresetSubType;
199 : : rtl::OUString maProperty;
200 : : sal_Int16 mnPresetClass;
201 : : double mfBegin;
202 : : double mfDuration; // this is the maximum duration of the subeffects
203 : : double mfAbsoluteDuration; // this is the maximum duration of the subeffects including possible iterations
204 : : sal_Int32 mnGroupId;
205 : : sal_Int16 mnIterateType;
206 : : double mfIterateInterval;
207 : : sal_Int32 mnParaDepth;
208 : : sal_Bool mbHasText;
209 : : double mfAcceleration;
210 : : double mfDecelerate;
211 : : sal_Bool mbAutoReverse;
212 : : sal_Int16 mnTargetSubItem;
213 : : sal_Int16 mnCommand;
214 : :
215 : : EffectSequenceHelper* mpEffectSequence;
216 : :
217 : : String maName;
218 : :
219 : : ::com::sun::star::uno::Reference< ::com::sun::star::animations::XAnimationNode > mxNode;
220 : : ::com::sun::star::uno::Reference< ::com::sun::star::animations::XAudio > mxAudio;
221 : : ::com::sun::star::uno::Any maTarget;
222 : :
223 : : sal_Bool mbHasAfterEffect;
224 : : ::com::sun::star::uno::Any maDimColor;
225 : : bool mbAfterEffectOnNextEffect;
226 : : };
227 : :
228 : : struct stl_CustomAnimationEffect_search_node_predict
229 : : {
230 : : stl_CustomAnimationEffect_search_node_predict( const ::com::sun::star::uno::Reference< ::com::sun::star::animations::XAnimationNode >& xSearchNode );
231 : : bool operator()( CustomAnimationEffectPtr pEffect ) const;
232 : : const ::com::sun::star::uno::Reference< ::com::sun::star::animations::XAnimationNode >& mxSearchNode;
233 : : };
234 : :
235 : : enum ESequenceHint { EFFECT_EDITED, EFFECT_REMOVED, EFFECT_ADDED };
236 : :
237 : : /** this listener is implemented by UI components to track changes in the animation core */
238 : 4 : class ISequenceListener
239 : : {
240 : : public:
241 : : virtual void notify_change() = 0;
242 : :
243 : : protected:
244 : 4 : ~ISequenceListener() {}
245 : : };
246 : :
247 : : /** this class keeps track of a group of animations that build up
248 : : a text animation for a single shape */
249 : 0 : class CustomAnimationTextGroup
250 : : {
251 : : friend class EffectSequenceHelper;
252 : :
253 : : public:
254 : : CustomAnimationTextGroup( const ::com::sun::star::uno::Reference< com::sun::star::drawing::XShape >& rTarget, sal_Int32 nGroupId );
255 : :
256 : : void reset();
257 : : void addEffect( CustomAnimationEffectPtr& pEffect );
258 : :
259 : : const ::com::sun::star::uno::Reference< com::sun::star::drawing::XShape >& getTarget() const { return maTarget; }
260 : 0 : const EffectSequence& getEffects() const { return maEffects; }
261 : :
262 : : /* -1: as single object, 0: all at once, n > 0: by n Th paragraph */
263 : 0 : sal_Int32 getTextGrouping() const { return mnTextGrouping; }
264 : :
265 : 0 : sal_Bool getAnimateForm() const { return mbAnimateForm; }
266 : 0 : sal_Bool getTextReverse() const { return mbTextReverse; }
267 : 0 : double getTextGroupingAuto() const { return mfGroupingAuto; }
268 : :
269 : : private:
270 : : EffectSequence maEffects;
271 : : ::com::sun::star::uno::Reference< com::sun::star::drawing::XShape > maTarget;
272 : :
273 : : enum { PARA_LEVELS = 5 };
274 : :
275 : : sal_Int32 mnTextGrouping;
276 : : sal_Bool mbAnimateForm;
277 : : sal_Bool mbTextReverse;
278 : : double mfGroupingAuto;
279 : : sal_Int32 mnLastPara;
280 : : sal_Int8 mnDepthFlags[PARA_LEVELS];
281 : : sal_Int32 mnGroupId;
282 : : };
283 : :
284 : : typedef boost::shared_ptr< CustomAnimationTextGroup > CustomAnimationTextGroupPtr;
285 : : typedef std::map< sal_Int32, CustomAnimationTextGroupPtr > CustomAnimationTextGroupMap;
286 : :
287 : : class EffectSequenceHelper
288 : : {
289 : : friend class MainSequence;
290 : :
291 : : public:
292 : : EffectSequenceHelper();
293 : : EffectSequenceHelper( const ::com::sun::star::uno::Reference< ::com::sun::star::animations::XTimeContainer >& xSequenceRoot );
294 : : virtual ~EffectSequenceHelper();
295 : :
296 : : virtual ::com::sun::star::uno::Reference< ::com::sun::star::animations::XAnimationNode > getRootNode();
297 : :
298 : : CustomAnimationEffectPtr append( const CustomAnimationPresetPtr& pDescriptor, const ::com::sun::star::uno::Any& rTarget, double fDuration = -1.0 );
299 : : CustomAnimationEffectPtr append( const SdrPathObj& rPathObj, const ::com::sun::star::uno::Any& rTarget, double fDuration = -1.0 );
300 : : SD_DLLPUBLIC void append( const CustomAnimationEffectPtr& pEffect );
301 : : void insert( EffectSequence::iterator& rPos, const CustomAnimationEffectPtr& pEffect );
302 : : void replace( const CustomAnimationEffectPtr& pEffect, const CustomAnimationPresetPtr& pDescriptor, double fDuration = -1.0 );
303 : : void replace( const CustomAnimationEffectPtr& pEffect, const CustomAnimationPresetPtr& pDescriptor, const rtl::OUString& rPresetSubType, double fDuration = -1.0 );
304 : : void remove( const CustomAnimationEffectPtr& pEffect );
305 : :
306 : : void create( const ::com::sun::star::uno::Reference< ::com::sun::star::animations::XAnimationNode >& xNode );
307 : : void createEffectsequence( const ::com::sun::star::uno::Reference< ::com::sun::star::animations::XAnimationNode >& xNode );
308 : : void processAfterEffect( const ::com::sun::star::uno::Reference< ::com::sun::star::animations::XAnimationNode >& xNode );
309 : : void createEffects( const ::com::sun::star::uno::Reference< ::com::sun::star::animations::XAnimationNode >& xNode );
310 : :
311 : 0 : sal_Int32 getCount() const { return sal::static_int_cast< sal_Int32 >( maEffects.size() ); }
312 : :
313 : : virtual CustomAnimationEffectPtr findEffect( const ::com::sun::star::uno::Reference< ::com::sun::star::animations::XAnimationNode >& xNode ) const;
314 : :
315 : : virtual bool disposeShape( const com::sun::star::uno::Reference< com::sun::star::drawing::XShape >& xShape );
316 : : virtual void insertTextRange( const com::sun::star::uno::Any& aTarget );
317 : : virtual void disposeTextRange( const com::sun::star::uno::Any& aTarget );
318 : : virtual bool hasEffect( const com::sun::star::uno::Reference< com::sun::star::drawing::XShape >& xShape );
319 : : virtual void onTextChanged( const com::sun::star::uno::Reference< com::sun::star::drawing::XShape >& xShape );
320 : :
321 : : /** this must be called if effects from this sequence are changed.
322 : : the method will call the registered listeners */
323 : : void update( const CustomAnimationEffectPtr& pEffect );
324 : :
325 : : /** this method rebuilds the animation nodes */
326 : : virtual void rebuild();
327 : :
328 : 32 : EffectSequence::iterator getBegin() { return maEffects.begin(); }
329 : 36 : EffectSequence::iterator getEnd() { return maEffects.end(); }
330 : : EffectSequence::iterator find( const CustomAnimationEffectPtr& pEffect );
331 : :
332 : 4 : EffectSequence& getSequence() { return maEffects; }
333 : :
334 : : void addListener( ISequenceListener* pListener );
335 : : void removeListener( ISequenceListener* pListener );
336 : :
337 : : // text group methods
338 : :
339 : : CustomAnimationTextGroupPtr findGroup( sal_Int32 nGroupId );
340 : : SD_DLLPUBLIC CustomAnimationTextGroupPtr createTextGroup( CustomAnimationEffectPtr pEffect, sal_Int32 nTextGrouping, double fTextGroupingAuto, sal_Bool bAnimateForm, sal_Bool bTextReverse );
341 : : void setTextGrouping( CustomAnimationTextGroupPtr pTextGroup, sal_Int32 nTextGrouping );
342 : : void setAnimateForm( CustomAnimationTextGroupPtr pTextGroup, sal_Bool bAnimateForm );
343 : : void setTextGroupingAuto( CustomAnimationTextGroupPtr pTextGroup, double fTextGroupingAuto );
344 : : void setTextReverse( CustomAnimationTextGroupPtr pTextGroup, sal_Bool bAnimateForm );
345 : :
346 : 0 : sal_Int32 getSequenceType() const { return mnSequenceType; }
347 : :
348 : 0 : ::com::sun::star::uno::Reference< ::com::sun::star::drawing::XShape > getTriggerShape() const { return mxEventSource; }
349 : 0 : void setTriggerShape( const ::com::sun::star::uno::Reference< ::com::sun::star::drawing::XShape >& xTrigger ) { mxEventSource = xTrigger; }
350 : :
351 : : virtual sal_Int32 getOffsetFromEffect( const CustomAnimationEffectPtr& xEffect ) const;
352 : : virtual CustomAnimationEffectPtr getEffectFromOffset( sal_Int32 nOffset ) const;
353 : :
354 : : protected:
355 : : virtual void implRebuild();
356 : : virtual void reset();
357 : :
358 : : void createTextGroupParagraphEffects( CustomAnimationTextGroupPtr pTextGroup, CustomAnimationEffectPtr pEffect, bool bUsed );
359 : :
360 : : void notify_listeners();
361 : :
362 : : ::com::sun::star::uno::Reference< ::com::sun::star::animations::XTimeContainer > createParallelTimeContainer() const;
363 : :
364 : : void updateTextGroups();
365 : :
366 : : protected:
367 : : ::com::sun::star::uno::Reference< ::com::sun::star::animations::XTimeContainer > mxSequenceRoot;
368 : : EffectSequence maEffects;
369 : : std::list< ISequenceListener* > maListeners;
370 : : CustomAnimationTextGroupMap maGroupMap;
371 : : sal_Int32 mnSequenceType;
372 : : ::com::sun::star::uno::Reference< ::com::sun::star::drawing::XShape > mxEventSource;
373 : : };
374 : :
375 : : class MainSequence;
376 : :
377 [ # # ]: 0 : class InteractiveSequence : public EffectSequenceHelper
378 : : {
379 : : friend class MainSequence;
380 : : friend class MainSequenceChangeGuard;
381 : :
382 : : public:
383 : : InteractiveSequence( const ::com::sun::star::uno::Reference< ::com::sun::star::animations::XTimeContainer >& xSequenceRoot, MainSequence* pMainSequence );
384 : :
385 : : /** this method rebuilds the animation nodes */
386 : : virtual void rebuild();
387 : :
388 : : private:
389 : : virtual void implRebuild();
390 : :
391 : : MainSequence* mpMainSequence;
392 : : };
393 : :
394 : : typedef boost::shared_ptr< InteractiveSequence > InteractiveSequencePtr;
395 : : typedef std::list< InteractiveSequencePtr > InteractiveSequenceList;
396 : :
397 : : class MainSequence : public EffectSequenceHelper, public ISequenceListener
398 : : {
399 : : friend class UndoAnimation;
400 : : friend class MainSequenceRebuildGuard;
401 : : friend class MainSequenceChangeGuard;
402 : :
403 : : public:
404 : : MainSequence();
405 : : MainSequence( const ::com::sun::star::uno::Reference< ::com::sun::star::animations::XAnimationNode >& xTimingRootNode );
406 : : ~MainSequence();
407 : :
408 : : virtual ::com::sun::star::uno::Reference< ::com::sun::star::animations::XAnimationNode > getRootNode();
409 : : void reset( const ::com::sun::star::uno::Reference< ::com::sun::star::animations::XAnimationNode >& xTimingRootNode );
410 : :
411 : : /** this method rebuilds the animation nodes */
412 : : virtual void rebuild();
413 : :
414 : : virtual CustomAnimationEffectPtr findEffect( const ::com::sun::star::uno::Reference< ::com::sun::star::animations::XAnimationNode >& xNode ) const;
415 : :
416 : : virtual bool disposeShape( const com::sun::star::uno::Reference< com::sun::star::drawing::XShape >& xShape );
417 : : virtual void insertTextRange( const com::sun::star::uno::Any& aTarget );
418 : : virtual void disposeTextRange( const com::sun::star::uno::Any& aTarget );
419 : : virtual bool hasEffect( const com::sun::star::uno::Reference< com::sun::star::drawing::XShape >& xShape );
420 : : virtual void onTextChanged( const com::sun::star::uno::Reference< com::sun::star::drawing::XShape >& xShape );
421 : :
422 : 0 : const InteractiveSequenceList& getInteractiveSequenceList() const { return maInteractiveSequenceList; }
423 : :
424 : : virtual void notify_change();
425 : :
426 : : bool setTrigger( const CustomAnimationEffectPtr& pEffect, const ::com::sun::star::uno::Reference< ::com::sun::star::drawing::XShape >& xTriggerShape );
427 : :
428 : : /** starts a timer that recreates the internal structure from the API core after 1 second */
429 : : void startRecreateTimer();
430 : :
431 : : /** starts a timer that rebuilds the API core from the internal structure after 1 second */
432 : : void startRebuildTimer();
433 : :
434 : : virtual sal_Int32 getOffsetFromEffect( const CustomAnimationEffectPtr& xEffect ) const;
435 : : virtual CustomAnimationEffectPtr getEffectFromOffset( sal_Int32 nOffset ) const;
436 : :
437 : : protected:
438 : : /** permits rebuilds until unlockRebuilds() is called. All rebuild calls during a locked sequence are
439 : : process after unlockRebuilds() call. lockRebuilds() and unlockRebuilds() calls can be nested. */
440 : : void lockRebuilds();
441 : : void unlockRebuilds();
442 : :
443 : : DECL_LINK(onTimerHdl, void *);
444 : :
445 : : virtual void implRebuild();
446 : :
447 : : void init();
448 : :
449 : : void createMainSequence();
450 : : virtual void reset();
451 : :
452 : : InteractiveSequencePtr createInteractiveSequence( const ::com::sun::star::uno::Reference< ::com::sun::star::drawing::XShape >& xShape );
453 : :
454 : : InteractiveSequenceList maInteractiveSequenceList;
455 : :
456 : : ::com::sun::star::uno::Reference< ::com::sun::star::util::XChangesListener > mxChangesListener;
457 : : ::com::sun::star::uno::Reference< ::com::sun::star::animations::XTimeContainer > mxTimingRootNode;
458 : : Timer maTimer;
459 : : bool mbTimerMode;
460 : : bool mbRebuilding;
461 : :
462 : : long mnRebuildLockGuard;
463 : : bool mbPendingRebuildRequest;
464 : : sal_Int32 mbIgnoreChanges;
465 : : };
466 : :
467 : : typedef boost::shared_ptr< MainSequence > MainSequencePtr;
468 : :
469 : : class MainSequenceRebuildGuard
470 : : {
471 : : public:
472 : : MainSequenceRebuildGuard( const MainSequencePtr& pMainSequence );
473 : : ~MainSequenceRebuildGuard();
474 : :
475 : : private:
476 : : MainSequencePtr mpMainSequence;
477 : : };
478 : :
479 : : }
480 : :
481 : : #endif // _SD_CUSTOMANIMATIONEFFECT_HXX
482 : :
483 : : /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
|