| OLD | NEW |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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 COMPONENTS_ARC_ARC_SERVICE_MANAGER_H_ | 5 #ifndef COMPONENTS_ARC_ARC_SERVICE_MANAGER_H_ |
| 6 #define COMPONENTS_ARC_ARC_SERVICE_MANAGER_H_ | 6 #define COMPONENTS_ARC_ARC_SERVICE_MANAGER_H_ |
| 7 | 7 |
| 8 #include <memory> | 8 #include <memory> |
| 9 #include <vector> | 9 #include <vector> |
| 10 | 10 |
| (...skipping 26 matching lines...) Expand all Loading... |
| 37 // Adds a service to the managed services list. | 37 // Adds a service to the managed services list. |
| 38 void AddService(std::unique_ptr<ArcService> service); | 38 void AddService(std::unique_ptr<ArcService> service); |
| 39 | 39 |
| 40 // Gets the global instance of the ARC Service Manager. This can only be | 40 // Gets the global instance of the ARC Service Manager. This can only be |
| 41 // called on the thread that this class was created on. | 41 // called on the thread that this class was created on. |
| 42 static ArcServiceManager* Get(); | 42 static ArcServiceManager* Get(); |
| 43 | 43 |
| 44 // Called when the main profile is initialized after user logs in. | 44 // Called when the main profile is initialized after user logs in. |
| 45 void OnPrimaryUserProfilePrepared( | 45 void OnPrimaryUserProfilePrepared( |
| 46 const AccountId& account_id, | 46 const AccountId& account_id, |
| 47 std::unique_ptr<BooleanPrefMember> arc_enabled_pref); | 47 std::unique_ptr<BooleanPrefMember> arc_enabled_pref, |
| 48 PrefService* pref_service); |
| 48 | 49 |
| 49 // Called once the windowing system (ash) has been started. | 50 // Called once the windowing system (ash) has been started. |
| 50 void OnAshStarted(); | 51 void OnAshStarted(); |
| 51 | 52 |
| 52 // Called to shut down all ARC services. | 53 // Called to shut down all ARC services. |
| 53 void Shutdown(); | 54 void Shutdown(); |
| 54 | 55 |
| 55 scoped_refptr<base::TaskRunner> blocking_task_runner() const { | 56 scoped_refptr<base::TaskRunner> blocking_task_runner() const { |
| 56 return blocking_task_runner_; | 57 return blocking_task_runner_; |
| 57 } | 58 } |
| (...skipping 23 matching lines...) Expand all Loading... |
| 81 // True once the window manager service got added, barring adding any more | 82 // True once the window manager service got added, barring adding any more |
| 82 // of those since OnAshStarted() might be called multiple times. | 83 // of those since OnAshStarted() might be called multiple times. |
| 83 bool on_ash_started_called_ = false; | 84 bool on_ash_started_called_ = false; |
| 84 | 85 |
| 85 DISALLOW_COPY_AND_ASSIGN(ArcServiceManager); | 86 DISALLOW_COPY_AND_ASSIGN(ArcServiceManager); |
| 86 }; | 87 }; |
| 87 | 88 |
| 88 } // namespace arc | 89 } // namespace arc |
| 89 | 90 |
| 90 #endif // COMPONENTS_ARC_ARC_SERVICE_MANAGER_H_ | 91 #endif // COMPONENTS_ARC_ARC_SERVICE_MANAGER_H_ |
| OLD | NEW |