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

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

Issue 1089933004: DevTools: make DOMNodeIds a trivial wrapper around WeakIdentifierMap (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 5 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 | Annotate | Revision Log
« no previous file with comments | « Source/core/dom/WeakIdentifierMap.h ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #ifndef WeakNodeMap_h
6 #define WeakNodeMap_h
7
8 // Oilpan supports weak maps, so we no longer need WeakNodeMap.
9 #if !ENABLE(OILPAN)
10
11 #include "core/dom/Node.h"
12 #include "core/dom/WeakIdentifierMap.h"
13
14 namespace blink {
15
16 template<> struct WeakIdentifierMapTraits<Node> {
17 static void removedFromIdentifierMap(Node* node) { node->clearFlag(Node::Has WeakReferencesFlag); }
18 static void addedToIdentifierMap(Node* node) { node->setFlag(Node::HasWeakRe ferencesFlag); }
19 };
20
21 typedef WeakIdentifierMap<Node> WeakNodeMap;
22
23 } // namespace blink
24
25 #endif // !ENABLE(OILPAN)
26
27 #endif // WeakNodeMap_h
OLDNEW
« no previous file with comments | « Source/core/dom/WeakIdentifierMap.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698