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/ssl/ssl_client_certificate_selector.h" | 5 #include "chrome/browser/ssl/ssl_client_certificate_selector.h" |
6 | 6 |
7 #include <gtk/gtk.h> | 7 #include <gtk/gtk.h> |
8 | 8 |
9 #include <string> | 9 #include <string> |
10 #include <vector> | 10 #include <vector> |
11 | 11 |
12 #include "base/bind.h" | 12 #include "base/bind.h" |
13 #include "base/i18n/time_formatting.h" | 13 #include "base/i18n/time_formatting.h" |
14 #include "base/logging.h" | 14 #include "base/logging.h" |
15 #include "base/utf_string_conversions.h" | 15 #include "base/utf_string_conversions.h" |
16 #include "chrome/browser/certificate_viewer.h" | 16 #include "chrome/browser/certificate_viewer.h" |
17 #include "chrome/browser/ssl/ssl_client_auth_observer.h" | 17 #include "chrome/browser/ssl/ssl_client_auth_observer.h" |
18 #include "chrome/browser/ui/crypto_module_password_dialog.h" | 18 #include "chrome/browser/ui/crypto_module_password_dialog.h" |
19 #include "chrome/browser/ui/gtk/constrained_window_gtk.h" | 19 #include "chrome/browser/ui/gtk/constrained_window_gtk.h" |
20 #include "chrome/browser/ui/gtk/gtk_util.h" | 20 #include "chrome/browser/ui/gtk/gtk_util.h" |
21 #include "chrome/browser/ui/web_contents_modal_dialog_manager.h" | |
22 #include "chrome/common/net/x509_certificate_model.h" | 21 #include "chrome/common/net/x509_certificate_model.h" |
| 22 #include "components/web_modal/web_contents_modal_dialog_manager.h" |
23 #include "content/public/browser/browser_thread.h" | 23 #include "content/public/browser/browser_thread.h" |
24 #include "grit/generated_resources.h" | 24 #include "grit/generated_resources.h" |
25 #include "net/cert/x509_certificate.h" | 25 #include "net/cert/x509_certificate.h" |
26 #include "net/ssl/ssl_cert_request_info.h" | 26 #include "net/ssl/ssl_cert_request_info.h" |
27 #include "ui/base/gtk/gtk_compat.h" | 27 #include "ui/base/gtk/gtk_compat.h" |
28 #include "ui/base/gtk/gtk_hig_constants.h" | 28 #include "ui/base/gtk/gtk_hig_constants.h" |
29 #include "ui/base/gtk/gtk_signal.h" | 29 #include "ui/base/gtk/gtk_signal.h" |
30 #include "ui/base/gtk/scoped_gobject.h" | 30 #include "ui/base/gtk/scoped_gobject.h" |
31 #include "ui/base/l10n/l10n_util.h" | 31 #include "ui/base/l10n/l10n_util.h" |
32 #include "ui/gfx/native_widget_types.h" | 32 #include "ui/gfx/native_widget_types.h" |
33 | 33 |
34 using content::BrowserThread; | 34 using content::BrowserThread; |
35 using content::WebContents; | 35 using content::WebContents; |
| 36 using web_modal::WebContentsModalDialogManager; |
36 | 37 |
37 namespace { | 38 namespace { |
38 | 39 |
39 enum { | 40 enum { |
40 RESPONSE_SHOW_CERT_INFO = 1, | 41 RESPONSE_SHOW_CERT_INFO = 1, |
41 }; | 42 }; |
42 | 43 |
43 /////////////////////////////////////////////////////////////////////////////// | 44 /////////////////////////////////////////////////////////////////////////////// |
44 // SSLClientCertificateSelector | 45 // SSLClientCertificateSelector |
45 | 46 |
(...skipping 342 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
388 content::WebContents* contents, | 389 content::WebContents* contents, |
389 const net::HttpNetworkSession* network_session, | 390 const net::HttpNetworkSession* network_session, |
390 net::SSLCertRequestInfo* cert_request_info, | 391 net::SSLCertRequestInfo* cert_request_info, |
391 const base::Callback<void(net::X509Certificate*)>& callback) { | 392 const base::Callback<void(net::X509Certificate*)>& callback) { |
392 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI)); | 393 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI)); |
393 (new SSLClientCertificateSelector( | 394 (new SSLClientCertificateSelector( |
394 contents, network_session, cert_request_info, callback))->Show(); | 395 contents, network_session, cert_request_info, callback))->Show(); |
395 } | 396 } |
396 | 397 |
397 } // namespace chrome | 398 } // namespace chrome |
OLD | NEW |