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

Side by Side Diff: extensions/common/extension_set.h

Issue 1293673002: Create thread-safe RendererExtensionRegistry from ExtensionSet (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 4 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
« no previous file with comments | « no previous file | extensions/common/extension_set.cc » ('j') | extensions/common/extension_set.cc » ('J')
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef EXTENSIONS_COMMON_EXTENSION_SET_H_ 5 #ifndef EXTENSIONS_COMMON_EXTENSION_SET_H_
6 #define EXTENSIONS_COMMON_EXTENSION_SET_H_ 6 #define EXTENSIONS_COMMON_EXTENSION_SET_H_
7 7
8 #include <iterator> 8 #include <iterator>
9 #include <map> 9 #include <map>
10 #include <string> 10 #include <string>
(...skipping 121 matching lines...) Expand 10 before | Expand all | Expand 10 after
132 void set_modification_callback( 132 void set_modification_callback(
133 const ModificationCallback& modification_callback) { 133 const ModificationCallback& modification_callback) {
134 modification_callback_ = modification_callback; 134 modification_callback_ = modification_callback;
135 } 135 }
136 136
137 private: 137 private:
138 FRIEND_TEST_ALL_PREFIXES(ExtensionSetTest, ExtensionSet); 138 FRIEND_TEST_ALL_PREFIXES(ExtensionSetTest, ExtensionSet);
139 139
140 ExtensionMap extensions_; 140 ExtensionMap extensions_;
141 141
142 mutable base::Lock runtime_lock_;
143
142 // If non-null, called with the extension ids in this set after a modification 144 // If non-null, called with the extension ids in this set after a modification
143 // occurred. This is not called on Clear() which is typically used when 145 // occurred. This is not called on Clear() which is typically used when
144 // discarding the set (e.g., on shutdown) and we do not want to track that as 146 // discarding the set (e.g., on shutdown) and we do not want to track that as
145 // a real modification. 147 // a real modification.
146 ModificationCallback modification_callback_; 148 ModificationCallback modification_callback_;
147 149
148 DISALLOW_COPY_AND_ASSIGN(ExtensionSet); 150 DISALLOW_COPY_AND_ASSIGN(ExtensionSet);
149 }; 151 };
150 152
151 } // namespace extensions 153 } // namespace extensions
152 154
153 #endif // EXTENSIONS_COMMON_EXTENSION_SET_H_ 155 #endif // EXTENSIONS_COMMON_EXTENSION_SET_H_
OLDNEW
« no previous file with comments | « no previous file | extensions/common/extension_set.cc » ('j') | extensions/common/extension_set.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698