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

Unified Diff: components/scheduler/child/web_scheduler_impl.cc

Issue 1477353002: Revert of Move throttling of background timers into the renderer scheduler (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 1 month 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: components/scheduler/child/web_scheduler_impl.cc
diff --git a/components/scheduler/child/web_scheduler_impl.cc b/components/scheduler/child/web_scheduler_impl.cc
index cc08d38b0005f038f8d5949a0be5c852b715a43d..ce5436e2110d9b8c5b2a29d5e969dfe074995ca2 100644
--- a/components/scheduler/child/web_scheduler_impl.cc
+++ b/components/scheduler/child/web_scheduler_impl.cc
@@ -87,6 +87,20 @@
return timer_web_task_runner_.get();
}
+void WebSchedulerImpl::postTimerTaskAt(
+ const blink::WebTraceLocation& web_location,
+ blink::WebTaskRunner::Task* task,
+ double monotonicTime) {
+ DCHECK(timer_task_runner_);
+ tracked_objects::Location location(web_location.functionName(),
+ web_location.fileName(), -1, nullptr);
+ timer_task_runner_->PostDelayedTaskAt(
+ location,
+ base::Bind(&WebTaskRunnerImpl::runTask,
+ base::Passed(scoped_ptr<blink::WebTaskRunner::Task>(task))),
+ base::TimeTicks() + base::TimeDelta::FromSecondsD(monotonicTime));
+}
+
blink::WebPassOwnPtr<blink::WebViewScheduler>
WebSchedulerImpl::createWebViewScheduler(blink::WebView*) {
NOTREACHED();
« no previous file with comments | « components/scheduler/child/web_scheduler_impl.h ('k') | components/scheduler/renderer/renderer_scheduler_impl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698