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

Unified Diff: third_party/WebKit/Source/core/frame/FrameView.cpp

Issue 2198853002: Draw main frame custom scrollbars in root layer scrolling mode. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: addressed review comments Created 4 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/Source/core/frame/FrameView.cpp
diff --git a/third_party/WebKit/Source/core/frame/FrameView.cpp b/third_party/WebKit/Source/core/frame/FrameView.cpp
index 3b1b7cc80d33f2edf14595b69711e9ab47901362..c9d8bb787ff2370223ee28363abbeb0beae9371f 100644
--- a/third_party/WebKit/Source/core/frame/FrameView.cpp
+++ b/third_party/WebKit/Source/core/frame/FrameView.cpp
@@ -2679,14 +2679,19 @@ void FrameView::synchronizedPaint()
if (GraphicsLayer* rootGraphicsLayer = view.compositor()->rootGraphicsLayer()) {
synchronizedPaintRecursively(rootGraphicsLayer);
}
- if (GraphicsLayer* layerForHorizontalScrollbar = view.compositor()->layerForHorizontalScrollbar()) {
- synchronizedPaintRecursively(layerForHorizontalScrollbar);
- }
- if (GraphicsLayer* layerForVerticalScrollbar = view.compositor()->layerForVerticalScrollbar()) {
- synchronizedPaintRecursively(layerForVerticalScrollbar);
- }
- if (GraphicsLayer* layerForScrollCorner = view.compositor()->layerForScrollCorner()) {
- synchronizedPaintRecursively(layerForScrollCorner);
+
+ // TODO(sataya.m):Main frame doesn't create RootFrameViewport in some
+ // webkit_unit_tests (http://crbug.com/607987).
+ if (m_viewportScrollableArea) {
+ if (GraphicsLayer* layerForHorizontalScrollbar = m_viewportScrollableArea->layerForHorizontalScrollbar()) {
+ synchronizedPaintRecursively(layerForHorizontalScrollbar);
+ }
+ if (GraphicsLayer* layerForVerticalScrollbar = m_viewportScrollableArea->layerForVerticalScrollbar()) {
+ synchronizedPaintRecursively(layerForVerticalScrollbar);
+ }
+ if (GraphicsLayer* layerForScrollCorner = m_viewportScrollableArea->layerForScrollCorner()) {
+ synchronizedPaintRecursively(layerForScrollCorner);
+ }
}
forAllNonThrottledFrameViews([](FrameView& frameView) {

Powered by Google App Engine
This is Rietveld 408576698