Index: third_party/WebKit/Source/platform/scheduler/child/scheduler_tqm_delegate_impl.cc |
diff --git a/third_party/WebKit/Source/platform/scheduler/child/scheduler_tqm_delegate_impl.cc b/third_party/WebKit/Source/platform/scheduler/child/scheduler_tqm_delegate_impl.cc |
index 007dd53947faa8eb102c499996ab7b1d2cd8ab37..ffbdb775fc689ac2d6449bd204a6001a978d543e 100644 |
--- a/third_party/WebKit/Source/platform/scheduler/child/scheduler_tqm_delegate_impl.cc |
+++ b/third_party/WebKit/Source/platform/scheduler/child/scheduler_tqm_delegate_impl.cc |
@@ -6,6 +6,8 @@ |
#include <utility> |
+#include "base/run_loop.h" |
+ |
namespace blink { |
namespace scheduler { |
@@ -59,17 +61,18 @@ bool SchedulerTqmDelegateImpl::RunsTasksOnCurrentThread() const { |
} |
bool SchedulerTqmDelegateImpl::IsNested() const { |
- return message_loop_->IsNested(); |
+ DCHECK(RunsTasksOnCurrentThread()); |
+ return base::RunLoop::IsNestedOnCurrentThread(); |
} |
void SchedulerTqmDelegateImpl::AddNestingObserver( |
- base::MessageLoop::NestingObserver* observer) { |
- message_loop_->AddNestingObserver(observer); |
+ base::RunLoop::NestingObserver* observer) { |
+ base::RunLoop::AddNestingObserverOnCurrentThread(observer); |
} |
void SchedulerTqmDelegateImpl::RemoveNestingObserver( |
- base::MessageLoop::NestingObserver* observer) { |
- message_loop_->RemoveNestingObserver(observer); |
+ base::RunLoop::NestingObserver* observer) { |
+ base::RunLoop::RemoveNestingObserverOnCurrentThread(observer); |
} |
base::TimeTicks SchedulerTqmDelegateImpl::NowTicks() { |