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

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

Issue 1581593003: Skip PaintPhaseFloat if no floats in a layer (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@OutlinePhase
Patch Set: 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
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2003, 2009, 2012 Apple Inc. All rights reserved. 2 * Copyright (C) 2003, 2009, 2012 Apple Inc. All rights reserved.
3 * Copyright (C) 2013 Intel Corporation. All rights reserved. 3 * Copyright (C) 2013 Intel Corporation. All rights reserved.
4 * 4 *
5 * Portions are Copyright (C) 1998 Netscape Communications Corporation. 5 * Portions are Copyright (C) 1998 Netscape Communications Corporation.
6 * 6 *
7 * Other contributors: 7 * Other contributors:
8 * Robert O'Callahan <roc+@cs.cmu.edu> 8 * Robert O'Callahan <roc+@cs.cmu.edu>
9 * David Baron <dbaron@fas.harvard.edu> 9 * David Baron <dbaron@fas.harvard.edu>
10 * Christian Biesinger <cbiesinger@web.de> 10 * Christian Biesinger <cbiesinger@web.de>
(...skipping 609 matching lines...) Expand 10 before | Expand all | Expand 10 after
620 LayoutRect previousPaintDirtyRect() const { return m_previousPaintDirtyRect; } 620 LayoutRect previousPaintDirtyRect() const { return m_previousPaintDirtyRect; }
621 void setPreviousPaintDirtyRect(const LayoutRect& rect) { m_previousPaintDirt yRect = rect; } 621 void setPreviousPaintDirtyRect(const LayoutRect& rect) { m_previousPaintDirt yRect = rect; }
622 622
623 PaintLayerPainter::PaintResult previousPaintResult() const { return static_c ast<PaintLayerPainter::PaintResult>(m_previousPaintResult); } 623 PaintLayerPainter::PaintResult previousPaintResult() const { return static_c ast<PaintLayerPainter::PaintResult>(m_previousPaintResult); }
624 void setPreviousPaintResult(PaintLayerPainter::PaintResult result) { m_previ ousPaintResult = static_cast<unsigned>(result); ASSERT(m_previousPaintResult == static_cast<unsigned>(result)); } 624 void setPreviousPaintResult(PaintLayerPainter::PaintResult result) { m_previ ousPaintResult = static_cast<unsigned>(result); ASSERT(m_previousPaintResult == static_cast<unsigned>(result)); }
625 625
626 bool needsPaintPhaseDescendantOutlines() const { return m_needsPaintPhaseDes cendantOutlines; } 626 bool needsPaintPhaseDescendantOutlines() const { return m_needsPaintPhaseDes cendantOutlines; }
627 void setNeedsPaintPhaseDescendantOutlines() { ASSERT(isSelfPaintingLayer()); m_needsPaintPhaseDescendantOutlines = true; } 627 void setNeedsPaintPhaseDescendantOutlines() { ASSERT(isSelfPaintingLayer()); m_needsPaintPhaseDescendantOutlines = true; }
628 void clearNeedsPaintPhaseDescendantOutlines() { ASSERT(isSelfPaintingLayer() ); m_needsPaintPhaseDescendantOutlines = false; } 628 void clearNeedsPaintPhaseDescendantOutlines() { ASSERT(isSelfPaintingLayer() ); m_needsPaintPhaseDescendantOutlines = false; }
629 629
630 bool needsPaintPhaseFloat() const { return m_needsPaintPhaseFloat; }
631 void setNeedsPaintPhaseFloat() { ASSERT(isSelfPaintingLayer()); m_needsPaint PhaseFloat = true; }
632 void clearNeedsPaintPhaseFloat() { ASSERT(isSelfPaintingLayer()); m_needsPai ntPhaseFloat = false; }
633
630 PaintTiming* paintTiming(); 634 PaintTiming* paintTiming();
631 635
632 private: 636 private:
633 // Bounding box in the coordinates of this layer. 637 // Bounding box in the coordinates of this layer.
634 LayoutRect logicalBoundingBox() const; 638 LayoutRect logicalBoundingBox() const;
635 639
636 bool hasOverflowControls() const; 640 bool hasOverflowControls() const;
637 641
638 void dirtyAncestorChainHasSelfPaintingLayerDescendantStatus(); 642 void dirtyAncestorChainHasSelfPaintingLayerDescendantStatus();
639 643
(...skipping 113 matching lines...) Expand 10 before | Expand all | Expand 10 after
753 unsigned m_shouldIsolateCompositedDescendants : 1; 757 unsigned m_shouldIsolateCompositedDescendants : 1;
754 758
755 // True if this layout layer just lost its grouped mapping due to the Compos itedLayerMapping being destroyed, 759 // True if this layout layer just lost its grouped mapping due to the Compos itedLayerMapping being destroyed,
756 // and we don't yet know to what graphics layer this Layer will be assigned. 760 // and we don't yet know to what graphics layer this Layer will be assigned.
757 unsigned m_lostGroupedMapping : 1; 761 unsigned m_lostGroupedMapping : 1;
758 762
759 unsigned m_needsRepaint : 1; 763 unsigned m_needsRepaint : 1;
760 unsigned m_previousPaintResult : 1; // PaintLayerPainter::PaintResult 764 unsigned m_previousPaintResult : 1; // PaintLayerPainter::PaintResult
761 765
762 unsigned m_needsPaintPhaseDescendantOutlines : 1; 766 unsigned m_needsPaintPhaseDescendantOutlines : 1;
767 unsigned m_needsPaintPhaseFloat : 1;
chrishtr 2016/01/21 22:09:08 Add a test like this one? https://code.google.com
Xianzhu 2016/01/21 23:58:35 Done (https://codereview.chromium.org/1616193002/)
763 768
764 LayoutBoxModelObject* m_layoutObject; 769 LayoutBoxModelObject* m_layoutObject;
765 770
766 PaintLayer* m_parent; 771 PaintLayer* m_parent;
767 PaintLayer* m_previous; 772 PaintLayer* m_previous;
768 PaintLayer* m_next; 773 PaintLayer* m_next;
769 PaintLayer* m_first; 774 PaintLayer* m_first;
770 PaintLayer* m_last; 775 PaintLayer* m_last;
771 776
772 // Our current relative position offset. 777 // Our current relative position offset.
(...skipping 54 matching lines...) Expand 10 before | Expand all | Expand 10 after
827 832
828 } // namespace blink 833 } // namespace blink
829 834
830 #ifndef NDEBUG 835 #ifndef NDEBUG
831 // Outside the WebCore namespace for ease of invocation from gdb. 836 // Outside the WebCore namespace for ease of invocation from gdb.
832 void showLayerTree(const blink::PaintLayer*); 837 void showLayerTree(const blink::PaintLayer*);
833 void showLayerTree(const blink::LayoutObject*); 838 void showLayerTree(const blink::LayoutObject*);
834 #endif 839 #endif
835 840
836 #endif // Layer_h 841 #endif // Layer_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698