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

Side by Side Diff: components/scheduler/base/time_domain.h

Issue 2189573002: Fix TimeDomain::MigrateQueue with incoming immediate tasks (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix nits Created 4 years, 4 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 unified diff | Download patch
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef COMPONENTS_SCHEDULER_BASE_TIME_DOMAIN_H_ 5 #ifndef COMPONENTS_SCHEDULER_BASE_TIME_DOMAIN_H_
6 #define COMPONENTS_SCHEDULER_BASE_TIME_DOMAIN_H_ 6 #define COMPONENTS_SCHEDULER_BASE_TIME_DOMAIN_H_
7 7
8 #include <map> 8 #include <map>
9 9
10 #include "base/callback.h" 10 #include "base/callback.h"
(...skipping 71 matching lines...) Expand 10 before | Expand all | Expand 10 after
82 // Schedules a call to TaskQueueImpl::MoveReadyDelayedTasksToDelayedWorkQueue 82 // Schedules a call to TaskQueueImpl::MoveReadyDelayedTasksToDelayedWorkQueue
83 // when this TimeDomain reaches |delayed_run_time|. 83 // when this TimeDomain reaches |delayed_run_time|.
84 void ScheduleDelayedWork(internal::TaskQueueImpl* queue, 84 void ScheduleDelayedWork(internal::TaskQueueImpl* queue,
85 base::TimeTicks delayed_run_time, 85 base::TimeTicks delayed_run_time,
86 base::TimeTicks now); 86 base::TimeTicks now);
87 87
88 // Registers the |queue|. 88 // Registers the |queue|.
89 void RegisterQueue(internal::TaskQueueImpl* queue); 89 void RegisterQueue(internal::TaskQueueImpl* queue);
90 90
91 // Removes |queue| from the set of task queues that UpdateWorkQueues calls 91 // Removes |queue| from the set of task queues that UpdateWorkQueues calls
92 // UpdateWorkQueue on. 92 // UpdateWorkQueue on. Returns true if |queue| was updatable.
93 void UnregisterAsUpdatableTaskQueue(internal::TaskQueueImpl* queue); 93 bool UnregisterAsUpdatableTaskQueue(internal::TaskQueueImpl* queue);
94 94
95 // Removes |queue| from all internal data structures. 95 // Removes |queue| from all internal data structures.
96 void UnregisterQueue(internal::TaskQueueImpl* queue); 96 void UnregisterQueue(internal::TaskQueueImpl* queue);
97 97
98 // Updates active queues associated with this TimeDomain. 98 // Updates active queues associated with this TimeDomain.
99 void UpdateWorkQueues(bool should_trigger_wakeup, 99 void UpdateWorkQueues(bool should_trigger_wakeup,
100 const internal::TaskQueueImpl::Task* previous_task, 100 const internal::TaskQueueImpl::Task* previous_task,
101 LazyNow lazy_now); 101 LazyNow lazy_now);
102 102
103 // Called by the TaskQueueManager when the TimeDomain is registered. 103 // Called by the TaskQueueManager when the TimeDomain is registered.
(...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after
148 Observer* observer_; // NOT OWNED. 148 Observer* observer_; // NOT OWNED.
149 149
150 base::ThreadChecker main_thread_checker_; 150 base::ThreadChecker main_thread_checker_;
151 151
152 DISALLOW_COPY_AND_ASSIGN(TimeDomain); 152 DISALLOW_COPY_AND_ASSIGN(TimeDomain);
153 }; 153 };
154 154
155 } // namespace scheduler 155 } // namespace scheduler
156 156
157 #endif // COMPONENTS_SCHEDULER_BASE_TIME_DOMAIN_H_ 157 #endif // COMPONENTS_SCHEDULER_BASE_TIME_DOMAIN_H_
OLDNEW
« no previous file with comments | « components/scheduler/base/task_queue_manager_unittest.cc ('k') | components/scheduler/base/time_domain.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698