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

Unified Diff: client/html/generated/html/dartium/MessagePort.dart

Issue 9537001: Generate dart:html bindings for Dartium as well as Frog. All unittests now pass (or are disabled fo… (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 8 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 side-by-side diff with in-line comments
Download patch
Index: client/html/generated/html/dartium/MessagePort.dart
diff --git a/client/html/generated/html/dartium/MessagePort.dart b/client/html/generated/html/dartium/MessagePort.dart
new file mode 100644
index 0000000000000000000000000000000000000000..b5ee048ffe439472a9191afa1b1d8d308fb4287e
--- /dev/null
+++ b/client/html/generated/html/dartium/MessagePort.dart
@@ -0,0 +1,69 @@
+
+class _MessagePortImpl extends _EventTargetImpl implements MessagePort {
+ _MessagePortImpl._wrap(ptr) : super._wrap(ptr);
+
+ _MessagePortEventsImpl get on() {
+ if (_on == null) _on = new _MessagePortEventsImpl(this);
+ return _on;
+ }
+
+ void _addEventListener(String type, EventListener listener, [bool useCapture = null]) {
+ if (useCapture === null) {
+ _ptr.addEventListener(_unwrap(type), _unwrap(listener));
+ return;
+ } else {
+ _ptr.addEventListener(_unwrap(type), _unwrap(listener), _unwrap(useCapture));
+ return;
+ }
+ }
+
+ void close() {
+ _ptr.close();
+ return;
+ }
+
+ bool _dispatchEvent(Event evt) {
+ return _wrap(_ptr.dispatchEvent(_unwrap(evt)));
+ }
+
+ void postMessage(String message, [List messagePorts = null]) {
+ if (messagePorts === null) {
+ _ptr.postMessage(_unwrap(message));
+ return;
+ } else {
+ _ptr.postMessage(_unwrap(message), _unwrap(messagePorts));
+ return;
+ }
+ }
+
+ void _removeEventListener(String type, EventListener listener, [bool useCapture = null]) {
+ if (useCapture === null) {
+ _ptr.removeEventListener(_unwrap(type), _unwrap(listener));
+ return;
+ } else {
+ _ptr.removeEventListener(_unwrap(type), _unwrap(listener), _unwrap(useCapture));
+ return;
+ }
+ }
+
+ void start() {
+ _ptr.start();
+ return;
+ }
+
+ void webkitPostMessage(String message, [List transfer = null]) {
+ if (transfer === null) {
+ _ptr.webkitPostMessage(_unwrap(message));
+ return;
+ } else {
+ _ptr.webkitPostMessage(_unwrap(message), _unwrap(transfer));
+ return;
+ }
+ }
+}
+
+class _MessagePortEventsImpl extends _EventsImpl implements MessagePortEvents {
+ _MessagePortEventsImpl(_ptr) : super(_ptr);
+
+ EventListenerList get message() => _get('message');
+}

Powered by Google App Engine
This is Rietveld 408576698