Chromium Code Reviews| OLD | NEW |
|---|---|
| (Empty) | |
| 1 // Copyright 2012 Google Inc. All Rights Reserved. | |
| 2 // Author: khorimoto@google.com (Kyle Horimoto) | |
|
Evan Stade
2012/04/24 19:02:43
ditto
Kyle Horimoto
2012/04/24 21:09:59
Done.
| |
| 3 | |
| 4 #include "chrome/browser/ui/webui/chrome_url_data_manager_factory.h" | |
| 5 | |
| 6 #include "chrome/browser/profiles/profile.h" | |
| 7 #include "chrome/browser/profiles/profile_dependency_manager.h" | |
| 8 #include "chrome/browser/profiles/profile_keyed_service.h" | |
| 9 | |
| 10 // static | |
| 11 ChromeURLDataManager* ChromeURLDataManagerFactory::GetForProfile( | |
| 12 Profile* profile) { | |
| 13 return static_cast<ChromeURLDataManager*>( | |
| 14 GetInstance()->GetServiceForProfile(profile, true)); | |
|
Evan Stade
2012/04/24 19:02:43
wrong indent (should be just 4 spaces)
Kyle Horimoto
2012/04/24 21:09:59
Done.
| |
| 15 } | |
| 16 | |
| 17 // static | |
| 18 ChromeURLDataManagerFactory* ChromeURLDataManagerFactory::GetInstance() { | |
| 19 return Singleton<ChromeURLDataManagerFactory>::get(); | |
| 20 } | |
| 21 | |
| 22 ChromeURLDataManagerFactory::ChromeURLDataManagerFactory() | |
| 23 : ProfileKeyedServiceFactory("ChromeURLDataManager", | |
| 24 ProfileDependencyManager::GetInstance()){ | |
| 25 } | |
| 26 | |
| 27 ChromeURLDataManagerFactory::~ChromeURLDataManagerFactory() { | |
| 28 } | |
| 29 | |
| 30 ProfileKeyedService* ChromeURLDataManagerFactory::BuildServiceInstanceFor( | |
| 31 Profile* profile) const { | |
| 32 return new ChromeURLDataManager( | |
| 33 profile->GetChromeURLDataManagerBackendGetter()); | |
| 34 } | |
| 35 | |
| 36 bool ChromeURLDataManagerFactory::ServiceHasOwnInstanceInIncognito() { | |
| 37 return true; | |
| 38 } | |
| OLD | NEW |