SetAnimator() 개인적인 정적인 메소드

private static SetAnimator ( DependencyObject obj, XamlAnimatedGif.Animator value ) : void
obj DependencyObject
value XamlAnimatedGif.Animator
리턴 void
예제 #1
0
        private static void ClearAnimatorCore(Image image)
        {
            Animator animator = AnimationBehavior.GetAnimator((DependencyObject)image);

            if (animator == null)
            {
                return;
            }
            animator.Dispose();
            AnimationBehavior.SetAnimator((DependencyObject)image, null);
        }
예제 #2
0
 private static void SetAnimatorCore(Image image, Animator animator)
 {
     AnimationBehavior.SetAnimator((DependencyObject)image, animator);
     image.Source = ((ImageSource)animator.Bitmap);
     if (AnimationBehavior.GetAutoStart((DependencyObject)image))
     {
         animator.Play();
     }
     else
     {
         animator.ShowFirstFrame();
     }
 }