0

我目前在一些应用程序中使用 WP7 takeit GestureService,以便在 Silverlight UI 元素上执行轻拂和捏合/缩放手势。但是,看到该服务已被弃用,我试图找到一个替代库,它可以以类似的方式执行所有低级计算。

我一直在阅读挂钩ManipulationDelta是要走的路,但如果我不需要,我宁愿不深入研究 - 是否有任何人都知道的替代方案?

4

1 回答 1

0

您可以使用高级别的 ManipulationStarted、ManipulationDelta 和 ManipulationCompleted。您还可以使用 Touch.FrameReported - 它提供了用户触摸的低级界面

http://invokeit.wordpress.com/2012/04/27/high-performance-touch-interface-wpdev-wp7dev/

我使用 GestureService 而不是自己滚动来进行捏缩放、轻弹和拖动

找到了更多可以用来代替手势服务的东西。

// Scale the rectangle.
this.scale.ScaleX *= e.DeltaManipulation.Scale.X;
this.scale.ScaleY *= e.DeltaManipulation.Scale.Y;

// Move the rectangle.
this.translation.X += e.DeltaManipulation.Translation.X;
this.translation.Y += e.DeltaManipulation.Translation.Y;

更多信息在这里http://msdn.microsoft.com/en-us/library/ff426933(v=vs.95).aspx

于 2012-05-09T19:26:33.353 回答