| Index: content/renderer/render_thread_impl.cc
|
| diff --git a/content/renderer/render_thread_impl.cc b/content/renderer/render_thread_impl.cc
|
| index 61fd8409dfa26dbbb2a2e52266667ea9a2d9180f..2eebde9b7476312198c0b31db5d2c916f3bdbcbf 100644
|
| --- a/content/renderer/render_thread_impl.cc
|
| +++ b/content/renderer/render_thread_impl.cc
|
| @@ -1269,7 +1269,7 @@ void RenderThreadImpl::PostponeIdleNotification() {
|
|
|
| scoped_refptr<media::GpuVideoAcceleratorFactories>
|
| RenderThreadImpl::GetGpuFactories() {
|
| - DCHECK(IsMainThread());
|
| + DCHECK(GetMainTaskRunner()->BelongsToCurrentThread());
|
|
|
| scoped_refptr<GpuChannelHost> gpu_channel_host = GetGpuChannel();
|
| const base::CommandLine* cmd_line = base::CommandLine::ForCurrentProcess();
|
| @@ -1323,7 +1323,7 @@ RenderThreadImpl::CreateOffscreenContext3d() {
|
|
|
| scoped_refptr<cc_blink::ContextProviderWebContext>
|
| RenderThreadImpl::SharedMainThreadContextProvider() {
|
| - DCHECK(IsMainThread());
|
| + DCHECK(GetMainTaskRunner()->BelongsToCurrentThread());
|
| if (!shared_main_thread_contexts_.get() ||
|
| shared_main_thread_contexts_->DestroyedOnMainThread()) {
|
| shared_main_thread_contexts_ = NULL;
|
| @@ -1471,12 +1471,9 @@ bool RenderThreadImpl::IsGatherPixelRefsEnabled() {
|
| return is_gather_pixel_refs_enabled_;
|
| }
|
|
|
| -bool RenderThreadImpl::IsMainThread() {
|
| - return !!current();
|
| -}
|
| -
|
| -base::MessageLoop* RenderThreadImpl::GetMainLoop() {
|
| - return message_loop();
|
| +scoped_refptr<base::SingleThreadTaskRunner>
|
| +RenderThreadImpl::GetMainTaskRunner() {
|
| + return message_loop()->task_runner();
|
| }
|
|
|
| scoped_refptr<base::MessageLoopProxy> RenderThreadImpl::GetIOLoopProxy() {
|
|
|