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

Unified Diff: chrome/common/profiling.cc

Issue 1167163002: chrome: Remove use of MessageLoopProxy and deprecated MessageLoop APIs (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Added some missing message_loop.h includes. Created 5 years, 6 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: chrome/common/profiling.cc
diff --git a/chrome/common/profiling.cc b/chrome/common/profiling.cc
index 07cc8def0c34a2a01a24a672d2f5c96fe160ed5d..6dc28c6a813350bf07bf3a96f2037b4388888f32 100644
--- a/chrome/common/profiling.cc
+++ b/chrome/common/profiling.cc
@@ -9,7 +9,8 @@
#include "base/command_line.h"
#include "base/debug/profiler.h"
#include "base/lazy_instance.h"
-#include "base/message_loop/message_loop.h"
+#include "base/location.h"
+#include "base/single_thread_task_runner.h"
#include "base/strings/string_util.h"
#include "base/threading/thread.h"
#include "chrome/common/chrome_switches.h"
@@ -82,9 +83,8 @@ void FlushProfilingData(base::Thread* thread) {
flush_seconds = kProfilingFlushSeconds;
}
}
- thread->message_loop()->PostDelayedTask(
- FROM_HERE,
- base::Bind(&FlushProfilingData, thread),
+ thread->task_runner()->PostDelayedTask(
+ FROM_HERE, base::Bind(&FlushProfilingData, thread),
base::TimeDelta::FromSeconds(flush_seconds));
}
@@ -99,8 +99,8 @@ class ProfilingThreadControl {
return;
thread_ = new base::Thread("Profiling_Flush");
thread_->Start();
- thread_->message_loop()->PostTask(
- FROM_HERE, base::Bind(&FlushProfilingData, thread_));
+ thread_->task_runner()->PostTask(FROM_HERE,
+ base::Bind(&FlushProfilingData, thread_));
}
void Stop() {
« no previous file with comments | « chrome/common/local_discovery/service_discovery_client_unittest.cc ('k') | chrome/common/service_process_util.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698