From e1c6c3ae21a527c5ddb4386ceee51e9ebd4ad58f Mon Sep 17 00:00:00 2001 From: Selim Gurun Date: Mon, 28 Apr 2014 14:21:21 -0700 Subject: Design a static API for clearclientcertpreferences Bug: 12983007 Change-Id: I869b4cd4c178b8fedf725f108fd2e369895543e9 --- core/java/android/webkit/WebView.java | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) (limited to 'core/java/android/webkit/WebView.java') diff --git a/core/java/android/webkit/WebView.java b/core/java/android/webkit/WebView.java index efb246a..2f4d593 100644 --- a/core/java/android/webkit/WebView.java +++ b/core/java/android/webkit/WebView.java @@ -1479,18 +1479,19 @@ public class WebView extends AbsoluteLayout * Clears the client certificate preferences table stored in response * to proceeding/cancelling client cert requests. Note that webview * automatically clears these preferences when it receives a - * {@link KeyChain.ACTION_STORAGE_CHANGED} + * {@link KeyChain.ACTION_STORAGE_CHANGED} intent. The client certificate + * preferences are global for all Webviews. * - * @param resultCallback A callback to be invoked when client certs are cleared. - * The embedder can pass null if not interested in the callback. + * @param onCleared A runnable to be invoked when client certs are cleared. + * The embedder can pass null if not interested in the + * callback. The runnable will be called in UI thread. * * TODO(sgurun) unhide * @hide */ - public void clearClientCertPreferences(ValueCallback resultCallback) { - checkThread(); + public static void clearClientCertPreferences(Runnable onCleared) { if (DebugFlags.TRACE_API) Log.d(LOGTAG, "clearClientCertPreferences"); - mProvider.clearClientCertPreferences(resultCallback); + getFactory().getStatics().clearClientCertPreferences(onCleared); } /** -- cgit v1.1