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

Unified Diff: device/serial/data_receiver.cc

Issue 2031743005: Remove use of deprecated MessageLoop methods in device. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 7 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 | « device/hid/hid_service.cc ('k') | device/serial/data_sender.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: device/serial/data_receiver.cc
diff --git a/device/serial/data_receiver.cc b/device/serial/data_receiver.cc
index 95f2154039decc37c871d3fa0d4b8c96c706cc09..361e201a550a096ba8f6db28e7e23fcfcb6ebcd5 100644
--- a/device/serial/data_receiver.cc
+++ b/device/serial/data_receiver.cc
@@ -9,7 +9,9 @@
#include <utility>
#include "base/bind.h"
-#include "base/message_loop/message_loop.h"
+#include "base/location.h"
+#include "base/single_thread_task_runner.h"
+#include "base/threading/thread_task_runner_handle.h"
namespace device {
@@ -225,12 +227,12 @@ bool DataReceiver::PendingReceive::DispatchDataFrame(
if (data->is_error) {
data->dispatched = true;
- base::MessageLoop::current()->PostTask(
+ base::ThreadTaskRunnerHandle::Get()->PostTask(
FROM_HERE, base::Bind(receive_error_callback_, data->error));
return true;
}
buffer_in_use_ = true;
- base::MessageLoop::current()->PostTask(
+ base::ThreadTaskRunnerHandle::Get()->PostTask(
FROM_HERE,
base::Bind(
receive_callback_,
« no previous file with comments | « device/hid/hid_service.cc ('k') | device/serial/data_sender.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698