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

Issue 2826893003: Remove ScrollableArea::GetFrameViewBase and move ScheduleAnimation into subclasses. (Closed)

Created:
3 years, 8 months ago by joelhockey
Modified:
3 years, 8 months ago
Reviewers:
haraken, slangley, dcheng
CC:
darktears, blink-reviews, blink-reviews-animation_chromium.org, blink-reviews-frames_chromium.org, blink-reviews-paint_chromium.org, chromium-reviews, dshwang, krit, Eric Willigers, fmalita+watch_chromium.org, fs, gyuyoung2, kinuko+watch, kouhei+svg_chromium.org, pdr+svgwatchlist_chromium.org, rjwright, rwlbuis, Stephen Chennney, shans
Target Ref:
refs/heads/master
Project:
chromium
Visibility:
Public.

Description

Remove ScrollableArea::GetFrameViewBase and move ScrollableArea::ScheduleAnimation into subclasses. This is part of an overall effort to remove the FrameViewBase (old Widget) class. This change helps to remove an unneeded reference. ScrollableArea implemented ScheduleAnimation by defining GetFrameViewBase that subclasses could implement. The alternative implementation is for subclasses to implement ScheduleAnimation and then there is no need for the awkward reference to FrameViewBase. I have added ScheduleAnimation into LocalFrame which is the core class required by HostWindow/ChromeClientImpl. All subclasses of ScrollableArea now implement ScheduleAnimation by calling it on their local reference to LocalFrame. BUG=637460 CQ_INCLUDE_TRYBOTS=master.tryserver.chromium.linux:linux_layout_tests_slimming_paint_v2 Review-Url: https://codereview.chromium.org/2826893003 Cr-Commit-Position: refs/heads/master@{#465546} Committed: https://chromium.googlesource.com/chromium/src/+/c00bae0bd50204fc323a37c28f9e77b39c8dc376

Patch Set 1 #

Patch Set 2 : After rebase #

Patch Set 3 : Remove UNREACHED #

Total comments: 14
Unified diffs Side-by-side diffs Delta from patch set Stats (+46 lines, -49 lines) Patch
M third_party/WebKit/Source/core/frame/FrameView.h View 1 chunk +1 line, -1 line 0 comments Download
M third_party/WebKit/Source/core/frame/FrameView.cpp View 2 chunks +4 lines, -4 lines 2 comments Download
M third_party/WebKit/Source/core/frame/FrameViewTest.cpp View 1 chunk +1 line, -1 line 2 comments Download
M third_party/WebKit/Source/core/frame/LocalFrame.h View 2 chunks +3 lines, -0 lines 0 comments Download
M third_party/WebKit/Source/core/frame/LocalFrame.cpp View 2 chunks +9 lines, -0 lines 6 comments Download
M third_party/WebKit/Source/core/frame/RootFrameViewport.h View 1 2 1 chunk +0 lines, -1 line 0 comments Download
M third_party/WebKit/Source/core/frame/RootFrameViewport.cpp View 1 chunk +0 lines, -4 lines 0 comments Download
M third_party/WebKit/Source/core/frame/VisualViewport.h View 1 chunk +1 line, -1 line 0 comments Download
M third_party/WebKit/Source/core/frame/VisualViewport.cpp View 1 chunk +2 lines, -2 lines 0 comments Download
M third_party/WebKit/Source/core/loader/EmptyClients.h View 1 chunk +1 line, -1 line 0 comments Download
M third_party/WebKit/Source/core/page/AutoscrollController.cpp View 1 chunk +4 lines, -3 lines 0 comments Download
M third_party/WebKit/Source/core/page/PageAnimator.cpp View 1 chunk +1 line, -1 line 0 comments Download
M third_party/WebKit/Source/core/paint/PaintLayerScrollableArea.h View 1 chunk +1 line, -1 line 0 comments Download
M third_party/WebKit/Source/core/paint/PaintLayerScrollableArea.cpp View 1 chunk +2 lines, -2 lines 0 comments Download
M third_party/WebKit/Source/core/svg/graphics/SVGImageChromeClient.h View 1 chunk +1 line, -1 line 0 comments Download
M third_party/WebKit/Source/core/svg/graphics/SVGImageChromeClient.cpp View 1 chunk +1 line, -1 line 0 comments Download
M third_party/WebKit/Source/platform/HostWindow.h View 2 chunks +2 lines, -1 line 2 comments Download
M third_party/WebKit/Source/platform/scroll/ScrollableArea.h View 1 2 2 chunks +1 line, -4 lines 0 comments Download
M third_party/WebKit/Source/platform/scroll/ScrollableArea.cpp View 1 chunk +0 lines, -8 lines 0 comments Download
M third_party/WebKit/Source/web/ChromeClientImpl.h View 1 chunk +1 line, -1 line 0 comments Download
M third_party/WebKit/Source/web/ChromeClientImpl.cpp View 1 chunk +2 lines, -5 lines 0 comments Download
M third_party/WebKit/Source/web/InspectorOverlay.cpp View 1 2 chunks +7 lines, -5 lines 2 comments Download
M third_party/WebKit/Source/web/WebPagePopupImpl.cpp View 1 chunk +1 line, -1 line 0 comments Download

Messages

Total messages: 31 (22 generated)
slangley
lgtm https://codereview.chromium.org/2826893003/diff/40001/third_party/WebKit/Source/core/frame/FrameViewTest.cpp File third_party/WebKit/Source/core/frame/FrameViewTest.cpp (right): https://codereview.chromium.org/2826893003/diff/40001/third_party/WebKit/Source/core/frame/FrameViewTest.cpp#newcode48 third_party/WebKit/Source/core/frame/FrameViewTest.cpp:48: } add vertical whitespace? https://codereview.chromium.org/2826893003/diff/40001/third_party/WebKit/Source/core/frame/LocalFrame.cpp File third_party/WebKit/Source/core/frame/LocalFrame.cpp (right): ...
3 years, 8 months ago (2017-04-19 07:15:45 UTC) #13
joelhockey
https://codereview.chromium.org/2826893003/diff/40001/third_party/WebKit/Source/core/frame/FrameViewTest.cpp File third_party/WebKit/Source/core/frame/FrameViewTest.cpp (right): https://codereview.chromium.org/2826893003/diff/40001/third_party/WebKit/Source/core/frame/FrameViewTest.cpp#newcode48 third_party/WebKit/Source/core/frame/FrameViewTest.cpp:48: } On 2017/04/19 at 07:15:45, slangley wrote: > add ...
3 years, 8 months ago (2017-04-19 07:20:47 UTC) #14
joelhockey
dcheng@, haraken@, ptal
3 years, 8 months ago (2017-04-19 07:22:52 UTC) #16
haraken
LGTM with comments. You can address the comments in follow-up CLs. https://codereview.chromium.org/2826893003/diff/40001/third_party/WebKit/Source/core/frame/FrameView.cpp File third_party/WebKit/Source/core/frame/FrameView.cpp (right): ...
3 years, 8 months ago (2017-04-19 09:44:07 UTC) #21
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/2826893003/40001
3 years, 8 months ago (2017-04-19 10:17:19 UTC) #25
commit-bot: I haz the power
Committed patchset #3 (id:40001) as https://chromium.googlesource.com/chromium/src/+/c00bae0bd50204fc323a37c28f9e77b39c8dc376
3 years, 8 months ago (2017-04-19 10:22:04 UTC) #28
joelhockey
https://codereview.chromium.org/2826893003/diff/40001/third_party/WebKit/Source/core/frame/FrameView.cpp File third_party/WebKit/Source/core/frame/FrameView.cpp (right): https://codereview.chromium.org/2826893003/diff/40001/third_party/WebKit/Source/core/frame/FrameView.cpp#newcode2750 third_party/WebKit/Source/core/frame/FrameView.cpp:2750: bool FrameView::ScheduleAnimation() { On 2017/04/19 at 09:44:07, haraken wrote: ...
3 years, 8 months ago (2017-04-19 10:27:54 UTC) #29
dcheng
https://codereview.chromium.org/2826893003/diff/40001/third_party/WebKit/Source/core/frame/LocalFrame.cpp File third_party/WebKit/Source/core/frame/LocalFrame.cpp (right): https://codereview.chromium.org/2826893003/diff/40001/third_party/WebKit/Source/core/frame/LocalFrame.cpp#newcode876 third_party/WebKit/Source/core/frame/LocalFrame.cpp:876: bool LocalFrame::ScheduleAnimation(HostWindow* window) { Can we avoid plumbing HostWindow* ...
3 years, 8 months ago (2017-04-19 11:26:25 UTC) #30
joelhockey
3 years, 8 months ago (2017-04-19 11:33:18 UTC) #31
Message was sent while issue was closed.
https://codereview.chromium.org/2826893003/diff/40001/third_party/WebKit/Sour...
File third_party/WebKit/Source/core/frame/LocalFrame.cpp (right):

https://codereview.chromium.org/2826893003/diff/40001/third_party/WebKit/Sour...
third_party/WebKit/Source/core/frame/LocalFrame.cpp:876: bool
LocalFrame::ScheduleAnimation(HostWindow* window) {
On 2017/04/19 at 11:26:25, dcheng (OOO through May 2) wrote:
> Can we avoid plumbing HostWindow* through here?

Yes, I've fixed this in https://codereview.chromium.org/2829613002

https://codereview.chromium.org/2826893003/diff/40001/third_party/WebKit/Sour...
File third_party/WebKit/Source/platform/HostWindow.h (right):

https://codereview.chromium.org/2826893003/diff/40001/third_party/WebKit/Sour...
third_party/WebKit/Source/platform/HostWindow.h:59: virtual void
ScheduleAnimation(LocalFrame*) = 0;
On 2017/04/19 at 11:26:25, dcheng (OOO through May 2) wrote:
> The reason we didn't plumb through Frame to begin with is because HostWindow
is in platform and shouldn't know about frames.

Yes, that makes sense.

Could there be an empty PlatformFrame class in platform that
core/frame/LocalFrame extends?

https://codereview.chromium.org/2826893003/diff/40001/third_party/WebKit/Sour...
File third_party/WebKit/Source/web/InspectorOverlay.cpp (right):

https://codereview.chromium.org/2826893003/diff/40001/third_party/WebKit/Sour...
third_party/WebKit/Source/web/InspectorOverlay.cpp:406: // TODO(joelhockey):
Remove this check once all tests pass.
On 2017/04/19 at 11:26:25, dcheng (OOO through May 2) wrote:
> I don't think I understand this comment. Presumably all the tests pass if this
CL landed?

Thanks for picking this up.  I'll send a fix now.

Powered by Google App Engine
This is Rietveld 408576698