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

Side by Side Diff: chrome/browser/sync/profile_sync_service_factory.h

Issue 2689773002: [Sync] Replace typedef with using. (Closed)
Patch Set: [Sync] Replace typedef with using. Created 3 years, 10 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 | chrome/browser/sync/sync_ui_util.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) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 CHROME_BROWSER_SYNC_PROFILE_SYNC_SERVICE_FACTORY_H_ 5 #ifndef CHROME_BROWSER_SYNC_PROFILE_SYNC_SERVICE_FACTORY_H_
6 #define CHROME_BROWSER_SYNC_PROFILE_SYNC_SERVICE_FACTORY_H_ 6 #define CHROME_BROWSER_SYNC_PROFILE_SYNC_SERVICE_FACTORY_H_
7 7
8 #include <memory> 8 #include <memory>
9 9
10 #include "base/macros.h" 10 #include "base/macros.h"
(...skipping 10 matching lines...) Expand all
21 class ProfileSyncService; 21 class ProfileSyncService;
22 } // namespace browser_sync 22 } // namespace browser_sync
23 23
24 namespace syncer { 24 namespace syncer {
25 class SyncClient; 25 class SyncClient;
26 class SyncService; 26 class SyncService;
27 } // namespace syncer 27 } // namespace syncer
28 28
29 class ProfileSyncServiceFactory : public BrowserContextKeyedServiceFactory { 29 class ProfileSyncServiceFactory : public BrowserContextKeyedServiceFactory {
30 public: 30 public:
31 typedef base::Callback<std::unique_ptr<syncer::SyncClient>(Profile*)> 31 using SyncClientFactory =
32 SyncClientFactory; 32 base::Callback<std::unique_ptr<syncer::SyncClient>(Profile*)>;
33 33
34 static browser_sync::ProfileSyncService* GetForProfile(Profile* profile); 34 static browser_sync::ProfileSyncService* GetForProfile(Profile* profile);
35 static bool HasProfileSyncService(Profile* profile); 35 static bool HasProfileSyncService(Profile* profile);
36 36
37 // Convenience method that returns the ProfileSyncService as a 37 // Convenience method that returns the ProfileSyncService as a
38 // syncer::SyncService. 38 // syncer::SyncService.
39 static syncer::SyncService* GetSyncServiceForBrowserContext( 39 static syncer::SyncService* GetSyncServiceForBrowserContext(
40 content::BrowserContext* context); 40 content::BrowserContext* context);
41 41
42 static ProfileSyncServiceFactory* GetInstance(); 42 static ProfileSyncServiceFactory* GetInstance();
(...skipping 12 matching lines...) Expand all
55 content::BrowserContext* context) const override; 55 content::BrowserContext* context) const override;
56 56
57 // A factory function for overriding the way the SyncClient is created. 57 // A factory function for overriding the way the SyncClient is created.
58 // This is a raw pointer so it can be statically initialized. 58 // This is a raw pointer so it can be statically initialized.
59 static SyncClientFactory* client_factory_; 59 static SyncClientFactory* client_factory_;
60 60
61 DISALLOW_COPY_AND_ASSIGN(ProfileSyncServiceFactory); 61 DISALLOW_COPY_AND_ASSIGN(ProfileSyncServiceFactory);
62 }; 62 };
63 63
64 #endif // CHROME_BROWSER_SYNC_PROFILE_SYNC_SERVICE_FACTORY_H_ 64 #endif // CHROME_BROWSER_SYNC_PROFILE_SYNC_SERVICE_FACTORY_H_
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/sync/sync_ui_util.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698