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

Unified Diff: cc/layer_tree_impl.cc

Issue 11886091: cc: Fix resource eviction with impl-side painting. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix enforceManagedMemoryPolicy. It's possible we have pending tree when this is called. Created 7 years, 11 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
« no previous file with comments | « cc/layer_tree_impl.h ('k') | cc/single_thread_proxy.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/layer_tree_impl.cc
diff --git a/cc/layer_tree_impl.cc b/cc/layer_tree_impl.cc
index 769639a4091c9dc2e987c7c7b546658329f23489..ad2298184324f45482c9b33c20012e6d2427c869 100644
--- a/cc/layer_tree_impl.cc
+++ b/cc/layer_tree_impl.cc
@@ -19,7 +19,8 @@ LayerTreeImpl::LayerTreeImpl(LayerTreeHostImpl* layer_tree_host_impl)
, currently_scrolling_layer_(0)
, background_color_(0)
, has_transparent_background_(false)
- , scrolling_layer_id_from_previous_tree_(0) {
+ , scrolling_layer_id_from_previous_tree_(0)
+ , contents_textures_purged_(false) {
}
LayerTreeImpl::~LayerTreeImpl() {
@@ -215,6 +216,20 @@ void LayerTreeImpl::DidBecomeActive() {
DidBecomeActiveRecursive(RootLayer());
}
+bool LayerTreeImpl::ContentsTexturesPurged() const {
+ return contents_textures_purged_;
+}
+
+void LayerTreeImpl::SetContentsTexturesPurged() {
+ contents_textures_purged_ = true;
+ layer_tree_host_impl_->OnCanDrawStateChangedForTree(this);
+}
+
+void LayerTreeImpl::ResetContentsTexturesPurged() {
+ contents_textures_purged_ = false;
+ layer_tree_host_impl_->OnCanDrawStateChangedForTree(this);
+}
+
const LayerTreeSettings& LayerTreeImpl::settings() const {
return layer_tree_host_impl_->settings();
}
« no previous file with comments | « cc/layer_tree_impl.h ('k') | cc/single_thread_proxy.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698