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

Side by Side Diff: chrome/browser/sync/engine/all_status.h

Issue 6142009: Upating the app, ceee, chrome, ipc, media, and net directories to use the correct lock.h file. (Closed) Base URL: http://git.chromium.org/git/chromium.git@trunk
Patch Set: Unified patch updating all references to the new base/synchronization/lock.h Created 9 years, 11 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 | « chrome/browser/speech/speech_input_manager.cc ('k') | chrome/browser/sync/engine/all_status.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) 2006-2009 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2006-2009 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 // The AllStatus object watches various sync engine components and aggregates 5 // The AllStatus object watches various sync engine components and aggregates
6 // the status of all of them into one place. 6 // the status of all of them into one place.
7 7
8 #ifndef CHROME_BROWSER_SYNC_ENGINE_ALL_STATUS_H_ 8 #ifndef CHROME_BROWSER_SYNC_ENGINE_ALL_STATUS_H_
9 #define CHROME_BROWSER_SYNC_ENGINE_ALL_STATUS_H_ 9 #define CHROME_BROWSER_SYNC_ENGINE_ALL_STATUS_H_
10 #pragma once 10 #pragma once
11 11
12 #include <map> 12 #include <map>
13 13
14 #include "base/lock.h"
15 #include "base/scoped_ptr.h" 14 #include "base/scoped_ptr.h"
15 #include "base/synchronization/lock.h"
16 #include "chrome/browser/sync/engine/syncer_types.h" 16 #include "chrome/browser/sync/engine/syncer_types.h"
17 17
18 namespace browser_sync { 18 namespace browser_sync {
19 19
20 class ScopedStatusLock; 20 class ScopedStatusLock;
21 class ServerConnectionManager; 21 class ServerConnectionManager;
22 class Syncer; 22 class Syncer;
23 class SyncerThread; 23 class SyncerThread;
24 struct AuthWatcherEvent; 24 struct AuthWatcherEvent;
25 struct ServerConnectionEvent; 25 struct ServerConnectionEvent;
(...skipping 80 matching lines...) Expand 10 before | Expand all | Expand 10 after
106 // Examines syncer to calculate syncing and the unsynced count, 106 // Examines syncer to calculate syncing and the unsynced count,
107 // and returns a Status with new values. 107 // and returns a Status with new values.
108 Status CalcSyncing(const SyncEngineEvent& event) const; 108 Status CalcSyncing(const SyncEngineEvent& event) const;
109 Status CreateBlankStatus() const; 109 Status CreateBlankStatus() const;
110 110
111 // Examines status to see what has changed, updates old_status in place. 111 // Examines status to see what has changed, updates old_status in place.
112 void CalcStatusChanges(); 112 void CalcStatusChanges();
113 113
114 Status status_; 114 Status status_;
115 115
116 mutable Lock mutex_; // Protects all data members. 116 mutable base::Lock mutex_; // Protects all data members.
117 DISALLOW_COPY_AND_ASSIGN(AllStatus); 117 DISALLOW_COPY_AND_ASSIGN(AllStatus);
118 }; 118 };
119 119
120 class ScopedStatusLock { 120 class ScopedStatusLock {
121 public: 121 public:
122 explicit ScopedStatusLock(AllStatus* allstatus); 122 explicit ScopedStatusLock(AllStatus* allstatus);
123 ~ScopedStatusLock(); 123 ~ScopedStatusLock();
124 protected: 124 protected:
125 AllStatus* allstatus_; 125 AllStatus* allstatus_;
126 }; 126 };
127 127
128 } // namespace browser_sync 128 } // namespace browser_sync
129 129
130 #endif // CHROME_BROWSER_SYNC_ENGINE_ALL_STATUS_H_ 130 #endif // CHROME_BROWSER_SYNC_ENGINE_ALL_STATUS_H_
OLDNEW
« no previous file with comments | « chrome/browser/speech/speech_input_manager.cc ('k') | chrome/browser/sync/engine/all_status.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698