2 * Copyright(c) 2021 Samsung Electronics Co., Ltd.
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
8 * http://www.apache.org/licenses/LICENSE-2.0
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
19 using System.ComponentModel;
20 using Tizen.NUI.Binding;
22 namespace Tizen.NUI.BaseComponents
25 /// AnimatedVectorImageView is a class for displaying a vector resource.
27 [EditorBrowsable(EditorBrowsableState.Never)]
28 public partial class AnimatedVectorImageView : LottieAnimationView
30 #region Constructor, Destructor, Dispose
32 static AnimatedVectorImageView()
34 //to get "IsUsingXaml" feature working at preload, we need to remove readonly for BindableProperty.
35 //this AnimatedVectorImageView is not preloaded.
36 if (NUIApplication.IsUsingXaml)
38 ResourceURLProperty = BindableProperty.Create(nameof(ResourceURL), typeof(string), typeof(AnimatedVectorImageView), string.Empty,
39 propertyChanged: SetInternalResourceURLProperty, defaultValueCreator: GetInternalResourceURLProperty);
41 ResourceUrlProperty = BindableProperty.Create(nameof(ResourceUrl), typeof(string), typeof(AnimatedVectorImageView), string.Empty,
42 propertyChanged: SetInternalResourceUrlProperty, defaultValueCreator: GetInternalResourceUrlProperty);
44 RepeatCountProperty = BindableProperty.Create(nameof(RepeatCount), typeof(int), typeof(AnimatedVectorImageView), 0,
45 propertyChanged: SetInternalRepeatCountProperty, defaultValueCreator: GetInternalRepeatCountProperty);
47 CurrentFrameProperty = BindableProperty.Create(nameof(CurrentFrame), typeof(int), typeof(AnimatedVectorImageView), 0,
48 propertyChanged: SetInternalCurrentFrameProperty, defaultValueCreator: GetInternalCurrentFrameProperty);
50 RepeatModeProperty = BindableProperty.Create(nameof(RepeatMode), typeof(RepeatModes), typeof(AnimatedVectorImageView), default(RepeatModes),
51 propertyChanged: SetInternalRepeatModeProperty, defaultValueCreator: GetInternalRepeatModeProperty);
56 /// Construct VectorAnimationView.
58 [EditorBrowsable(EditorBrowsableState.Never)]
59 public AnimatedVectorImageView() : base()
61 NUILog.Debug($"[AnimatedVectorImageView START[ constructor objId={GetId()} ] END]");
65 /// Construct VectorAnimationView.
67 /// <param name="scale">Set scaling factor for Vector Animation, while creating.</param>
68 [EditorBrowsable(EditorBrowsableState.Never)]
69 public AnimatedVectorImageView(float scale) : base(scale)
71 NUILog.Debug($"[AnimatedVectorImageView START[ constructor scale={scale}) objId={GetId()} ] END]");
75 /// You can override it to clean-up your own resources
77 /// <param name="type">DisposeTypes</param>
78 [EditorBrowsable(EditorBrowsableState.Never)]
79 protected override void Dispose(DisposeTypes type)
85 NUILog.Debug($"AnimatedVectorImageView START");
87 //Release your own unmanaged resources here.
88 //You should not access any managed member here except static instance.
89 //because the execution order of Finalizes is non-deterministic.
93 NUILog.Debug($"AnimatedVectorImageView END");
95 #endregion Constructor, Destructor, Dispose
102 // Suppress warning : This has been being used by users, so that the interface can not be changed.
103 [EditorBrowsable(EditorBrowsableState.Never)]
104 public string ResourceURL
108 if (NUIApplication.IsUsingXaml)
110 return GetValue(ResourceURLProperty) as string;
114 return GetInternalResourceURLProperty(this) as string;
119 if (NUIApplication.IsUsingXaml)
121 SetValue(ResourceURLProperty, value);
125 SetInternalResourceURLProperty(this, null, value);
127 NotifyPropertyChanged();
131 private string InternalResourceURL
135 NUILog.Debug($"[AnimatedVectorImageView START[ [{GetId()}] ResourceURL SET");
137 if (value == resourceUrl)
139 NUILog.Debug($"set same URL! ");
142 resourceUrl = (value == null) ? "" : value;
144 isMinMaxFrameSet = minMaxSetTypes.NotSetByUser;
145 NUILog.Debug($" [{GetId()}] resourceUrl={resourceUrl}) ]AnimatedVectorImageView END]");
153 // Suppress warning : This has been being used by users, so that the interface can not be changed.
154 [EditorBrowsable(EditorBrowsableState.Never)]
155 public new string ResourceUrl
159 if (NUIApplication.IsUsingXaml)
161 return GetValue(ResourceUrlProperty) as string;
165 return GetInternalResourceUrlProperty(this) as string;
170 if (NUIApplication.IsUsingXaml)
172 SetValue(ResourceUrlProperty, value);
176 SetInternalResourceUrlProperty(this, null, value);
178 NotifyPropertyChanged();
182 private string InternalResourceUrl
186 NUILog.Debug($"[AnimatedVectorImageView START[ [{GetId()}] ResourceUrl SET");
187 this.ResourceURL = value;
188 NUILog.Debug($" [{GetId()}] value={value}) ]AnimatedVectorImageView END]");
192 NUILog.Debug($"[AnimatedVectorImageView [ [{GetId()}] ResourceUrl GET");
193 return this.ResourceURL;
199 /// RepeatCount of animation.
200 /// The repeat count is 0 by default.
201 /// If the RepeatCount is 0, the animation is never repeated.
202 /// If the RepeatCount is greater than 0, the repeat mode will be taken into account.
203 /// If RepeatCount is -1, animation is infinite loops.
205 [EditorBrowsable(EditorBrowsableState.Never)]
206 public int RepeatCount
210 if (NUIApplication.IsUsingXaml)
212 return (int)GetValue(RepeatCountProperty);
216 return (int)GetInternalRepeatCountProperty(this);
221 if (NUIApplication.IsUsingXaml)
223 SetValue(RepeatCountProperty, value);
227 SetInternalRepeatCountProperty(this, null, value);
229 NotifyPropertyChanged();
233 private int InternalRepeatCount
237 NUILog.Debug($"[AnimatedVectorImageView START[ [{GetId()}] RepeatCount SET");
239 repeatCnt = (value < -1) ? -1 : value;
240 LoopCount = (repeatCnt < 0) ? repeatCnt : repeatCnt + 1;
242 NUILog.Debug($"[{GetId()}] repeatCnt={repeatCnt} ]AnimatedVectorImageView END]");
248 /// TotalFrame of animation.
249 /// If resouce is still not be loaded, or invalid resource, the value is 0.
251 [EditorBrowsable(EditorBrowsableState.Never)]
252 public new int TotalFrame
254 get => totalFrameNum;
257 private int totalFrameNum
259 get => base.TotalFrame;
263 /// CurrentFrame of animation.
265 /// <returns> Returns user set value for the current frame. Cannot provide actual playing current frame. </returns>
266 [EditorBrowsable(EditorBrowsableState.Never)]
267 public new int CurrentFrame
271 if (NUIApplication.IsUsingXaml)
273 return (int)GetValue(CurrentFrameProperty);
277 return (int)GetInternalCurrentFrameProperty(this);
282 if (NUIApplication.IsUsingXaml)
284 SetValue(CurrentFrameProperty, value);
288 SetInternalCurrentFrameProperty(this, null, value);
290 NotifyPropertyChanged();
294 private int InternalCurrentFrame
298 NUILog.Debug($"[AnimatedVectorImageView START[ [{GetId()}] CurrentFrame SET");
300 if (string.IsNullOrEmpty(resourceUrl))
302 throw new InvalidOperationException("Resource Url not yet Set");
310 innerCurrentFrame = value;
311 AnimationState = AnimationStates.Paused;
313 base.SetMinMaxFrame(0, IntegerMaxValue);
314 base.CurrentFrame = innerCurrentFrame;
316 NUILog.Debug($" [{GetId()}] innerCurrentFrame={innerCurrentFrame}) ]AnimatedVectorImageView END]");
318 get => innerCurrentFrame;
322 /// RepeatMode of animation.
324 [EditorBrowsable(EditorBrowsableState.Never)]
325 public RepeatModes RepeatMode
329 if (NUIApplication.IsUsingXaml)
331 return (RepeatModes)GetValue(RepeatModeProperty);
335 return (RepeatModes)GetInternalRepeatModeProperty(this);
340 if (NUIApplication.IsUsingXaml)
342 SetValue(RepeatModeProperty, value);
346 SetInternalRepeatModeProperty(this, null, value);
348 NotifyPropertyChanged();
352 private RepeatModes InternalRepeatMode
356 NUILog.Debug($"[AnimatedVectorImageView START[ [{GetId()}] RepeatMode SET");
361 case RepeatModes.Restart:
362 LoopingMode = LoopingModeType.Restart;
364 case RepeatModes.Reverse:
365 LoopingMode = LoopingModeType.AutoReverse;
368 LoopingMode = LoopingModeType.Restart;
372 NUILog.Debug($" [{GetId()}] repeatMode={repeatMode}) ]AnimatedVectorImageView END]");
378 /// Get state of animation.
380 [EditorBrowsable(EditorBrowsableState.Never)]
381 public AnimationStates AnimationState
385 CurrentAnimationState = value;
389 if (CurrentAnimationState == AnimationStates.Playing)
391 if (PlayState == PlayStateType.Stopped)
393 CurrentAnimationState = AnimationStates.Stopped;
396 return CurrentAnimationState;
404 /// Set minimum frame and maximum frame
406 /// <param name="minFrame">minimum frame.</param>
407 /// <param name="maxFrame">maximum frame.</param>
408 [EditorBrowsable(EditorBrowsableState.Never)]
409 public void SetMinAndMaxFrame(int minFrame, int maxFrame)
411 NUILog.Debug($"[AnimatedVectorImageView START[ [{GetId()}] SetMinAndMaxFrame({minFrame}, {maxFrame})");
413 minimumFrame = (minFrame) > 0 ? minFrame : 0;
414 maximumFrame = (maxFrame) > 0 ? maxFrame : 0;
415 isMinMaxFrameSet = minMaxSetTypes.SetByMinAndMaxFrameMethod;
417 // Remove marker information.
418 minimumFrameMarker = null;
419 maximumFrameMarker = null;
421 if (minimumFrame > maximumFrame)
423 NUILog.Debug($" [{GetId()}] minimumFrame:{minimumFrame} > maximumFrame:{maximumFrame}) ]AnimatedVectorImageView END]");
427 NUILog.Debug($" [{GetId()}] minimumFrame:{minimumFrame}, maximumFrame:{maximumFrame}) ]AnimatedVectorImageView END]");
431 /// Set minimum frame and maximum frame by marker.
432 /// Animation will play between the start frame and the end frame of the marker if one marker is specified.
433 /// Or animation will play between the start frame of the first marker and the end frame of the second marker if two markers are specified.
436 /// If we use invaliad markers, or we load image asynchronous and load is not finished yet,
437 /// CurrentFrame might not be matched with real value.
439 /// <param name="marker1">First marker</param>
440 /// <param name="marker2">Second marker</param>
441 [EditorBrowsable(EditorBrowsableState.Never)]
442 public void SetMinAndMaxFrameByMarker(string marker1, string marker2 = null)
444 NUILog.Debug($"[AnimatedVectorImageView START[ [{GetId()}] SetMinAndMaxFrameByMarker({marker1}, {marker2})");
446 minimumFrameMarker = marker1;
447 maximumFrameMarker = marker2;
448 isMinMaxFrameSet = minMaxSetTypes.SetByMinAndMaxFrameByMarkerMethod;
450 // Remove frame information.
454 NUILog.Debug($" [{GetId()}] minimumFrameMarker:{minimumFrameMarker}, maximumFrameMarker:{maximumFrameMarker}) ]AnimatedVectorImageView END]");
458 /// SetMinMaxFrame(int startFrame, int endFrame)
460 /// <param name="minFrame"></param>
461 /// <param name="maxFrame"></param>
462 [EditorBrowsable(EditorBrowsableState.Never)]
463 public new void SetMinMaxFrame(int minFrame, int maxFrame)
465 NUILog.Debug($"SetMinMaxFrame({minFrame}, {maxFrame})!!!");
467 minimumFrame = (minFrame) > 0 ? minFrame : 0;
468 maximumFrame = (maxFrame) > 0 ? maxFrame : 0;
469 isMinMaxFrameSet = minMaxSetTypes.SetByBaseSetMinMaxFrameMethod;
471 // Remove marker information.
472 minimumFrameMarker = null;
473 maximumFrameMarker = null;
475 if (minimumFrame >= totalFrameNum)
477 minimumFrame = totalFrameNum - 1;
480 if (maximumFrame >= totalFrameNum)
482 maximumFrame = totalFrameNum - 1;
485 base.SetMinMaxFrame(minimumFrame, maximumFrame);
489 /// A marker has its start frame and end frame.
490 /// Animation will play between the start frame and the end frame of the marker if one marker is specified.
491 /// Or animation will play between the start frame of the first marker and the end frame of the second marker if two markers are specified.
493 /// <param name="marker1">First marker</param>
494 /// <param name="marker2">Second marker</param>
495 [EditorBrowsable(EditorBrowsableState.Never)]
496 public new void SetMinMaxFrameByMarker(string marker1, string marker2 = null)
498 NUILog.Debug($"SetMinMaxFrameByMarker({marker1}, {marker2})");
500 minimumFrameMarker = marker1;
501 maximumFrameMarker = marker2;
502 isMinMaxFrameSet = minMaxSetTypes.SetByMarker;
504 // Remove frame information.
508 base.SetMinMaxFrameByMarker(marker1, marker2);
514 [EditorBrowsable(EditorBrowsableState.Never)]
515 public new void Play()
517 NUILog.Debug($"[AnimatedVectorImageView START[ [{GetId()}] AnimationState={AnimationState}, PlayState={PlayState}");
519 if (string.IsNullOrEmpty(resourceUrl))
521 throw new InvalidOperationException("Resource Url not yet Set");
524 switch (isMinMaxFrameSet)
526 case minMaxSetTypes.NotSetByUser:
527 base.SetMinMaxFrame(0, totalFrameNum - 1);
528 base.CurrentFrame = 0;
529 innerCurrentFrame = 0;
532 case minMaxSetTypes.SetByMinAndMaxFrameByMarkerMethod:
533 base.SetMinMaxFrameByMarker(minimumFrameMarker, maximumFrameMarker);
534 if (GetFrameValueFromMarkerInfo())
536 base.CurrentFrame = minimumFrame;
537 innerCurrentFrame = minimumFrame;
541 Tizen.Log.Error("NUI", $"[Warning] Play with invalid marker! Current frame become 0\n");
542 base.CurrentFrame = 0;
543 innerCurrentFrame = 0;
547 case minMaxSetTypes.SetByMinAndMaxFrameMethod:
548 base.SetMinMaxFrame(minimumFrame, maximumFrame);
549 base.CurrentFrame = minimumFrame;
550 innerCurrentFrame = minimumFrame;
553 case minMaxSetTypes.SetByMarker:
554 case minMaxSetTypes.SetByBaseSetMinMaxFrameMethod:
561 AnimationState = AnimationStates.Playing;
563 NUILog.Debug($" [{GetId()}] isMinMaxFrameSet={isMinMaxFrameSet}) ]AnimatedVectorImageView END]");
569 [EditorBrowsable(EditorBrowsableState.Never)]
570 public new void Pause()
572 NUILog.Debug($"[AnimatedVectorImageView START[ [{GetId()}] AnimationState={AnimationState}, PlayState={PlayState}");
574 if (string.IsNullOrEmpty(resourceUrl))
576 throw new InvalidOperationException("Resource Url not yet Set");
580 AnimationState = AnimationStates.Paused;
582 NUILog.Debug($" [{GetId()}] ]AnimatedVectorImageView END]");
588 /// <param name="endAction">Defines, what should be behaviour after cancel operation
589 /// End action is Cancel, Animation Stops at the Current Frame.
590 /// End action is Discard, Animation Stops at the Min Frame
591 /// End action is StopFinal, Animation Stops at the Max Frame
593 [EditorBrowsable(EditorBrowsableState.Never)]
594 public void Stop(EndActions endAction = EndActions.Cancel)
596 NUILog.Debug($"[AnimatedVectorImageView START[ [{GetId()}] endAction:({endAction}), PlayState={PlayState}");
598 if (string.IsNullOrEmpty(resourceUrl))
600 throw new InvalidOperationException("Resource Url not yet Set");
603 if (AnimationState == AnimationStates.Stopped)
608 if (innerEndAction != endAction)
610 innerEndAction = endAction;
613 case EndActions.Cancel:
614 StopBehavior = StopBehaviorType.CurrentFrame;
616 case EndActions.Discard:
617 StopBehavior = StopBehaviorType.MinimumFrame;
619 case EndActions.StopFinal:
620 StopBehavior = StopBehaviorType.MaximumFrame;
623 NUILog.Debug($" [{GetId()}] no endAction : default set");
627 AnimationState = AnimationStates.Stopped;
631 NUILog.Debug($"isMinMaxFrameSet:{isMinMaxFrameSet}, base.CurrentFrame:{base.CurrentFrame}, totalFrameNum:{totalFrameNum}, minimumFrame:{minimumFrame}, maximumFrame:{maximumFrame}, StopBehavior:{StopBehavior}, endAction:{endAction}");
633 switch (isMinMaxFrameSet)
635 case minMaxSetTypes.NotSetByUser:
638 case EndActions.Cancel:
639 innerCurrentFrame = base.CurrentFrame;
641 case EndActions.Discard:
642 base.CurrentFrame = innerCurrentFrame = 0;
644 case EndActions.StopFinal:
645 base.CurrentFrame = innerCurrentFrame = totalFrameNum - 1;
650 case minMaxSetTypes.SetByMinAndMaxFrameByMarkerMethod:
651 if (GetFrameValueFromMarkerInfo())
653 goto case minMaxSetTypes.SetByMinAndMaxFrameMethod;
659 case EndActions.Cancel:
660 innerCurrentFrame = base.CurrentFrame;
662 case EndActions.Discard:
663 Tizen.Log.Error("NUI", $"[Warning] Stop(Discard) with invalid marker! Current frame become 0\n");
664 base.CurrentFrame = innerCurrentFrame = 0;
666 case EndActions.StopFinal:
667 Tizen.Log.Error("NUI", $"[Warning] Stop(StopFinal) with invalid marker! Current frame become {totalFrameNum - 1}\n");
668 base.CurrentFrame = innerCurrentFrame = totalFrameNum - 1;
674 case minMaxSetTypes.SetByMinAndMaxFrameMethod:
677 case EndActions.Cancel:
678 innerCurrentFrame = base.CurrentFrame;
680 case EndActions.Discard:
681 base.CurrentFrame = innerCurrentFrame = minimumFrame;
683 case EndActions.StopFinal:
684 base.CurrentFrame = innerCurrentFrame = maximumFrame;
689 case minMaxSetTypes.SetByMarker:
690 case minMaxSetTypes.SetByBaseSetMinMaxFrameMethod:
695 NUILog.Debug($" [{GetId()}] innerCurrentFrame={innerCurrentFrame}, base.CurrentFrame={base.CurrentFrame}");
696 NUILog.Debug($" [{GetId()}] ]AnimatedVectorImageView END]");
701 #region Event, Enum, Struct, ETC
703 /// RepeatMode of animation.
705 // Suppress warning : This has been being used by users, so that the interface can not be changed.
706 [System.Diagnostics.CodeAnalysis.SuppressMessage("Naming", "CA1717:Only FlagsAttribute enums should have plural names", Justification = "<Pending>")]
707 [EditorBrowsable(EditorBrowsableState.Never)]
708 public enum RepeatModes
711 /// When the animation reaches the end and RepeatCount is nonZero, the animation restarts from the beginning.
713 [EditorBrowsable(EditorBrowsableState.Never)]
714 Restart = LoopingModeType.Restart,
716 /// When the animation reaches the end and RepeatCount nonZero, the animation reverses direction on every animation cycle.
718 [EditorBrowsable(EditorBrowsableState.Never)]
719 Reverse = LoopingModeType.AutoReverse
723 /// EndActions of animation.
725 // Suppress warning : This has been being used by users, so that the interface can not be changed.
726 [System.Diagnostics.CodeAnalysis.SuppressMessage("Naming", "CA1717:Only FlagsAttribute enums should have plural names", Justification = "<Pending>")]
727 [EditorBrowsable(EditorBrowsableState.Never)]
728 public enum EndActions
730 /// <summary> End action is Cancel, Animation Stops at the Current Frame.</summary>
731 [EditorBrowsable(EditorBrowsableState.Never)]
733 /// <summary> End action is Discard, Animation Stops at the Min Frame</summary>
734 [EditorBrowsable(EditorBrowsableState.Never)]
736 /// <summary> End action is StopFinal, Animation Stops at the Max Frame</summary>
737 [EditorBrowsable(EditorBrowsableState.Never)]
742 /// AnimationStates of animation.
744 // Suppress warning : This has been being used by users, so that the interface can not be changed.
745 [System.Diagnostics.CodeAnalysis.SuppressMessage("Naming", "CA1717:Only FlagsAttribute enums should have plural names", Justification = "<Pending>")]
746 [EditorBrowsable(EditorBrowsableState.Never)]
747 public enum AnimationStates
749 /// <summary> The animation has stopped.</summary>
750 [EditorBrowsable(EditorBrowsableState.Never)]
751 Stopped = PlayStateType.Stopped,
752 /// <summary> The animation is playing.</summary>
753 [EditorBrowsable(EditorBrowsableState.Never)]
754 Playing = PlayStateType.Playing,
755 /// <summary> The animation is paused.</summary>
756 [EditorBrowsable(EditorBrowsableState.Never)]
757 Paused = PlayStateType.Paused
759 #endregion Event, Enum, Struct, ETC
763 internal bool GetFrameValueFromMarkerInfo()
765 bool minimumMarkerFoundSuccess = false;
766 bool maximumMarkerFoundSuccess = false;
767 int foundedMinimumFrame = 0;
768 int foundedMaximumFrame = 0;
770 NUILog.Debug($" [{GetId()}] GetFrameValueFromMarkerInfo : marker = (minimumFrameMarker:{minimumFrameMarker}, maximumFrameMarker:{maximumFrameMarker})");
772 var markerInfoList = GetMarkerInfo();
773 if (markerInfoList != null)
775 foreach (var markerInfo in markerInfoList)
777 if (markerInfo.Item1 == minimumFrameMarker)
779 if (string.IsNullOrEmpty(maximumFrameMarker))
781 minimumMarkerFoundSuccess = true;
782 maximumMarkerFoundSuccess = true;
783 foundedMinimumFrame = markerInfo.Item2;
784 foundedMaximumFrame = markerInfo.Item3;
788 minimumMarkerFoundSuccess = true;
789 foundedMinimumFrame = markerInfo.Item2;
792 else if (markerInfo.Item1 == maximumFrameMarker)
794 maximumMarkerFoundSuccess = true;
795 foundedMaximumFrame = markerInfo.Item2;
800 if (minimumMarkerFoundSuccess && maximumMarkerFoundSuccess)
802 minimumFrame = (foundedMinimumFrame) > 0 ? foundedMinimumFrame : 0;
803 maximumFrame = (foundedMaximumFrame) > 0 ? foundedMaximumFrame : 0;
804 NUILog.Debug($" [{GetId()}] GetFrameValueFromMarkerInfo Sucess! frame set as {minimumFrame} ~ {maximumFrame} : marker = (minimumFrameMarker:{minimumFrameMarker}, maximumFrameMarker:{maximumFrameMarker})");
805 if (minimumFrame > maximumFrame)
807 NUILog.Debug($" [{GetId()}] minimumFrame:{minimumFrame} > maximumFrame:{maximumFrame})");
810 // Note : let we insure to get marker frame value only one time per each frame marker setter
811 minimumFrameMarker = null;
812 maximumFrameMarker = null;
813 isMinMaxFrameSet = minMaxSetTypes.SetByMinAndMaxFrameMethod;
818 Tizen.Log.Error("NUI", $"Fail to get frame from marker = (minimumFrameMarker:{minimumFrameMarker}, maximumFrameMarker:{maximumFrameMarker}). Maybe file is not loaded yet, or invalid marker used. url : {resourceUrl}\n");
819 NUILog.Debug($" [{GetId()}] GetFrameValueFromMarkerInfo Failed! frame set as {minimumFrame} ~ {maximumFrame} : marker = (minimumFrameMarker:{minimumFrameMarker}, maximumFrameMarker:{maximumFrameMarker})");
827 private string resourceUrl = null;
828 private int repeatCnt = 0;
829 private RepeatModes repeatMode = RepeatModes.Restart;
830 private int minimumFrame = -1, maximumFrame = -1;
831 private string minimumFrameMarker = null;
832 private string maximumFrameMarker = null;
833 private minMaxSetTypes isMinMaxFrameSet = minMaxSetTypes.NotSetByUser;
834 private int innerCurrentFrame = -1;
835 private EndActions innerEndAction = EndActions.Cancel;
836 private enum minMaxSetTypes
839 SetByMinAndMaxFrameMethod,
840 SetByMinAndMaxFrameByMarkerMethod,
842 SetByBaseSetMinMaxFrameMethod,
845 private AnimationStates CurrentAnimationState = AnimationStates.Stopped;
846 private const int IntegerMaxValue = 0x7FFFFFFF;