Chromium Code Reviews| 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 * (C) 2005 Allan Sandfeld Jensen (kde@carewolf.com) | 4 * (C) 2005 Allan Sandfeld Jensen (kde@carewolf.com) |
| 5 * (C) 2005, 2006 Samuel Weinig (sam.weinig@gmail.com) | 5 * (C) 2005, 2006 Samuel Weinig (sam.weinig@gmail.com) |
| 6 * Copyright (C) 2005, 2006, 2007, 2008, 2009, 2010 Apple Inc. All rights reserv ed. | 6 * Copyright (C) 2005, 2006, 2007, 2008, 2009, 2010 Apple Inc. All rights reserv ed. |
| 7 * Copyright (C) 2013 Adobe Systems Incorporated. All rights reserved. | 7 * Copyright (C) 2013 Adobe Systems Incorporated. All rights reserved. |
| 8 * | 8 * |
| 9 * This library is free software; you can redistribute it and/or | 9 * This library is free software; you can redistribute it and/or |
| 10 * modify it under the terms of the GNU Library General Public | 10 * modify it under the terms of the GNU Library General Public |
| (...skipping 84 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 95 | 95 |
| 96 RenderBox::RenderBox(ContainerNode* node) | 96 RenderBox::RenderBox(ContainerNode* node) |
| 97 : RenderBoxModelObject(node) | 97 : RenderBoxModelObject(node) |
| 98 , m_intrinsicContentLogicalHeight(-1) | 98 , m_intrinsicContentLogicalHeight(-1) |
| 99 , m_minPreferredLogicalWidth(-1) | 99 , m_minPreferredLogicalWidth(-1) |
| 100 , m_maxPreferredLogicalWidth(-1) | 100 , m_maxPreferredLogicalWidth(-1) |
| 101 { | 101 { |
| 102 setIsBox(); | 102 setIsBox(); |
| 103 } | 103 } |
| 104 | 104 |
| 105 LayerType RenderBox::layerTypeRequired() const | |
| 106 { | |
| 107 // hasAutoZIndex only returns true if the element is positioned or a flex-it em since | |
| 108 // position:static elements that are not flex-items get their z-index coerce d to auto. | |
| 109 if (isPositioned() || createsGroup() || hasClipPath() || hasTransformRelated Property() || hasHiddenBackface() || hasReflection() || style()->specifiesColumn s() || !style()->hasAutoZIndex() || style()->shouldCompositeForCurrentAnimations ()) | |
|
skobes
2015/01/07 18:49:24
Could you wrap this line at some reasonable length
Rick Byers
2015/01/08 21:08:11
Done.
| |
| 110 return NormalLayer; | |
| 111 if (style()->hasScrollBlocksOn()) { | |
| 112 if (isDocumentElement()) { | |
|
Ian Vollick
2015/01/06 04:13:51
Once skobes' root layer scroll refactor is done, t
skobes
2015/01/07 18:49:24
If I'm reading it right, this check is just making
Rick Byers
2015/01/08 21:08:11
Right. I've added a comment to clarify this.
| |
| 113 ASSERT(style()->scrollBlocksOn() == view()->style()->scrollBlocksOn( )); | |
| 114 return NoLayer; | |
| 115 } | |
| 116 return NormalLayer; | |
| 117 } | |
| 118 if (hasOverflowClip()) | |
| 119 return OverflowClipLayer; | |
| 120 | |
| 121 return NoLayer; | |
| 122 } | |
| 123 | |
| 105 void RenderBox::willBeRemovedFromTree() | 124 void RenderBox::willBeRemovedFromTree() |
| 106 { | 125 { |
| 107 if (m_rareData && m_rareData->m_spannerPlaceholder) { | 126 if (m_rareData && m_rareData->m_spannerPlaceholder) { |
| 108 m_rareData->m_spannerPlaceholder->spannerWillBeRemoved(); | 127 m_rareData->m_spannerPlaceholder->spannerWillBeRemoved(); |
| 109 m_rareData->m_spannerPlaceholder = 0; | 128 m_rareData->m_spannerPlaceholder = 0; |
| 110 } | 129 } |
| 111 RenderBoxModelObject::willBeRemovedFromTree(); | 130 RenderBoxModelObject::willBeRemovedFromTree(); |
| 112 } | 131 } |
| 113 | 132 |
| 114 void RenderBox::willBeDestroyed() | 133 void RenderBox::willBeDestroyed() |
| (...skipping 4404 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 4519 computedValues.m_margins.m_end = marginEnd(); | 4538 computedValues.m_margins.m_end = marginEnd(); |
| 4520 | 4539 |
| 4521 setLogicalTop(oldLogicalTop); | 4540 setLogicalTop(oldLogicalTop); |
| 4522 setLogicalWidth(oldLogicalWidth); | 4541 setLogicalWidth(oldLogicalWidth); |
| 4523 setLogicalLeft(oldLogicalLeft); | 4542 setLogicalLeft(oldLogicalLeft); |
| 4524 setMarginLeft(oldMarginLeft); | 4543 setMarginLeft(oldMarginLeft); |
| 4525 setMarginRight(oldMarginRight); | 4544 setMarginRight(oldMarginRight); |
| 4526 } | 4545 } |
| 4527 | 4546 |
| 4528 } // namespace blink | 4547 } // namespace blink |
| OLD | NEW |