OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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/login/login_prompt.h" | 5 #include "chrome/browser/ui/login/login_prompt.h" |
6 | 6 |
7 #include <vector> | 7 #include <vector> |
8 | 8 |
9 #include "base/bind.h" | 9 #include "base/bind.h" |
10 #include "base/command_line.h" | 10 #include "base/command_line.h" |
11 #include "base/strings/string_util.h" | 11 #include "base/strings/string_util.h" |
12 #include "base/strings/utf_string_conversions.h" | 12 #include "base/strings/utf_string_conversions.h" |
13 #include "base/synchronization/lock.h" | 13 #include "base/synchronization/lock.h" |
14 #include "chrome/browser/chrome_notification_types.h" | 14 #include "chrome/browser/chrome_notification_types.h" |
15 #include "chrome/browser/password_manager/chrome_password_manager_client.h" | 15 #include "chrome/browser/password_manager/chrome_password_manager_client.h" |
16 #include "chrome/browser/prerender/prerender_contents.h" | 16 #include "chrome/browser/prerender/prerender_contents.h" |
17 #include "chrome/browser/tab_contents/tab_util.h" | 17 #include "chrome/browser/tab_contents/tab_util.h" |
18 #include "chrome/browser/ui/login/login_interstitial_delegate.h" | 18 #include "chrome/browser/ui/login/login_interstitial_delegate.h" |
| 19 #include "chrome/grit/generated_resources.h" |
19 #include "components/password_manager/core/browser/browser_save_password_progres
s_logger.h" | 20 #include "components/password_manager/core/browser/browser_save_password_progres
s_logger.h" |
20 #include "components/password_manager/core/browser/password_manager.h" | 21 #include "components/password_manager/core/browser/password_manager.h" |
21 #include "content/public/browser/browser_thread.h" | 22 #include "content/public/browser/browser_thread.h" |
22 #include "content/public/browser/notification_registrar.h" | 23 #include "content/public/browser/notification_registrar.h" |
23 #include "content/public/browser/notification_service.h" | 24 #include "content/public/browser/notification_service.h" |
24 #include "content/public/browser/render_frame_host.h" | 25 #include "content/public/browser/render_frame_host.h" |
25 #include "content/public/browser/resource_dispatcher_host.h" | 26 #include "content/public/browser/resource_dispatcher_host.h" |
26 #include "content/public/browser/resource_request_info.h" | 27 #include "content/public/browser/resource_request_info.h" |
27 #include "content/public/browser/web_contents.h" | 28 #include "content/public/browser/web_contents.h" |
28 #include "grit/generated_resources.h" | |
29 #include "net/base/auth.h" | 29 #include "net/base/auth.h" |
30 #include "net/base/load_flags.h" | 30 #include "net/base/load_flags.h" |
31 #include "net/base/net_util.h" | 31 #include "net/base/net_util.h" |
32 #include "net/http/http_transaction_factory.h" | 32 #include "net/http/http_transaction_factory.h" |
33 #include "net/url_request/url_request.h" | 33 #include "net/url_request/url_request.h" |
34 #include "net/url_request/url_request_context.h" | 34 #include "net/url_request/url_request_context.h" |
35 #include "ui/base/l10n/l10n_util.h" | 35 #include "ui/base/l10n/l10n_util.h" |
36 #include "ui/gfx/text_elider.h" | 36 #include "ui/gfx/text_elider.h" |
37 | 37 |
38 using autofill::PasswordForm; | 38 using autofill::PasswordForm; |
(...skipping 506 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
545 net::URLRequest* request) { | 545 net::URLRequest* request) { |
546 bool is_main_frame = (request->load_flags() & net::LOAD_MAIN_FRAME) != 0; | 546 bool is_main_frame = (request->load_flags() & net::LOAD_MAIN_FRAME) != 0; |
547 LoginHandler* handler = LoginHandler::Create(auth_info, request); | 547 LoginHandler* handler = LoginHandler::Create(auth_info, request); |
548 BrowserThread::PostTask( | 548 BrowserThread::PostTask( |
549 BrowserThread::UI, FROM_HERE, | 549 BrowserThread::UI, FROM_HERE, |
550 base::Bind(&LoginDialogCallback, request->url(), | 550 base::Bind(&LoginDialogCallback, request->url(), |
551 make_scoped_refptr(auth_info), make_scoped_refptr(handler), | 551 make_scoped_refptr(auth_info), make_scoped_refptr(handler), |
552 is_main_frame)); | 552 is_main_frame)); |
553 return handler; | 553 return handler; |
554 } | 554 } |
OLD | NEW |