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

Unified Diff: services/ui/public/interfaces/window_tree_host.mojom

Issue 2712203002: c++ / mojo changes for 'external window mode'
Patch Set: addressed sky/fwang feedback (take 5), simpler mus_demo changes / passing unittests Created 3 years, 9 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
Index: services/ui/public/interfaces/window_tree_host.mojom
diff --git a/services/ui/public/interfaces/window_tree_host.mojom b/services/ui/public/interfaces/window_tree_host.mojom
index 8a349600a3d9b22aa5ca114ea6c949ad30e60315..aacab5e1e5a4154bab1c4c2815bf81738668393a 100644
--- a/services/ui/public/interfaces/window_tree_host.mojom
+++ b/services/ui/public/interfaces/window_tree_host.mojom
@@ -17,9 +17,32 @@ interface WindowTreeHost {
SetTitle(string title);
};
+// WindowTreeHostFactoryRegistrar is the entry point to obtain a
+// WindowTreeHostFactory instance in 'external window mode'.
+// Callers also obtain a mojo handle to the unique ws::WindowTree instance,
+// on the server-side.
+//
+// NOTE: WindowTreeHostFactoryRegistrar::Register and
+// WindowTreeHostFactory::CreatePlatformWindow are put on separate interfaces,
+// so that the interface containing ::CreatePlatformWindow is obtained by
+// calling ::Register. That eliminates the possibility of ::CreatePlatformWindow
+// being called before ::Register.
+//
kylechar 2017/03/07 18:19:37 Delete empty comment line.
tonikitoo 2017/03/07 20:09:36 Will fix.
+interface WindowTreeHostFactoryRegistrar {
+ Register(WindowTreeHostFactory& window_tree_host_factory,
+ WindowTree& tree_request,
+ WindowTreeClient client);
+};
+
+// WindowTreeHostFactory triggers the creation of WindowTreeHost instances.
interface WindowTreeHostFactory {
// Creates a new WindowTreeHost. |tree_client| is queried for the
// WindowManager.
CreateWindowTreeHost(WindowTreeHost& window_tree_host,
WindowTreeClient tree_client);
+
+ // Creates a new WindowTreeHost in 'external window mode'.
+ // One WindowTree/WindowTreeClient pair can serve one or more WindowTreeHost
+ // instances.
+ CreatePlatformWindow(WindowTreeHost& window_tree_host, uint32 client_id);
kylechar 2017/03/07 18:19:36 What is |client_id| supposed to be?
tonikitoo 2017/03/07 20:09:36 WindowHostTreeMus is created on the client side be
};

Powered by Google App Engine
This is Rietveld 408576698