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

Side by Side Diff: chrome/browser/sync/glue/local_device_info_provider_impl.h

Issue 367153005: Sync: Refactoring of DEVICE_INFO syncable type - Part 1 (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fixed scoped_ptr issue in ProfileSyncService constructor Created 6 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
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 CHROME_BROWSER_SYNC_GLUE_LOCAL_DEVICE_INFO_PROVIDER_IMPL_H_
6 #define CHROME_BROWSER_SYNC_GLUE_LOCAL_DEVICE_INFO_PROVIDER_IMPL_H_
7
8 #include "base/memory/weak_ptr.h"
9 #include "chrome/browser/sync/glue/device_info.h"
10 #include "chrome/browser/sync/glue/local_device_info_provider.h"
11
12 namespace browser_sync {
13
14 class LocalDeviceInfoProviderImpl : public LocalDeviceInfoProvider {
15 public:
16 LocalDeviceInfoProviderImpl();
17 virtual ~LocalDeviceInfoProviderImpl();
18
19 // LocalDeviceInfoProvider implementation.
20 virtual const DeviceInfo* GetLocalDeviceInfo() const OVERRIDE;
21 virtual std::string GetLocalSyncCacheGUID() const OVERRIDE;
22 virtual void Initialize(const std::string& cache_guid) OVERRIDE;
23 virtual scoped_ptr<Subscription> RegisterOnInitializedCallback(
24 const base::Closure& callback) OVERRIDE;
25
26 private:
27 void InitializeContinuation(const DeviceInfo& local_info);
28
29 std::string cache_guid_;
30 scoped_ptr<DeviceInfo> local_device_info_;
31 base::CallbackList<void(void)> callback_list_;
32 base::WeakPtrFactory<LocalDeviceInfoProviderImpl> weak_factory_;
33
34 DISALLOW_COPY_AND_ASSIGN(LocalDeviceInfoProviderImpl);
35 };
36
37 } // namespace browser_sync
38
39 #endif // CHROME_BROWSER_SYNC_GLUE_LOCAL_DEVICE_INFO_PROVIDER_IMPL_H_
OLDNEW
« no previous file with comments | « chrome/browser/sync/glue/local_device_info_provider.h ('k') | chrome/browser/sync/glue/local_device_info_provider_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698