【问题标题】:Kendo UI Mobile - Stop ScrollerKendo UI Mobile - 停止滚动
【发布时间】:2013-04-10 17:01:25
【问题描述】:

有没有办法停止滚动?例如,我想允许用户在触摸按钮时返回特定位置。到目前为止,我的方法是:

// 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 年第一季度发布的 Kendo Mobile

【问题讨论】:

    标签: listview kendo-ui


    【解决方案1】:

    虽然没有从他们的文档中公开,但我通过在此处将速度属性设置为 0 来解决它:

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

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2014-01-04
      • 2014-10-15
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多