summaryrefslogtreecommitdiff
path: root/src/com/android/browser/BrowserWebViewFactory.java
diff options
context:
space:
mode:
authorRicardo Cerqueira <cyanogenmod@cerqueira.org>2014-01-18 19:22:47 +0000
committerAndrew Warfield <hiasant@gmail.com>2014-01-25 20:30:56 -0800
commit71f3b26f6f0690f897973d3f201cd27c3ada920e (patch)
tree484674c01cf91e3e87aba310b14d488c24fdfe6b /src/com/android/browser/BrowserWebViewFactory.java
parentead806471dc9a1d981d360f810de5c4b75c5bca6 (diff)
Implement client-side incognito mode
Since WebView deprecated privateBrowsing in API 17 (and killed it for good in API 19), we were left without incognito in the Browser app. Follow the docs' recommendations and implement it with "manual" control of privacy-related engine options * Internally track incognito state for tabs * Disable all forms of storage and cache on private webviews * Disable all cookie activity while an incognito tab is active * Stop trying to use the deprecated "privateBrowsing" argument when creating webViews, always set to false Change-Id: I23f2e34ee125635bba8981f0711ba4986a9beaab
Diffstat (limited to 'src/com/android/browser/BrowserWebViewFactory.java')
-rw-r--r--src/com/android/browser/BrowserWebViewFactory.java1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/com/android/browser/BrowserWebViewFactory.java b/src/com/android/browser/BrowserWebViewFactory.java
index f976b071..3424820d 100644
--- a/src/com/android/browser/BrowserWebViewFactory.java
+++ b/src/com/android/browser/BrowserWebViewFactory.java
@@ -46,6 +46,7 @@ public class BrowserWebViewFactory implements WebViewFactory {
public WebView createWebView(boolean privateBrowsing) {
WebView w = instantiateWebView(null, android.R.attr.webViewStyle, privateBrowsing);
initWebViewSettings(w);
+ ((BrowserWebView)w).setPrivateBrowsing(privateBrowsing);
return w;
}