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

Unified Diff: third_party/WebKit/Source/platform/scheduler/base/task_queue_impl.cc

Issue 2823103003: Introduce TaskRunner::RunsTasksInCurrentSequence() (Closed)
Patch Set: remove RunsTasksOnCurrentThread() overrided. Created 3 years, 8 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: third_party/WebKit/Source/platform/scheduler/base/task_queue_impl.cc
diff --git a/third_party/WebKit/Source/platform/scheduler/base/task_queue_impl.cc b/third_party/WebKit/Source/platform/scheduler/base/task_queue_impl.cc
index 1ff9b277a137a9614c32bbad1885c0e61ad622db..9382fdfad8938f1bc499a04265ba2fce0efaf783 100644
--- a/third_party/WebKit/Source/platform/scheduler/base/task_queue_impl.cc
+++ b/third_party/WebKit/Source/platform/scheduler/base/task_queue_impl.cc
@@ -193,7 +193,7 @@ void TaskQueueImpl::UnregisterTaskQueue() {
main_thread_only().delayed_work_queue.reset();
}
-bool TaskQueueImpl::RunsTasksOnCurrentThread() const {
+bool TaskQueueImpl::RunsTasksInCurrentSequence() const {
return base::PlatformThread::CurrentId() == thread_id_;
}
@@ -358,7 +358,7 @@ void TaskQueueImpl::PushOntoImmediateIncomingQueueLocked(
// However there's no point posting a DoWork for a blocked queue. NB we can
// only tell if it's disabled from the main thread.
bool queue_is_blocked =
- RunsTasksOnCurrentThread() &&
+ RunsTasksInCurrentSequence() &&
(!IsQueueEnabled() || main_thread_only().current_fence);
any_thread().task_queue_manager->OnQueueHasIncomingImmediateWork(
this, sequence_number, queue_is_blocked);

Powered by Google App Engine
This is Rietveld 408576698