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) 2001 Peter Kelly (pmk@post.com) | 4 * (C) 2001 Peter Kelly (pmk@post.com) |
| 5 * (C) 2001 Dirk Mueller (mueller@kde.org) | 5 * (C) 2001 Dirk Mueller (mueller@kde.org) |
| 6 * Copyright (C) 2003-2011, 2013, 2014 Apple Inc. All rights reserved. | 6 * Copyright (C) 2003-2011, 2013, 2014 Apple Inc. All rights reserved. |
| 7 * | 7 * |
| 8 * This library is free software; you can redistribute it and/or | 8 * This library is free software; you can redistribute it and/or |
| 9 * modify it under the terms of the GNU Library General Public | 9 * modify it under the terms of the GNU Library General Public |
| 10 * License as published by the Free Software Foundation; either | 10 * License as published by the Free Software Foundation; either |
| (...skipping 778 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 789 setFlag(InDocumentFlag); | 789 setFlag(InDocumentFlag); |
| 790 if (parentOrShadowHostNode()->isInShadowTree()) | 790 if (parentOrShadowHostNode()->isInShadowTree()) |
| 791 setFlag(IsInShadowTreeFlag); | 791 setFlag(IsInShadowTreeFlag); |
| 792 if (childNeedsDistributionRecalc() && !insertionPoint->childNeedsDistributio nRecalc()) | 792 if (childNeedsDistributionRecalc() && !insertionPoint->childNeedsDistributio nRecalc()) |
| 793 insertionPoint->markAncestorsWithChildNeedsDistributionRecalc(); | 793 insertionPoint->markAncestorsWithChildNeedsDistributionRecalc(); |
| 794 return InsertionDone; | 794 return InsertionDone; |
| 795 } | 795 } |
| 796 | 796 |
| 797 inline void Node::removedFrom(ContainerNode* insertionPoint) | 797 inline void Node::removedFrom(ContainerNode* insertionPoint) |
| 798 { | 798 { |
| 799 ASSERT(insertionPoint->inDocument() || isContainerNode()); | 799 ASSERT(insertionPoint->inDocument() || isContainerNode() || isInShadowTree() ); |
|
rhogan
2015/06/24 20:34:41
I didn't use isInTreeScope() here as it would expa
| |
| 800 if (insertionPoint->inDocument()) | 800 if (insertionPoint->inDocument()) |
| 801 clearFlag(InDocumentFlag); | 801 clearFlag(InDocumentFlag); |
| 802 if (isInShadowTree() && !treeScope().rootNode().isShadowRoot()) | 802 if (isInShadowTree() && !treeScope().rootNode().isShadowRoot()) |
| 803 clearFlag(IsInShadowTreeFlag); | 803 clearFlag(IsInShadowTreeFlag); |
| 804 } | 804 } |
| 805 | 805 |
| 806 inline void Element::invalidateStyleAttribute() | 806 inline void Element::invalidateStyleAttribute() |
| 807 { | 807 { |
| 808 ASSERT(elementData()); | 808 ASSERT(elementData()); |
| 809 elementData()->m_styleAttributeIsDirty = true; | 809 elementData()->m_styleAttributeIsDirty = true; |
| (...skipping 67 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 877 static PassRefPtrWillBeRawPtr<T> create(const QualifiedName&, Document&) | 877 static PassRefPtrWillBeRawPtr<T> create(const QualifiedName&, Document&) |
| 878 #define DEFINE_ELEMENT_FACTORY_WITH_TAGNAME(T) \ | 878 #define DEFINE_ELEMENT_FACTORY_WITH_TAGNAME(T) \ |
| 879 PassRefPtrWillBeRawPtr<T> T::create(const QualifiedName& tagName, Document& document) \ | 879 PassRefPtrWillBeRawPtr<T> T::create(const QualifiedName& tagName, Document& document) \ |
| 880 { \ | 880 { \ |
| 881 return adoptRefWillBeNoop(new T(tagName, document)); \ | 881 return adoptRefWillBeNoop(new T(tagName, document)); \ |
| 882 } | 882 } |
| 883 | 883 |
| 884 } // namespace | 884 } // namespace |
| 885 | 885 |
| 886 #endif // Element_h | 886 #endif // Element_h |
| OLD | NEW |