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

Unified Diff: content/browser/plugin_service_impl.cc

Issue 2837863003: Use TaskScheduler instead of blocking pool in plugin_service_impl.cc. (Closed)
Patch Set: USER_VISIBLE 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: content/browser/plugin_service_impl.cc
diff --git a/content/browser/plugin_service_impl.cc b/content/browser/plugin_service_impl.cc
index 480c659e0431c0b6c043c79eea3fa5567b4b8734..542e873060c691da0a4e98a3014960f0fd84eb5e 100644
--- a/content/browser/plugin_service_impl.cc
+++ b/content/browser/plugin_service_impl.cc
@@ -17,7 +17,7 @@
#include "base/strings/string_util.h"
#include "base/strings/utf_string_conversions.h"
#include "base/synchronization/waitable_event.h"
-#include "base/threading/sequenced_worker_pool.h"
+#include "base/task_scheduler/post_task.h"
#include "base/threading/thread.h"
#include "base/threading/thread_task_runner_handle.h"
#include "build/build_config.h"
@@ -97,11 +97,11 @@ PluginServiceImpl::~PluginServiceImpl() {
}
void PluginServiceImpl::Init() {
- plugin_list_task_runner_ =
- BrowserThread::GetBlockingPool()
- ->GetSequencedTaskRunnerWithShutdownBehavior(
- base::SequencedWorkerPool::GetSequenceToken(),
- base::SequencedWorkerPool::SKIP_ON_SHUTDOWN);
+ plugin_list_task_runner_ = base::CreateSequencedTaskRunnerWithTraits(
+ base::TaskTraits()
+ .MayBlock()
+ .WithPriority(base::TaskPriority::USER_VISIBLE)
+ .WithShutdownBehavior(base::TaskShutdownBehavior::SKIP_ON_SHUTDOWN));
PluginList::Singleton()->set_will_load_plugins_callback(
base::Bind(&WillLoadPluginsCallback, &plugin_list_sequence_checker_));
« 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