Don't sync SUPERVISED_USER_SHARED_SETTINGS for child accounts
[chromium-blink-merge.git] / chrome / browser / supervised_user / supervised_user_sync_data_type_controller.h
blob5e4faee87b9294b670c63c48f9b5bcc21a47f287
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.
5 #ifndef CHROME_BROWSER_SUPERVISED_USER_SUPERVISED_USER_SYNC_DATA_TYPE_CONTROLLER_H_
6 #define CHROME_BROWSER_SUPERVISED_USER_SUPERVISED_USER_SYNC_DATA_TYPE_CONTROLLER_H_
8 #include "base/macros.h"
9 #include "components/sync_driver/data_type_controller.h"
10 #include "components/sync_driver/ui_data_type_controller.h"
12 namespace sync_driver {
13 class SyncApiComponentFactory;
16 class Profile;
18 // A UIDataTypeController for supervised user sync datatypes, which enables or
19 // disables these types based on the profile's IsSupervised state.
20 class SupervisedUserSyncDataTypeController
21 : public sync_driver::UIDataTypeController {
22 public:
23 SupervisedUserSyncDataTypeController(
24 syncer::ModelType type,
25 sync_driver::SyncApiComponentFactory* sync_factory,
26 Profile* profile);
28 bool ReadyForStart() const override;
30 private:
31 // DataTypeController is RefCounted.
32 ~SupervisedUserSyncDataTypeController() override;
34 Profile* profile_;
36 DISALLOW_COPY_AND_ASSIGN(SupervisedUserSyncDataTypeController);
39 #endif // CHROME_BROWSER_SUPERVISED_USER_SUPERVISED_USER_SYNC_DATA_TYPE_CONTROLLER_H_