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

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

Issue 1526093006: Fix paint code so that overlays and views paint their own layers. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years 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 09546b9c07ab0bb84eb72169a14e49969e352496..93aade61f3fcfd4d48cf4bc614194e1c05122aa4 100644
--- a/third_party/WebKit/Source/core/frame/FrameView.cpp
+++ b/third_party/WebKit/Source/core/frame/FrameView.cpp
@@ -2439,14 +2439,17 @@ void FrameView::synchronizedPaint()
// or when the FrameView is the main frame view of a page overlay. The page overlay is in the layer tree of
// the host page and will be painted during synchronized painting of the host page.
if (GraphicsLayer* rootGraphicsLayer = view->compositor()->rootGraphicsLayer()) {
- // Find the real root GraphicsLayer because we also need to paint layers not under the root graphics layer of
- // the LayoutView, e.g. scrollbar layers created by PaintLayerCompositor and VisualViewport.
- // We could ask PaintLayerCompositor and VisualViewport for the real root GraphicsLayer, but the following loop
- // has the least dependency to those things which might change for slimming paint v2.
- while (GraphicsLayer* parent = rootGraphicsLayer->parent())
- rootGraphicsLayer = parent;
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);
+ }
forAllNonThrottledFrameViews([](FrameView& frameView) {
frameView.lifecycle().advanceTo(DocumentLifecycle::PaintClean);
« no previous file with comments | « third_party/WebKit/LayoutTests/TestExpectations ('k') | third_party/WebKit/Source/core/frame/VisualViewport.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698