am 7450a32b: Merge "Clear the files we copy over to the temp cache" into honeycomb

* commit '7450a32bab8945738589d7b323953cdc80de111f':
  Clear the files we copy over to the temp cache
This commit is contained in:
Kristian Monsen
2011-01-20 06:37:24 -08:00
committed by Android Git Automerger
2 changed files with 7 additions and 3 deletions

View File

@@ -244,6 +244,9 @@ public final class CacheManager {
* obtained from {@link android.webkit.CacheManager.CacheResult#getLocalPath}, this
* identifies the cache file.
*
* Cache files are not guaranteed to be in this directory before
* CacheManager#getCacheFile(String, Map<String, String>) is called.
*
* @return File The base directory of the cache.
*
* @deprecated Access to the HTTP cache will be removed in a future release.
@@ -611,8 +614,9 @@ public final class CacheManager {
return true;
}
// delete rows in the cache database
WebViewWorker.getHandler().sendEmptyMessage(
WebViewWorker.MSG_CLEAR_CACHE);
if (!JniUtil.useChromiumHttpStack())
WebViewWorker.getHandler().sendEmptyMessage(WebViewWorker.MSG_CLEAR_CACHE);
// delete cache files in a separate thread to not block UI.
final Runnable clearCache = new Runnable() {
public void run() {

View File

@@ -1770,7 +1770,7 @@ final class WebViewCore {
private void clearCache(boolean includeDiskFiles) {
mBrowserFrame.clearCache();
if (includeDiskFiles && !JniUtil.useChromiumHttpStack()) {
if (includeDiskFiles) {
CacheManager.removeAllCacheFiles();
}
}