| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 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 | 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 #include "chrome/browser/chromeos/ownership/owner_settings_service_chromeos_fact
ory.h" | 5 #include "chrome/browser/chromeos/ownership/owner_settings_service_chromeos_fact
ory.h" |
| 6 | 6 |
| 7 #include "base/path_service.h" | 7 #include "base/path_service.h" |
| 8 #include "chrome/browser/chromeos/ownership/owner_settings_service_chromeos.h" | 8 #include "chrome/browser/chromeos/ownership/owner_settings_service_chromeos.h" |
| 9 #include "chrome/browser/chromeos/profiles/profile_helper.h" | 9 #include "chrome/browser/chromeos/profiles/profile_helper.h" |
| 10 #include "chrome/browser/chromeos/settings/device_settings_service.h" | 10 #include "chrome/browser/chromeos/settings/device_settings_service.h" |
| (...skipping 22 matching lines...) Expand all Loading... |
| 33 : BrowserContextKeyedServiceFactory( | 33 : BrowserContextKeyedServiceFactory( |
| 34 "OwnerSettingsService", | 34 "OwnerSettingsService", |
| 35 BrowserContextDependencyManager::GetInstance()) { | 35 BrowserContextDependencyManager::GetInstance()) { |
| 36 } | 36 } |
| 37 | 37 |
| 38 OwnerSettingsServiceChromeOSFactory::~OwnerSettingsServiceChromeOSFactory() { | 38 OwnerSettingsServiceChromeOSFactory::~OwnerSettingsServiceChromeOSFactory() { |
| 39 } | 39 } |
| 40 | 40 |
| 41 // static | 41 // static |
| 42 OwnerSettingsServiceChromeOS* | 42 OwnerSettingsServiceChromeOS* |
| 43 OwnerSettingsServiceChromeOSFactory::GetForBrowserContext( | 43 OwnerSettingsServiceChromeOSFactory::GetForProfile(Profile* profile) { |
| 44 content::BrowserContext* context) { | |
| 45 return static_cast<OwnerSettingsServiceChromeOS*>( | 44 return static_cast<OwnerSettingsServiceChromeOS*>( |
| 46 GetInstance()->GetServiceForBrowserContext(context, true)); | 45 GetInstance()->GetServiceForBrowserContext(profile, true)); |
| 47 } | 46 } |
| 48 | 47 |
| 49 // static | 48 // static |
| 50 OwnerSettingsServiceChromeOSFactory* | 49 OwnerSettingsServiceChromeOSFactory* |
| 51 OwnerSettingsServiceChromeOSFactory::GetInstance() { | 50 OwnerSettingsServiceChromeOSFactory::GetInstance() { |
| 52 return Singleton<OwnerSettingsServiceChromeOSFactory>::get(); | 51 return Singleton<OwnerSettingsServiceChromeOSFactory>::get(); |
| 53 } | 52 } |
| 54 | 53 |
| 55 // static | 54 // static |
| 56 void OwnerSettingsServiceChromeOSFactory::SetDeviceSettingsServiceForTesting( | 55 void OwnerSettingsServiceChromeOSFactory::SetDeviceSettingsServiceForTesting( |
| (...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 90 const { | 89 const { |
| 91 return true; | 90 return true; |
| 92 } | 91 } |
| 93 | 92 |
| 94 KeyedService* OwnerSettingsServiceChromeOSFactory::BuildServiceInstanceFor( | 93 KeyedService* OwnerSettingsServiceChromeOSFactory::BuildServiceInstanceFor( |
| 95 content::BrowserContext* context) const { | 94 content::BrowserContext* context) const { |
| 96 return BuildInstanceFor(context); | 95 return BuildInstanceFor(context); |
| 97 } | 96 } |
| 98 | 97 |
| 99 } // namespace chromeos | 98 } // namespace chromeos |
| OLD | NEW |