Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(9)

Side by Side Diff: Source/core/dom/TreeScope.h

Issue 262093006: Oilpan: Make the Node hierarchy RefCountedGarbageCollected instead of TreeShared. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Address more comments. Created 6 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2011 Google Inc. All Rights Reserved. 2 * Copyright (C) 2011 Google Inc. All Rights Reserved.
3 * Copyright (C) 2012 Apple Inc. All Rights Reserved. 3 * Copyright (C) 2012 Apple Inc. All Rights Reserved.
4 * 4 *
5 * Redistribution and use in source and binary forms, with or without 5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions 6 * modification, are permitted provided that the following conditions
7 * are met: 7 * are met:
8 * 1. Redistributions of source code must retain the above copyright 8 * 1. Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * 2. Redistributions in binary form must reproduce the above copyright 10 * 2. Redistributions in binary form must reproduce the above copyright
(...skipping 139 matching lines...) Expand 10 before | Expand all | Expand 10 after
150 150
151 #if !ENABLE(OILPAN) 151 #if !ENABLE(OILPAN)
152 bool hasGuardRefCount() const { return m_guardRefCount; } 152 bool hasGuardRefCount() const { return m_guardRefCount; }
153 #endif 153 #endif
154 154
155 void setNeedsStyleRecalcForViewportUnits(); 155 void setNeedsStyleRecalcForViewportUnits();
156 156
157 private: 157 private:
158 virtual void dispose() { } 158 virtual void dispose() { }
159 159
160 #if !ENABLE(OILPAN)
160 int refCount() const; 161 int refCount() const;
161 #if SECURITY_ASSERT_ENABLED 162 #endif
163
164 #if SECURITY_ASSERT_ENABLED && !ENABLE(OILPAN)
162 bool deletionHasBegun(); 165 bool deletionHasBegun();
163 void beginDeletion(); 166 void beginDeletion();
164 #else 167 #else
165 bool deletionHasBegun() { return false; } 168 bool deletionHasBegun() { return false; }
166 void beginDeletion() { } 169 void beginDeletion() { }
167 #endif 170 #endif
168 171
169 bool rootNodeHasTreeSharedParent() const; 172 bool rootNodeHasTreeSharedParent() const;
170 173
171 Node& m_rootNode; 174 Node& m_rootNode;
172 Document* m_document; 175 RawPtrWillBeMember<Document> m_document;
173 RawPtrWillBeMember<TreeScope> m_parentTreeScope; 176 RawPtrWillBeMember<TreeScope> m_parentTreeScope;
174 177
175 #if !ENABLE(OILPAN) 178 #if !ENABLE(OILPAN)
176 int m_guardRefCount; 179 int m_guardRefCount;
177 #endif 180 #endif
178 181
179 OwnPtr<DocumentOrderedMap> m_elementsById; 182 OwnPtr<DocumentOrderedMap> m_elementsById;
180 OwnPtr<DocumentOrderedMap> m_imageMapsByName; 183 OwnPtr<DocumentOrderedMap> m_imageMapsByName;
181 OwnPtr<DocumentOrderedMap> m_labelsByForAttribute; 184 OwnPtr<DocumentOrderedMap> m_labelsByForAttribute;
182 185
(...skipping 19 matching lines...) Expand all
202 inline bool operator!=(const TreeScope& a, const TreeScope& b) { return !(a == b ); } 205 inline bool operator!=(const TreeScope& a, const TreeScope& b) { return !(a == b ); }
203 inline bool operator!=(const TreeScope& a, const TreeScope* b) { return !(a == b ); } 206 inline bool operator!=(const TreeScope& a, const TreeScope* b) { return !(a == b ); }
204 inline bool operator!=(const TreeScope* a, const TreeScope& b) { return !(a == b ); } 207 inline bool operator!=(const TreeScope* a, const TreeScope& b) { return !(a == b ); }
205 208
206 HitTestResult hitTestInDocument(const Document*, int x, int y); 209 HitTestResult hitTestInDocument(const Document*, int x, int y);
207 TreeScope* commonTreeScope(Node*, Node*); 210 TreeScope* commonTreeScope(Node*, Node*);
208 211
209 } // namespace WebCore 212 } // namespace WebCore
210 213
211 #endif // TreeScope_h 214 #endif // TreeScope_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698