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

Unified Diff: sdk/lib/html/dart2js/html_dart2js.dart

Issue 22263002: Adding API to remove send ports from Window. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 7 years, 4 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:
Download patch
« no previous file with comments | « no previous file | sdk/lib/html/dartium/html_dartium.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: sdk/lib/html/dart2js/html_dart2js.dart
diff --git a/sdk/lib/html/dart2js/html_dart2js.dart b/sdk/lib/html/dart2js/html_dart2js.dart
index 0cf52e56c103e954a9d1f4a5373eaf4cfa460e19..1570ab1f8bb87bf768118ad84d65d433e8e81074 100644
--- a/sdk/lib/html/dart2js/html_dart2js.dart
+++ b/sdk/lib/html/dart2js/html_dart2js.dart
@@ -23996,6 +23996,15 @@ class Window extends EventTarget implements WindowBase, WindowTimers native "Win
}
/**
+ * Deregister a [port] on this window under the given [name]. This
+ * port may be retrieved by any isolate (or JavaScript script)
+ * running in this window.
+ */
+ void deregisterPort(String name) {
+ document.documentElement.attributes.remove('dart-port:$name');
+ }
+
+ /**
* Returns a Future that completes just before the window is about to
* repaint so the user can draw an animation frame.
*
@@ -25004,9 +25013,9 @@ class Window extends EventTarget implements WindowBase, WindowTimers native "Win
$dom_moveTo(p.x, p.y);
}
- int get scrollX => JS('bool', '("scrollX" in #)', this) ? JS('int',
+ int get scrollX => JS('bool', '("scrollX" in #)', this) ? JS('int',
'#.scrollX', this) : document.documentElement.scrollLeft;
- int get scrollY => JS('bool', '("scrollY" in #)', this) ? JS('int',
+ int get scrollY => JS('bool', '("scrollY" in #)', this) ? JS('int',
'#.scrollY', this) : document.documentElement.scrollTop;
}
« no previous file with comments | « no previous file | sdk/lib/html/dartium/html_dartium.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698