OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 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/ui/webui/signin/inline_login_handler.h" | 5 #include "chrome/browser/ui/webui/signin/inline_login_handler.h" |
6 | 6 |
7 #include <limits.h> | 7 #include <limits.h> |
8 | 8 |
9 #include "base/bind.h" | 9 #include "base/bind.h" |
10 #include "base/prefs/pref_service.h" | |
11 #include "base/strings/string_number_conversions.h" | 10 #include "base/strings/string_number_conversions.h" |
12 #include "base/strings/utf_string_conversions.h" | 11 #include "base/strings/utf_string_conversions.h" |
13 #include "base/values.h" | 12 #include "base/values.h" |
14 #include "chrome/browser/browser_process.h" | 13 #include "chrome/browser/browser_process.h" |
15 #include "chrome/browser/extensions/signin/gaia_auth_extension_loader.h" | 14 #include "chrome/browser/extensions/signin/gaia_auth_extension_loader.h" |
16 #include "chrome/browser/profiles/profile.h" | 15 #include "chrome/browser/profiles/profile.h" |
17 #include "chrome/browser/signin/signin_promo.h" | 16 #include "chrome/browser/signin/signin_promo.h" |
18 #include "chrome/browser/ui/browser_navigator.h" | 17 #include "chrome/browser/ui/browser_navigator.h" |
19 #include "chrome/browser/ui/browser_navigator_params.h" | 18 #include "chrome/browser/ui/browser_navigator_params.h" |
20 #include "chrome/common/pref_names.h" | 19 #include "chrome/common/pref_names.h" |
21 #include "components/metrics/metrics_pref_names.h" | 20 #include "components/metrics/metrics_pref_names.h" |
| 21 #include "components/prefs/pref_service.h" |
22 #include "components/signin/core/common/signin_pref_names.h" | 22 #include "components/signin/core/common/signin_pref_names.h" |
23 #include "content/public/browser/storage_partition.h" | 23 #include "content/public/browser/storage_partition.h" |
24 #include "content/public/browser/user_metrics.h" | 24 #include "content/public/browser/user_metrics.h" |
25 #include "content/public/browser/web_contents.h" | 25 #include "content/public/browser/web_contents.h" |
26 #include "content/public/browser/web_ui.h" | 26 #include "content/public/browser/web_ui.h" |
27 #include "google_apis/gaia/gaia_urls.h" | 27 #include "google_apis/gaia/gaia_urls.h" |
28 #include "net/base/url_util.h" | 28 #include "net/base/url_util.h" |
29 | 29 |
30 InlineLoginHandler::InlineLoginHandler() : weak_ptr_factory_(this) {} | 30 InlineLoginHandler::InlineLoginHandler() : weak_ptr_factory_(this) {} |
31 | 31 |
(...skipping 196 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
228 | 228 |
229 chrome::NavigateParams params( | 229 chrome::NavigateParams params( |
230 profile, | 230 profile, |
231 net::AppendOrReplaceQueryParameter( | 231 net::AppendOrReplaceQueryParameter( |
232 main_frame_url, signin::kSignInPromoQueryKeyConstrained, "0"), | 232 main_frame_url, signin::kSignInPromoQueryKeyConstrained, "0"), |
233 ui::PAGE_TRANSITION_AUTO_TOPLEVEL); | 233 ui::PAGE_TRANSITION_AUTO_TOPLEVEL); |
234 chrome::Navigate(¶ms); | 234 chrome::Navigate(¶ms); |
235 | 235 |
236 web_ui()->CallJavascriptFunction("inline.login.closeDialog"); | 236 web_ui()->CallJavascriptFunction("inline.login.closeDialog"); |
237 } | 237 } |
OLD | NEW |