Skip to content

Commit

Permalink
[NUI] Get Lottie ActionId of SetDynamicProperty
Browse files Browse the repository at this point in the history
Since we change the value of SetDynamicProperty value in dali side,
we need to get correct value from dali.

Signed-off-by: Eunki, Hong <[email protected]>
  • Loading branch information
Eunki, Hong committed Jul 24, 2023
1 parent 437208d commit 8062178
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,9 @@ internal static partial class LottieAnimationView

[global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_AnimatedVectorImageVisual_Actions_JUMP_TO_get")]
public static extern int AnimatedVectorImageVisualActionJumpToGet();

[global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_AnimatedVectorImageVisual_Actions_SET_DYNAMIC_PROPERTY_get")]
public static extern int AnimatedVectorImageVisualActionSetDynamicProperty();
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -453,7 +453,7 @@ private bool InternalRedrawInScalingDown

// This is used for internal purpose. hidden API.
[EditorBrowsable(EditorBrowsableState.Never)]
protected int SetDynamicProperty => ActionJumpTo + 1;
protected int ActionSetDynamicProperty { get; set; } = Interop.LottieAnimationView.AnimatedVectorImageVisualActionSetDynamicProperty();
#endregion Property


Expand Down Expand Up @@ -662,7 +662,7 @@ public void DoActionExtension(LottieAnimationViewDynamicProperty info)
weakReferencesOfLottie?.Add(dynamicPropertyCallbackId, new WeakReference<LottieAnimationView>(this));
InternalSavedDynamicPropertyCallbacks?.Add(dynamicPropertyCallbackId, info.Callback);

Interop.View.DoActionExtension(SwigCPtr, ImageView.Property.IMAGE, SetDynamicProperty, dynamicPropertyCallbackId, info.KeyPath, (int)info.Property, Marshal.GetFunctionPointerForDelegate<System.Delegate>(rootCallback));
Interop.View.DoActionExtension(SwigCPtr, ImageView.Property.IMAGE, ActionSetDynamicProperty, dynamicPropertyCallbackId, info.KeyPath, (int)info.Property, Marshal.GetFunctionPointerForDelegate<System.Delegate>(rootCallback));

if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
}
Expand Down

0 comments on commit 8062178

Please sign in to comment.