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

Unified Diff: chrome/browser/chromeos/policy/remote_commands/device_commands_factory_chromeos.cc

Issue 2837083002: Use TaskScheduler instead of blocking pool in device_commands_factory_chromeos.cc. (Closed)
Patch Set: Created 3 years, 8 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 | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/chromeos/policy/remote_commands/device_commands_factory_chromeos.cc
diff --git a/chrome/browser/chromeos/policy/remote_commands/device_commands_factory_chromeos.cc b/chrome/browser/chromeos/policy/remote_commands/device_commands_factory_chromeos.cc
index de461e56db0059a85692878de1610db33a7bb758..0c70a1fba1b31c21c783293239eeb82637f3a93a 100644
--- a/chrome/browser/chromeos/policy/remote_commands/device_commands_factory_chromeos.cc
+++ b/chrome/browser/chromeos/policy/remote_commands/device_commands_factory_chromeos.cc
@@ -7,7 +7,7 @@
#include <memory>
#include "base/memory/ptr_util.h"
-#include "base/threading/sequenced_worker_pool.h"
+#include "base/task_scheduler/post_task.h"
#include "chrome/browser/chromeos/policy/remote_commands/device_command_fetch_status_job.h"
#include "chrome/browser/chromeos/policy/remote_commands/device_command_reboot_job.h"
#include "chrome/browser/chromeos/policy/remote_commands/device_command_screenshot_job.h"
@@ -16,7 +16,6 @@
#include "chromeos/dbus/dbus_thread_manager.h"
#include "components/policy/core/common/remote_commands/remote_command_job.h"
#include "components/policy/proto/device_management_backend.pb.h"
-#include "content/public/browser/browser_thread.h"
namespace em = enterprise_management;
@@ -37,9 +36,9 @@ DeviceCommandsFactoryChromeOS::BuildJobForType(em::RemoteCommand_Type type) {
case em::RemoteCommand_Type_DEVICE_SCREENSHOT:
return base::WrapUnique<RemoteCommandJob>(
new DeviceCommandScreenshotJob(base::MakeUnique<ScreenshotDelegate>(
- content::BrowserThread::GetBlockingPool()->GetSequencedTaskRunner(
- content::BrowserThread::GetBlockingPool()
- ->GetSequenceToken()))));
+ base::CreateSequencedTaskRunnerWithTraits(
+ base::TaskTraits().MayBlock().WithPriority(
+ base::TaskPriority::BACKGROUND)))));
Thiemo Nagel 2017/04/27 09:48:43 Same here, I think we should SKIP_ON_SHUTDOWN. I
fdoray 2017/04/27 13:27:45 Done.
case em::RemoteCommand_Type_DEVICE_SET_VOLUME:
return base::WrapUnique<RemoteCommandJob>(
new DeviceCommandSetVolumeJob());
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698