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

Side by Side Diff: mojo/services/public/interfaces/view_manager/view_manager.mojom

Issue 534843002: Convert view manager to surfaces with uploading shim in client lib (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 3 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
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 import "mojo/public/interfaces/application/service_provider.mojom" 5 import "mojo/public/interfaces/application/service_provider.mojom"
6 import "mojo/services/public/interfaces/geometry/geometry.mojom" 6 import "mojo/services/public/interfaces/geometry/geometry.mojom"
7 import "mojo/services/public/interfaces/input_events/input_events.mojom" 7 import "mojo/services/public/interfaces/input_events/input_events.mojom"
8 import "mojo/services/public/interfaces/surfaces/surface_id.mojom"
8 import "mojo/services/public/interfaces/view_manager/view_manager_constants.mojo m" 9 import "mojo/services/public/interfaces/view_manager/view_manager_constants.mojo m"
9 10
10 module mojo { 11 module mojo {
11 12
12 struct ViewData { 13 struct ViewData {
13 uint32 parent_id; 14 uint32 parent_id;
14 uint32 view_id; 15 uint32 view_id;
15 mojo.Rect? bounds; 16 mojo.Rect? bounds;
16 // TODO(sky): add visible. 17 // TODO(sky): add visible.
17 }; 18 };
(...skipping 75 matching lines...) Expand 10 before | Expand all | Expand 10 after
93 ReorderView(uint32 view_id, 94 ReorderView(uint32 view_id,
94 uint32 relative_view_id, 95 uint32 relative_view_id,
95 OrderDirection direction) => (bool success); 96 OrderDirection direction) => (bool success);
96 97
97 // Returns the views comprising the tree starting at |view_id|. |view_id| is 98 // Returns the views comprising the tree starting at |view_id|. |view_id| is
98 // the first result in the return value, unless |view_id| is invalid, in which 99 // the first result in the return value, unless |view_id| is invalid, in which
99 // case an empty vector is returned. The views are visited using a depth first 100 // case an empty vector is returned. The views are visited using a depth first
100 // search (pre-order). 101 // search (pre-order).
101 GetViewTree(uint32 view_id) => (ViewData?[]? views); 102 GetViewTree(uint32 view_id) => (ViewData?[]? views);
102 103
103 // Shows the specified image (png encoded) in the specified view. 104 // Shows the surface in the specified view.
104 SetViewContents(uint32 view_id, 105 SetViewSurfaceId(uint32 view_id, SurfaceId surface_id) => (bool success);
105 handle<shared_buffer>? buffer,
106 uint32 buffer_size) => (bool success);
107 106
108 // Embeds the app for |url| in the specified view. More specifically this 107 // Embeds the app for |url| in the specified view. More specifically this
109 // creates a new connection to the specified url, expecting to get a 108 // creates a new connection to the specified url, expecting to get a
110 // ViewManagerClient and configures it with the root view |view|. Fails 109 // ViewManagerClient and configures it with the root view |view|. Fails
111 // if |view| was not created by this connection. 110 // if |view| was not created by this connection.
112 // 111 //
113 // If a particular client invokes Embed() multiple times with the same url, 112 // If a particular client invokes Embed() multiple times with the same url,
114 // the connection is reused. When this happens the ViewManagerClient is 113 // the connection is reused. When this happens the ViewManagerClient is
115 // notified of the additional roots by way of OnEmbed(). 114 // notified of the additional roots by way of OnEmbed().
116 // 115 //
(...skipping 73 matching lines...) Expand 10 before | Expand all | Expand 10 after
190 // once support for derived FIFOs is landed. 189 // once support for derived FIFOs is landed.
191 190
192 // Requests the window manager create a "top level" view embedding |url|. 191 // Requests the window manager create a "top level" view embedding |url|.
193 Embed(string? url, ServiceProvider&? service_provider); 192 Embed(string? url, ServiceProvider&? service_provider);
194 193
195 // Requests the view manager dispatch the event. 194 // Requests the view manager dispatch the event.
196 DispatchOnViewInputEvent(mojo.Event? event); 195 DispatchOnViewInputEvent(mojo.Event? event);
197 }; 196 };
198 197
199 } 198 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698