You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The scrolling area touch-event hack is necessary on iOS and Android<2.3, but many devices support CSS position: fixed.
In my own testing, web applications have much better performance characteristics for content in the scrolling pane. I've noticed that the web forms kitchen-sink widgets' animations are smoother when compared to the touch-event hacked technique.
However, in the example for Modernizr.addTest(), they give example code that actually tends to work in a few browsers (although I've noticed it produced false-positives in iOS): http://www.modernizr.com/docs/#addtest
I'm using the example code with some hard coded user-agent sniffing, which is also what the Wink Toolkit does (although they have a slightly more interesting detection mechanism involving getBoundingClientRect).
I use user-agent sniffing in my sample apps for this. In one of my apps, I use this to change to native scrolling:
// turn off flick based scrolling
if (!jo.matchPlatform("ios ipad iphone hpwos webos playbook android bada playbook")) {
joDOM.loadCSS("css/browser.css");
joScroller.prototype.onDown = function() {};
}
The browser.css file here just reverts back to overflow: auto for divs, but the same sort of approach could be used to also change from position: absolute to position: fixed for certain elements. This sort of thing is something I could see moving into the core library, but I want to do it cleanly.
The scrolling area touch-event hack is necessary on iOS and Android<2.3, but many devices support CSS position: fixed.
In my own testing, web applications have much better performance characteristics for content in the scrolling pane. I've noticed that the web forms kitchen-sink widgets' animations are smoother when compared to the touch-event hacked technique.
This might be a solution to:
#22
The text was updated successfully, but these errors were encountered: