Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1076)

Unified Diff: chrome/browser/android/thumbnail/thumbnail_cache.cc

Issue 1371523003: Android: Don't destroy LayerTreeHost when Surface goes away (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: chrome/browser/android/thumbnail/thumbnail_cache.cc
diff --git a/chrome/browser/android/thumbnail/thumbnail_cache.cc b/chrome/browser/android/thumbnail/thumbnail_cache.cc
index ca6751592eca8c9d96853fa851f1b9d0a11c7cb6..381bbc32ab1dfa7f1aea8bf909feec61f561edbc 100644
--- a/chrome/browser/android/thumbnail/thumbnail_cache.cc
+++ b/chrome/browser/android/thumbnail/thumbnail_cache.cc
@@ -473,6 +473,11 @@ void ThumbnailCache::RemoveFromReadQueue(TabId tab_id) {
read_queue_.erase(read_iter);
}
+void ThumbnailCache::OnUIResourcesWereEvicted() {
+ cache_.Clear();
+ approximation_cache_.Clear();
+}
+
void ThumbnailCache::InvalidateCachedThumbnail(Thumbnail* thumbnail) {
DCHECK(thumbnail);
TabId tab_id = thumbnail->tab_id();
« no previous file with comments | « chrome/browser/android/thumbnail/thumbnail_cache.h ('k') | content/browser/renderer_host/compositor_impl_android.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698