Bug 68184 - Add an option to limit scrolling beyond end of page bounds when !constrainsScrollingToContentEdge() [work in progress]
Summary: Add an option to limit scrolling beyond end of page bounds when !constrainsSc...
Status: NEW
Alias: None
Product: WebKit
Classification: Unclassified
Component: New Bugs (show other bugs)
Version: 528+ (Nightly build)
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Fady Samuel
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-09-15 13:01 PDT by Fady Samuel
Modified: 2011-10-06 10:27 PDT (History)
12 users (show)

See Also:


Attachments
Patch (9.89 KB, patch)
2011-09-15 13:05 PDT, Fady Samuel
no flags Details | Formatted Diff | Diff
Patch (11.57 KB, patch)
2011-09-22 15:49 PDT, Fady Samuel
webkit.review.bot: commit-queue-
Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Fady Samuel 2011-09-15 13:01:07 PDT
Optionally Allow Scrolling Beyond End of Page Bounds
Comment 1 Fady Samuel 2011-09-15 13:05:14 PDT
Created attachment 107533 [details]
Patch
Comment 2 WebKit Review Bot 2011-09-15 13:07:42 PDT
Attachment 107533 [details] did not pass style-queue:

Failed to run "['Tools/Scripts/check-webkit-style', '--diff-files', u'Source/WebCore/ChangeLog', u'Source/WebCor..." exit_code: 1

Source/WebCore/platform/ScrollAnimatorNone.cpp:415:  One line control clauses should not use braces.  [whitespace/braces] [4]
Source/WebCore/platform/ScrollAnimatorNone.cpp:417:  One line control clauses should not use braces.  [whitespace/braces] [4]
Source/WebCore/platform/ScrollableArea.cpp:42:  Alphabetical sorting problem.  [build/include_order] [4]
Total errors found: 3 in 7 files


If any of these errors are false positives, please file a bug against check-webkit-style.
Comment 3 Alexey Proskuryakov 2011-09-15 15:49:09 PDT
Is this like elastic scrolling that's available in Safari on Lion? I don't know how that's implemented - is that unsuitable for other ports?
Comment 4 Fady Samuel 2011-09-15 16:00:05 PDT
(In reply to comment #3)
> Is this like elastic scrolling that's available in Safari on Lion? I don't know how that's implemented - is that unsuitable for other ports?

This is not elastic scrolling because this scrolling sticks. This patch is still a work-in-progress and is not yet ready for review.
Comment 5 Alexey Proskuryakov 2011-09-15 16:07:54 PDT
I'm just trying to help. Knowing that WebCore can already handle scrolling beyond page bounds (regardless of how scrolling animator returns you back afterwards) may help you find some existing code to reuse.
Comment 6 WebKit Review Bot 2011-09-15 16:16:54 PDT
Comment on attachment 107533 [details]
Patch

Attachment 107533 [details] did not pass chromium-ews (chromium-xvfb):
Output: http://queues.webkit.org/results/9686268

New failing tests:
scrollbars/scrollbar-miss-mousemove.html
fast/dom/vertical-scrollbar-in-rtl.html
fast/repaint/fixed-move-after-keyboard-scroll.html
Comment 7 Fady Samuel 2011-09-22 15:49:05 PDT
Created attachment 108413 [details]
Patch
Comment 8 Fady Samuel 2011-09-22 15:55:41 PDT
(In reply to comment #7)
> Created an attachment (id=108413) [details]
> Patch

Uploaded a patch with minor tweaks. The following are TODOs:

1. Chromium-WebKit API that gives access to this (probably in WebViewImpl.cpp).
2. Add support for this in layout tests perhaps window.internal or layoutTestController
3. Add a couple of layout tests (will look weird on BUILDS that don't have ENABLE(RUBBER_BANDING))
4. Hook into WebViewImpl::scrollFocusedNodeIntoRect to allow it to optionally scroll beyond the edges of the page: see https://bugs.webkit.org/show_bug.cgi?id=68192

dglazkov, thakis: Can you give me feedback before I jump in and do all this over the next day or two?
Comment 9 Nico Weber 2011-09-22 16:13:07 PDT
This feels a bit weird to me, but I think I'm not qualified enough in this area to comment either way.
Comment 10 James Robinson 2011-09-22 16:17:17 PDT
Is this the same thing as rubber-banding?
Comment 11 James Robinson 2011-09-22 16:18:10 PDT
(In reply to comment #10)
> Is this the same thing as rubber-banding?

Ah, I see this question has already been asked.  If it's not, then I have no idea what this feature is all about.  Could you please provide a bit more context about what this is?
Comment 12 WebKit Review Bot 2011-09-23 01:27:33 PDT
Comment on attachment 108413 [details]
Patch

Attachment 108413 [details] did not pass chromium-ews (chromium-xvfb):
Output: http://queues.webkit.org/results/9798638

New failing tests:
fast/events/touch/touch-target-limited.html
fast/events/wheelevent-in-horizontal-scrollbar-in-rtl.html
fast/dom/left-overflow-in-ltr.html
fast/dom/right-overflow-in-rtl.html
fast/events/reveal-link-when-focused.html
fast/forms/focus-selection-textarea.html
fast/overflow/overflow_hidden.html
fast/repaint/nested-iframe-scroll-inner.html
fast/dom/horizontal-scrollbar-when-dir-change.html
fast/events/autoscroll.html
fast/dom/focus-contenteditable.html
fast/dom/vertical-scrollbar-when-dir-change.html
fast/repaint/fixed-move-after-keyboard-scroll.html
fast/events/scroll-after-click-on-tab-index.html
fast/events/touch/touch-target.html
fast/forms/input-readonly-autoscroll.html
fast/repaint/nested-iframe-scroll-outer.html
fast/events/wheelevent-in-vertical-scrollbar-in-rtl.html
fast/events/scroll-in-scaled-page-with-overflow-hidden.html
fast/dom/vertical-scrollbar-in-rtl.html