diff options
| author | 2010-11-26 11:55:35 +0000 | |
|---|---|---|
| committer | 2010-11-26 11:55:35 +0000 | |
| commit | 5fd5d74f794cc92d24882803dcf355ac24e01ac4 (patch) | |
| tree | 9282ceea117fb19d3eee175fb8165c9ea5224446 | |
| parent | b416a71e56cdd50742eb897366a140775aa4cd61 (diff) | |
No longer need to pass storage paths to WebRequestContext.cleanupPrivateBrowsingFiles()
Requires the following changes to external/webkit and packages/apps/Browser
https://android-git.corp.google.com/g/81781
https://android-git.corp.google.com/g/81780
Bug: 3232569
Change-Id: I0247f3db25edfdc95363a5a94296458b20456a46
| -rw-r--r-- | core/java/android/webkit/WebView.java | 16 |
1 files changed, 3 insertions, 13 deletions
diff --git a/core/java/android/webkit/WebView.java b/core/java/android/webkit/WebView.java index 56325f6e1269..a98c83a9be82 100644 --- a/core/java/android/webkit/WebView.java +++ b/core/java/android/webkit/WebView.java @@ -1923,25 +1923,15 @@ public class WebView extends AbsoluteLayout * browsing session and clears any internal state associated with that * session. The consequences of calling this method while a private * browsing session is active are unspecified. - * @param context The same context which was used to create the private - * browsing WebView. * @return True if the private browsing files were successfully deleted, * false otherwise. * @hide pending API council approval. */ - public static boolean cleanupPrivateBrowsingFiles(Context context) { - // It seems wrong that we have to pass the storage locations here, given - // that the storage files are created native-side in WebRequestContext - // (albeit using a dumb getter on BrowserFrame to get the paths from - // Java). It looks like this is required because we may need to call - // this method before the BrowserFrame has been set up. - // TODO: Investigate whether this can be avoided. - return nativeCleanupPrivateBrowsingFiles(context.getDatabasePath("dummy").getParent(), - context.getCacheDir().getAbsolutePath()); + public static boolean cleanupPrivateBrowsingFiles() { + return nativeCleanupPrivateBrowsingFiles(); } - private static native boolean nativeCleanupPrivateBrowsingFiles(String databaseDirectory, - String cacheDirectory); + private static native boolean nativeCleanupPrivateBrowsingFiles(); private boolean extendScroll(int y) { int finalY = mScroller.getFinalY(); |