Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(618)

Issue 2484563003: Determine the layoutobject of middleClickAutoscroll by the scroll direction. (Closed)

Created:
4 years, 1 month ago by sunyunjia
Modified:
4 years, 1 month ago
Reviewers:
bokan
CC:
chromium-reviews, pdr+renderingwatchlist_chromium.org, szager+layoutwatch_chromium.org, zoltan1, blink-reviews-layout_chromium.org, sof, eae+blinkwatch, leviw+renderwatch, blink-reviews-dom_chromium.org, dglazkov+blink, jchaffraix+rendering, blink-reviews, rwlbuis
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Determine the layoutobject of middleClickAutoscroll by the scroll direction. Previously, when middleClickAutoscroll is triggered, the layoutObject to be scrolled is only determined by the element clicked. However, if the layoutObject can be scrolled but not in the direction we want, the autoscroll could not be triggered. In this patch, we determine the layoutObject not only by the initial click position, but also the initial scroll direction. We also make sure that when the initial click position is in an iframe, the event will correctly propagate to its owner element. BUG=623366 Committed: https://crrev.com/e4af1f04e6a998799e2dab6633518470dc95d826 Cr-Commit-Position: refs/heads/master@{#432534}

Patch Set 1 #

Patch Set 2 : Add test. #

Patch Set 3 : Rename #

Total comments: 5

Patch Set 4 : Move the logic to AutoscrollController.cpp #

Total comments: 2

Patch Set 5 : Change the variable name #

Patch Set 6 : Better tests. #

Unified diffs Side-by-side diffs Delta from patch set Stats (+174 lines, -60 lines) Patch
A third_party/WebKit/LayoutTests/fast/events/middleClickAutoscroll-latching.html View 1 2 3 4 5 1 chunk +77 lines, -0 lines 0 comments Download
A third_party/WebKit/LayoutTests/fast/events/resources/middleClickAutoscroll-iframe.html View 1 2 1 chunk +4 lines, -0 lines 0 comments Download
M third_party/WebKit/Source/core/dom/Node.cpp View 1 2 3 1 chunk +11 lines, -5 lines 0 comments Download
M third_party/WebKit/Source/core/layout/LayoutBox.h View 1 2 3 1 chunk +0 lines, -1 line 0 comments Download
M third_party/WebKit/Source/core/layout/LayoutBox.cpp View 1 2 3 1 chunk +0 lines, -51 lines 0 comments Download
M third_party/WebKit/Source/core/page/AutoscrollController.h View 1 2 3 4 3 chunks +3 lines, -0 lines 0 comments Download
M third_party/WebKit/Source/core/page/AutoscrollController.cpp View 1 2 3 4 4 chunks +79 lines, -3 lines 0 comments Download

Messages

Total messages: 41 (29 generated)
sunyunjia
PTAL, thanks!
4 years, 1 month ago (2016-11-08 21:16:47 UTC) #12
bokan
https://codereview.chromium.org/2484563003/diff/40001/third_party/WebKit/LayoutTests/fast/events/middleClickAutoscroll-layoutObject.html File third_party/WebKit/LayoutTests/fast/events/middleClickAutoscroll-layoutObject.html (right): https://codereview.chromium.org/2484563003/diff/40001/third_party/WebKit/LayoutTests/fast/events/middleClickAutoscroll-layoutObject.html#newcode21 third_party/WebKit/LayoutTests/fast/events/middleClickAutoscroll-layoutObject.html:21: var startx = 100; It's hard to tell where ...
4 years, 1 month ago (2016-11-09 15:34:10 UTC) #15
sunyunjia
PTAL, thanks!
4 years, 1 month ago (2016-11-11 19:16:48 UTC) #19
bokan
Is there some kind of threshold you have to cross before we start autoscrolling in ...
4 years, 1 month ago (2016-11-11 19:48:46 UTC) #20
bokan
By the way, for future reference, when you do a rebase/merge it's helpful for reviewers ...
4 years, 1 month ago (2016-11-11 19:51:56 UTC) #21
sunyunjia
On 2016/11/11 19:48:46, bokan wrote: > Is there some kind of threshold you have to ...
4 years, 1 month ago (2016-11-13 23:22:55 UTC) #26
bokan
On 2016/11/13 23:22:55, sunyunjia wrote: > On 2016/11/11 19:48:46, bokan wrote: > > Is there ...
4 years, 1 month ago (2016-11-14 14:22:45 UTC) #29
sunyunjia
On 2016/11/14 14:22:45, bokan wrote: > On 2016/11/13 23:22:55, sunyunjia wrote: > > On 2016/11/11 ...
4 years, 1 month ago (2016-11-16 17:10:49 UTC) #34
bokan
On 2016/11/16 17:10:49, sunyunjia wrote: > On 2016/11/14 14:22:45, bokan wrote: > > On 2016/11/13 ...
4 years, 1 month ago (2016-11-16 17:13:30 UTC) #35
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2484563003/120001
4 years, 1 month ago (2016-11-16 17:17:40 UTC) #37
commit-bot: I haz the power
Committed patchset #6 (id:120001)
4 years, 1 month ago (2016-11-16 17:23:42 UTC) #39
commit-bot: I haz the power
4 years, 1 month ago (2016-11-16 17:48:55 UTC) #41
Message was sent while issue was closed.
Patchset 6 (id:??) landed as
https://crrev.com/e4af1f04e6a998799e2dab6633518470dc95d826
Cr-Commit-Position: refs/heads/master@{#432534}

Powered by Google App Engine
This is Rietveld 408576698