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

Side by Side Diff: cc/CCRenderer.h

Issue 10985088: cc: Switch it to use DISALLOW_COPY_AND_ASSIGN macro from base/ library. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: review Created 8 years, 2 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/CCRenderSurface.h ('k') | cc/CCRendererGL.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 #ifndef CCRenderer_h 5 #ifndef CCRenderer_h
6 #define CCRenderer_h 6 #define CCRenderer_h
7 7
8 #include "base/basictypes.h"
8 #include "CCLayerTreeHost.h" 9 #include "CCLayerTreeHost.h"
9 #include "CCRenderPass.h" 10 #include "CCRenderPass.h"
10 #include "FloatQuad.h" 11 #include "FloatQuad.h"
11 #include "IntRect.h" 12 #include "IntRect.h"
12 #include <wtf/Noncopyable.h>
13 #include <wtf/PassRefPtr.h> 13 #include <wtf/PassRefPtr.h>
14 14
15 namespace cc { 15 namespace cc {
16 16
17 class CCScopedTexture; 17 class CCScopedTexture;
18 18
19 class CCRendererClient { 19 class CCRendererClient {
20 public: 20 public:
21 virtual const IntSize& deviceViewportSize() const = 0; 21 virtual const IntSize& deviceViewportSize() const = 0;
22 virtual const CCLayerTreeSettings& settings() const = 0; 22 virtual const CCLayerTreeSettings& settings() const = 0;
23 virtual void didLoseContext() = 0; 23 virtual void didLoseContext() = 0;
24 virtual void onSwapBuffersComplete() = 0; 24 virtual void onSwapBuffersComplete() = 0;
25 virtual void releaseContentsTextures() = 0; 25 virtual void releaseContentsTextures() = 0;
26 virtual void setFullRootLayerDamage() = 0; 26 virtual void setFullRootLayerDamage() = 0;
27 virtual void setMemoryAllocationLimitBytes(size_t) = 0; 27 virtual void setMemoryAllocationLimitBytes(size_t) = 0;
28 protected: 28 protected:
29 virtual ~CCRendererClient() { } 29 virtual ~CCRendererClient() { }
30 }; 30 };
31 31
32 class CCRenderer { 32 class CCRenderer {
33 WTF_MAKE_NONCOPYABLE(CCRenderer);
34 public: 33 public:
35 // This enum defines the various resource pools for the CCResourceProvider 34 // This enum defines the various resource pools for the CCResourceProvider
36 // where textures get allocated. 35 // where textures get allocated.
37 enum ResourcePool { 36 enum ResourcePool {
38 ImplPool = 1, // This pool is for textures that get allocated on the impl thread (e.g. RenderSurfaces). 37 ImplPool = 1, // This pool is for textures that get allocated on the impl thread (e.g. RenderSurfaces).
39 ContentPool // This pool is for textures that get allocated on the main th read (e.g. tiles). 38 ContentPool // This pool is for textures that get allocated on the main th read (e.g. tiles).
40 }; 39 };
41 40
42 virtual ~CCRenderer() { } 41 virtual ~CCRenderer() { }
43 42
(...skipping 25 matching lines...) Expand all
69 68
70 virtual void setVisible(bool) = 0; 69 virtual void setVisible(bool) = 0;
71 70
72 protected: 71 protected:
73 explicit CCRenderer(CCRendererClient* client) 72 explicit CCRenderer(CCRendererClient* client)
74 : m_client(client) 73 : m_client(client)
75 { 74 {
76 } 75 }
77 76
78 CCRendererClient* m_client; 77 CCRendererClient* m_client;
78
79 DISALLOW_COPY_AND_ASSIGN(CCRenderer);
79 }; 80 };
80 81
81 } 82 }
82 83
83 #endif // CCRenderer_h 84 #endif // CCRenderer_h
OLDNEW
« no previous file with comments | « cc/CCRenderSurface.h ('k') | cc/CCRendererGL.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698