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

Side by Side Diff: third_party/WebKit/Source/core/paint/PaintLayer.cpp

Issue 1945983002: Set layers needsRepaint along the original compositingContainer chain if stacking status changes (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@2704
Patch Set: Created 4 years, 7 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 unified diff | Download patch
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2006, 2007, 2008, 2009, 2010, 2011, 2012 Apple Inc. All rights reserved. 2 * Copyright (C) 2006, 2007, 2008, 2009, 2010, 2011, 2012 Apple Inc. All rights reserved.
3 * 3 *
4 * Portions are Copyright (C) 1998 Netscape Communications Corporation. 4 * Portions are Copyright (C) 1998 Netscape Communications Corporation.
5 * 5 *
6 * Other contributors: 6 * Other contributors:
7 * Robert O'Callahan <roc+@cs.cmu.edu> 7 * Robert O'Callahan <roc+@cs.cmu.edu>
8 * David Baron <dbaron@fas.harvard.edu> 8 * David Baron <dbaron@fas.harvard.edu>
9 * Christian Biesinger <cbiesinger@web.de> 9 * Christian Biesinger <cbiesinger@web.de>
10 * Randall Jesup <rjesup@wgate.com> 10 * Randall Jesup <rjesup@wgate.com>
(...skipping 1310 matching lines...) Expand 10 before | Expand all | Expand 10 after
1321 curr->moveLayers(m_parent, this); 1321 curr->moveLayers(m_parent, this);
1322 1322
1323 // If the previous paint invalidation container is not a stacking context an d this object is 1323 // If the previous paint invalidation container is not a stacking context an d this object is
1324 // stacked content, creating this layer may cause this object and its descen dants to change 1324 // stacked content, creating this layer may cause this object and its descen dants to change
1325 // paint invalidation container. 1325 // paint invalidation container.
1326 bool didSetPaintInvalidation = false; 1326 bool didSetPaintInvalidation = false;
1327 if (!RuntimeEnabledFeatures::slimmingPaintV2Enabled() && !layoutObject()->is LayoutView() && layoutObject()->isRooted() && layoutObject()->styleRef().isStack ed()) { 1327 if (!RuntimeEnabledFeatures::slimmingPaintV2Enabled() && !layoutObject()->is LayoutView() && layoutObject()->isRooted() && layoutObject()->styleRef().isStack ed()) {
1328 const LayoutBoxModelObject& previousPaintInvalidationContainer = layoutO bject()->parent()->containerForPaintInvalidation(); 1328 const LayoutBoxModelObject& previousPaintInvalidationContainer = layoutO bject()->parent()->containerForPaintInvalidation();
1329 if (!previousPaintInvalidationContainer.styleRef().isStackingContext()) { 1329 if (!previousPaintInvalidationContainer.styleRef().isStackingContext()) {
1330 layoutObject()->invalidatePaintIncludingNonSelfPaintingLayerDescenda nts(previousPaintInvalidationContainer); 1330 layoutObject()->invalidatePaintIncludingNonSelfPaintingLayerDescenda nts(previousPaintInvalidationContainer);
1331 // Set needsRepaint along the original compositingContainer chain.
1332 layoutObject()->parent()->enclosingLayer()->setNeedsRepaint();
1331 didSetPaintInvalidation = true; 1333 didSetPaintInvalidation = true;
1332 } 1334 }
1333 } 1335 }
1334 1336
1335 if (!didSetPaintInvalidation && isSelfPaintingLayer()) { 1337 if (!didSetPaintInvalidation && isSelfPaintingLayer()) {
1336 if (PaintLayer* enclosingSelfPaintingLayer = m_parent->enclosingSelfPain tingLayer()) 1338 if (PaintLayer* enclosingSelfPaintingLayer = m_parent->enclosingSelfPain tingLayer())
1337 mergeNeedsPaintPhaseFlagsFrom(*enclosingSelfPaintingLayer); 1339 mergeNeedsPaintPhaseFlagsFrom(*enclosingSelfPaintingLayer);
1338 } 1340 }
1339 1341
1340 // Clear out all the clip rects. 1342 // Clear out all the clip rects.
(...skipping 1572 matching lines...) Expand 10 before | Expand all | Expand 10 after
2913 2915
2914 void showLayerTree(const blink::LayoutObject* layoutObject) 2916 void showLayerTree(const blink::LayoutObject* layoutObject)
2915 { 2917 {
2916 if (!layoutObject) { 2918 if (!layoutObject) {
2917 fprintf(stderr, "Cannot showLayerTree. Root is (nil)\n"); 2919 fprintf(stderr, "Cannot showLayerTree. Root is (nil)\n");
2918 return; 2920 return;
2919 } 2921 }
2920 showLayerTree(layoutObject->enclosingLayer()); 2922 showLayerTree(layoutObject->enclosingLayer());
2921 } 2923 }
2922 #endif 2924 #endif
OLDNEW
« no previous file with comments | « third_party/WebKit/LayoutTests/paint/invalidation/relative-position-under-composited-scroll-expected.html ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698