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

Side by Side Diff: third_party/WebKit/Source/core/dom/NodeRareData.h

Issue 2776203002: Migrate WTF::Vector::remove() to ::erase() (Closed)
Patch Set: rebase, repatch VectorTest Created 3 years, 8 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
OLDNEW
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 48 matching lines...) Expand 10 before | Expand all | Expand 10 after
59 m_transientRegistry.erase(registration); 59 m_transientRegistry.erase(registration);
60 } 60 }
61 61
62 void addRegistration(MutationObserverRegistration* registration) { 62 void addRegistration(MutationObserverRegistration* registration) {
63 m_registry.push_back( 63 m_registry.push_back(
64 TraceWrapperMember<MutationObserverRegistration>(this, registration)); 64 TraceWrapperMember<MutationObserverRegistration>(this, registration));
65 } 65 }
66 66
67 void removeRegistration(MutationObserverRegistration* registration) { 67 void removeRegistration(MutationObserverRegistration* registration) {
68 DCHECK(m_registry.contains(registration)); 68 DCHECK(m_registry.contains(registration));
69 m_registry.remove(m_registry.find(registration)); 69 m_registry.erase(m_registry.find(registration));
70 } 70 }
71 71
72 DEFINE_INLINE_TRACE() { 72 DEFINE_INLINE_TRACE() {
73 visitor->trace(m_registry); 73 visitor->trace(m_registry);
74 visitor->trace(m_transientRegistry); 74 visitor->trace(m_transientRegistry);
75 } 75 }
76 76
77 DEFINE_INLINE_TRACE_WRAPPERS() { 77 DEFINE_INLINE_TRACE_WRAPPERS() {
78 for (auto registration : m_registry) { 78 for (auto registration : m_registry) {
79 visitor->traceWrappers(registration); 79 visitor->traceWrappers(registration);
(...skipping 100 matching lines...) Expand 10 before | Expand all | Expand 10 after
180 180
181 protected: 181 protected:
182 unsigned m_isElementRareData : 1; 182 unsigned m_isElementRareData : 1;
183 }; 183 };
184 184
185 DEFINE_TRAIT_FOR_TRACE_WRAPPERS(NodeRareData); 185 DEFINE_TRAIT_FOR_TRACE_WRAPPERS(NodeRareData);
186 186
187 } // namespace blink 187 } // namespace blink
188 188
189 #endif // NodeRareData_h 189 #endif // NodeRareData_h
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/core/dom/Fullscreen.cpp ('k') | third_party/WebKit/Source/core/dom/SpaceSplitString.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698