summaryrefslogtreecommitdiff
path: root/oox/source/ppt/timenode.cxx
blob: e8732e8858a6b2c437f6469abfd331bacfbf8311 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*
 * This file is part of the LibreOffice project.
 *
 * This Source Code Form is subject to the terms of the Mozilla Public
 * License, v. 2.0. If a copy of the MPL was not distributed with this
 * file, You can obtain one at http://mozilla.org/MPL/2.0/.
 *
 * This file incorporates work covered by the following license notice:
 *
 *   Licensed to the Apache Software Foundation (ASF) under one or more
 *   contributor license agreements. See the NOTICE file distributed
 *   with this work for additional information regarding copyright
 *   ownership. The ASF licenses this file to you under the Apache
 *   License, Version 2.0 (the "License"); you may not use this file
 *   except in compliance with the License. You may obtain a copy of
 *   the License at http://www.apache.org/licenses/LICENSE-2.0 .
 */

#include <oox/ppt/timenode.hxx>

#include <com/sun/star/beans/NamedValue.hpp>
#include <com/sun/star/container/XEnumerationAccess.hpp>
#include <com/sun/star/lang/XMultiServiceFactory.hpp>
#include <com/sun/star/animations/XAnimateColor.hpp>
#include <com/sun/star/animations/XAnimateMotion.hpp>
#include <com/sun/star/animations/XAnimateTransform.hpp>
#include <com/sun/star/animations/XCommand.hpp>
#include <com/sun/star/animations/XAudio.hpp>
#include <com/sun/star/animations/XIterateContainer.hpp>
#include <com/sun/star/animations/XTimeContainer.hpp>
#include <com/sun/star/animations/XTransitionFilter.hpp>
#include <com/sun/star/animations/AnimationNodeType.hpp>
#include <com/sun/star/animations/Event.hpp>
#include <com/sun/star/animations/EventTrigger.hpp>
#include <com/sun/star/io/WrongFormatException.hpp>
#include <com/sun/star/presentation/EffectNodeType.hpp>
#include <com/sun/star/uno/XComponentContext.hpp>

#include <oox/core/xmlfilterbase.hxx>
#include <oox/ppt/pptfilterhelpers.hxx>
#include <oox/token/tokens.hxx>
#include <sal/log.hxx>
#include <comphelper/diagnose_ex.hxx>

using namespace ::oox::core;
using namespace ::com::sun::star::beans;
using namespace ::com::sun::star::container;
using namespace ::com::sun::star::uno;
using namespace ::com::sun::star::lang;
using namespace ::com::sun::star::animations;
using namespace ::com::sun::star::presentation;

namespace {

void lcl_setAncestorSubItem( const Reference<XAnimationNode>& xParent, sal_Int16 nSubItem )
{

    Reference<XAnimationNode> xNode = xParent;

    while ( xNode.is() )
    {
        if ( xNode->getType() == AnimationNodeType::ANIMATE )
        {
            Reference<XAnimate> xAnimate( xNode, UNO_QUERY );
            if ( xAnimate.is() )
                xAnimate->setSubItem( nSubItem );
            break;
        }
        else if ( xNode->getType() == AnimationNodeType::ITERATE )
        {
            Reference<XIterateContainer> xIterateContainer( xNode, UNO_QUERY );
            if ( xIterateContainer.is() )
                xIterateContainer->setSubItem( nSubItem );
            break;
        }

        xNode.set( xNode->getParent(), UNO_QUERY );
    }
}

}

namespace oox::ppt {
        OUString TimeNode::getServiceName( sal_Int16 nNodeType )
        {
            OUString sServiceName;
            switch( nNodeType )
            {
            case AnimationNodeType::PAR:
                sServiceName = "com.sun.star.animations.ParallelTimeContainer";
                break;
            case AnimationNodeType::SEQ:
                sServiceName = "com.sun.star.animations.SequenceTimeContainer";
                break;
            case AnimationNodeType::ANIMATE:
                sServiceName = "com.sun.star.animations.Animate";
                break;
            case AnimationNodeType::ITERATE:
                sServiceName = "com.sun.star.animations.IterateContainer";
                break;
            case AnimationNodeType::ANIMATECOLOR:
                sServiceName = "com.sun.star.animations.AnimateColor";
                break;
            case AnimationNodeType::TRANSITIONFILTER:
                sServiceName = "com.sun.star.animations.TransitionFilter";
                break;
            case AnimationNodeType::ANIMATEMOTION:
                sServiceName = "com.sun.star.animations.AnimateMotion";
                break;
            case AnimationNodeType::ANIMATETRANSFORM:
                sServiceName = "com.sun.star.animations.AnimateTransform";
                break;
            case AnimationNodeType::COMMAND:
                sServiceName = "com.sun.star.animations.Command";
                break;
            case AnimationNodeType::SET:
                sServiceName = "com.sun.star.animations.AnimateSet";
                break;
            case AnimationNodeType::AUDIO:
                sServiceName = "com.sun.star.animations.Audio";
                break;
            default:
                SAL_INFO("oox.ppt","OOX: unhandled type " << nNodeType );
                break;
            }
            return sServiceName;
        }

    TimeNode::TimeNode( sal_Int16 nNodeType )
        : mnNodeType( nNodeType )
        , mbHasEndSyncValue( false )
    {
    }

    TimeNode::~TimeNode()
    {
    }

    void fixMainSequenceTiming( const css::uno::Reference< css::animations::XAnimationNode >& xNode )
    {
        try
        {
            bool bFirst = true;
            Reference< XEnumerationAccess > xEA( xNode, UNO_QUERY_THROW );
            Reference< XEnumeration > xE( xEA->createEnumeration(), UNO_SET_THROW );
            while( xE->hasMoreElements() )
            {
                // click node
                Reference< XAnimationNode > xClickNode( xE->nextElement(), UNO_QUERY );

                Event aEvent;
                aEvent.Trigger = EventTrigger::ON_NEXT;
                aEvent.Repeat = 0;
                xClickNode->setBegin( Any( aEvent ) );

                if( bFirst )
                {
                    bFirst = false;
                    Reference< XEnumerationAccess > xEA2( xClickNode, UNO_QUERY_THROW );
                    Reference< XEnumeration > xE2( xEA2->createEnumeration(), UNO_SET_THROW );
                    if( xE2->hasMoreElements() )
                    {
                        // with node
                        xE2->nextElement() >>= xEA2;
                        if( xEA2.is() )
                            xE2 = xEA2->createEnumeration();
                        else
                            xE2.clear();

                        if( xE2.is() && xE2->hasMoreElements() )
                        {
                            Reference< XAnimationNode > xEffectNode( xE2->nextElement(), UNO_QUERY_THROW );
                            const Sequence< NamedValue > aUserData( xEffectNode->getUserData() );
                            for( const NamedValue& rProp : aUserData )
                            {
                                if ( rProp.Name == "node-type" )
                                {
                                    sal_Int16 nNodeType = 0;
                                    rProp.Value >>= nNodeType;
                                    if( nNodeType != css::presentation::EffectNodeType::ON_CLICK )
                                    {
                                        // first effect does not start on click, so correct
                                        // first click nodes begin to 0s
                                        xClickNode->setBegin( Any( 0.0 ) );
                                        break;
                                    }
                                }
                            }
                        }
                    }
                }
            }
        }
        catch( Exception& )
        {
            SAL_INFO("oox.ppt","fixMainSequenceTiming(), exception caught!" );
        }
    }

    void fixInteractiveSequenceTiming( const css::uno::Reference< css::animations::XAnimationNode >& xNode )
    {
        try
        {
            Any aBegin( xNode->getBegin() );
            Any aEmpty;
            xNode->setBegin( aEmpty );

            Reference< XEnumerationAccess > xEA( xNode, UNO_QUERY_THROW );
            Reference< XEnumeration > xE( xEA->createEnumeration(), UNO_SET_THROW );
            while( xE->hasMoreElements() )
            {
                // click node
                Reference< XAnimationNode > xClickNode( xE->nextElement(), UNO_QUERY );
                xClickNode->setBegin( aBegin );
            }
        }
        catch( Exception& )
        {
            SAL_INFO("oox.ppt","fixInteractiveSequenceTiming(), exception caught!" );
        }
    }

    void TimeNode::addNode( const XmlFilterBase& rFilter, const Reference< XAnimationNode >& rxNode, const SlidePersistPtr & pSlide )
    {
        try {
            sal_Int16 nNodeType = mnNodeType;

            if (mnNodeType == AnimationNodeType::PAR && maNodeProperties[NP_ITERATETYPE].hasValue())
                nNodeType = AnimationNodeType::ITERATE;

            OUString sServiceName = getServiceName(nNodeType);

            Reference< XAnimationNode > xNode = createAndInsert( rFilter, sServiceName, rxNode );
            if (!xNode)
                return;
            setNode(rFilter, xNode, pSlide, rxNode);
        }
        catch( const Exception& )
        {
            TOOLS_INFO_EXCEPTION("oox.ppt","OOX: exception raised in TimeNode::addNode()" );
        }
    }

    void TimeNode::setNode(const XmlFilterBase& rFilter, const Reference< XAnimationNode >& xNode, const SlidePersistPtr & pSlide, const Reference<XAnimationNode>& xParent)
    {
        SAL_WARN_IF( !xNode.is(), "oox.ppt", "null node passed" );

        try {
            if( !msId.isEmpty() )
            {
                pSlide->getAnimNodesMap()[ msId ] = xNode;
            }

            if( mpTarget )
            {
                sal_Int16 nSubItem(0);
                maNodeProperties[ NP_TARGET ] = mpTarget->convert( pSlide, nSubItem );
                if( mpTarget->mnType == XML_spTgt )
                {
                    if ( xNode->getType() == AnimationNodeType::ANIMATE ||
                            xNode->getType() == AnimationNodeType::ITERATE )
                    {
                        maNodeProperties[ NP_SUBITEM ] <<= nSubItem;
                    }
                    else
                        lcl_setAncestorSubItem( xParent, nSubItem );
                }
            }

            if( !maStCondList.empty() )
            {
                Any aAny = AnimationCondition::convertList( pSlide, maStCondList );
                if( aAny.hasValue() )
                {
                    xNode->setBegin( aAny );
                }

            }
            if( !maEndCondList.empty() )
            {
                Any aAny = AnimationCondition::convertList( pSlide, maEndCondList );
                if( aAny.hasValue() )
                {
                    xNode->setEnd( aAny );
                }
            }
            if( mbHasEndSyncValue )
            {
                Any aValue = maEndSyncValue.convert( pSlide );
                xNode->setEndSync(aValue);
            }

            if( !maUserData.empty() )
            {
                Sequence< NamedValue > aUserDataSeq( static_cast< sal_Int32 >( maUserData.size() ) );
                NamedValue* pValues = aUserDataSeq.getArray();
                for (auto const& elem : maUserData)
                {
                    pValues->Name = elem.first;
                    pValues->Value = elem.second;
                    ++pValues;
                }
                maNodeProperties[ NP_USERDATA ] <<= aUserDataSeq;
            }

            Reference< XAnimate > xAnimate( xNode, UNO_QUERY );
            Reference< XAnimateColor > xAnimateColor( xNode, UNO_QUERY );
            Reference< XAnimateMotion > xAnimateMotion( xNode, UNO_QUERY );
            Reference< XAnimateTransform > xAnimateTransform( xNode, UNO_QUERY );
            Reference< XCommand > xCommand( xNode, UNO_QUERY );
            Reference< XAudio > xAudio( xNode, UNO_QUERY );
            Reference< XIterateContainer > xIterateContainer( xNode, UNO_QUERY );
            sal_Int16 nInt16 = 0;
            bool bBool = false;
            double fDouble = 0;
            OUString sString;
            Sequence< NamedValue > aSeq;

            for( int i = 0; i < NP_SIZE_; i++)
            {
                Any & aValue( maNodeProperties[ i ] );
                if( aValue.hasValue() )
                {
                    switch( i )
                    {
                    case NP_TO:
                        if( xAnimate.is() )
                            xAnimate->setTo( aValue );
                        break;
                    case NP_FROM:
                        if( xAnimate.is() )
                            xAnimate->setFrom( aValue );
                        break;
                    case NP_BY:
                        if( xAnimate.is() )
                            xAnimate->setBy( aValue );
                        break;
                    case NP_HIDEDURINGSHOW:
                        if (xAudio.is() && (aValue >>= bBool))
                        {
                            xAudio->setHideDuringShow(bBool);
                        }
                        break;
                    case NP_ISNARRATION:
                        if (xAudio.is() && (aValue >>= bBool))
                        {
                            xAudio->setNarration(bBool);
                        }
                        break;
                    case NP_TARGET:

                        if (xParent.is() && xParent->getType() == AnimationNodeType::ITERATE)
                        {
                            Reference<XIterateContainer> xParentContainer(xParent, UNO_QUERY);
                            if (xParentContainer.is())
                                xParentContainer->setTarget(aValue);
                        }
                        else
                        {
                            if (xAnimate.is())
                                xAnimate->setTarget(aValue);
                            if (xCommand.is())
                                xCommand->setTarget(aValue);
                            if (xAudio.is())
                                xAudio->setSource(aValue);
                        }
                        break;
                    case NP_SUBITEM:
                        if( aValue >>= nInt16 )
                        {
                            if( xAnimate.is() )
                            {
                                xAnimate->setSubItem( nInt16 );
                            }
                            else if ( xIterateContainer.is() )
                            {
                                xIterateContainer->setSubItem( nInt16 );
                            }
                        }
                        else
                        {
                            SAL_INFO("oox.ppt","any >>= failed " << __LINE__ );
                        }
                        break;
                    case NP_ATTRIBUTENAME:
                        if( xAnimate.is() )
                        {
                            if( aValue >>= sString )
                                xAnimate->setAttributeName( sString );
                            else
                            {
                                SAL_INFO("oox.ppt","any >>= failed " << __LINE__ );
                            }
                        }
                        break;
                    case NP_CALCMODE:
                        if( xAnimate.is() )
                        {
                            if( aValue >>= nInt16 )
                                xAnimate->setCalcMode( nInt16 );
                            else
                            {
                                SAL_INFO("oox.ppt","any >>= failed " << __LINE__ );
                            }
                        }
                        break;
                    case NP_KEYTIMES:
                        if( xAnimate.is() )
                        {
                            Sequence<double> aKeyTimes;
                            if( aValue >>= aKeyTimes )
                                xAnimate->setKeyTimes(aKeyTimes);
                            else
                            {
                                SAL_INFO("oox.ppt","any >>= failed " << __LINE__ );
                            }
                        }
                        break;
                    case NP_VALUES:
                        if( xAnimate.is() )
                        {
                            Sequence<Any> aValues;
                            if( aValue >>= aValues )
                                xAnimate->setValues(aValues);
                            else
                            {
                                SAL_INFO("oox.ppt","any >>= failed " << __LINE__ );
                            }
                        }
                        break;
                    case NP_FORMULA:
                        if( xAnimate.is() )
                        {
                            if( aValue >>= sString )
                                xAnimate->setFormula(sString);
                            else
                            {
                                SAL_INFO("oox.ppt","any >>= failed " << __LINE__ );
                            }
                        }
                        break;
                    case NP_COLORINTERPOLATION:
                        if( xAnimateColor.is() )
                        {
                            if( aValue >>= nInt16 )
                                xAnimateColor->setColorInterpolation( nInt16 );
                            else
                            {
                                SAL_INFO("oox.ppt","any >>= failed " << __LINE__ );
                            }
                        }
                        break;
                    case NP_DIRECTION:
                        if( xAnimateColor.is() )
                        {
                            if( aValue >>= bBool )
                                xAnimateColor->setDirection( bBool );
                            else
                            {
                                SAL_INFO("oox.ppt","any >>= failed " << __LINE__ );
                            }
                        }
                        break;
                    case NP_PATH:
                        if( xAnimateMotion.is() )
                            xAnimateMotion->setPath( aValue );
                        break;
                    case NP_TRANSFORMTYPE:
                        if( xAnimateTransform.is() )
                        {
                            if( aValue >>= nInt16 )
                                xAnimateTransform->setTransformType( nInt16 );
                            else
                            {
                                SAL_INFO("oox.ppt","any >>= failed " << __LINE__ );
                            }
                        }
                        break;
                    case NP_USERDATA:
                        if( aValue >>= aSeq )
                            xNode->setUserData( aSeq );
                        else
                        {
                            SAL_INFO("oox.ppt","any >>= failed " << __LINE__ );
                        }
                        break;
                    case NP_ACCELERATION:
                        if( aValue >>= fDouble )
                            xNode->setAcceleration( fDouble );
                        else
                        {
                            SAL_INFO("oox.ppt","any >>= failed " << __LINE__ );
                        }
                        break;
                    case NP_DECELERATE:
                        if( aValue >>= fDouble )
                            xNode->setDecelerate( fDouble );
                        else
                        {
                            SAL_INFO("oox.ppt","any >>= failed " << __LINE__ );
                        }
                        break;
                    case NP_AUTOREVERSE:
                        if( aValue >>= bBool )
                            xNode->setAutoReverse( bBool );
                        else
                        {
                            SAL_INFO("oox.ppt","any >>= failed " << __LINE__ );
                        }
                        break;
                    case NP_DURATION:
                        xNode->setDuration( aValue );
                        break;
                    case NP_FILL:
                        if( aValue >>= nInt16 )
                            xNode->setFill( nInt16 );
                        else
                        {
                            SAL_INFO("oox.ppt","any >>= failed " << __LINE__ );
                        }
                        break;
                    case NP_REPEATCOUNT:
                        xNode->setRepeatCount( aValue );
                        break;
                    case NP_REPEATDURATION:
                        xNode->setRepeatDuration( aValue );
                        break;
                    case NP_RESTART:
                        if( aValue >>= nInt16 )
                            xNode->setRestart( nInt16 );
                        else
                        {
                            SAL_INFO("oox.ppt","any >>= failed " << __LINE__ );
                        }
                        break;
                    case NP_COMMAND:
                        if( xCommand.is() )
                        {
                            if( aValue >>= nInt16 )
                                xCommand->setCommand( nInt16 );
                            else
                            {
                                SAL_INFO("oox.ppt","any >>= failed " << __LINE__ );
                            }
                        }
                        break;
                    case NP_PARAMETER:
                        if( xCommand.is() )
                            xCommand->setParameter( aValue );
                        break;
                    case NP_ITERATETYPE:
                        if( xIterateContainer.is() )
                        {
                            if( aValue >>= nInt16 )
                                xIterateContainer->setIterateType( nInt16 );
                            else
                            {
                                SAL_INFO("oox.ppt","any >>= failed " << __LINE__ );
                            }
                        }
                        break;
                    case NP_ITERATEINTERVAL:
                        if( xIterateContainer.is() )
                        {
                            if( aValue >>= fDouble )
                                xIterateContainer->setIterateInterval( fDouble );
                            else
                            {
                                SAL_INFO("oox.ppt","any >>= failed " << __LINE__ );
                            }
                        }
                        break;
                    default:
                        SAL_INFO("oox.ppt","ERR-OOX: unknown prop index " << i );
                        break;
                    }
                }
            }

            if (xAnimate.is() && xAnimate->getValues().getLength() != xAnimate->getKeyTimes().getLength())
                throw css::io::WrongFormatException();

            if( mnNodeType == AnimationNodeType::TRANSITIONFILTER )
            {

                Reference< XTransitionFilter > xFilter( xNode, UNO_QUERY );
                maTransitionFilter.setTransitionFilterProperties( xFilter );
            }

            std::for_each(
                maChildren.begin(), maChildren.end(),
                [&rFilter, &xNode, &pSlide] (TimeNodePtr const & child) {
                    child->addNode(rFilter, xNode, pSlide);
                } );

            switch( mnNodeType )
            {
            case AnimationNodeType::SEQ:
            {
                sal_Int16 nEnum = 0;
                if( maUserData[ "node-type" ] >>= nEnum )
                {
                    if( nEnum == EffectNodeType::MAIN_SEQUENCE )
                    {
                        fixMainSequenceTiming( xNode );
                    }
                    else if( nEnum ==  EffectNodeType::INTERACTIVE_SEQUENCE )
                    {
                        fixInteractiveSequenceTiming( xNode );
                    }
                }
                break;
            }
            case AnimationNodeType::PAR:
                // some other cut&paste... from AnimationImporter::importAnimationContainer()
                break;
            }
        }
        catch( const Exception& )
        {
            TOOLS_INFO_EXCEPTION("oox.ppt","OOX: exception raised in TimeNode::setNode()");
        }
    }

    Reference< XAnimationNode > TimeNode::createAndInsert(
            const XmlFilterBase& rFilter,
            const OUString& rServiceName,
            const Reference< XAnimationNode >& rxNode )
    {
        try {
            Reference< XAnimationNode > xNode( Reference<css::lang::XMultiServiceFactory>(rFilter.getComponentContext()->getServiceManager(), UNO_QUERY_THROW)->createInstance( rServiceName ), UNO_QUERY_THROW );
            Reference< XTimeContainer > xParentContainer( rxNode, UNO_QUERY_THROW );

            xParentContainer->appendChild( xNode );
            return xNode;
        }
        catch( const Exception& )
        {
            TOOLS_INFO_EXCEPTION("oox.ppt", "OOX: exception raised in TimeNode::createAndInsert() trying to create a service " << rServiceName);
        }

        return Reference< XAnimationNode >();
    }

    void    TimeNode::setId( sal_Int32 nId )
    {
        msId = OUString::number(nId);
    }

    void TimeNode::setTo( const Any & aTo )
    {
        maNodeProperties[ NP_TO ] = aTo;
    }

    void TimeNode::setFrom( const Any & aFrom )
    {
        maNodeProperties[ NP_FROM ] = aFrom;
    }

    void TimeNode::setBy( const Any & aBy )
    {
        maNodeProperties[ NP_BY ] = aBy;
    }

}

/* vim:set shiftwidth=4 softtabstop=4 expandtab: */