如何知道 Silverlight VisualStateManager.GoToState 转换何时完成?
我正在使用 Silverlight VisualStateManager.GoToState
方法将控件从一种状态转换到另一种状态。这一切都运行良好,并且过渡动画效果很好。但我想知道转换何时完成,以便我可以在代码中启动其他操作。是否有一个事件或其他机制可以用来发现到另一个状态的转换何时完成?
I am using the Silverlight VisualStateManager.GoToState
method to transition my control from one state to another. This all works fine and the transition animations works great. But I want to know when the transition has completed so I can then start other actions in my code. Is there an event or other mechanism I can use to discover when the transition to another state has completed?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
控件立即进入给定的状态。这触发的动画可以被认为是副作用。您可以通过其 Completed 事件确定触发的时间线何时完成:
http://msdn.microsoft.com/en-us/library/system.windows.media.animation.timeline.completed%28VS.95%29.aspx
科林·E。
The control immediately goes to the state given. The animations that this triggers can be thought of as a side-effect. You can determine when a triggered timeline is complete via its Completed event:
http://msdn.microsoft.com/en-us/library/system.windows.media.animation.timeline.completed%28VS.95%29.aspx
Colin E.