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

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

Issue 1544973002: Document lifecycle violation (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Backtrack to only update comments Created 4 years, 11 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
« no previous file with comments | « third_party/WebKit/Source/core/frame/FrameView.cpp ('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 2694 matching lines...) Expand 10 before | Expand all | Expand 10 after
2705 } 2705 }
2706 2706
2707 ensureFilterInfo()->setBuilder(nullptr); 2707 ensureFilterInfo()->setBuilder(nullptr);
2708 } 2708 }
2709 2709
2710 void PaintLayer::filterNeedsPaintInvalidation() 2710 void PaintLayer::filterNeedsPaintInvalidation()
2711 { 2711 {
2712 { 2712 {
2713 DeprecatedScheduleStyleRecalcDuringLayout marker(layoutObject()->documen t().lifecycle()); 2713 DeprecatedScheduleStyleRecalcDuringLayout marker(layoutObject()->documen t().lifecycle());
2714 // It's possible for scheduleSVGFilterLayerUpdateHack to schedule a styl e recalc, which 2714 // It's possible for scheduleSVGFilterLayerUpdateHack to schedule a styl e recalc, which
2715 // is a problem because this function can be called while performing lay out. 2715 // is a problem because this function can be called right before perform ing layout but
2716 // Presumably this represents an illegal data flow of layout or composit ing 2716 // after style recalc.
2717 // information into the style system. 2717 //
2718 // See LayoutView::layout() and the call to
2719 // invalidateSVGRootsWithRelativeLengthDescendents(). This violation is worked around
2720 // in FrameView::updateStyleAndLayoutIfNeededRecursive() by doing an ext ra style recalc
2721 // and layout in case it's needed.
2718 toElement(layoutObject()->node())->scheduleSVGFilterLayerUpdateHack(); 2722 toElement(layoutObject()->node())->scheduleSVGFilterLayerUpdateHack();
2719 } 2723 }
2720 2724
2721 layoutObject()->setShouldDoFullPaintInvalidation(); 2725 layoutObject()->setShouldDoFullPaintInvalidation();
2722 } 2726 }
2723 2727
2724 void PaintLayer::addLayerHitTestRects(LayerHitTestRects& rects) const 2728 void PaintLayer::addLayerHitTestRects(LayerHitTestRects& rects) const
2725 { 2729 {
2726 computeSelfHitTestRects(rects); 2730 computeSelfHitTestRects(rects);
2727 for (PaintLayer* child = firstChild(); child; child = child->nextSibling()) 2731 for (PaintLayer* child = firstChild(); child; child = child->nextSibling())
(...skipping 103 matching lines...) Expand 10 before | Expand all | Expand 10 after
2831 2835
2832 void showLayerTree(const blink::LayoutObject* layoutObject) 2836 void showLayerTree(const blink::LayoutObject* layoutObject)
2833 { 2837 {
2834 if (!layoutObject) { 2838 if (!layoutObject) {
2835 fprintf(stderr, "Cannot showLayerTree. Root is (nil)\n"); 2839 fprintf(stderr, "Cannot showLayerTree. Root is (nil)\n");
2836 return; 2840 return;
2837 } 2841 }
2838 showLayerTree(layoutObject->enclosingLayer()); 2842 showLayerTree(layoutObject->enclosingLayer());
2839 } 2843 }
2840 #endif 2844 #endif
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/core/frame/FrameView.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698