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

Side by Side Diff: cc/RateLimiter.cpp

Issue 11091028: [cc] Remove all WTF #includes from CCLayerTreeHost (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: 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/RateLimiter.h ('k') | cc/TiledLayerChromium.cpp » ('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 2011 The Chromium Authors. All rights reserved. 1 // Copyright 2011 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 "config.h" 5 #include "config.h"
6 6
7 #if USE(ACCELERATED_COMPOSITING) 7 #if USE(ACCELERATED_COMPOSITING)
8 #include "RateLimiter.h" 8 #include "RateLimiter.h"
9 9
10 #include "CCProxy.h" 10 #include "CCProxy.h"
(...skipping 17 matching lines...) Expand all
28 : CCThread::Task(this) 28 : CCThread::Task(this)
29 , m_rateLimiter(rateLimiter) 29 , m_rateLimiter(rateLimiter)
30 { 30 {
31 } 31 }
32 32
33 virtual void performTask() OVERRIDE 33 virtual void performTask() OVERRIDE
34 { 34 {
35 m_rateLimiter->rateLimitContext(); 35 m_rateLimiter->rateLimitContext();
36 } 36 }
37 37
38 RefPtr<RateLimiter> m_rateLimiter; 38 scoped_refptr<RateLimiter> m_rateLimiter;
39 }; 39 };
40 40
41 PassRefPtr<RateLimiter> RateLimiter::create(WebKit::WebGraphicsContext3D* contex t, RateLimiterClient *client) 41 scoped_refptr<RateLimiter> RateLimiter::create(WebKit::WebGraphicsContext3D* con text, RateLimiterClient *client)
42 { 42 {
43 return adoptRef(new RateLimiter(context, client)); 43 return make_scoped_refptr(new RateLimiter(context, client));
44 } 44 }
45 45
46 RateLimiter::RateLimiter(WebKit::WebGraphicsContext3D* context, RateLimiterClien t *client) 46 RateLimiter::RateLimiter(WebKit::WebGraphicsContext3D* context, RateLimiterClien t *client)
47 : m_context(context) 47 : m_context(context)
48 , m_active(false) 48 , m_active(false)
49 , m_client(client) 49 , m_client(client)
50 { 50 {
51 turnOffVerifier();
52 ASSERT(context); 51 ASSERT(context);
53 } 52 }
54 53
55 RateLimiter::~RateLimiter() 54 RateLimiter::~RateLimiter()
56 { 55 {
57 } 56 }
58 57
59 void RateLimiter::start() 58 void RateLimiter::start()
60 { 59 {
61 if (m_active) 60 if (m_active)
(...skipping 17 matching lines...) Expand all
79 78
80 TRACE_EVENT0("cc", "RateLimiter::rateLimitContext"); 79 TRACE_EVENT0("cc", "RateLimiter::rateLimitContext");
81 80
82 m_active = false; 81 m_active = false;
83 m_client->rateLimit(); 82 m_client->rateLimit();
84 m_context->rateLimitOffscreenContextCHROMIUM(); 83 m_context->rateLimitOffscreenContextCHROMIUM();
85 } 84 }
86 85
87 } 86 }
88 #endif // USE(ACCELERATED_COMPOSITING) 87 #endif // USE(ACCELERATED_COMPOSITING)
OLDNEW
« no previous file with comments | « cc/RateLimiter.h ('k') | cc/TiledLayerChromium.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698