Closed
Bug 585680
Opened 15 years ago
Closed 13 years ago
Allow scrollable views to scroll past the end of content
Categories
(Core :: Layout, defect)
Core
Layout
Tracking
()
RESOLVED
WONTFIX
Tracking | Status | |
---|---|---|
fennec | - | --- |
People
(Reporter: mfinkle, Unassigned)
References
(Blocks 1 open bug)
Details
Attachments
(1 file, 1 obsolete file)
4.67 KB,
patch
|
Details | Diff | Splinter Review |
We have a have issues with scrolling on mobile devices:
* Most mobile OSes allow for scrolling past the end of the content (web or XUL) and then the content will snap back when the user releases
* Some mobile OSes float virtual keyboards over content, but do not resize the actual application window. In order to scroll any textbox or focusable elements at the bottom of the page into view, we may need to scroll the content past the end of the page.
Both of these uses cases are currently out of our grasp since the scrollable view will cease scrolling when it reaches the end of the content.
Updated•15 years ago
|
OS: Mac OS X → All
Hardware: x86 → All
OK.
You want to change nsGfxScrollFrameInner::GetScrolledRectInternal to add some height to the returned rectangle. That basically work. There might be some assertions or assumptions that we break, but a quick look at the code doesn't show me any.
Reporter | ||
Comment 2•15 years ago
|
||
I was playing around with this bug and tried this change to nsGfxScrollFrameInner::GetScrolledRectInternal:
+ return nsRect(x1, y1, (x2 - x1) + aScrollPortSize.width, (y2 - y1) + aScrollPortSize.height);
- return nsRect(x1, y1, x2 - x1, y2 - y1);
It seemed to work exactly the way I wanted. I could scroll content of anything a full viewport width (or height) beyond the content. I will try to use attributes or CSS properties to control the amount to over scroll in the x and y directions.
In Fennec, the browser content, drawn to the canvas was changed. It was like the extra scroll extent was used to create the document bounding rect or something. Since we try to render the entire content area in the canvas tiles, I saw a lot of whitespace to the right and below the real web content.
Updated•15 years ago
|
tracking-fennec: --- → ?
Reporter | ||
Comment 3•15 years ago
|
||
Maybe an "overScrollBy" API would be better. Android has one:
http://developer.android.com/reference/android/view/View.html#overScrollBy%28int,%20int,%20int,%20int,%20int,%20int,%20int,%20int,%20boolean%29
Updated•15 years ago
|
tracking-fennec: ? → 2.0-
Reporter | ||
Updated•14 years ago
|
tracking-fennec: 2.0- → 2.0next+
Blocks: 649051
Updated•14 years ago
|
Assignee: nobody → ben
Updated•14 years ago
|
tracking-fennec: 2.0next+ → 6+
Reporter | ||
Updated•14 years ago
|
tracking-fennec: 6+ → 7+
Updated•14 years ago
|
tracking-fennec: 7+ → +
Comment 4•14 years ago
|
||
Matt, is this what is needed for the front end?
Assignee: ben → blassey.bugs
Attachment #553799 -
Flags: feedback?(mbrubeck)
Comment 5•14 years ago
|
||
Comment on attachment 553799 [details] [diff] [review]
patch
Yes, this looks good for our use cases.
Attachment #553799 -
Flags: feedback?(mbrubeck) → feedback+
Comment 6•14 years ago
|
||
layout/xul/base/public/nsIScrollBoxObject.idl needs an IID rev.
Comment 7•14 years ago
|
||
Attachment #553799 -
Attachment is obsolete: true
Attachment #553864 -
Flags: review?(roc)
How does this interact with scrollbar rendering?
What happens if you're overscrolled and a reflow occurs in the content? Seems to me the reflow will snap you back into range, which you probably don't want.
Comment 9•14 years ago
|
||
Madhava, are we going to want overscroll for iframes? If not, I'll probably just cancel this review. If so, I need to figure out answers to roc's questions.
Comment 10•14 years ago
|
||
(In reply to Brad Lassey [:blassey] from comment #9)
> Madhava, are we going to want overscroll for iframes? If not, I'll probably
> just cancel this review. If so, I need to figure out answers to roc's
> questions.
I guess for mobile you don't need that anymore since you have moved to native widgets, but for B2G it will be nice to have overscroll - even for scrollable views that are not iframes.
Would still be desired for scrollable areas inside Web pages, wouldn't it?
Comment 12•14 years ago
|
||
(In reply to Vivien Nicolas (:vingtetun) from comment #10)
> (In reply to Brad Lassey [:blassey] from comment #9)
> > Madhava, are we going to want overscroll for iframes? If not, I'll probably
> > just cancel this review. If so, I need to figure out answers to roc's
> > questions.
>
> I guess for mobile you don't need that anymore since you have moved to
> native widgets, but for B2G it will be nice to have overscroll - even for
> scrollable views that are not iframes.
Would there be any compatibility concerns with enabling this for iframes & overflow:scroll regions? Seems like overscrolling might reveal some content that the page author didn't intend.
Comment 13•14 years ago
|
||
(In reply to Rob Arnold [:robarnold] from comment #12)
> (In reply to Vivien Nicolas (:vingtetun) from comment #10)
> > (In reply to Brad Lassey [:blassey] from comment #9)
> > > Madhava, are we going to want overscroll for iframes? If not, I'll probably
> > > just cancel this review. If so, I need to figure out answers to roc's
> > > questions.
> >
> > I guess for mobile you don't need that anymore since you have moved to
> > native widgets, but for B2G it will be nice to have overscroll - even for
> > scrollable views that are not iframes.
>
> Would there be any compatibility concerns with enabling this for iframes &
> overflow:scroll regions? Seems like overscrolling might reveal some content
> that the page author didn't intend.
From what I understand of the patch there is a new scrollable.overScrollBy(x, y) method. If the web author did not use it there will be no overscroll of the iframe/overflow:scroll regions of the page.
(In reply to Robert O'Callahan (:roc) (Mozilla Corporation) from comment #11)
> Would still be desired for scrollable areas inside Web pages, wouldn't it?
Sorry I didn't realize this question was for me. B2G probably wants scrollable area inside iframes since application are nested iframes and the web browser will be a kind of iframe inside an other iframe.
Comment 14•14 years ago
|
||
(In reply to Vivien Nicolas (:vingtetun) from comment #13)
> (In reply to Rob Arnold [:robarnold] from comment #12)
> > (In reply to Vivien Nicolas (:vingtetun) from comment #10)
> > > (In reply to Brad Lassey [:blassey] from comment #9)
> > > > Madhava, are we going to want overscroll for iframes? If not, I'll probably
> > > > just cancel this review. If so, I need to figure out answers to roc's
> > > > questions.
> > >
> > > I guess for mobile you don't need that anymore since you have moved to
> > > native widgets, but for B2G it will be nice to have overscroll - even for
> > > scrollable views that are not iframes.
> >
> > Would there be any compatibility concerns with enabling this for iframes &
> > overflow:scroll regions? Seems like overscrolling might reveal some content
> > that the page author didn't intend.
>
>
> From what I understand of the patch there is a new
> scrollable.overScrollBy(x, y) method. If the web author did not use it there
> will be no overscroll of the iframe/overflow:scroll regions of the page.
Ah ok. I thought this was about overscrolling in response to mouse wheel events or inertial scrolling.
(In reply to Rob Arnold [:robarnold] from comment #12)
> Would there be any compatibility concerns with enabling this for iframes &
> overflow:scroll regions? Seems like overscrolling might reveal some content
> that the page author didn't intend.
For LTR content, Web authors already can't prevent users from scrolling as far right or down as the content extends. So the only new issue would be if there's content above or to the left of the origin. Sometimes authors shove things there to hide them, but usually they put it quite far off to make sure it doesn't accidentally intrude on the page. I could be wrong, but personally I wouldn't worry about it.
Comment 16•13 years ago
|
||
Comment on attachment 553864 [details] [diff] [review]
patch with uuid rev'd
its not clear that this is needed anymore
Attachment #553864 -
Flags: review?(roc)
Updated•13 years ago
|
Assignee: blassey.bugs → nobody
Comment 17•13 years ago
|
||
don't want this
Status: NEW → RESOLVED
tracking-fennec: + → -
Closed: 13 years ago
Resolution: --- → WONTFIX
You need to log in
before you can comment on or make changes to this bug.
Description
•