| 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 446 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 457 | 457 |
| 458 void filterNeedsRepaint(); | 458 void filterNeedsRepaint(); |
| 459 bool hasFilter() const { return renderer()->hasFilter(); } | 459 bool hasFilter() const { return renderer()->hasFilter(); } |
| 460 | 460 |
| 461 bool hasBlendMode() const; | 461 bool hasBlendMode() const; |
| 462 | 462 |
| 463 void* operator new(size_t); | 463 void* operator new(size_t); |
| 464 // Only safe to call from RenderLayerModelObject::destroyLayer() | 464 // Only safe to call from RenderLayerModelObject::destroyLayer() |
| 465 void operator delete(void*); | 465 void operator delete(void*); |
| 466 | 466 |
| 467 bool isComposited() const { return m_compositedLayerMapping; } | 467 CompositingState compositingState() const; |
| 468 |
| 469 CompositedLayerMapping* compositedLayerMapping() const |
| 470 { |
| 471 // NOTE: Checking whether backing exists is equivalent to asking if you
are in one of these two compositing states. |
| 472 // If this is why you are using compositedLayerMapping(), consider
using compositingState() instead. |
| 473 return m_compositedLayerMapping.get(); |
| 474 } |
| 475 |
| 476 CompositedLayerMapping* ensureCompositedLayerMapping(); |
| 477 void clearCompositedLayerMapping(bool layerBeingDestroyed = false); |
| 478 |
| 468 bool hasCompositedMask() const; | 479 bool hasCompositedMask() const; |
| 469 bool hasCompositedClippingMask() const; | 480 bool hasCompositedClippingMask() const; |
| 470 CompositedLayerMapping* compositedLayerMapping() const { return m_composited
LayerMapping.get(); } | |
| 471 CompositedLayerMapping* ensureCompositedLayerMapping(); | |
| 472 void clearCompositedLayerMapping(bool layerBeingDestroyed = false); | |
| 473 bool needsCompositedScrolling() const; | 481 bool needsCompositedScrolling() const; |
| 474 bool needsToBeStackingContainer() const; | 482 bool needsToBeStackingContainer() const; |
| 475 | 483 |
| 476 RenderLayer* scrollParent() const; | 484 RenderLayer* scrollParent() const; |
| 477 RenderLayer* clipParent() const; | 485 RenderLayer* clipParent() const; |
| 478 | 486 |
| 479 bool needsCompositingLayersRebuiltForClip(const RenderStyle* oldStyle, const
RenderStyle* newStyle) const; | 487 bool needsCompositingLayersRebuiltForClip(const RenderStyle* oldStyle, const
RenderStyle* newStyle) const; |
| 480 bool needsCompositingLayersRebuiltForOverflow(const RenderStyle* oldStyle, c
onst RenderStyle* newStyle) const; | 488 bool needsCompositingLayersRebuiltForOverflow(const RenderStyle* oldStyle, c
onst RenderStyle* newStyle) const; |
| 481 bool needsCompositingLayersRebuiltForFilters(const RenderStyle* oldStyle, co
nst RenderStyle* newStyle, bool didPaintWithFilters) const; | 489 bool needsCompositingLayersRebuiltForFilters(const RenderStyle* oldStyle, co
nst RenderStyle* newStyle, bool didPaintWithFilters) const; |
| 482 | 490 |
| 483 bool paintsWithTransparency(PaintBehavior paintBehavior) const | 491 bool paintsWithTransparency(PaintBehavior paintBehavior) const |
| 484 { | 492 { |
| 485 return isTransparent() && ((paintBehavior & PaintBehaviorFlattenComposit
ingLayers) || !isComposited()); | 493 return isTransparent() && ((paintBehavior & PaintBehaviorFlattenComposit
ingLayers) || compositingState() != PaintsIntoOwnBacking); |
| 486 } | 494 } |
| 487 | 495 |
| 488 bool paintsWithTransform(PaintBehavior) const; | 496 bool paintsWithTransform(PaintBehavior) const; |
| 489 | 497 |
| 490 // Returns true if background phase is painted opaque in the given rect. | 498 // Returns true if background phase is painted opaque in the given rect. |
| 491 // The query rect is given in local coordinates. | 499 // The query rect is given in local coordinates. |
| 492 bool backgroundIsKnownToBeOpaqueInRect(const LayoutRect&) const; | 500 bool backgroundIsKnownToBeOpaqueInRect(const LayoutRect&) const; |
| 493 | 501 |
| 494 bool containsDirtyOverlayScrollbars() const { return m_containsDirtyOverlayS
crollbars; } | 502 bool containsDirtyOverlayScrollbars() const { return m_containsDirtyOverlayS
crollbars; } |
| 495 void setContainsDirtyOverlayScrollbars(bool dirtyScrollbars) { m_containsDir
tyOverlayScrollbars = dirtyScrollbars; } | 503 void setContainsDirtyOverlayScrollbars(bool dirtyScrollbars) { m_containsDir
tyOverlayScrollbars = dirtyScrollbars; } |
| (...skipping 516 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1012 | 1020 |
| 1013 } // namespace WebCore | 1021 } // namespace WebCore |
| 1014 | 1022 |
| 1015 #ifndef NDEBUG | 1023 #ifndef NDEBUG |
| 1016 // Outside the WebCore namespace for ease of invocation from gdb. | 1024 // Outside the WebCore namespace for ease of invocation from gdb. |
| 1017 void showLayerTree(const WebCore::RenderLayer*); | 1025 void showLayerTree(const WebCore::RenderLayer*); |
| 1018 void showLayerTree(const WebCore::RenderObject*); | 1026 void showLayerTree(const WebCore::RenderObject*); |
| 1019 #endif | 1027 #endif |
| 1020 | 1028 |
| 1021 #endif // RenderLayer_h | 1029 #endif // RenderLayer_h |
| OLD | NEW |