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

Side by Side Diff: cc/gl_renderer_unittest.cc

Issue 12648005: cc: Chromify the LayerTreeHostImpl class. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Compl Created 7 years, 9 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « cc/delegating_renderer_unittest.cc ('k') | cc/input_handler.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2012 The Chromium Authors. All rights reserved. 1 // Copyright 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "cc/gl_renderer.h" 5 #include "cc/gl_renderer.h"
6 6
7 #include "cc/compositor_frame_metadata.h" 7 #include "cc/compositor_frame_metadata.h"
8 #include "cc/draw_quad.h" 8 #include "cc/draw_quad.h"
9 #include "cc/prioritized_resource_manager.h" 9 #include "cc/prioritized_resource_manager.h"
10 #include "cc/resource_provider.h" 10 #include "cc/resource_provider.h"
(...skipping 49 matching lines...) Expand 10 before | Expand all | Expand 10 after
60 int m_frame; 60 int m_frame;
61 WebGraphicsMemoryAllocationChangedCallbackCHROMIUM* m_memoryAllocationChange dCallback; 61 WebGraphicsMemoryAllocationChangedCallbackCHROMIUM* m_memoryAllocationChange dCallback;
62 }; 62 };
63 63
64 class FakeRendererClient : public RendererClient { 64 class FakeRendererClient : public RendererClient {
65 public: 65 public:
66 FakeRendererClient() 66 FakeRendererClient()
67 : m_hostImpl(&m_proxy) 67 : m_hostImpl(&m_proxy)
68 , m_setFullRootLayerDamageCount(0) 68 , m_setFullRootLayerDamageCount(0)
69 , m_lastCallWasSetVisibility(0) 69 , m_lastCallWasSetVisibility(0)
70 , m_rootLayer(LayerImpl::Create(m_hostImpl.activeTree(), 1)) 70 , m_rootLayer(LayerImpl::Create(m_hostImpl.active_tree(), 1))
71 , m_memoryAllocationLimitBytes(PrioritizedResourceManager::defaultMemory AllocationLimit()) 71 , m_memoryAllocationLimitBytes(PrioritizedResourceManager::defaultMemory AllocationLimit())
72 { 72 {
73 m_rootLayer->CreateRenderSurface(); 73 m_rootLayer->CreateRenderSurface();
74 RenderPass::Id renderPassId = m_rootLayer->render_surface()->RenderPassI d(); 74 RenderPass::Id renderPassId = m_rootLayer->render_surface()->RenderPassI d();
75 scoped_ptr<RenderPass> root_render_pass = RenderPass::Create(); 75 scoped_ptr<RenderPass> root_render_pass = RenderPass::Create();
76 root_render_pass->SetNew(renderPassId, gfx::Rect(), gfx::Rect(), gfx::Tr ansform()); 76 root_render_pass->SetNew(renderPassId, gfx::Rect(), gfx::Rect(), gfx::Tr ansform());
77 m_renderPassesInDrawOrder.push_back(root_render_pass.Pass()); 77 m_renderPassesInDrawOrder.push_back(root_render_pass.Pass());
78 } 78 }
79 79
80 // RendererClient methods. 80 // RendererClient methods.
(...skipping 742 matching lines...) Expand 10 before | Expand all | Expand 10 after
823 823
824 TEST_F(MockOutputSurfaceTestWithSendCompositorFrame, DrawFrame) 824 TEST_F(MockOutputSurfaceTestWithSendCompositorFrame, DrawFrame)
825 { 825 {
826 EXPECT_CALL(m_outputSurface, SendFrameToParentCompositor(_)) 826 EXPECT_CALL(m_outputSurface, SendFrameToParentCompositor(_))
827 .Times(1); 827 .Times(1);
828 DrawFrame(); 828 DrawFrame();
829 } 829 }
830 830
831 } // namespace 831 } // namespace
832 } // namespace cc 832 } // namespace cc
OLDNEW
« no previous file with comments | « cc/delegating_renderer_unittest.cc ('k') | cc/input_handler.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698