From fe33a75cc8883dc5d50dd5a2fb0eac702f2a6992 Mon Sep 17 00:00:00 2001 From: Steve Block Date: Tue, 4 Oct 2011 19:09:13 +0100 Subject: Add WebViewClient.onProceededAfterSslError() This is used to notify the host application that an SSL error occurred while loading a resource, but the WebView but chose to proceed anyway based on a decision retained from a previous response to onReceivedSslError(). Bug: 5403366 Change-Id: I51a25b93d7824b7eb7b6d5a961cba948e37c85db --- core/java/android/webkit/WebViewClient.java | 19 ++++++++++++++----- 1 file changed, 14 insertions(+), 5 deletions(-) (limited to 'core/java/android/webkit/WebViewClient.java') diff --git a/core/java/android/webkit/WebViewClient.java b/core/java/android/webkit/WebViewClient.java index d3be2bf1a8d6..81de35644455 100644 --- a/core/java/android/webkit/WebViewClient.java +++ b/core/java/android/webkit/WebViewClient.java @@ -186,11 +186,11 @@ public class WebViewClient { } /** - * Notify the host application to handle a SSL certificate error request - * (display the error to the user and ask whether to proceed or not). The - * host application has to call either handler.cancel() or handler.proceed() - * as the connection is suspended and waiting for the response. The default - * behavior is to cancel the load. + * Notify the host application that an SSL error occurred while loading a + * resource. The host application must call either handler.cancel() or + * handler.proceed(). Note that the decision may be retained for use in + * response to future SSL errors. The default behavior is to cancel the + * load. * * @param view The WebView that is initiating the callback. * @param handler An SslErrorHandler object that will handle the user's @@ -202,6 +202,15 @@ public class WebViewClient { handler.cancel(); } + /** + * Notify the host application that an SSL error occurred while loading a + * resource, but the WebView but chose to proceed anyway based on a + * decision retained from a previous response to onReceivedSslError(). + * @hide + */ + public void onProceededAfterSslError(WebView view, SslError error) { + } + /** * Notify the host application to handle a SSL client certificate * request (display the request to the user and ask whether to -- cgit v1.2.3