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

Unified Diff: cc/gl_renderer_unittest.cc

Issue 11472021: cc: Pass LayerTreeHostImpl to LayerImpl constructor (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebase Created 8 years 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/delegated_renderer_layer_impl_unittest.cc ('k') | cc/heads_up_display_layer.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/gl_renderer_unittest.cc
diff --git a/cc/gl_renderer_unittest.cc b/cc/gl_renderer_unittest.cc
index 9e040bf84804921cf7cf68099360c44f64e126d0..909ca5915fc5ec5caaa93a2d8665dc4c645854f1 100644
--- a/cc/gl_renderer_unittest.cc
+++ b/cc/gl_renderer_unittest.cc
@@ -7,6 +7,8 @@
#include "cc/draw_quad.h"
#include "cc/prioritized_resource_manager.h"
#include "cc/resource_provider.h"
+#include "cc/test/fake_impl_proxy.h"
+#include "cc/test/fake_layer_tree_host_impl.h"
#include "cc/test/fake_web_compositor_output_surface.h"
#include "cc/test/fake_web_graphics_context_3d.h"
#include "cc/test/render_pass_test_common.h"
@@ -57,9 +59,10 @@ private:
class FakeRendererClient : public RendererClient {
public:
FakeRendererClient()
- : m_setFullRootLayerDamageCount(0)
+ : m_hostImpl(&m_proxy)
+ , m_setFullRootLayerDamageCount(0)
, m_lastCallWasSetVisibility(0)
- , m_rootLayer(LayerImpl::create(1))
+ , m_rootLayer(LayerImpl::create(&m_hostImpl, 1))
, m_memoryAllocationLimitBytes(PrioritizedResourceManager::defaultMemoryAllocationLimit())
{
m_rootLayer->createRenderSurface();
@@ -91,6 +94,8 @@ public:
size_t memoryAllocationLimitBytes() const { return m_memoryAllocationLimitBytes; }
private:
+ FakeImplProxy m_proxy;
+ FakeLayerTreeHostImpl m_hostImpl;
int m_setFullRootLayerDamageCount;
bool* m_lastCallWasSetVisibility;
scoped_ptr<LayerImpl> m_rootLayer;
« no previous file with comments | « cc/delegated_renderer_layer_impl_unittest.cc ('k') | cc/heads_up_display_layer.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698