| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) | 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) |
| 3 * (C) 1999 Antti Koivisto (koivisto@kde.org) | 3 * (C) 1999 Antti Koivisto (koivisto@kde.org) |
| 4 * Copyright (C) 2003, 2006, 2007 Apple Inc. All rights reserved. | 4 * Copyright (C) 2003, 2006, 2007 Apple Inc. All rights reserved. |
| 5 * | 5 * |
| 6 * This library is free software; you can redistribute it and/or | 6 * This library is free software; you can redistribute it and/or |
| 7 * modify it under the terms of the GNU Library General Public | 7 * modify it under the terms of the GNU Library General Public |
| 8 * License as published by the Free Software Foundation; either | 8 * License as published by the Free Software Foundation; either |
| 9 * version 2 of the License, or (at your option) any later version. | 9 * version 2 of the License, or (at your option) any later version. |
| 10 * | 10 * |
| (...skipping 58 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 69 LayoutUnit m_overrideLogicalContentWidth; | 69 LayoutUnit m_overrideLogicalContentWidth; |
| 70 | 70 |
| 71 // Set by RenderBox::updatePreviousBorderBoxSizeIfNeeded(). | 71 // Set by RenderBox::updatePreviousBorderBoxSizeIfNeeded(). |
| 72 LayoutSize m_previousBorderBoxSize; | 72 LayoutSize m_previousBorderBoxSize; |
| 73 }; | 73 }; |
| 74 | 74 |
| 75 class RenderBox : public RenderBoxModelObject { | 75 class RenderBox : public RenderBoxModelObject { |
| 76 public: | 76 public: |
| 77 explicit RenderBox(ContainerNode*); | 77 explicit RenderBox(ContainerNode*); |
| 78 | 78 |
| 79 // hasAutoZIndex only returns true if the element is positioned or a flex-it
em since | 79 virtual LayerType layerTypeRequired() const override; |
| 80 // position:static elements that are not flex-items get their z-index coerce
d to auto. | |
| 81 virtual LayerType layerTypeRequired() const override | |
| 82 { | |
| 83 if (isPositioned() || createsGroup() || hasClipPath() || hasTransformRel
atedProperty() || hasHiddenBackface() || hasReflection() || style()->specifiesCo
lumns() || !style()->hasAutoZIndex() || style()->shouldCompositeForCurrentAnimat
ions()) | |
| 84 return NormalLayer; | |
| 85 if (hasOverflowClip()) | |
| 86 return OverflowClipLayer; | |
| 87 | |
| 88 return NoLayer; | |
| 89 } | |
| 90 | 80 |
| 91 virtual bool backgroundIsKnownToBeOpaqueInRect(const LayoutRect& localRect)
const override; | 81 virtual bool backgroundIsKnownToBeOpaqueInRect(const LayoutRect& localRect)
const override; |
| 92 | 82 |
| 93 virtual bool backgroundShouldAlwaysBeClipped() const { return false; } | 83 virtual bool backgroundShouldAlwaysBeClipped() const { return false; } |
| 94 | 84 |
| 95 // Use this with caution! No type checking is done! | 85 // Use this with caution! No type checking is done! |
| 96 RenderBox* firstChildBox() const; | 86 RenderBox* firstChildBox() const; |
| 97 RenderBox* lastChildBox() const; | 87 RenderBox* lastChildBox() const; |
| 98 | 88 |
| 99 int pixelSnappedWidth() const { return m_frameRect.pixelSnappedWidth(); } | 89 int pixelSnappedWidth() const { return m_frameRect.pixelSnappedWidth(); } |
| (...skipping 769 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 869 if (UNLIKELY(inlineBoxWrapper() != 0)) | 859 if (UNLIKELY(inlineBoxWrapper() != 0)) |
| 870 deleteLineBoxWrapper(); | 860 deleteLineBoxWrapper(); |
| 871 } | 861 } |
| 872 | 862 |
| 873 ensureRareData().m_inlineBoxWrapper = boxWrapper; | 863 ensureRareData().m_inlineBoxWrapper = boxWrapper; |
| 874 } | 864 } |
| 875 | 865 |
| 876 } // namespace blink | 866 } // namespace blink |
| 877 | 867 |
| 878 #endif // RenderBox_h | 868 #endif // RenderBox_h |
| OLD | NEW |