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

Unified Diff: mojo/services/html_viewer/webscheduler_impl.cc

Issue 962273002: Experimental: Chrome side of killing the blink timer heap (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase Created 5 years, 9 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
« no previous file with comments | « mojo/services/html_viewer/webscheduler_impl.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: mojo/services/html_viewer/webscheduler_impl.cc
diff --git a/mojo/services/html_viewer/webscheduler_impl.cc b/mojo/services/html_viewer/webscheduler_impl.cc
index 20442ea9671dd29edd103dde771c011e38793c81..e5ac76e3209187538539787a9b65c1e2c9db7e0b 100644
--- a/mojo/services/html_viewer/webscheduler_impl.cc
+++ b/mojo/services/html_viewer/webscheduler_impl.cc
@@ -39,6 +39,18 @@ void WebSchedulerImpl::postLoadingTask(
base::Passed(&scoped_task)));
}
+void WebSchedulerImp::postTimerTask(const WebTraceLocation& web_location,
+ blink::WebThread::Task* task,
+ long long delayMs) {
+ scoped_ptr<blink::WebThread::Task> scoped_task(task);
+ tracked_objects::Location location(web_location.functionName(),
+ web_location.fileName(), -1, nullptr);
+ task_runner_->PostDelayedTask(
+ location,
+ base::Bind(&WebSchedulerImpl::RunTask, base::Passed(&scoped_task)),
+ base::TimeDelta::FromMilliseconds(delayMs));
+}
+
void WebSchedulerImpl::shutdown() {
task_runner_ = nullptr;
}
« no previous file with comments | « mojo/services/html_viewer/webscheduler_impl.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698