Getting AppBuilder to work with animatescroll.js

2 posts, 0 answers
  1. David Gerding
    David Gerding avatar
    44 posts
    Member since:
    Sep 2005

    Posted 09 Nov 2014 Link to this post

    Hi All,
    I've been struggling trying to get Ram Swaroop's animateScroll.js to work with AppBuilder. I need the nice fine-grained control of animateScroll, like pre and post scroll event handling, animation easing and controllable scrolling speed (!).

    However, no matter what I do the scrolling behavior won't actually happen, even though the jquery animate code that does the work (line 162 ) of animateScroll does seem to fire, at as near as I can tell by instrumenting with console.log. To be clear the behavior I am after is the method in animatescroll where you are scrolling within an existing element as opposed to the default behavior of scrolling the whole page. Scrolling within an element is achieved referencing the containing element as a parameter. Effectively, this approach turns an arbitrary containing div into a "scroller" and can be seen in the demo under the parameter section.

    I have a large appbuilder project, so I made an essentially empty appbuilder project from Telerik's demo templates and I get the same result. It's a really nice scroller - if I can get it to work in a hybrid mobile app context.

    Any suggestions or help appreciated. I've posted the same ask for help at Stackoverflow - and you can see the html fragment of my mobile view that "won't scroll" along with the complete source of animatescroll.js.

    Thanks, Dave Gerding

  2. Martin Yankov
    Martin Yankov avatar
    177 posts

    Posted 12 Nov 2014 Link to this post

    Hi David Gerding,

    Unfortunately, you won't be able to use the jQuery plugin you specified in Kendo UI Mobile. Scrolling the mobile views is handled entirely by the framework. This is done, so that the scrolling can be as fluid as possible and mimic the native scrolling. Fortunately, Kendo UI Mobile provides an animatedScrollTo() method to the Scroller widget.

    You can try it out and see if it works for you.

    Martin Yankov

    Visit the Telerik Verified Plugins Marketplace and get the custom Cordova plugin you need, already tweaked to work seamlessly with AppBuilder.

Back to Top