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

Unified Diff: device/hid/hid_service.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/bluetooth/bluez/bluetooth_socket_bluez.cc ('k') | device/serial/data_receiver.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: device/hid/hid_service.cc
diff --git a/device/hid/hid_service.cc b/device/hid/hid_service.cc
index 00f52dc52fb8cd1a83d2f3f84b88304a09943f6b..d908fe7d2d09d5018fb943309996a82cbfdee0bc 100644
--- a/device/hid/hid_service.cc
+++ b/device/hid/hid_service.cc
@@ -6,10 +6,11 @@
#include "base/at_exit.h"
#include "base/bind.h"
+#include "base/location.h"
#include "base/logging.h"
#include "base/memory/ptr_util.h"
-#include "base/message_loop/message_loop.h"
#include "base/stl_util.h"
+#include "base/threading/thread_task_runner_handle.h"
#include "build/build_config.h"
#include "components/device_event_log/device_event_log.h"
@@ -55,8 +56,8 @@ void HidService::GetDevices(const GetDevicesCallback& callback) {
for (const auto& map_entry : devices_) {
devices.push_back(map_entry.second);
}
- base::MessageLoop::current()->PostTask(FROM_HERE,
- base::Bind(callback, devices));
+ base::ThreadTaskRunnerHandle::Get()->PostTask(
+ FROM_HERE, base::Bind(callback, devices));
} else {
pending_enumerations_.push_back(callback);
}
« no previous file with comments | « device/bluetooth/bluez/bluetooth_socket_bluez.cc ('k') | device/serial/data_receiver.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698