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

Side by Side Diff: base/observer_list_threadsafe.h

Issue 2937010: Reland r52336. (Closed) Base URL: http://src.chromium.org/git/chromium.git
Patch Set: Created 10 years, 5 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 | « base/message_loop_proxy_impl_unittest.cc ('k') | base/weak_ptr_unittest.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2010 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 BASE_OBSERVER_LIST_THREADSAFE_H_ 5 #ifndef BASE_OBSERVER_LIST_THREADSAFE_H_
6 #define BASE_OBSERVER_LIST_THREADSAFE_H_ 6 #define BASE_OBSERVER_LIST_THREADSAFE_H_
7 7
8 #include <algorithm>
9 #include <map>
8 #include <vector> 10 #include <vector>
9 #include <algorithm>
10 11
11 #include "base/basictypes.h" 12 #include "base/basictypes.h"
12 #include "base/callback.h" 13 #include "base/callback.h"
13 #include "base/logging.h" 14 #include "base/logging.h"
14 #include "base/message_loop.h" 15 #include "base/message_loop.h"
15 #include "base/observer_list.h" 16 #include "base/observer_list.h"
16 #include "base/ref_counted.h" 17 #include "base/ref_counted.h"
17 #include "base/task.h" 18 #include "base/task.h"
18 19
19 /////////////////////////////////////////////////////////////////////////////// 20 ///////////////////////////////////////////////////////////////////////////////
(...skipping 172 matching lines...) Expand 10 before | Expand all | Expand 10 after
192 typedef std::map<MessageLoop*, ObserverList<ObserverType>*> ObserversListMap; 193 typedef std::map<MessageLoop*, ObserverList<ObserverType>*> ObserversListMap;
193 194
194 // These are marked mutable to facilitate having NotifyAll be const. 195 // These are marked mutable to facilitate having NotifyAll be const.
195 Lock list_lock_; // Protects the observer_lists_. 196 Lock list_lock_; // Protects the observer_lists_.
196 ObserversListMap observer_lists_; 197 ObserversListMap observer_lists_;
197 198
198 DISALLOW_COPY_AND_ASSIGN(ObserverListThreadSafe); 199 DISALLOW_COPY_AND_ASSIGN(ObserverListThreadSafe);
199 }; 200 };
200 201
201 #endif // BASE_OBSERVER_LIST_THREADSAFE_H_ 202 #endif // BASE_OBSERVER_LIST_THREADSAFE_H_
OLDNEW
« no previous file with comments | « base/message_loop_proxy_impl_unittest.cc ('k') | base/weak_ptr_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698