| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2008, 2010 Apple Inc. All rights reserved. | 2 * Copyright (C) 2008, 2010 Apple Inc. All rights reserved. |
| 3 * Copyright (C) 2008 David Smith <catfish.man@gmail.com> | 3 * Copyright (C) 2008 David Smith <catfish.man@gmail.com> |
| 4 * | 4 * |
| 5 * This library is free software; you can redistribute it and/or | 5 * This library is free software; you can redistribute it and/or |
| 6 * modify it under the terms of the GNU Library General Public | 6 * modify it under the terms of the GNU Library General Public |
| 7 * License as published by the Free Software Foundation; either | 7 * License as published by the Free Software Foundation; either |
| 8 * version 2 of the License, or (at your option) any later version. | 8 * version 2 of the License, or (at your option) any later version. |
| 9 * | 9 * |
| 10 * This library is distributed in the hope that it will be useful, | 10 * This library is distributed in the hope that it will be useful, |
| (...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 52 } | 52 } |
| 53 | 53 |
| 54 private: | 54 private: |
| 55 NodeMutationObserverData() { } | 55 NodeMutationObserverData() { } |
| 56 }; | 56 }; |
| 57 | 57 |
| 58 class NodeRareData : public NoBaseWillBeGarbageCollectedFinalized<NodeRareData>,
public NodeRareDataBase { | 58 class NodeRareData : public NoBaseWillBeGarbageCollectedFinalized<NodeRareData>,
public NodeRareDataBase { |
| 59 WTF_MAKE_NONCOPYABLE(NodeRareData); | 59 WTF_MAKE_NONCOPYABLE(NodeRareData); |
| 60 WTF_MAKE_FAST_ALLOCATED_WILL_BE_REMOVED; | 60 WTF_MAKE_FAST_ALLOCATED_WILL_BE_REMOVED; |
| 61 public: | 61 public: |
| 62 static NodeRareData* create(RenderObject* renderer) | 62 static NodeRareData* create(LayoutObject* renderer) |
| 63 { | 63 { |
| 64 return new NodeRareData(renderer); | 64 return new NodeRareData(renderer); |
| 65 } | 65 } |
| 66 | 66 |
| 67 void clearNodeLists() { m_nodeLists.clear(); } | 67 void clearNodeLists() { m_nodeLists.clear(); } |
| 68 NodeListsNodeData* nodeLists() const { return m_nodeLists.get(); } | 68 NodeListsNodeData* nodeLists() const { return m_nodeLists.get(); } |
| 69 NodeListsNodeData& ensureNodeLists() | 69 NodeListsNodeData& ensureNodeLists() |
| 70 { | 70 { |
| 71 if (!m_nodeLists) | 71 if (!m_nodeLists) |
| 72 m_nodeLists = NodeListsNodeData::create(); | 72 m_nodeLists = NodeListsNodeData::create(); |
| (...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 105 enum { | 105 enum { |
| 106 ConnectedFrameCountBits = 10, // Must fit Page::maxNumberOfFrames. | 106 ConnectedFrameCountBits = 10, // Must fit Page::maxNumberOfFrames. |
| 107 }; | 107 }; |
| 108 | 108 |
| 109 void trace(Visitor*); | 109 void trace(Visitor*); |
| 110 | 110 |
| 111 void traceAfterDispatch(Visitor*); | 111 void traceAfterDispatch(Visitor*); |
| 112 void finalizeGarbageCollectedObject(); | 112 void finalizeGarbageCollectedObject(); |
| 113 | 113 |
| 114 protected: | 114 protected: |
| 115 explicit NodeRareData(RenderObject* renderer) | 115 explicit NodeRareData(LayoutObject* renderer) |
| 116 : NodeRareDataBase(renderer) | 116 : NodeRareDataBase(renderer) |
| 117 , m_connectedFrameCount(0) | 117 , m_connectedFrameCount(0) |
| 118 , m_elementFlags(0) | 118 , m_elementFlags(0) |
| 119 , m_restyleFlags(0) | 119 , m_restyleFlags(0) |
| 120 , m_isElementRareData(false) | 120 , m_isElementRareData(false) |
| 121 { } | 121 { } |
| 122 | 122 |
| 123 private: | 123 private: |
| 124 OwnPtrWillBeMember<NodeListsNodeData> m_nodeLists; | 124 OwnPtrWillBeMember<NodeListsNodeData> m_nodeLists; |
| 125 OwnPtrWillBeMember<NodeMutationObserverData> m_mutationObserverData; | 125 OwnPtrWillBeMember<NodeMutationObserverData> m_mutationObserverData; |
| 126 | 126 |
| 127 unsigned m_connectedFrameCount : ConnectedFrameCountBits; | 127 unsigned m_connectedFrameCount : ConnectedFrameCountBits; |
| 128 unsigned m_elementFlags : NumberOfElementFlags; | 128 unsigned m_elementFlags : NumberOfElementFlags; |
| 129 unsigned m_restyleFlags : NumberOfDynamicRestyleFlags; | 129 unsigned m_restyleFlags : NumberOfDynamicRestyleFlags; |
| 130 protected: | 130 protected: |
| 131 unsigned m_isElementRareData : 1; | 131 unsigned m_isElementRareData : 1; |
| 132 }; | 132 }; |
| 133 | 133 |
| 134 } // namespace blink | 134 } // namespace blink |
| 135 | 135 |
| 136 #endif // NodeRareData_h | 136 #endif // NodeRareData_h |
| OLD | NEW |