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

Unified Diff: mojo/dart/packages/mojo_services/lib/mojo/ui/view_associates.mojom.dart

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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | mojo/dart/packages/mojo_services/lib/mojo/ui/view_manager.mojom.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: mojo/dart/packages/mojo_services/lib/mojo/ui/view_associates.mojom.dart
diff --git a/mojo/dart/packages/mojo_services/lib/mojo/ui/view_associates.mojom.dart b/mojo/dart/packages/mojo_services/lib/mojo/ui/view_associates.mojom.dart
index eeed7cfe72a111ad3dccebe760e8144ebf818efa..96f3d2a5b11d5d8f38cc74543a6a8d4f8931c1b3 100644
--- a/mojo/dart/packages/mojo_services/lib/mojo/ui/view_associates.mojom.dart
+++ b/mojo/dart/packages/mojo_services/lib/mojo/ui/view_associates.mojom.dart
@@ -1088,6 +1088,183 @@ class ViewAssociateStub
}
}
+
+class _ViewAssociateOwnerServiceDescription implements service_describer.ServiceDescription {
+ dynamic getTopLevelInterface([Function responseFactory]) =>
+ responseFactory(null);
+
+ dynamic getTypeDefinition(String typeKey, [Function responseFactory]) =>
+ responseFactory(null);
+
+ dynamic getAllTypeDefinitions([Function responseFactory]) =>
+ responseFactory(null);
+}
+
+abstract class ViewAssociateOwner {
+ static const String serviceName = "mojo::ui::ViewAssociateOwner";
+}
+
+class _ViewAssociateOwnerProxyControl
+ extends bindings.ProxyMessageHandler
+ implements bindings.ProxyControl {
+ _ViewAssociateOwnerProxyControl.fromEndpoint(
+ core.MojoMessagePipeEndpoint endpoint) : super.fromEndpoint(endpoint);
+
+ _ViewAssociateOwnerProxyControl.fromHandle(
+ core.MojoHandle handle) : super.fromHandle(handle);
+
+ _ViewAssociateOwnerProxyControl.unbound() : super.unbound();
+
+ service_describer.ServiceDescription get serviceDescription =>
+ new _ViewAssociateOwnerServiceDescription();
+
+ String get serviceName => ViewAssociateOwner.serviceName;
+
+ void handleResponse(bindings.ServiceMessage message) {
+ switch (message.header.type) {
+ default:
+ proxyError("Unexpected message type: ${message.header.type}");
+ close(immediate: true);
+ break;
+ }
+ }
+
+ @override
+ String toString() {
+ var superString = super.toString();
+ return "_ViewAssociateOwnerProxyControl($superString)";
+ }
+}
+
+class ViewAssociateOwnerProxy
+ extends bindings.Proxy
+ implements ViewAssociateOwner {
+ ViewAssociateOwnerProxy.fromEndpoint(
+ core.MojoMessagePipeEndpoint endpoint)
+ : super(new _ViewAssociateOwnerProxyControl.fromEndpoint(endpoint));
+
+ ViewAssociateOwnerProxy.fromHandle(core.MojoHandle handle)
+ : super(new _ViewAssociateOwnerProxyControl.fromHandle(handle));
+
+ ViewAssociateOwnerProxy.unbound()
+ : super(new _ViewAssociateOwnerProxyControl.unbound());
+
+ static ViewAssociateOwnerProxy newFromEndpoint(
+ core.MojoMessagePipeEndpoint endpoint) {
+ assert(endpoint.setDescription("For ViewAssociateOwnerProxy"));
+ return new ViewAssociateOwnerProxy.fromEndpoint(endpoint);
+ }
+
+ factory ViewAssociateOwnerProxy.connectToService(
+ bindings.ServiceConnector s, String url, [String serviceName]) {
+ ViewAssociateOwnerProxy p = new ViewAssociateOwnerProxy.unbound();
+ s.connectToService(url, p, serviceName);
+ return p;
+ }
+
+
+}
+
+class _ViewAssociateOwnerStubControl
+ extends bindings.StubMessageHandler
+ implements bindings.StubControl<ViewAssociateOwner> {
+ ViewAssociateOwner _impl;
+
+ _ViewAssociateOwnerStubControl.fromEndpoint(
+ core.MojoMessagePipeEndpoint endpoint, [ViewAssociateOwner impl])
+ : super.fromEndpoint(endpoint, autoBegin: impl != null) {
+ _impl = impl;
+ }
+
+ _ViewAssociateOwnerStubControl.fromHandle(
+ core.MojoHandle handle, [ViewAssociateOwner impl])
+ : super.fromHandle(handle, autoBegin: impl != null) {
+ _impl = impl;
+ }
+
+ _ViewAssociateOwnerStubControl.unbound([this._impl]) : super.unbound();
+
+
+
+ dynamic handleMessage(bindings.ServiceMessage message) {
+ if (bindings.ControlMessageHandler.isControlMessage(message)) {
+ return bindings.ControlMessageHandler.handleMessage(this,
+ 0,
+ message);
+ }
+ if (_impl == null) {
+ throw new core.MojoApiError("$this has no implementation set");
+ }
+ switch (message.header.type) {
+ default:
+ throw new bindings.MojoCodecError("Unexpected message name");
+ break;
+ }
+ return null;
+ }
+
+ ViewAssociateOwner get impl => _impl;
+ set impl(ViewAssociateOwner d) {
+ if (d == null) {
+ throw new core.MojoApiError("$this: Cannot set a null implementation");
+ }
+ if (isBound && (_impl == null)) {
+ beginHandlingEvents();
+ }
+ _impl = d;
+ }
+
+ @override
+ void bind(core.MojoMessagePipeEndpoint endpoint) {
+ super.bind(endpoint);
+ if (!isOpen && (_impl != null)) {
+ beginHandlingEvents();
+ }
+ }
+
+ @override
+ String toString() {
+ var superString = super.toString();
+ return "_ViewAssociateOwnerStubControl($superString)";
+ }
+
+ int get version => 0;
+
+ static service_describer.ServiceDescription _cachedServiceDescription;
+ static service_describer.ServiceDescription get serviceDescription {
+ if (_cachedServiceDescription == null) {
+ _cachedServiceDescription = new _ViewAssociateOwnerServiceDescription();
+ }
+ return _cachedServiceDescription;
+ }
+}
+
+class ViewAssociateOwnerStub
+ extends bindings.Stub<ViewAssociateOwner>
+ implements ViewAssociateOwner {
+ ViewAssociateOwnerStub.fromEndpoint(
+ core.MojoMessagePipeEndpoint endpoint, [ViewAssociateOwner impl])
+ : super(new _ViewAssociateOwnerStubControl.fromEndpoint(endpoint, impl));
+
+ ViewAssociateOwnerStub.fromHandle(
+ core.MojoHandle handle, [ViewAssociateOwner impl])
+ : super(new _ViewAssociateOwnerStubControl.fromHandle(handle, impl));
+
+ ViewAssociateOwnerStub.unbound([ViewAssociateOwner impl])
+ : super(new _ViewAssociateOwnerStubControl.unbound(impl));
+
+ static ViewAssociateOwnerStub newFromEndpoint(
+ core.MojoMessagePipeEndpoint endpoint) {
+ assert(endpoint.setDescription("For ViewAssociateOwnerStub"));
+ return new ViewAssociateOwnerStub.fromEndpoint(endpoint);
+ }
+
+ static service_describer.ServiceDescription get serviceDescription =>
+ _ViewAssociateOwnerStubControl.serviceDescription;
+
+
+}
+
const int _viewInspectorMethodGetHitTesterName = 0;
const int _viewInspectorMethodResolveScenesName = 1;
« no previous file with comments | « no previous file | mojo/dart/packages/mojo_services/lib/mojo/ui/view_manager.mojom.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698