可以使用FluidMoveBehavior吗? [英] Is FluidMoveBehavior available?

查看:115
本文介绍了可以使用FluidMoveBehavior吗?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在尝试制作动画的代码中调用了Grid.SetRow和Grid.SetColumn.根据 http:上的答案: //social.msdn.microsoft.com/Forums/zh-CN/wpf/thread/257779f7-b459-43fc-a4a1-f24641c50e09 ,建议使用FluidMoveBehavior,但看起来不像Windows 8可用.

I have calls to Grid.SetRow and Grid.SetColumn in my code which I'm trying to animate. According to the answer at http://social.msdn.microsoft.com/Forums/en-CA/wpf/thread/257779f7-b459-43fc-a4a1-f24641c50e09, it is recommended to make use of FluidMoveBehavior, but it doesn't look like this is available for Windows 8.

当网格的子项位置改变时,我可以为它们做些什么选择?我基本上是在寻找一种实现线性过渡的方法.

What are my options for animating the children of a Grid when their positions change? I'm basically looking for a way to achieve linear transition.

推荐答案

有一个名为Transitions的新内置功能可以使用,这是

There is a new built-in feature called Transitions that can be used, here is an intro. Try adding a RepositionThemeTransition to the grids ChildrenTransitions then items will animate when you change their row or column.

<Grid.ChildrenTransitions>
    <TransitionCollection>
        <RepositionThemeTransition/>
    </TransitionCollection>
</Grid.ChildrenTransitions>

这篇关于可以使用FluidMoveBehavior吗?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆