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

Unified Diff: base/message_loop/message_pump_perftest.cc

Issue 2103333006: Remove calls to deprecated MessageLoop methods in base. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 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
« no previous file with comments | « base/message_loop/message_pump_libevent_unittest.cc ('k') | base/observer_list_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: base/message_loop/message_pump_perftest.cc
diff --git a/base/message_loop/message_pump_perftest.cc b/base/message_loop/message_pump_perftest.cc
index edaf2068ff6ec1cdfe0df140f35f4a88f898954e..7bb942fa657707f2e9de8112d3e3b868435aa33e 100644
--- a/base/message_loop/message_pump_perftest.cc
+++ b/base/message_loop/message_pump_perftest.cc
@@ -9,6 +9,7 @@
#include "base/format_macros.h"
#include "base/memory/ptr_util.h"
#include "base/memory/scoped_vector.h"
+#include "base/single_thread_task_runner.h"
#include "base/strings/stringprintf.h"
#include "base/synchronization/condition_variable.h"
#include "base/synchronization/lock.h"
@@ -63,10 +64,9 @@ class ScheduleWorkTest : public testing::Test {
base::ThreadTicks::Now() - thread_start;
min_batch_times_[index] = minimum;
max_batch_times_[index] = maximum;
- target_message_loop()->PostTask(FROM_HERE,
- base::Bind(&ScheduleWorkTest::Increment,
- base::Unretained(this),
- schedule_calls));
+ target_message_loop()->task_runner()->PostTask(
+ FROM_HERE, base::Bind(&ScheduleWorkTest::Increment,
+ base::Unretained(this), schedule_calls));
}
void ScheduleWork(MessageLoop::Type target_type, int num_scheduling_threads) {
@@ -101,7 +101,7 @@ class ScheduleWorkTest : public testing::Test {
}
for (int i = 0; i < num_scheduling_threads; ++i) {
- scheduling_threads[i]->message_loop()->PostTask(
+ scheduling_threads[i]->message_loop()->task_runner()->PostTask(
FROM_HERE,
base::Bind(&ScheduleWorkTest::Schedule, base::Unretained(this), i));
}
« no previous file with comments | « base/message_loop/message_pump_libevent_unittest.cc ('k') | base/observer_list_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698