| OLD | NEW |
| 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 264 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 275 // Do *not* call this method unless you know what you are dooing. You probab
ly want to call enclosingCompositingLayerForPaintInvalidation() instead. | 275 // Do *not* call this method unless you know what you are dooing. You probab
ly want to call enclosingCompositingLayerForPaintInvalidation() instead. |
| 276 // If includeSelf is true, may return this. | 276 // If includeSelf is true, may return this. |
| 277 PaintLayer* enclosingLayerWithCompositedLayerMapping(IncludeSelfOrNot) const
; | 277 PaintLayer* enclosingLayerWithCompositedLayerMapping(IncludeSelfOrNot) const
; |
| 278 | 278 |
| 279 // Returns the enclosing layer root into which this layer paints, inclusive
of this one. Note that the enclosing layer may or may not have its own | 279 // Returns the enclosing layer root into which this layer paints, inclusive
of this one. Note that the enclosing layer may or may not have its own |
| 280 // GraphicsLayer backing, but is nevertheless the root for a call to the Lay
er::paint*() methods. | 280 // GraphicsLayer backing, but is nevertheless the root for a call to the Lay
er::paint*() methods. |
| 281 PaintLayer* enclosingLayerForPaintInvalidation() const; | 281 PaintLayer* enclosingLayerForPaintInvalidation() const; |
| 282 | 282 |
| 283 PaintLayer* enclosingLayerForPaintInvalidationCrossingFrameBoundaries() cons
t; | 283 PaintLayer* enclosingLayerForPaintInvalidationCrossingFrameBoundaries() cons
t; |
| 284 | 284 |
| 285 PaintLayer* enclosingSelfPaintingLayer() const; |
| 286 |
| 285 bool hasAncestorWithFilterOutsets() const; | 287 bool hasAncestorWithFilterOutsets() const; |
| 286 | 288 |
| 287 bool canUseConvertToLayerCoords() const | 289 bool canUseConvertToLayerCoords() const |
| 288 { | 290 { |
| 289 // These LayoutObjects have an impact on their layers without the layout
Objects knowing about it. | 291 // These LayoutObjects have an impact on their layers without the layout
Objects knowing about it. |
| 290 return !layoutObject()->hasTransformRelatedProperty() && !layoutObject()
->isSVGRoot(); | 292 return !layoutObject()->hasTransformRelatedProperty() && !layoutObject()
->isSVGRoot(); |
| 291 } | 293 } |
| 292 | 294 |
| 293 void convertToLayerCoords(const PaintLayer* ancestorLayer, LayoutPoint&) con
st; | 295 void convertToLayerCoords(const PaintLayer* ancestorLayer, LayoutPoint&) con
st; |
| 294 void convertToLayerCoords(const PaintLayer* ancestorLayer, LayoutRect&) cons
t; | 296 void convertToLayerCoords(const PaintLayer* ancestorLayer, LayoutRect&) cons
t; |
| (...skipping 319 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 614 | 616 |
| 615 ClipRects* previousPaintingClipRects() const { return m_previousPaintingClip
Rects.get(); } | 617 ClipRects* previousPaintingClipRects() const { return m_previousPaintingClip
Rects.get(); } |
| 616 void setPreviousPaintingClipRects(ClipRects* clipRects) { m_previousPainting
ClipRects = clipRects; } | 618 void setPreviousPaintingClipRects(ClipRects* clipRects) { m_previousPainting
ClipRects = clipRects; } |
| 617 | 619 |
| 618 LayoutRect previousPaintDirtyRect() const { return m_previousPaintDirtyRect;
} | 620 LayoutRect previousPaintDirtyRect() const { return m_previousPaintDirtyRect;
} |
| 619 void setPreviousPaintDirtyRect(const LayoutRect& rect) { m_previousPaintDirt
yRect = rect; } | 621 void setPreviousPaintDirtyRect(const LayoutRect& rect) { m_previousPaintDirt
yRect = rect; } |
| 620 | 622 |
| 621 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); } |
| 622 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)); } |
| 623 | 625 |
| 626 // Used to skip PaintPhaseDescendantOutlinesOnly for layers that have never
had descendant outlines. |
| 627 // Once it's set we never clear it because it's not easy to track if all out
lines have been removed. |
| 628 bool needsPaintPhaseDescendantOutlines() const { return m_needsPaintPhaseDes
cendantOutlines; } |
| 629 void setNeedsPaintPhaseDescendantOutlines() { ASSERT(isSelfPaintingLayer());
m_needsPaintPhaseDescendantOutlines = true; } |
| 630 |
| 624 PaintTiming* paintTiming(); | 631 PaintTiming* paintTiming(); |
| 625 | 632 |
| 626 private: | 633 private: |
| 627 // Bounding box in the coordinates of this layer. | 634 // Bounding box in the coordinates of this layer. |
| 628 LayoutRect logicalBoundingBox() const; | 635 LayoutRect logicalBoundingBox() const; |
| 629 | 636 |
| 630 bool hasOverflowControls() const; | 637 bool hasOverflowControls() const; |
| 631 | 638 |
| 632 void dirtyAncestorChainHasSelfPaintingLayerDescendantStatus(); | 639 void dirtyAncestorChainHasSelfPaintingLayerDescendantStatus(); |
| 633 | 640 |
| (...skipping 112 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 746 // Should be for stacking contexts having unisolated blending descendants. | 753 // Should be for stacking contexts having unisolated blending descendants. |
| 747 unsigned m_shouldIsolateCompositedDescendants : 1; | 754 unsigned m_shouldIsolateCompositedDescendants : 1; |
| 748 | 755 |
| 749 // True if this layout layer just lost its grouped mapping due to the Compos
itedLayerMapping being destroyed, | 756 // True if this layout layer just lost its grouped mapping due to the Compos
itedLayerMapping being destroyed, |
| 750 // and we don't yet know to what graphics layer this Layer will be assigned. | 757 // and we don't yet know to what graphics layer this Layer will be assigned. |
| 751 unsigned m_lostGroupedMapping : 1; | 758 unsigned m_lostGroupedMapping : 1; |
| 752 | 759 |
| 753 unsigned m_needsRepaint : 1; | 760 unsigned m_needsRepaint : 1; |
| 754 unsigned m_previousPaintResult : 1; // PaintLayerPainter::PaintResult | 761 unsigned m_previousPaintResult : 1; // PaintLayerPainter::PaintResult |
| 755 | 762 |
| 763 unsigned m_needsPaintPhaseDescendantOutlines : 1; |
| 764 |
| 756 LayoutBoxModelObject* m_layoutObject; | 765 LayoutBoxModelObject* m_layoutObject; |
| 757 | 766 |
| 758 PaintLayer* m_parent; | 767 PaintLayer* m_parent; |
| 759 PaintLayer* m_previous; | 768 PaintLayer* m_previous; |
| 760 PaintLayer* m_next; | 769 PaintLayer* m_next; |
| 761 PaintLayer* m_first; | 770 PaintLayer* m_first; |
| 762 PaintLayer* m_last; | 771 PaintLayer* m_last; |
| 763 | 772 |
| 764 // Our current relative position offset. | 773 // Our current relative position offset. |
| 765 LayoutSize m_offsetForInFlowPosition; | 774 LayoutSize m_offsetForInFlowPosition; |
| (...skipping 53 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 819 | 828 |
| 820 } // namespace blink | 829 } // namespace blink |
| 821 | 830 |
| 822 #ifndef NDEBUG | 831 #ifndef NDEBUG |
| 823 // Outside the WebCore namespace for ease of invocation from gdb. | 832 // Outside the WebCore namespace for ease of invocation from gdb. |
| 824 void showLayerTree(const blink::PaintLayer*); | 833 void showLayerTree(const blink::PaintLayer*); |
| 825 void showLayerTree(const blink::LayoutObject*); | 834 void showLayerTree(const blink::LayoutObject*); |
| 826 #endif | 835 #endif |
| 827 | 836 |
| 828 #endif // Layer_h | 837 #endif // Layer_h |
| OLD | NEW |