tags:

views:

175

answers:

1

My code is here, and I can't edit the offset property of TranslateTransform3D any more after running this:

DoubleAnimation doubleAnimationX = new DoubleAnimation(x, new Duration(TimeSpan.FromSeconds(second))); DoubleAnimation doubleAnimationY = new DoubleAnimation(y, new Duration(TimeSpan.FromSeconds(second))); DoubleAnimation doubleAnimationZ = new DoubleAnimation(z, new Duration(TimeSpan.FromSeconds(second))); translate.BeginAnimation(TranslateTransform3D.OffsetXProperty, doubleAnimationX); translate.BeginAnimation(TranslateTransform3D.OffsetYProperty, doubleAnimationY); translate.BeginAnimation(TranslateTransform3D.OffsetZProperty, doubleAnimationZ);

+1  A: 

TranslateTransform3D derives from Freezable. Your translate is being frozen after the animation, which makes it immutable.

Reed Copsey