Elements with overflow cannot be scrolled on device

Bug #1296468 reported by Robert Schroll
10
This bug affects 2 people
Affects Status Importance Assigned to Milestone
Ubuntu HTML5 UI SDK
Triaged
Undecided
Unassigned

Bug Description

When there is a single long list in an app, it can be scrolled by flicking on the device. But if there are two lists, absolutely positioned and set with overflow: auto, they cannot. On the desktop, both lists scroll. In a browser, they even get scrollbars. But on the device, they are stuck at the top. The attached test case demonstrates the problem.

Two caveats:
1) This is based only a testing on an emulator (r226). It seems to get flicks in other contexts, so I don't think it's an emulator issue. But if you test on a device and things work, then it must be.
2) I haven't tried other ways to position the lists, so I don't know how specific this problem is to the CSS I'm using.

Revision history for this message
Robert Schroll (rschroll) wrote :
Revision history for this message
Robert Schroll (rschroll) wrote :
Revision history for this message
Adnane Belmadiaf (daker) wrote :

Confirmed by Alan Pope, i am not really sure why this happening, i tested the code on Chrome & FF for Android and it works as expected.

Changed in ubuntu-html5-theme:
status: New → Triaged
Revision history for this message
Robert Schroll (rschroll) wrote :

I don't think the absolute positioning is actually coming into play. The problem seems to be that elements with overflow can't be scrolled by flicking. The attached test case give just a single list that's in the default flow of the document. It's in a container with a fixed height and overflow: scroll. It cannot be scrolled on the emulator.

Revision history for this message
Robert Schroll (rschroll) wrote :
summary: - Absolutely positioned lists cannot be scrolled on device
+ Elements with overflow cannot be scrolled on device
Revision history for this message
Adnane Belmadiaf (daker) wrote :

I think this is a qtwebkit bug, the same code works on Chrome and FF for android

Revision history for this message
Robert Schroll (rschroll) wrote :

In case anyone else is trying to work around this bug, here's the kludge I came up with: https://github.com/rschroll/crosswords/commit/ed96ec1030744eea255164d8a5ac4e4aa2cb3618. It uses hammer.js to detect drags and scroll the elements in response. It's not general or robust, but it works for my purposes.

Revision history for this message
Daniel Beck (d-danielbeck) wrote :

I observed the same problem. The problem also happens when the position is set to absolute.

This behavior makes developing games with javascript and DOM manipulations quite difficult, because games often use absolute or fixed positioning.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.