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

Side by Side Diff: mojo/dart/packages/mojo_services/lib/mojo/native_viewport.mojom.dart

Issue 1539673003: Generate Mojom Types in Dart (Take 2) (Closed) Base URL: https://github.com/domokit/mojo.git@master
Patch Set: Merge with master Created 4 years, 10 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 library native_viewport_mojom; 5 library native_viewport_mojom;
6 6
7 import 'dart:async'; 7 import 'dart:async';
8 8
9 import 'package:mojo/bindings.dart' as bindings; 9 import 'package:mojo/bindings.dart' as bindings;
10 import 'package:mojo/core.dart' as core; 10 import 'package:mojo/core.dart' as core;
11 import 'package:mojo/mojo/bindings/types/mojom_types.mojom.dart' as mojom_types;
12 import 'package:mojo/mojo/bindings/types/service_describer.mojom.dart' as servic e_describer;
11 import 'package:mojo_services/mojo/geometry.mojom.dart' as geometry_mojom; 13 import 'package:mojo_services/mojo/geometry.mojom.dart' as geometry_mojom;
12 import 'package:mojo_services/mojo/context_provider.mojom.dart' as context_provi der_mojom; 14 import 'package:mojo_services/mojo/context_provider.mojom.dart' as context_provi der_mojom;
13 import 'package:mojo_services/mojo/input_events.mojom.dart' as input_events_mojo m; 15 import 'package:mojo_services/mojo/input_events.mojom.dart' as input_events_mojo m;
14 16
15 17
16 18
17 class ViewportMetrics extends bindings.Struct { 19 class ViewportMetrics extends bindings.Struct {
18 static const List<bindings.StructDataHeader> kVersions = const [ 20 static const List<bindings.StructDataHeader> kVersions = const [
19 const bindings.StructDataHeader(24, 0) 21 const bindings.StructDataHeader(24, 0)
20 ]; 22 ];
(...skipping 63 matching lines...) Expand 10 before | Expand all | Expand 10 after
84 86
85 Map toJson() { 87 Map toJson() {
86 Map map = new Map(); 88 Map map = new Map();
87 map["size"] = size; 89 map["size"] = size;
88 map["devicePixelRatio"] = devicePixelRatio; 90 map["devicePixelRatio"] = devicePixelRatio;
89 return map; 91 return map;
90 } 92 }
91 } 93 }
92 94
93 95
96
97
94 class SurfaceConfiguration extends bindings.Struct { 98 class SurfaceConfiguration extends bindings.Struct {
95 static const List<bindings.StructDataHeader> kVersions = const [ 99 static const List<bindings.StructDataHeader> kVersions = const [
96 const bindings.StructDataHeader(16, 0) 100 const bindings.StructDataHeader(16, 0)
97 ]; 101 ];
98 int redBits = 8; 102 int redBits = 8;
99 int greenBits = 8; 103 int greenBits = 8;
100 int blueBits = 8; 104 int blueBits = 8;
101 int alphaBits = 8; 105 int alphaBits = 8;
102 int depthBits = 0; 106 int depthBits = 0;
103 int stencilBits = 0; 107 int stencilBits = 0;
(...skipping 92 matching lines...) Expand 10 before | Expand all | Expand 10 after
196 map["greenBits"] = greenBits; 200 map["greenBits"] = greenBits;
197 map["blueBits"] = blueBits; 201 map["blueBits"] = blueBits;
198 map["alphaBits"] = alphaBits; 202 map["alphaBits"] = alphaBits;
199 map["depthBits"] = depthBits; 203 map["depthBits"] = depthBits;
200 map["stencilBits"] = stencilBits; 204 map["stencilBits"] = stencilBits;
201 return map; 205 return map;
202 } 206 }
203 } 207 }
204 208
205 209
210
211
206 class _NativeViewportCreateParams extends bindings.Struct { 212 class _NativeViewportCreateParams extends bindings.Struct {
207 static const List<bindings.StructDataHeader> kVersions = const [ 213 static const List<bindings.StructDataHeader> kVersions = const [
208 const bindings.StructDataHeader(24, 0) 214 const bindings.StructDataHeader(24, 0)
209 ]; 215 ];
210 geometry_mojom.Size size = null; 216 geometry_mojom.Size size = null;
211 SurfaceConfiguration requestedConfiguration = null; 217 SurfaceConfiguration requestedConfiguration = null;
212 218
213 _NativeViewportCreateParams() : super(kVersions.last.size); 219 _NativeViewportCreateParams() : super(kVersions.last.size);
214 220
215 static _NativeViewportCreateParams deserialize(bindings.Message message) { 221 static _NativeViewportCreateParams deserialize(bindings.Message message) {
(...skipping 58 matching lines...) Expand 10 before | Expand all | Expand 10 after
274 280
275 Map toJson() { 281 Map toJson() {
276 Map map = new Map(); 282 Map map = new Map();
277 map["size"] = size; 283 map["size"] = size;
278 map["requestedConfiguration"] = requestedConfiguration; 284 map["requestedConfiguration"] = requestedConfiguration;
279 return map; 285 return map;
280 } 286 }
281 } 287 }
282 288
283 289
290
291
284 class NativeViewportCreateResponseParams extends bindings.Struct { 292 class NativeViewportCreateResponseParams extends bindings.Struct {
285 static const List<bindings.StructDataHeader> kVersions = const [ 293 static const List<bindings.StructDataHeader> kVersions = const [
286 const bindings.StructDataHeader(16, 0) 294 const bindings.StructDataHeader(16, 0)
287 ]; 295 ];
288 ViewportMetrics metrics = null; 296 ViewportMetrics metrics = null;
289 297
290 NativeViewportCreateResponseParams() : super(kVersions.last.size); 298 NativeViewportCreateResponseParams() : super(kVersions.last.size);
291 299
292 static NativeViewportCreateResponseParams deserialize(bindings.Message message ) { 300 static NativeViewportCreateResponseParams deserialize(bindings.Message message ) {
293 var decoder = new bindings.Decoder(message); 301 var decoder = new bindings.Decoder(message);
(...skipping 48 matching lines...) Expand 10 before | Expand all | Expand 10 after
342 } 350 }
343 351
344 Map toJson() { 352 Map toJson() {
345 Map map = new Map(); 353 Map map = new Map();
346 map["metrics"] = metrics; 354 map["metrics"] = metrics;
347 return map; 355 return map;
348 } 356 }
349 } 357 }
350 358
351 359
360
361
352 class _NativeViewportShowParams extends bindings.Struct { 362 class _NativeViewportShowParams extends bindings.Struct {
353 static const List<bindings.StructDataHeader> kVersions = const [ 363 static const List<bindings.StructDataHeader> kVersions = const [
354 const bindings.StructDataHeader(8, 0) 364 const bindings.StructDataHeader(8, 0)
355 ]; 365 ];
356 366
357 _NativeViewportShowParams() : super(kVersions.last.size); 367 _NativeViewportShowParams() : super(kVersions.last.size);
358 368
359 static _NativeViewportShowParams deserialize(bindings.Message message) { 369 static _NativeViewportShowParams deserialize(bindings.Message message) {
360 var decoder = new bindings.Decoder(message); 370 var decoder = new bindings.Decoder(message);
361 var result = decode(decoder); 371 var result = decode(decoder);
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after
400 return "_NativeViewportShowParams("")"; 410 return "_NativeViewportShowParams("")";
401 } 411 }
402 412
403 Map toJson() { 413 Map toJson() {
404 Map map = new Map(); 414 Map map = new Map();
405 return map; 415 return map;
406 } 416 }
407 } 417 }
408 418
409 419
420
421
410 class _NativeViewportHideParams extends bindings.Struct { 422 class _NativeViewportHideParams extends bindings.Struct {
411 static const List<bindings.StructDataHeader> kVersions = const [ 423 static const List<bindings.StructDataHeader> kVersions = const [
412 const bindings.StructDataHeader(8, 0) 424 const bindings.StructDataHeader(8, 0)
413 ]; 425 ];
414 426
415 _NativeViewportHideParams() : super(kVersions.last.size); 427 _NativeViewportHideParams() : super(kVersions.last.size);
416 428
417 static _NativeViewportHideParams deserialize(bindings.Message message) { 429 static _NativeViewportHideParams deserialize(bindings.Message message) {
418 var decoder = new bindings.Decoder(message); 430 var decoder = new bindings.Decoder(message);
419 var result = decode(decoder); 431 var result = decode(decoder);
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after
458 return "_NativeViewportHideParams("")"; 470 return "_NativeViewportHideParams("")";
459 } 471 }
460 472
461 Map toJson() { 473 Map toJson() {
462 Map map = new Map(); 474 Map map = new Map();
463 return map; 475 return map;
464 } 476 }
465 } 477 }
466 478
467 479
480
481
468 class _NativeViewportCloseParams extends bindings.Struct { 482 class _NativeViewportCloseParams extends bindings.Struct {
469 static const List<bindings.StructDataHeader> kVersions = const [ 483 static const List<bindings.StructDataHeader> kVersions = const [
470 const bindings.StructDataHeader(8, 0) 484 const bindings.StructDataHeader(8, 0)
471 ]; 485 ];
472 486
473 _NativeViewportCloseParams() : super(kVersions.last.size); 487 _NativeViewportCloseParams() : super(kVersions.last.size);
474 488
475 static _NativeViewportCloseParams deserialize(bindings.Message message) { 489 static _NativeViewportCloseParams deserialize(bindings.Message message) {
476 var decoder = new bindings.Decoder(message); 490 var decoder = new bindings.Decoder(message);
477 var result = decode(decoder); 491 var result = decode(decoder);
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after
516 return "_NativeViewportCloseParams("")"; 530 return "_NativeViewportCloseParams("")";
517 } 531 }
518 532
519 Map toJson() { 533 Map toJson() {
520 Map map = new Map(); 534 Map map = new Map();
521 return map; 535 return map;
522 } 536 }
523 } 537 }
524 538
525 539
540
541
526 class _NativeViewportSetSizeParams extends bindings.Struct { 542 class _NativeViewportSetSizeParams extends bindings.Struct {
527 static const List<bindings.StructDataHeader> kVersions = const [ 543 static const List<bindings.StructDataHeader> kVersions = const [
528 const bindings.StructDataHeader(16, 0) 544 const bindings.StructDataHeader(16, 0)
529 ]; 545 ];
530 geometry_mojom.Size size = null; 546 geometry_mojom.Size size = null;
531 547
532 _NativeViewportSetSizeParams() : super(kVersions.last.size); 548 _NativeViewportSetSizeParams() : super(kVersions.last.size);
533 549
534 static _NativeViewportSetSizeParams deserialize(bindings.Message message) { 550 static _NativeViewportSetSizeParams deserialize(bindings.Message message) {
535 var decoder = new bindings.Decoder(message); 551 var decoder = new bindings.Decoder(message);
(...skipping 48 matching lines...) Expand 10 before | Expand all | Expand 10 after
584 } 600 }
585 601
586 Map toJson() { 602 Map toJson() {
587 Map map = new Map(); 603 Map map = new Map();
588 map["size"] = size; 604 map["size"] = size;
589 return map; 605 return map;
590 } 606 }
591 } 607 }
592 608
593 609
610
611
594 class _NativeViewportSetEventDispatcherParams extends bindings.Struct { 612 class _NativeViewportSetEventDispatcherParams extends bindings.Struct {
595 static const List<bindings.StructDataHeader> kVersions = const [ 613 static const List<bindings.StructDataHeader> kVersions = const [
596 const bindings.StructDataHeader(16, 0) 614 const bindings.StructDataHeader(16, 0)
597 ]; 615 ];
598 Object dispatcher = null; 616 Object dispatcher = null;
599 617
600 _NativeViewportSetEventDispatcherParams() : super(kVersions.last.size); 618 _NativeViewportSetEventDispatcherParams() : super(kVersions.last.size);
601 619
602 static _NativeViewportSetEventDispatcherParams deserialize(bindings.Message me ssage) { 620 static _NativeViewportSetEventDispatcherParams deserialize(bindings.Message me ssage) {
603 var decoder = new bindings.Decoder(message); 621 var decoder = new bindings.Decoder(message);
(...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after
650 "dispatcher: $dispatcher" ")"; 668 "dispatcher: $dispatcher" ")";
651 } 669 }
652 670
653 Map toJson() { 671 Map toJson() {
654 throw new bindings.MojoCodecError( 672 throw new bindings.MojoCodecError(
655 'Object containing handles cannot be encoded to JSON.'); 673 'Object containing handles cannot be encoded to JSON.');
656 } 674 }
657 } 675 }
658 676
659 677
678
679
660 class _NativeViewportGetContextProviderParams extends bindings.Struct { 680 class _NativeViewportGetContextProviderParams extends bindings.Struct {
661 static const List<bindings.StructDataHeader> kVersions = const [ 681 static const List<bindings.StructDataHeader> kVersions = const [
662 const bindings.StructDataHeader(16, 0) 682 const bindings.StructDataHeader(16, 0)
663 ]; 683 ];
664 Object provider = null; 684 Object provider = null;
665 685
666 _NativeViewportGetContextProviderParams() : super(kVersions.last.size); 686 _NativeViewportGetContextProviderParams() : super(kVersions.last.size);
667 687
668 static _NativeViewportGetContextProviderParams deserialize(bindings.Message me ssage) { 688 static _NativeViewportGetContextProviderParams deserialize(bindings.Message me ssage) {
669 var decoder = new bindings.Decoder(message); 689 var decoder = new bindings.Decoder(message);
(...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after
716 "provider: $provider" ")"; 736 "provider: $provider" ")";
717 } 737 }
718 738
719 Map toJson() { 739 Map toJson() {
720 throw new bindings.MojoCodecError( 740 throw new bindings.MojoCodecError(
721 'Object containing handles cannot be encoded to JSON.'); 741 'Object containing handles cannot be encoded to JSON.');
722 } 742 }
723 } 743 }
724 744
725 745
746
747
726 class _NativeViewportRequestMetricsParams extends bindings.Struct { 748 class _NativeViewportRequestMetricsParams extends bindings.Struct {
727 static const List<bindings.StructDataHeader> kVersions = const [ 749 static const List<bindings.StructDataHeader> kVersions = const [
728 const bindings.StructDataHeader(8, 0) 750 const bindings.StructDataHeader(8, 0)
729 ]; 751 ];
730 752
731 _NativeViewportRequestMetricsParams() : super(kVersions.last.size); 753 _NativeViewportRequestMetricsParams() : super(kVersions.last.size);
732 754
733 static _NativeViewportRequestMetricsParams deserialize(bindings.Message messag e) { 755 static _NativeViewportRequestMetricsParams deserialize(bindings.Message messag e) {
734 var decoder = new bindings.Decoder(message); 756 var decoder = new bindings.Decoder(message);
735 var result = decode(decoder); 757 var result = decode(decoder);
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after
774 return "_NativeViewportRequestMetricsParams("")"; 796 return "_NativeViewportRequestMetricsParams("")";
775 } 797 }
776 798
777 Map toJson() { 799 Map toJson() {
778 Map map = new Map(); 800 Map map = new Map();
779 return map; 801 return map;
780 } 802 }
781 } 803 }
782 804
783 805
806
807
784 class NativeViewportRequestMetricsResponseParams extends bindings.Struct { 808 class NativeViewportRequestMetricsResponseParams extends bindings.Struct {
785 static const List<bindings.StructDataHeader> kVersions = const [ 809 static const List<bindings.StructDataHeader> kVersions = const [
786 const bindings.StructDataHeader(16, 0) 810 const bindings.StructDataHeader(16, 0)
787 ]; 811 ];
788 ViewportMetrics metrics = null; 812 ViewportMetrics metrics = null;
789 813
790 NativeViewportRequestMetricsResponseParams() : super(kVersions.last.size); 814 NativeViewportRequestMetricsResponseParams() : super(kVersions.last.size);
791 815
792 static NativeViewportRequestMetricsResponseParams deserialize(bindings.Message message) { 816 static NativeViewportRequestMetricsResponseParams deserialize(bindings.Message message) {
793 var decoder = new bindings.Decoder(message); 817 var decoder = new bindings.Decoder(message);
(...skipping 48 matching lines...) Expand 10 before | Expand all | Expand 10 after
842 } 866 }
843 867
844 Map toJson() { 868 Map toJson() {
845 Map map = new Map(); 869 Map map = new Map();
846 map["metrics"] = metrics; 870 map["metrics"] = metrics;
847 return map; 871 return map;
848 } 872 }
849 } 873 }
850 874
851 875
876
877
852 class _NativeViewportEventDispatcherOnEventParams extends bindings.Struct { 878 class _NativeViewportEventDispatcherOnEventParams extends bindings.Struct {
853 static const List<bindings.StructDataHeader> kVersions = const [ 879 static const List<bindings.StructDataHeader> kVersions = const [
854 const bindings.StructDataHeader(16, 0) 880 const bindings.StructDataHeader(16, 0)
855 ]; 881 ];
856 input_events_mojom.Event event = null; 882 input_events_mojom.Event event = null;
857 883
858 _NativeViewportEventDispatcherOnEventParams() : super(kVersions.last.size); 884 _NativeViewportEventDispatcherOnEventParams() : super(kVersions.last.size);
859 885
860 static _NativeViewportEventDispatcherOnEventParams deserialize(bindings.Messag e message) { 886 static _NativeViewportEventDispatcherOnEventParams deserialize(bindings.Messag e message) {
861 var decoder = new bindings.Decoder(message); 887 var decoder = new bindings.Decoder(message);
(...skipping 48 matching lines...) Expand 10 before | Expand all | Expand 10 after
910 } 936 }
911 937
912 Map toJson() { 938 Map toJson() {
913 Map map = new Map(); 939 Map map = new Map();
914 map["event"] = event; 940 map["event"] = event;
915 return map; 941 return map;
916 } 942 }
917 } 943 }
918 944
919 945
946
947
920 class NativeViewportEventDispatcherOnEventResponseParams extends bindings.Struct { 948 class NativeViewportEventDispatcherOnEventResponseParams extends bindings.Struct {
921 static const List<bindings.StructDataHeader> kVersions = const [ 949 static const List<bindings.StructDataHeader> kVersions = const [
922 const bindings.StructDataHeader(8, 0) 950 const bindings.StructDataHeader(8, 0)
923 ]; 951 ];
924 952
925 NativeViewportEventDispatcherOnEventResponseParams() : super(kVersions.last.si ze); 953 NativeViewportEventDispatcherOnEventResponseParams() : super(kVersions.last.si ze);
926 954
927 static NativeViewportEventDispatcherOnEventResponseParams deserialize(bindings .Message message) { 955 static NativeViewportEventDispatcherOnEventResponseParams deserialize(bindings .Message message) {
928 var decoder = new bindings.Decoder(message); 956 var decoder = new bindings.Decoder(message);
929 var result = decode(decoder); 957 var result = decode(decoder);
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after
967 String toString() { 995 String toString() {
968 return "NativeViewportEventDispatcherOnEventResponseParams("")"; 996 return "NativeViewportEventDispatcherOnEventResponseParams("")";
969 } 997 }
970 998
971 Map toJson() { 999 Map toJson() {
972 Map map = new Map(); 1000 Map map = new Map();
973 return map; 1001 return map;
974 } 1002 }
975 } 1003 }
976 1004
1005
1006
1007
977 const int _NativeViewport_createName = 0; 1008 const int _NativeViewport_createName = 0;
978 const int _NativeViewport_showName = 1; 1009 const int _NativeViewport_showName = 1;
979 const int _NativeViewport_hideName = 2; 1010 const int _NativeViewport_hideName = 2;
980 const int _NativeViewport_closeName = 3; 1011 const int _NativeViewport_closeName = 3;
981 const int _NativeViewport_setSizeName = 4; 1012 const int _NativeViewport_setSizeName = 4;
982 const int _NativeViewport_setEventDispatcherName = 5; 1013 const int _NativeViewport_setEventDispatcherName = 5;
983 const int _NativeViewport_getContextProviderName = 6; 1014 const int _NativeViewport_getContextProviderName = 6;
984 const int _NativeViewport_requestMetricsName = 7; 1015 const int _NativeViewport_requestMetricsName = 7;
985 1016
1017
1018
1019 class _NativeViewportServiceDescription implements service_describer.ServiceDesc ription {
1020 dynamic getTopLevelInterface([Function responseFactory]) => null;
1021
1022 dynamic getTypeDefinition(String typeKey, [Function responseFactory]) => null;
1023
1024 dynamic getAllTypeDefinitions([Function responseFactory]) => null;
1025 }
1026
986 abstract class NativeViewport { 1027 abstract class NativeViewport {
987 static const String serviceName = "mojo::NativeViewport"; 1028 static const String serviceName = "mojo::NativeViewport";
988 dynamic create(geometry_mojom.Size size,SurfaceConfiguration requestedConfigur ation,[Function responseFactory = null]); 1029 dynamic create(geometry_mojom.Size size,SurfaceConfiguration requestedConfigur ation,[Function responseFactory = null]);
989 void show(); 1030 void show();
990 void hide(); 1031 void hide();
991 void close(); 1032 void close();
992 void setSize(geometry_mojom.Size size); 1033 void setSize(geometry_mojom.Size size);
993 void setEventDispatcher(Object dispatcher); 1034 void setEventDispatcher(Object dispatcher);
994 void getContextProvider(Object provider); 1035 void getContextProvider(Object provider);
995 dynamic requestMetrics([Function responseFactory = null]); 1036 dynamic requestMetrics([Function responseFactory = null]);
996 } 1037 }
997 1038
998 1039
999 class _NativeViewportProxyImpl extends bindings.Proxy { 1040 class _NativeViewportProxyImpl extends bindings.Proxy {
1000 _NativeViewportProxyImpl.fromEndpoint( 1041 _NativeViewportProxyImpl.fromEndpoint(
1001 core.MojoMessagePipeEndpoint endpoint) : super.fromEndpoint(endpoint); 1042 core.MojoMessagePipeEndpoint endpoint) : super.fromEndpoint(endpoint);
1002 1043
1003 _NativeViewportProxyImpl.fromHandle(core.MojoHandle handle) : 1044 _NativeViewportProxyImpl.fromHandle(core.MojoHandle handle) :
1004 super.fromHandle(handle); 1045 super.fromHandle(handle);
1005 1046
1006 _NativeViewportProxyImpl.unbound() : super.unbound(); 1047 _NativeViewportProxyImpl.unbound() : super.unbound();
1007 1048
1008 static _NativeViewportProxyImpl newFromEndpoint( 1049 static _NativeViewportProxyImpl newFromEndpoint(
1009 core.MojoMessagePipeEndpoint endpoint) { 1050 core.MojoMessagePipeEndpoint endpoint) {
1010 assert(endpoint.setDescription("For _NativeViewportProxyImpl")); 1051 assert(endpoint.setDescription("For _NativeViewportProxyImpl"));
1011 return new _NativeViewportProxyImpl.fromEndpoint(endpoint); 1052 return new _NativeViewportProxyImpl.fromEndpoint(endpoint);
1012 } 1053 }
1013 1054
1055 service_describer.ServiceDescription get serviceDescription =>
1056 new _NativeViewportServiceDescription();
1057
1014 void handleResponse(bindings.ServiceMessage message) { 1058 void handleResponse(bindings.ServiceMessage message) {
1015 switch (message.header.type) { 1059 switch (message.header.type) {
1016 case _NativeViewport_createName: 1060 case _NativeViewport_createName:
1017 var r = NativeViewportCreateResponseParams.deserialize( 1061 var r = NativeViewportCreateResponseParams.deserialize(
1018 message.payload); 1062 message.payload);
1019 if (!message.header.hasRequestId) { 1063 if (!message.header.hasRequestId) {
1020 proxyError("Expected a message with a valid request Id."); 1064 proxyError("Expected a message with a valid request Id.");
1021 return; 1065 return;
1022 } 1066 }
1023 Completer c = completerMap[message.header.requestId]; 1067 Completer c = completerMap[message.header.requestId];
(...skipping 302 matching lines...) Expand 10 before | Expand all | Expand 10 after
1326 assert(_impl == null); 1370 assert(_impl == null);
1327 _impl = d; 1371 _impl = d;
1328 } 1372 }
1329 1373
1330 String toString() { 1374 String toString() {
1331 var superString = super.toString(); 1375 var superString = super.toString();
1332 return "NativeViewportStub($superString)"; 1376 return "NativeViewportStub($superString)";
1333 } 1377 }
1334 1378
1335 int get version => 0; 1379 int get version => 0;
1380
1381 service_describer.ServiceDescription get serviceDescription =>
1382 new _NativeViewportServiceDescription();
1336 } 1383 }
1337 1384
1338 const int _NativeViewportEventDispatcher_onEventName = 0; 1385 const int _NativeViewportEventDispatcher_onEventName = 0;
1339 1386
1387
1388
1389 class _NativeViewportEventDispatcherServiceDescription implements service_descri ber.ServiceDescription {
1390 dynamic getTopLevelInterface([Function responseFactory]) => null;
1391
1392 dynamic getTypeDefinition(String typeKey, [Function responseFactory]) => null;
1393
1394 dynamic getAllTypeDefinitions([Function responseFactory]) => null;
1395 }
1396
1340 abstract class NativeViewportEventDispatcher { 1397 abstract class NativeViewportEventDispatcher {
1341 static const String serviceName = "mojo::NativeViewportEventDispatcher"; 1398 static const String serviceName = "mojo::NativeViewportEventDispatcher";
1342 dynamic onEvent(input_events_mojom.Event event,[Function responseFactory = nul l]); 1399 dynamic onEvent(input_events_mojom.Event event,[Function responseFactory = nul l]);
1343 } 1400 }
1344 1401
1345 1402
1346 class _NativeViewportEventDispatcherProxyImpl extends bindings.Proxy { 1403 class _NativeViewportEventDispatcherProxyImpl extends bindings.Proxy {
1347 _NativeViewportEventDispatcherProxyImpl.fromEndpoint( 1404 _NativeViewportEventDispatcherProxyImpl.fromEndpoint(
1348 core.MojoMessagePipeEndpoint endpoint) : super.fromEndpoint(endpoint); 1405 core.MojoMessagePipeEndpoint endpoint) : super.fromEndpoint(endpoint);
1349 1406
1350 _NativeViewportEventDispatcherProxyImpl.fromHandle(core.MojoHandle handle) : 1407 _NativeViewportEventDispatcherProxyImpl.fromHandle(core.MojoHandle handle) :
1351 super.fromHandle(handle); 1408 super.fromHandle(handle);
1352 1409
1353 _NativeViewportEventDispatcherProxyImpl.unbound() : super.unbound(); 1410 _NativeViewportEventDispatcherProxyImpl.unbound() : super.unbound();
1354 1411
1355 static _NativeViewportEventDispatcherProxyImpl newFromEndpoint( 1412 static _NativeViewportEventDispatcherProxyImpl newFromEndpoint(
1356 core.MojoMessagePipeEndpoint endpoint) { 1413 core.MojoMessagePipeEndpoint endpoint) {
1357 assert(endpoint.setDescription("For _NativeViewportEventDispatcherProxyImpl" )); 1414 assert(endpoint.setDescription("For _NativeViewportEventDispatcherProxyImpl" ));
1358 return new _NativeViewportEventDispatcherProxyImpl.fromEndpoint(endpoint); 1415 return new _NativeViewportEventDispatcherProxyImpl.fromEndpoint(endpoint);
1359 } 1416 }
1360 1417
1418 service_describer.ServiceDescription get serviceDescription =>
1419 new _NativeViewportEventDispatcherServiceDescription();
1420
1361 void handleResponse(bindings.ServiceMessage message) { 1421 void handleResponse(bindings.ServiceMessage message) {
1362 switch (message.header.type) { 1422 switch (message.header.type) {
1363 case _NativeViewportEventDispatcher_onEventName: 1423 case _NativeViewportEventDispatcher_onEventName:
1364 var r = NativeViewportEventDispatcherOnEventResponseParams.deserialize( 1424 var r = NativeViewportEventDispatcherOnEventResponseParams.deserialize(
1365 message.payload); 1425 message.payload);
1366 if (!message.header.hasRequestId) { 1426 if (!message.header.hasRequestId) {
1367 proxyError("Expected a message with a valid request Id."); 1427 proxyError("Expected a message with a valid request Id.");
1368 return; 1428 return;
1369 } 1429 }
1370 Completer c = completerMap[message.header.requestId]; 1430 Completer c = completerMap[message.header.requestId];
(...skipping 164 matching lines...) Expand 10 before | Expand all | Expand 10 after
1535 assert(_impl == null); 1595 assert(_impl == null);
1536 _impl = d; 1596 _impl = d;
1537 } 1597 }
1538 1598
1539 String toString() { 1599 String toString() {
1540 var superString = super.toString(); 1600 var superString = super.toString();
1541 return "NativeViewportEventDispatcherStub($superString)"; 1601 return "NativeViewportEventDispatcherStub($superString)";
1542 } 1602 }
1543 1603
1544 int get version => 0; 1604 int get version => 0;
1605
1606 service_describer.ServiceDescription get serviceDescription =>
1607 new _NativeViewportEventDispatcherServiceDescription();
1545 } 1608 }
1546 1609
1547 1610
1611
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698