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/login/auth/auth_prewarmer.h" | 5 #include "chrome/browser/chromeos/login/auth/auth_prewarmer.h" |
6 | 6 |
7 #include "chrome/browser/chrome_notification_types.h" | 7 #include "chrome/browser/chrome_notification_types.h" |
8 #include "chrome/browser/chromeos/profiles/profile_helper.h" | 8 #include "chrome/browser/chromeos/profiles/profile_helper.h" |
9 #include "chrome/browser/net/chrome_url_request_context.h" | 9 #include "chrome/browser/net/chrome_url_request_context.h" |
10 #include "chrome/browser/net/preconnect.h" | 10 #include "chrome/browser/net/preconnect.h" |
11 #include "chromeos/network/network_handler.h" | 11 #include "chromeos/network/network_handler.h" |
12 #include "chromeos/network/network_state.h" | 12 #include "chromeos/network/network_state.h" |
13 #include "chromeos/network/network_state_handler.h" | 13 #include "chromeos/network/network_state_handler.h" |
14 #include "chromeos/network/shill_property_util.h" | |
15 #include "content/public/browser/browser_thread.h" | 14 #include "content/public/browser/browser_thread.h" |
16 #include "google_apis/gaia/gaia_urls.h" | 15 #include "google_apis/gaia/gaia_urls.h" |
17 #include "url/gurl.h" | 16 #include "url/gurl.h" |
18 | 17 |
19 namespace chromeos { | 18 namespace chromeos { |
20 | 19 |
21 AuthPrewarmer::AuthPrewarmer() | 20 AuthPrewarmer::AuthPrewarmer() |
22 : doing_prewarm_(false) { | 21 : doing_prewarm_(false) { |
23 } | 22 } |
24 | 23 |
(...skipping 88 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
113 bool AuthPrewarmer::IsNetworkConnected() const { | 112 bool AuthPrewarmer::IsNetworkConnected() const { |
114 NetworkStateHandler* nsh = NetworkHandler::Get()->network_state_handler(); | 113 NetworkStateHandler* nsh = NetworkHandler::Get()->network_state_handler(); |
115 return (nsh->ConnectedNetworkByType(NetworkTypePattern::Default()) != NULL); | 114 return (nsh->ConnectedNetworkByType(NetworkTypePattern::Default()) != NULL); |
116 } | 115 } |
117 | 116 |
118 net::URLRequestContextGetter* AuthPrewarmer::GetRequestContext() const { | 117 net::URLRequestContextGetter* AuthPrewarmer::GetRequestContext() const { |
119 return ProfileHelper::GetSigninProfile()->GetRequestContext(); | 118 return ProfileHelper::GetSigninProfile()->GetRequestContext(); |
120 } | 119 } |
121 | 120 |
122 } // namespace chromeos | 121 } // namespace chromeos |
OLD | NEW |