intel / appframework

The definitive HTML5 mobile javascript framework
http://app-framework-software.intel.com/
MIT License
2.43k stars 882 forks source link

Touch Scrolling Inertia doesn't stop #895

Closed oldgeeksguide closed 9 years ago

oldgeeksguide commented 9 years ago

If I create an app in the Intel XDK using App Framework, I can scroll, but if I touch, move and stop it jumps when I eventually lift my finger, as though the pause never happened, i.e. if I scroll fast and stop then remove finger, it scrolls a bit further quickly. If I scroll slow, it scrolls slowly. What I expect to happen is that when I stop before lifting (rather than flicking) there should be no inertia in the scrolling, i.e. it shouldn't move. This results in seemingly random jumping up or down. Here is another description of the problem: http://stackoverflow.com/questions/32840681/how-to-fix-scroller-speed-animation-inside-intel-xdk?noredirect=1#comment53637760_32840681

I can reproduce this by adding the following to an empty template XDK file: In the header add these three lines:

    <link rel="stylesheet" type="text/css" href="http://cdn.app-framework-software.intel.com/2.1/app_framework/2.1/css/af.ui.min.css">
    <script type="text/javascript" charset="utf-8" src="http://cdn.app-framework-software.intel.com/2.1/appframework.min.js"></script>
    <script type="text/javascript" charset="utf-8" src="http://cdn.app-framework-software.intel.com/2.1/appframework.ui.min.js"></script>

Then in the body add this:

    <div id="content" class="uwrap">
        <div class="panel" id="mainpage">

              <h1>CONTENT GOES HERE</h1>

        </div>
    </div>

In place of "CONTENT GOES HERE" there should be enough content so that scrolling is required to see it all.

In the XDK I see this behavior in the emulator, as well as on devices via the debugger or a built app. I can reproduce this in Chrome as well, but only if I emable emulation of a touch oriented device, such as the Nexus 4, though the effect is not as pronounced as it is on a real device.

imaffett commented 9 years ago

Can you try 2.2? 2.1 is no longer supported. And the XDK templates are outdated.

https://github.com/01org/appframework/tree/2.2

Also, if on device is fine, I'm not too concerned about desktop.

imaffett commented 9 years ago

This was fixed last year.

https://github.com/01org/appframework/issues/710

https://github.com/01org/appframework/commit/93d48c53ff3fc60f5dc69faa51772105d4f56d55

imaffett commented 9 years ago

Ok - this was another bug. Fixed in the 2.2 and 2.1devtf branches