Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(154)

Side by Side Diff: ios/chrome/browser/ssl/ios_ssl_error_handler.mm

Issue 2455463004: [ios] Fixed SSL Interstitial reload. (Closed)
Patch Set: Created 4 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « no previous file | ios/web/interstitials/web_interstitial_impl.mm » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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 "ios/chrome/browser/ssl/ios_ssl_error_handler.h" 5 #include "ios/chrome/browser/ssl/ios_ssl_error_handler.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/callback.h" 8 #include "base/callback.h"
9 #include "components/security_interstitials/core/ssl_error_ui.h" 9 #include "components/security_interstitials/core/ssl_error_ui.h"
10 #include "ios/chrome/browser/ssl/ios_ssl_blocking_page.h" 10 #include "ios/chrome/browser/ssl/ios_ssl_blocking_page.h"
11 #import "ios/web/public/navigation_manager.h"
12 #import "ios/web/public/web_state/web_state.h" 11 #import "ios/web/public/web_state/web_state.h"
13 #include "net/ssl/ssl_info.h" 12 #include "net/ssl/ssl_info.h"
14 13
15 // static 14 // static
16 void IOSSSLErrorHandler::HandleSSLError( 15 void IOSSSLErrorHandler::HandleSSLError(
17 web::WebState* web_state, 16 web::WebState* web_state,
18 int cert_error, 17 int cert_error,
19 const net::SSLInfo& info, 18 const net::SSLInfo& info,
20 const GURL& request_url, 19 const GURL& request_url,
21 bool overridable, 20 bool overridable,
(...skipping 11 matching lines...) Expand all
33 web_state, cert_error, info, request_url, options_mask, 32 web_state, cert_error, info, request_url, options_mask,
34 base::Time::NowFromSystemTime(), dismissal_callback); 33 base::Time::NowFromSystemTime(), dismissal_callback);
35 page->Show(); 34 page->Show();
36 } 35 }
37 36
38 // static 37 // static
39 void IOSSSLErrorHandler::InterstitialWasDismissed( 38 void IOSSSLErrorHandler::InterstitialWasDismissed(
40 web::WebState* web_state, 39 web::WebState* web_state,
41 const base::Callback<void(bool)>& callback, 40 const base::Callback<void(bool)>& callback,
42 bool proceed) { 41 bool proceed) {
43 if (!proceed) {
44 web_state->GetNavigationManager()->Reload(true /* check_for_repost */);
45 }
46 callback.Run(proceed); 42 callback.Run(proceed);
47 } 43 }
OLDNEW
« no previous file with comments | « no previous file | ios/web/interstitials/web_interstitial_impl.mm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698