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