| OLD | NEW |
| 1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 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/prefs/preferences_connection_manager.h" | 5 #include "chrome/browser/prefs/preferences_connection_manager.h" |
| 6 | 6 |
| 7 #include "base/memory/ptr_util.h" |
| 7 #include "chrome/browser/browser_process.h" | 8 #include "chrome/browser/browser_process.h" |
| 8 #include "chrome/browser/prefs/preferences_manager.h" | 9 #include "chrome/browser/prefs/preferences_manager.h" |
| 9 #include "chrome/browser/profiles/profile.h" | 10 #include "chrome/browser/profiles/profile.h" |
| 10 #include "chrome/browser/profiles/profile_manager.h" | 11 #include "chrome/browser/profiles/profile_manager.h" |
| 11 #include "chrome/browser/signin/profile_oauth2_token_service_factory.h" | 12 #include "chrome/browser/signin/profile_oauth2_token_service_factory.h" |
| 12 #include "components/keyed_service/content/browser_context_keyed_service_shutdow
n_notifier_factory.h" | 13 #include "components/keyed_service/content/browser_context_keyed_service_shutdow
n_notifier_factory.h" |
| 13 #include "services/service_manager/public/cpp/interface_registry.h" | 14 #include "services/service_manager/public/cpp/interface_registry.h" |
| 14 | 15 |
| 15 namespace { | 16 namespace { |
| 16 | 17 |
| (...skipping 79 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 96 base::Bind(&PreferencesConnectionManager::OnProfileDestroyed, | 97 base::Bind(&PreferencesConnectionManager::OnProfileDestroyed, |
| 97 base::Unretained(this))); | 98 base::Unretained(this))); |
| 98 } | 99 } |
| 99 | 100 |
| 100 bool PreferencesConnectionManager::OnConnect( | 101 bool PreferencesConnectionManager::OnConnect( |
| 101 const service_manager::ServiceInfo& remote_info, | 102 const service_manager::ServiceInfo& remote_info, |
| 102 service_manager::InterfaceRegistry* registry) { | 103 service_manager::InterfaceRegistry* registry) { |
| 103 registry->AddInterface<prefs::mojom::PreferencesManager>(this); | 104 registry->AddInterface<prefs::mojom::PreferencesManager>(this); |
| 104 return true; | 105 return true; |
| 105 } | 106 } |
| OLD | NEW |