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

Side by Side Diff: cc/CCTextureUpdateController.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/CCScopedTexture.h ('k') | cc/CCTextureUpdateQueue.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 CCTextureUpdateController_h 5 #ifndef CCTextureUpdateController_h
6 #define CCTextureUpdateController_h 6 #define CCTextureUpdateController_h
7 7
8 #include "base/basictypes.h"
8 #include "base/time.h" 9 #include "base/time.h"
9 #include "CCTextureUpdateQueue.h" 10 #include "CCTextureUpdateQueue.h"
10 #include "CCTimer.h" 11 #include "CCTimer.h"
11 #include <wtf/Noncopyable.h>
12 #include <wtf/OwnPtr.h> 12 #include <wtf/OwnPtr.h>
13 13
14 namespace cc { 14 namespace cc {
15 15
16 class TextureUploader; 16 class TextureUploader;
17 17
18 class CCTextureUpdateControllerClient { 18 class CCTextureUpdateControllerClient {
19 public: 19 public:
20 virtual void readyToFinalizeTextureUpdates() = 0; 20 virtual void readyToFinalizeTextureUpdates() = 0;
21 21
22 protected: 22 protected:
23 virtual ~CCTextureUpdateControllerClient() { } 23 virtual ~CCTextureUpdateControllerClient() { }
24 }; 24 };
25 25
26 class CCTextureUpdateController : public CCTimerClient { 26 class CCTextureUpdateController : public CCTimerClient {
27 WTF_MAKE_NONCOPYABLE(CCTextureUpdateController);
28 public: 27 public:
29 static PassOwnPtr<CCTextureUpdateController> create(CCTextureUpdateControlle rClient* client, CCThread* thread, PassOwnPtr<CCTextureUpdateQueue> queue, CCRes ourceProvider* resourceProvider, TextureUploader* uploader) 28 static PassOwnPtr<CCTextureUpdateController> create(CCTextureUpdateControlle rClient* client, CCThread* thread, PassOwnPtr<CCTextureUpdateQueue> queue, CCRes ourceProvider* resourceProvider, TextureUploader* uploader)
30 { 29 {
31 return adoptPtr(new CCTextureUpdateController(client, thread, queue, res ourceProvider, uploader)); 30 return adoptPtr(new CCTextureUpdateController(client, thread, queue, res ourceProvider, uploader));
32 } 31 }
33 static size_t maxPartialTextureUpdates(); 32 static size_t maxPartialTextureUpdates();
34 33
35 virtual ~CCTextureUpdateController(); 34 virtual ~CCTextureUpdateController();
36 35
37 // Discard uploads to textures that were evicted on the impl thread. 36 // Discard uploads to textures that were evicted on the impl thread.
(...skipping 21 matching lines...) Expand all
59 58
60 CCTextureUpdateControllerClient* m_client; 59 CCTextureUpdateControllerClient* m_client;
61 OwnPtr<CCTimer> m_timer; 60 OwnPtr<CCTimer> m_timer;
62 OwnPtr<CCTextureUpdateQueue> m_queue; 61 OwnPtr<CCTextureUpdateQueue> m_queue;
63 bool m_contentsTexturesPurged; 62 bool m_contentsTexturesPurged;
64 CCResourceProvider* m_resourceProvider; 63 CCResourceProvider* m_resourceProvider;
65 TextureUploader* m_uploader; 64 TextureUploader* m_uploader;
66 base::TimeTicks m_timeLimit; 65 base::TimeTicks m_timeLimit;
67 size_t m_textureUpdatesPerTick; 66 size_t m_textureUpdatesPerTick;
68 bool m_firstUpdateAttempt; 67 bool m_firstUpdateAttempt;
68
69 private:
70 DISALLOW_COPY_AND_ASSIGN(CCTextureUpdateController);
69 }; 71 };
70 72
71 } 73 }
72 74
73 #endif // CCTextureUpdateController_h 75 #endif // CCTextureUpdateController_h
OLDNEW
« no previous file with comments | « cc/CCScopedTexture.h ('k') | cc/CCTextureUpdateQueue.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698