OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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_GLUE_PREFERENCE_DATA_TYPE_CONTROLLER_H__ | 5 #ifndef CHROME_BROWSER_SYNC_GLUE_PREFERENCE_DATA_TYPE_CONTROLLER_H__ |
6 #define CHROME_BROWSER_SYNC_GLUE_PREFERENCE_DATA_TYPE_CONTROLLER_H__ | 6 #define CHROME_BROWSER_SYNC_GLUE_PREFERENCE_DATA_TYPE_CONTROLLER_H__ |
7 #pragma once | 7 #pragma once |
8 | 8 |
9 #include <string> | 9 #include <string> |
10 | 10 |
11 #include "base/compiler_specific.h" | 11 #include "base/compiler_specific.h" |
| 12 #include "chrome/browser/sync/glue/generic_change_processor.h" |
12 #include "chrome/browser/sync/glue/frontend_data_type_controller.h" | 13 #include "chrome/browser/sync/glue/frontend_data_type_controller.h" |
13 | 14 |
14 namespace browser_sync { | 15 namespace browser_sync { |
15 | 16 |
16 class PreferenceDataTypeController : public FrontendDataTypeController { | 17 class PreferenceDataTypeController : public FrontendDataTypeController { |
17 public: | 18 public: |
18 PreferenceDataTypeController( | 19 PreferenceDataTypeController( |
19 ProfileSyncFactory* profile_sync_factory, | 20 ProfileSyncFactory* profile_sync_factory, |
20 Profile* profile, | 21 Profile* profile, |
21 ProfileSyncService* sync_service); | 22 ProfileSyncService* sync_service); |
22 virtual ~PreferenceDataTypeController(); | 23 virtual ~PreferenceDataTypeController(); |
23 | 24 |
24 // FrontendDataTypeController implementation. | 25 // FrontendDataTypeController implementation. |
25 virtual syncable::ModelType type() const OVERRIDE; | 26 virtual syncable::ModelType type() const OVERRIDE; |
26 | 27 |
| 28 protected: |
| 29 virtual GenericChangeProcessor* change_processor() const OVERRIDE; |
| 30 |
27 private: | 31 private: |
28 // FrontendDataTypeController implementations. | 32 // FrontendDataTypeController implementations. |
29 virtual void CreateSyncComponents() OVERRIDE; | 33 virtual void CreateSyncComponents() OVERRIDE; |
30 virtual void RecordUnrecoverableError( | 34 virtual void RecordUnrecoverableError( |
31 const tracked_objects::Location& from_here, | 35 const tracked_objects::Location& from_here, |
32 const std::string& message) OVERRIDE; | 36 const std::string& message) OVERRIDE; |
33 virtual void RecordAssociationTime(base::TimeDelta time) OVERRIDE; | 37 virtual void RecordAssociationTime(base::TimeDelta time) OVERRIDE; |
34 virtual void RecordStartFailure(StartResult result) OVERRIDE; | 38 virtual void RecordStartFailure(StartResult result) OVERRIDE; |
35 | 39 |
| 40 scoped_ptr<GenericChangeProcessor> change_processor_; |
| 41 |
36 DISALLOW_COPY_AND_ASSIGN(PreferenceDataTypeController); | 42 DISALLOW_COPY_AND_ASSIGN(PreferenceDataTypeController); |
37 }; | 43 }; |
38 | 44 |
39 } // namespace browser_sync | 45 } // namespace browser_sync |
40 | 46 |
41 #endif // CHROME_BROWSER_SYNC_GLUE_PREFERENCE_DATA_TYPE_CONTROLLER_H__ | 47 #endif // CHROME_BROWSER_SYNC_GLUE_PREFERENCE_DATA_TYPE_CONTROLLER_H__ |
OLD | NEW |