OLD | NEW |
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2013 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/services/gcm/gcm_profile_service_factory.h" | 5 #include "chrome/browser/services/gcm/gcm_profile_service_factory.h" |
6 | 6 |
7 #include "base/memory/scoped_ptr.h" | 7 #include "base/memory/scoped_ptr.h" |
8 #include "chrome/browser/profiles/incognito_helpers.h" | 8 #include "chrome/browser/profiles/incognito_helpers.h" |
9 #include "chrome/browser/profiles/profile.h" | 9 #include "chrome/browser/profiles/profile.h" |
10 #include "chrome/browser/services/gcm/gcm_client_factory.h" | |
11 #include "chrome/browser/services/gcm/gcm_profile_service.h" | 10 #include "chrome/browser/services/gcm/gcm_profile_service.h" |
12 #include "chrome/browser/signin/profile_oauth2_token_service_factory.h" | 11 #include "chrome/browser/signin/profile_oauth2_token_service_factory.h" |
13 #include "chrome/browser/signin/signin_manager_factory.h" | 12 #include "chrome/browser/signin/signin_manager_factory.h" |
| 13 #include "components/gcm/gcm_client_factory.h" |
14 #include "components/keyed_service/content/browser_context_dependency_manager.h" | 14 #include "components/keyed_service/content/browser_context_dependency_manager.h" |
15 | 15 |
16 #if !defined(OS_ANDROID) | 16 #if !defined(OS_ANDROID) |
17 #include "chrome/browser/ui/webui/signin/login_ui_service_factory.h" | 17 #include "chrome/browser/ui/webui/signin/login_ui_service_factory.h" |
18 #endif | 18 #endif |
19 | 19 |
20 namespace gcm { | 20 namespace gcm { |
21 | 21 |
22 // static | 22 // static |
23 GCMProfileService* GCMProfileServiceFactory::GetForProfile(Profile* profile) { | 23 GCMProfileService* GCMProfileServiceFactory::GetForProfile(Profile* profile) { |
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
56 service->Initialize(gcm_client_factory.Pass()); | 56 service->Initialize(gcm_client_factory.Pass()); |
57 return service; | 57 return service; |
58 } | 58 } |
59 | 59 |
60 content::BrowserContext* GCMProfileServiceFactory::GetBrowserContextToUse( | 60 content::BrowserContext* GCMProfileServiceFactory::GetBrowserContextToUse( |
61 content::BrowserContext* context) const { | 61 content::BrowserContext* context) const { |
62 return chrome::GetBrowserContextOwnInstanceInIncognito(context); | 62 return chrome::GetBrowserContextOwnInstanceInIncognito(context); |
63 } | 63 } |
64 | 64 |
65 } // namespace gcm | 65 } // namespace gcm |
OLD | NEW |