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

Side by Side Diff: Source/core/rendering/RenderLayer.cpp

Issue 744313002: Need to reset enclosingPaginationLayer when a RenderLayer is removed from the tree. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Put the expectation file in the right directory. Created 6 years, 1 month 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
« no previous file with comments | « Source/core/rendering/RenderLayer.h ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 517 matching lines...) Expand 10 before | Expand all | Expand 10 after
528 for (RenderLayer* curr = parent(); curr; curr = curr->parent()) { 528 for (RenderLayer* curr = parent(); curr; curr = curr->parent()) {
529 if (curr->renderer()->hasColumns()) { 529 if (curr->renderer()->hasColumns()) {
530 m_isPaginated = checkContainingBlockChainForPagination(renderer(), c urr->renderBox()); 530 m_isPaginated = checkContainingBlockChainForPagination(renderer(), c urr->renderBox());
531 return; 531 return;
532 } 532 }
533 if (curr->stackingNode() == ancestorStackingContextNode) 533 if (curr->stackingNode() == ancestorStackingContextNode)
534 return; 534 return;
535 } 535 }
536 } 536 }
537 537
538 void RenderLayer::clearPaginationRecursive()
539 {
540 m_enclosingPaginationLayer = 0;
541 for (RenderLayer* child = firstChild(); child; child = child->nextSibling())
542 child->clearPaginationRecursive();
543 }
544
538 LayoutPoint RenderLayer::positionFromPaintInvalidationBacking(const RenderObject * renderObject, const RenderLayerModelObject* paintInvalidationContainer, const PaintInvalidationState* paintInvalidationState) 545 LayoutPoint RenderLayer::positionFromPaintInvalidationBacking(const RenderObject * renderObject, const RenderLayerModelObject* paintInvalidationContainer, const PaintInvalidationState* paintInvalidationState)
539 { 546 {
540 FloatPoint point = renderObject->localToContainerPoint(FloatPoint(), paintIn validationContainer, 0, 0, paintInvalidationState); 547 FloatPoint point = renderObject->localToContainerPoint(FloatPoint(), paintIn validationContainer, 0, 0, paintInvalidationState);
541 548
542 // FIXME: Eventually we are going to unify coordinates in GraphicsLayer spac e. 549 // FIXME: Eventually we are going to unify coordinates in GraphicsLayer spac e.
543 if (paintInvalidationContainer && paintInvalidationContainer->layer()->group edMapping()) 550 if (paintInvalidationContainer && paintInvalidationContainer->layer()->group edMapping())
544 mapPointToPaintBackingCoordinates(paintInvalidationContainer, point); 551 mapPointToPaintBackingCoordinates(paintInvalidationContainer, point);
545 552
546 return LayoutPoint(point); 553 return LayoutPoint(point);
547 } 554 }
(...skipping 684 matching lines...) Expand 10 before | Expand all | Expand 10 after
1232 oldChild->setNextSibling(0); 1239 oldChild->setNextSibling(0);
1233 oldChild->m_parent = 0; 1240 oldChild->m_parent = 0;
1234 1241
1235 dirtyAncestorChainHasSelfPaintingLayerDescendantStatus(); 1242 dirtyAncestorChainHasSelfPaintingLayerDescendantStatus();
1236 1243
1237 oldChild->updateDescendantDependentFlags(); 1244 oldChild->updateDescendantDependentFlags();
1238 1245
1239 if (oldChild->m_hasVisibleContent || oldChild->m_hasVisibleDescendant) 1246 if (oldChild->m_hasVisibleContent || oldChild->m_hasVisibleDescendant)
1240 dirtyAncestorChainVisibleDescendantStatus(); 1247 dirtyAncestorChainVisibleDescendantStatus();
1241 1248
1249 if (oldChild->enclosingPaginationLayer())
1250 oldChild->clearPaginationRecursive();
1251
1242 return oldChild; 1252 return oldChild;
1243 } 1253 }
1244 1254
1245 void RenderLayer::removeOnlyThisLayer() 1255 void RenderLayer::removeOnlyThisLayer()
1246 { 1256 {
1247 if (!m_parent) 1257 if (!m_parent)
1248 return; 1258 return;
1249 1259
1250 m_clipper.clearClipRectsIncludingDescendants(); 1260 m_clipper.clearClipRectsIncludingDescendants();
1251 1261
(...skipping 1587 matching lines...) Expand 10 before | Expand all | Expand 10 after
2839 } 2849 }
2840 } 2850 }
2841 2851
2842 void showLayerTree(const blink::RenderObject* renderer) 2852 void showLayerTree(const blink::RenderObject* renderer)
2843 { 2853 {
2844 if (!renderer) 2854 if (!renderer)
2845 return; 2855 return;
2846 showLayerTree(renderer->enclosingLayer()); 2856 showLayerTree(renderer->enclosingLayer());
2847 } 2857 }
2848 #endif 2858 #endif
OLDNEW
« no previous file with comments | « Source/core/rendering/RenderLayer.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698