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

Issue 2942163002: [Refactor] Moved scrollbar creation and deletion to ScrollbarManager (Closed)

Created:
3 years, 6 months ago by chaopeng
Modified:
3 years, 4 months ago
Reviewers:
bokan, skobes, szager1
CC:
chromium-reviews, blink-reviews, blink-reviews-frames_chromium.org, dshwang, kinuko+watch, blink-reviews-paint_chromium.org
Target Ref:
refs/heads/master
Project:
chromium
Visibility:
Public.

Description

[Refactor] Moved scrollbar creation and deletion to ScrollbarManager We're currently in a limbo state where PLSA and FrameView each have their own version of a ScrollbarManager that's slightly different. This patch is a stepping on the way to moving scrollbar management out of ScrollableArea and into a single ScrollbarManager. This will make it cleaner to administer scrollbars directly from the RootFrameViewport and fix the blocking bugs on the linked bug. BUG=661236 CQ_INCLUDE_TRYBOTS=master.tryserver.chromium.linux:linux_layout_tests_slimming_paint_v2

Patch Set 1 #

Patch Set 2 : Move destroy scrollbar to scrollbar manager #

Patch Set 3 : change ShouldUseCustomScrollbars #

Total comments: 9

Patch Set 4 : bokan and skobes comments addressed #

Unified diffs Side-by-side diffs Delta from patch set Stats (+161 lines, -190 lines) Patch
M third_party/WebKit/Source/core/frame/LocalFrameView.h View 1 2 3 5 chunks +2 lines, -16 lines 0 comments Download
M third_party/WebKit/Source/core/frame/LocalFrameView.cpp View 1 2 3 7 chunks +13 lines, -72 lines 0 comments Download
M third_party/WebKit/Source/core/layout/LayoutObject.h View 1 2 3 1 chunk +2 lines, -0 lines 0 comments Download
M third_party/WebKit/Source/core/layout/LayoutObject.cpp View 1 2 3 1 chunk +4 lines, -0 lines 0 comments Download
M third_party/WebKit/Source/core/paint/PaintLayerScrollableArea.h View 1 2 3 3 chunks +3 lines, -4 lines 0 comments Download
M third_party/WebKit/Source/core/paint/PaintLayerScrollableArea.cpp View 1 2 3 7 chunks +59 lines, -93 lines 0 comments Download
M third_party/WebKit/Source/core/paint/ScrollbarManager.h View 1 1 chunk +3 lines, -5 lines 0 comments Download
M third_party/WebKit/Source/core/paint/ScrollbarManager.cpp View 1 2 3 2 chunks +65 lines, -0 lines 0 comments Download
M third_party/WebKit/Source/platform/scroll/ScrollableArea.h View 1 2 3 1 chunk +6 lines, -0 lines 0 comments Download
M third_party/WebKit/Source/platform/scroll/ScrollableArea.cpp View 1 2 3 2 chunks +4 lines, -0 lines 0 comments Download

Messages

Total messages: 83 (59 generated)
chaopeng
bokan@ PTAL. Thank you.
3 years, 5 months ago (2017-06-26 18:15:36 UTC) #53
bokan
Please add more detail/context to the commit message. +skobes,szager as FYI https://codereview.chromium.org/2942163002/diff/140001/third_party/WebKit/Source/core/frame/LocalFrameView.cpp File third_party/WebKit/Source/core/frame/LocalFrameView.cpp (right): ...
3 years, 5 months ago (2017-06-27 17:48:52 UTC) #54
skobes
What is the benefit of this change?
3 years, 5 months ago (2017-06-27 18:07:33 UTC) #56
bokan
On 2017/06/27 18:07:33, skobes wrote: > What is the benefit of this change? We're currently ...
3 years, 5 months ago (2017-06-27 18:31:37 UTC) #57
skobes
On 2017/06/27 18:31:37, bokan wrote: > We're currently in a limbo state where PLSA and ...
3 years, 5 months ago (2017-06-27 18:48:15 UTC) #58
bokan
On 2017/06/27 18:48:15, skobes wrote: > On 2017/06/27 18:31:37, bokan wrote: > > We're currently ...
3 years, 5 months ago (2017-06-27 18:56:51 UTC) #59
szager1
Can you move ScrollbarManager to platform/scroll? That seems like a better place for it.
3 years, 5 months ago (2017-06-27 20:36:48 UTC) #61
szager1
https://codereview.chromium.org/2942163002/diff/140001/third_party/WebKit/Source/core/paint/ScrollbarManager.cpp File third_party/WebKit/Source/core/paint/ScrollbarManager.cpp (right): https://codereview.chromium.org/2942163002/diff/140001/third_party/WebKit/Source/core/paint/ScrollbarManager.cpp#newcode36 third_party/WebKit/Source/core/paint/ScrollbarManager.cpp:36: Scrollbar* ScrollbarManager::CreateScrollbar(ScrollbarOrientation orientation) { All of this logic could ...
3 years, 5 months ago (2017-06-27 20:42:13 UTC) #62
skobes
On 2017/06/27 20:36:48, szager1 wrote: > Can you move ScrollbarManager to platform/scroll? That seems like ...
3 years, 5 months ago (2017-06-27 20:43:14 UTC) #63
szager1
On 2017/06/27 20:43:14, skobes wrote: > On 2017/06/27 20:36:48, szager1 wrote: > > Can you ...
3 years, 5 months ago (2017-06-27 20:57:16 UTC) #64
bokan
On 2017/06/27 20:42:13, szager1 wrote: > https://codereview.chromium.org/2942163002/diff/140001/third_party/WebKit/Source/core/paint/ScrollbarManager.cpp > File third_party/WebKit/Source/core/paint/ScrollbarManager.cpp (right): > > https://codereview.chromium.org/2942163002/diff/140001/third_party/WebKit/Source/core/paint/ScrollbarManager.cpp#newcode36 > ...
3 years, 5 months ago (2017-06-27 20:59:05 UTC) #65
szager1
On 2017/06/27 20:57:16, szager1 wrote: > platform/ > class ScrollableArea { > virtual Scrollbar* CreateScrollbar(...)=0; ...
3 years, 5 months ago (2017-06-27 21:02:45 UTC) #66
szager1
On 2017/06/27 20:59:05, bokan wrote: > On 2017/06/27 20:42:13, szager1 wrote: > > > https://codereview.chromium.org/2942163002/diff/140001/third_party/WebKit/Source/core/paint/ScrollbarManager.cpp ...
3 years, 5 months ago (2017-06-27 21:08:52 UTC) #68
bokan
On 2017/06/27 21:08:52, szager1 wrote: > On 2017/06/27 20:59:05, bokan wrote: > > On 2017/06/27 ...
3 years, 5 months ago (2017-06-27 21:16:22 UTC) #69
skobes
My two cents: I find the platform/core boundary unnatural and inconvenient. I'd recommend putting new ...
3 years, 5 months ago (2017-06-27 21:44:07 UTC) #72
szager1
On 2017/06/27 21:16:22, bokan wrote: > On 2017/06/27 21:08:52, szager1 wrote: > > On 2017/06/27 ...
3 years, 5 months ago (2017-06-27 21:55:16 UTC) #73
szager1
On 2017/06/27 21:44:07, skobes wrote: > My two cents: I find the platform/core boundary unnatural ...
3 years, 5 months ago (2017-06-27 22:00:27 UTC) #74
skobes
Maybe ScrollbarManager can fulfill its original purpose in platform, but it sounds like we want ...
3 years, 5 months ago (2017-06-27 22:26:13 UTC) #77
szager1
On 2017/06/27 22:26:13, skobes wrote: > Maybe ScrollbarManager can fulfill its original purpose in platform, ...
3 years, 5 months ago (2017-06-27 22:27:56 UTC) #78
bokan
On 2017/06/27 21:55:16, szager1 wrote: > On 2017/06/27 21:16:22, bokan wrote: > > On 2017/06/27 ...
3 years, 5 months ago (2017-06-27 22:33:34 UTC) #79
bokan
On 2017/06/27 22:27:56, szager1 wrote: > On 2017/06/27 22:26:13, skobes wrote: > > Maybe ScrollbarManager ...
3 years, 5 months ago (2017-06-27 22:38:27 UTC) #80
szager1
On 2017/06/27 22:33:34, bokan wrote: > On 2017/06/27 21:55:16, szager1 wrote: > > On 2017/06/27 ...
3 years, 5 months ago (2017-06-28 00:24:35 UTC) #81
szager1
On 2017/06/27 22:38:27, bokan wrote: > On 2017/06/27 22:27:56, szager1 wrote: > > On 2017/06/27 ...
3 years, 5 months ago (2017-06-28 00:26:35 UTC) #82
bokan
3 years, 5 months ago (2017-06-28 16:38:48 UTC) #83
On 2017/06/28 00:26:35, szager1 wrote:
> On 2017/06/27 22:38:27, bokan wrote:
> > On 2017/06/27 22:27:56, szager1 wrote:
> > > On 2017/06/27 22:26:13, skobes wrote:
> > > > Maybe ScrollbarManager can fulfill its original purpose in platform, but
> it
> > > > sounds like we want to expand the scope of its responsibilities. 
> Scrollbar
> > > > management is closely connected to layout in general, so we are going to
> > have
> > > > some code for it in core no matter what.  The question is whether to
keep
> it
> > > in
> > > > FrameView/PLSA, or move it into ScrollbarManager.  If we're moving it
into
> > > > ScrollbarManager then ScrollbarManager needs to be in core.
> > > 
> > > Aside from Scrollbar creation/destruction, what core/ functionality do we
> want
> > > ScrollbarManager to assume?
> > 
> > State management. i.e. when the scroll position or geometry in a
> ScrollableArea
> > changes, it notifies the manager which then updates the scrollbars. All
> > scrollbar event handling today is done in Blink so that also needs to stay
in
> > core/. There's a bunch of bugs around scrollbars in the RFV today because
it's
> > not easy to decouple the scrollbars from the main FrameView (i.e. we can't
> > really apply the pinch-zoom transformation so input handling is busted when
> > zoomed).
> 
> I don't know this stuff enough to comment on it.  Would this really be worse
> with ScrollbarManager in platform/?

hmm...I'll need to mull it over for a day or so, I'll get back to you.

Powered by Google App Engine
This is Rietveld 408576698