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

Unified Diff: cc/layers/delegated_renderer_layer.h

Issue 24078024: cc: Return resources to child compositor via a Callback. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: deletechild: No AndReceiveAck needed, change STP Created 7 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
« no previous file with comments | « no previous file | cc/layers/delegated_renderer_layer.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/layers/delegated_renderer_layer.h
diff --git a/cc/layers/delegated_renderer_layer.h b/cc/layers/delegated_renderer_layer.h
index b3a078fba515702f71185646e19333ac3d8d279d..60e9c3c05d9df80a399539cba1b05e6195a59fa4 100644
--- a/cc/layers/delegated_renderer_layer.h
+++ b/cc/layers/delegated_renderer_layer.h
@@ -5,12 +5,15 @@
#ifndef CC_LAYERS_DELEGATED_RENDERER_LAYER_H_
#define CC_LAYERS_DELEGATED_RENDERER_LAYER_H_
+#include "base/memory/ref_counted.h"
+#include "base/memory/weak_ptr.h"
+#include "base/synchronization/lock.h"
#include "cc/base/cc_export.h"
#include "cc/layers/layer.h"
#include "cc/resources/returned_resource.h"
namespace cc {
-
+class BlockingTaskRunner;
class DelegatedFrameData;
class DelegatedRendererLayerClient;
@@ -42,17 +45,27 @@ class CC_EXPORT DelegatedRendererLayer : public Layer {
virtual ~DelegatedRendererLayer();
private:
+ void ReceiveUnusedResources(const ReturnedResourceArray& unused);
+ static void ReceiveUnusedResourcesOnImplThread(
+ scoped_refptr<BlockingTaskRunner> task_runner,
+ base::WeakPtr<DelegatedRendererLayer> self,
+ const ReturnedResourceArray& unused);
+
scoped_ptr<DelegatedFrameData> frame_data_;
gfx::RectF damage_in_frame_;
gfx::Size frame_size_;
gfx::Size display_size_;
- ReturnedResourceArray unused_resources_for_child_compositor_;
DelegatedRendererLayerClient* client_;
bool needs_filter_context_;
+ ReturnedResourceArray unused_resources_for_child_compositor_;
+ scoped_refptr<BlockingTaskRunner> main_thread_runner_;
+ base::WeakPtrFactory<DelegatedRendererLayer> weak_ptrs_;
+
DISALLOW_COPY_AND_ASSIGN(DelegatedRendererLayer);
};
} // namespace cc
+
#endif // CC_LAYERS_DELEGATED_RENDERER_LAYER_H_
« no previous file with comments | « no previous file | cc/layers/delegated_renderer_layer.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698