2013-04-10 62 views
0

反正有停止Scroller?例如,我想允许用户在触摸按钮时返回到特定位置。我的做法迄今:Kendo UI Mobile - 停止Scroller

// scroll to the top 
e.view.scroller.reset(); 

// scroll to the destination offset 
e.view.scroller.scrollTo(0, targetOffset); 

的问题是,如果滚动先前滚动,它会继续targetOffset后滚动,直到其速度为0

有人能帮助我的方法首先停止滚动的速度?

我使用JQuery 1.9.1和剑道移动的2013年第一季度发布

回答

2

虽然没有从他们的文档暴露,我被这里的速度属性设置为0解决了这个问题:

e.view.scroller.yinertia.velocity = 0; 
+0

这应该被标记为答案 – 2014-11-23 23:40:24