0

我的代码在这里,运行后我无法再编辑 offset 属性TranslateTransform3D

                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);
4

1 回答 1

1

TranslateTransform3D 派生自Freezable。您的翻译在动画后被冻结,这使其不可变。

于 2009-07-30T18:26:14.037 回答