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

Unified Diff: webkit/compositor_bindings/CCThreadImpl.cpp

Issue 11189043: cc: Rename cc classes and members to match filenames (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 side-by-side diff with in-line comments
Download patch
Index: webkit/compositor_bindings/CCThreadImpl.cpp
diff --git a/webkit/compositor_bindings/CCThreadImpl.cpp b/webkit/compositor_bindings/CCThreadImpl.cpp
index 7830600ba105b3d9ce2fed996a03cd51862504cb..db6ce97b9981782a3a84debaf2f3a798ff7ddb12 100644
--- a/webkit/compositor_bindings/CCThreadImpl.cpp
+++ b/webkit/compositor_bindings/CCThreadImpl.cpp
@@ -9,8 +9,8 @@
#include "third_party/WebKit/Source/Platform/chromium/public/Platform.h"
#include "third_party/WebKit/Source/Platform/chromium/public/WebThread.h"
-using cc::CCThread;
-using cc::CCCompletionEvent;
+using cc::Thread;
+using cc::CompletionEvent;
namespace WebKit {
@@ -22,7 +22,7 @@ namespace WebKit {
// PassOwnPtrs.
class GetThreadIDTask : public WebThread::Task {
public:
- GetThreadIDTask(base::PlatformThreadId* result, CCCompletionEvent* completion)
+ GetThreadIDTask(base::PlatformThreadId* result, CompletionEvent* completion)
: m_completion(completion)
, m_result(result) { }
@@ -35,16 +35,16 @@ public:
}
private:
- CCCompletionEvent* m_completion;
+ CompletionEvent* m_completion;
base::PlatformThreadId* m_result;
};
-// General adapter from a CCThread::Task to a WebThread::Task.
-class CCThreadTaskAdapter : public WebThread::Task {
+// General adapter from a Thread::Task to a WebThread::Task.
+class ThreadTaskAdapter : public WebThread::Task {
public:
- explicit CCThreadTaskAdapter(PassOwnPtr<CCThread::Task> task) : m_task(task) { }
+ explicit ThreadTaskAdapter(PassOwnPtr<Thread::Task> task) : m_task(task) { }
- virtual ~CCThreadTaskAdapter() { }
+ virtual ~ThreadTaskAdapter() { }
virtual void run()
{
@@ -52,31 +52,31 @@ public:
}
private:
- OwnPtr<CCThread::Task> m_task;
+ OwnPtr<Thread::Task> m_task;
};
-scoped_ptr<CCThread> CCThreadImpl::createForCurrentThread()
+scoped_ptr<Thread> CCThreadImpl::createForCurrentThread()
{
- return scoped_ptr<CCThread>(new CCThreadImpl(Platform::current()->currentThread(), true)).Pass();
+ return scoped_ptr<Thread>(new CCThreadImpl(Platform::current()->currentThread(), true)).Pass();
}
-scoped_ptr<CCThread> CCThreadImpl::createForDifferentThread(WebThread* thread)
+scoped_ptr<Thread> CCThreadImpl::createForDifferentThread(WebThread* thread)
{
- return scoped_ptr<CCThread>(new CCThreadImpl(thread, false)).Pass();
+ return scoped_ptr<Thread>(new CCThreadImpl(thread, false)).Pass();
}
CCThreadImpl::~CCThreadImpl()
{
}
-void CCThreadImpl::postTask(PassOwnPtr<CCThread::Task> task)
+void CCThreadImpl::postTask(PassOwnPtr<Thread::Task> task)
{
- m_thread->postTask(new CCThreadTaskAdapter(task));
+ m_thread->postTask(new ThreadTaskAdapter(task));
}
-void CCThreadImpl::postDelayedTask(PassOwnPtr<CCThread::Task> task, long long delayMs)
+void CCThreadImpl::postDelayedTask(PassOwnPtr<Thread::Task> task, long long delayMs)
{
- m_thread->postDelayedTask(new CCThreadTaskAdapter(task), delayMs);
+ m_thread->postDelayedTask(new ThreadTaskAdapter(task), delayMs);
}
base::PlatformThreadId CCThreadImpl::threadID() const
@@ -94,7 +94,7 @@ CCThreadImpl::CCThreadImpl(WebThread* thread, bool currentThread)
// Get the threadId for the newly-created thread by running a task
// on that thread, blocking on the result.
- CCCompletionEvent completion;
+ CompletionEvent completion;
m_thread->postTask(new GetThreadIDTask(&m_threadID, &completion));
completion.wait();
}

Powered by Google App Engine
This is Rietveld 408576698