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

Side by Side Diff: mojo/services/ui/views/interfaces/view_manager.mojom

Issue 1949233002: Create a RegisterViewAssociate method in ViewManager (Closed) Base URL: https://github.com/domokit/mojo.git@master
Patch Set: add tests to mojo tests 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 unified diff | Download patch
« no previous file with comments | « mojo/services/ui/views/interfaces/view_associates.mojom ('k') | mojo/tools/data/apptests » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 [DartPackage="mojo_services"] 5 [DartPackage="mojo_services"]
6 module mojo.ui; 6 module mojo.ui;
7 7
8 import "mojo/services/ui/views/interfaces/view_associates.mojom"; 8 import "mojo/services/ui/views/interfaces/view_associates.mojom";
9 import "mojo/services/ui/views/interfaces/view_trees.mojom"; 9 import "mojo/services/ui/views/interfaces/view_trees.mojom";
10 import "mojo/services/ui/views/interfaces/views.mojom"; 10 import "mojo/services/ui/views/interfaces/views.mojom";
(...skipping 49 matching lines...) Expand 10 before | Expand all | Expand 10 after
60 // 60 //
61 // The |label| is an optional name to associate with the view tree for 61 // The |label| is an optional name to associate with the view tree for
62 // diagnostic purposes. The label will be truncated if it is longer 62 // diagnostic purposes. The label will be truncated if it is longer
63 // than |kLabelMaxLength|. 63 // than |kLabelMaxLength|.
64 // 64 //
65 // To destroy the view tree simply close the |view_tree| or 65 // To destroy the view tree simply close the |view_tree| or
66 // |view_tree_listener| message pipes. 66 // |view_tree_listener| message pipes.
67 CreateViewTree(mojo.ui.ViewTree& view_tree, 67 CreateViewTree(mojo.ui.ViewTree& view_tree,
68 mojo.ui.ViewTreeListener view_tree_listener, 68 mojo.ui.ViewTreeListener view_tree_listener,
69 string? label); 69 string? label);
70
71 // Registers a view associate with the view manager.
72 //
73 // The services provided by |view_associate| will be made available to views.
74 //
75 // You receive a |view_associate_owner| which will receive a connection error
76 // callback if |view_associate| is closed. Conversely, the service for
77 // |view_associate| will be destroyed if |view_associate_owner| is destroyed.
78 //
79 // |label| is used to identify the ViewAssociate for debug purposes.
80 //
81 // TODO(mikejurka): This method should only be made accessible to trusted
82 // services, once we have a security story
83 RegisterViewAssociate(mojo.ui.ViewAssociate view_associate,
84 mojo.ui.ViewAssociateOwner& view_associate_owner, string? label);
85
86 // Tells the view manager we've registered all our view associates.
87 //
88 // This allows it to prevent views from requesting services from ViewAssociate
89 // before all the ViewAssociates have been registered.
90 //
91 // TODO(mikejurka): This method should only be made accessible to trusted
92 // services, once we have a security story
93 // TODO(mikejurka): We should remove this method once we have a way of
94 // dynamically registering and unregistering ViewAssociates
95 FinishedRegisteringViewAssociates();
70 }; 96 };
OLDNEW
« no previous file with comments | « mojo/services/ui/views/interfaces/view_associates.mojom ('k') | mojo/tools/data/apptests » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698