summaryrefslogtreecommitdiffstats
path: root/cc/CCProxy.cpp
diff options
context:
space:
mode:
authorjamesr@chromium.org <jamesr@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2012-09-10 22:04:21 +0000
committerjamesr@chromium.org <jamesr@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2012-09-10 22:04:21 +0000
commitdedbe4068e61e476f7dc42f0921dba360329b3e8 (patch)
tree59f333e3ba8a54f324caae5d236e1bb679cc6ee1 /cc/CCProxy.cpp
parentefa810b842c84c52825e6446ba2608ffa4e2450a (diff)
downloadchromium_src-dedbe4068e61e476f7dc42f0921dba360329b3e8.zip
chromium_src-dedbe4068e61e476f7dc42f0921dba360329b3e8.tar.gz
chromium_src-dedbe4068e61e476f7dc42f0921dba360329b3e8.tar.bz2
Avoid using WTF threading code in cc
This stuff isn't available in the component build since we only initialize WTF threading inside WebKit.dll and cc isn't in WebKit.dll BUG= Review URL: https://chromiumcodereview.appspot.com/10913158 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@155846 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'cc/CCProxy.cpp')
-rw-r--r--cc/CCProxy.cpp16
1 files changed, 8 insertions, 8 deletions
diff --git a/cc/CCProxy.cpp b/cc/CCProxy.cpp
index 2e89398..b089442 100644
--- a/cc/CCProxy.cpp
+++ b/cc/CCProxy.cpp
@@ -17,7 +17,7 @@ namespace {
#ifndef NDEBUG
bool implThreadIsOverridden = false;
bool s_isMainThreadBlocked = false;
-ThreadIdentifier threadIDOverridenToBeImplThread;
+base::PlatformThreadId threadIDOverridenToBeImplThread;
#endif
CCThread* s_mainThread = 0;
CCThread* s_implThread = 0;
@@ -50,7 +50,7 @@ CCThread* CCProxy::implThread()
CCThread* CCProxy::currentThread()
{
- ThreadIdentifier currentThreadIdentifier = WTF::currentThread();
+ base::PlatformThreadId currentThreadIdentifier = base::PlatformThread::CurrentId();
if (s_mainThread && s_mainThread->threadID() == currentThreadIdentifier)
return s_mainThread;
if (s_implThread && s_implThread->threadID() == currentThreadIdentifier)
@@ -62,24 +62,24 @@ CCThread* CCProxy::currentThread()
bool CCProxy::isMainThread()
{
ASSERT(s_mainThread);
- if (implThreadIsOverridden && WTF::currentThread() == threadIDOverridenToBeImplThread)
+ if (implThreadIsOverridden && base::PlatformThread::CurrentId() == threadIDOverridenToBeImplThread)
return false;
- return WTF::currentThread() == s_mainThread->threadID();
+ return base::PlatformThread::CurrentId() == s_mainThread->threadID();
}
bool CCProxy::isImplThread()
{
- WTF::ThreadIdentifier implThreadID = s_implThread ? s_implThread->threadID() : 0;
- if (implThreadIsOverridden && WTF::currentThread() == threadIDOverridenToBeImplThread)
+ base::PlatformThreadId implThreadID = s_implThread ? s_implThread->threadID() : 0;
+ if (implThreadIsOverridden && base::PlatformThread::CurrentId() == threadIDOverridenToBeImplThread)
return true;
- return WTF::currentThread() == implThreadID;
+ return base::PlatformThread::CurrentId() == implThreadID;
}
void CCProxy::setCurrentThreadIsImplThread(bool isImplThread)
{
implThreadIsOverridden = isImplThread;
if (isImplThread)
- threadIDOverridenToBeImplThread = WTF::currentThread();
+ threadIDOverridenToBeImplThread = base::PlatformThread::CurrentId();
}
bool CCProxy::isMainThreadBlocked()