From: dongsug-song <35130733+dongsug-song@users.noreply.github.com>
Date: Thu, 26 Dec 2019 07:34:11 +0000 (+0900)
Subject: [NUI] Add SetMinMaxFrameByMarker() in LottieAnimationView (#1244)
X-Git-Tag: submit/tizen/20200114.005334~1^2~15
X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=8c93464887e7cef531b1a0de60984e761c96476f;p=platform%2Fcore%2Fcsapi%2Ftizenfx.git
[NUI] Add SetMinMaxFrameByMarker() in LottieAnimationView (#1244)
---
diff --git a/src/Tizen.NUI/src/public/BaseComponents/LottieAnimationView.cs b/src/Tizen.NUI/src/public/BaseComponents/LottieAnimationView.cs
index c8c9a86..e12f6bc 100755
--- a/src/Tizen.NUI/src/public/BaseComponents/LottieAnimationView.cs
+++ b/src/Tizen.NUI/src/public/BaseComponents/LottieAnimationView.cs
@@ -509,6 +509,36 @@ namespace Tizen.NUI.BaseComponents
tlog.Fatal(tag, $">");
return currentStates.contentInfo;
}
+
+ ///
+ /// A marker has its start frame and end frame.
+ /// Animation will play between the start frame and the end frame of the marker if one marker is specified.
+ /// 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. *
+ ///
+ /// First marker
+ /// Second marker
+ // This will be public opened after ACR done. (Before ACR, need to be hidden as Inhouse API)
+ [EditorBrowsable(EditorBrowsableState.Never)]
+ public void SetMinMaxFrameByMarker(string marker1, string marker2 = null)
+ {
+ tlog.Fatal(tag, $"< [{GetId()}] SetMinMaxFrameByMarker({marker1}, {marker2})");
+
+ currentStates.changed = true;
+ currentStates.mark1 = marker1;
+ currentStates.mark2 = marker2;
+
+ PropertyArray array = new PropertyArray();
+ array.PushBack(new PropertyValue(currentStates.mark1));
+ if (marker2 != null)
+ {
+ array.PushBack(new PropertyValue(currentStates.mark2));
+ }
+
+ PropertyMap map = new PropertyMap();
+ map.Add(ImageVisualProperty.PlayRange, new PropertyValue(array));
+ DoAction(vectorImageVisualIndex, (int)actionType.updateProperty, new PropertyValue(map));
+ tlog.Fatal(tag, $" [{GetId()}] currentStates.mark1:{currentStates.mark1}, mark2:{currentStates.mark2} >");
+ }
#endregion Method
@@ -676,6 +706,7 @@ namespace Tizen.NUI.BaseComponents
internal float scale;
internal PlayStateType playState;
internal List> contentInfo;
+ internal string mark1, mark2;
};
private states currentStates;