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

Unified Diff: ui/views/mus/window_manager_connection.h

Issue 2249413004: services/ui: Allow injecting the IO thread task runner for gpu channel. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: . Created 4 years, 4 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 | « services/ui/public/cpp/gpu_service.cc ('k') | ui/views/mus/window_manager_connection.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/views/mus/window_manager_connection.h
diff --git a/ui/views/mus/window_manager_connection.h b/ui/views/mus/window_manager_connection.h
index 6b2de1d70feb939e59d0e11438b32d1fb0908727..367f824d4a4f818c7553097c291d135f44428844 100644
--- a/ui/views/mus/window_manager_connection.h
+++ b/ui/views/mus/window_manager_connection.h
@@ -55,9 +55,12 @@ class VIEWS_MUS_EXPORT WindowManagerConnection
public:
~WindowManagerConnection() override;
+ // |io_task_runner| is used by the gpu service. If no task runner is provided,
+ // then a new thread is created and used by ui::GpuService.
static std::unique_ptr<WindowManagerConnection> Create(
shell::Connector* connector,
- const shell::Identity& identity);
+ const shell::Identity& identity,
+ scoped_refptr<base::SingleThreadTaskRunner> io_task_runner = nullptr);
static WindowManagerConnection* Get();
static bool Exists();
@@ -79,8 +82,10 @@ class VIEWS_MUS_EXPORT WindowManagerConnection
const std::set<ui::Window*>& GetRoots() const;
private:
- WindowManagerConnection(shell::Connector* connector,
- const shell::Identity& identity);
+ WindowManagerConnection(
+ shell::Connector* connector,
+ const shell::Identity& identity,
+ scoped_refptr<base::SingleThreadTaskRunner> task_runner);
// ui::WindowTreeClientDelegate:
void OnEmbed(ui::Window* root) override;
« no previous file with comments | « services/ui/public/cpp/gpu_service.cc ('k') | ui/views/mus/window_manager_connection.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698