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

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

Issue 406143004: Bugfix in html_dart2js: Detect window objects in a way compatible with cross domain iframes (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge
Patch Set: Use 'postMessage', change tools/dom/src/dart2js_Conversions.dart Created 6 years, 5 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 | dart/tests/html/cross_domain_iframe_script.html » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: dart/sdk/lib/html/dart2js/html_dart2js.dart
diff --git a/dart/sdk/lib/html/dart2js/html_dart2js.dart b/dart/sdk/lib/html/dart2js/html_dart2js.dart
index 7a2e9050709f9a44b31f75fa7ede832280a597d0..d65d60e8904eca3ac442c4777f3289ba812a5011 100644
--- a/dart/sdk/lib/html/dart2js/html_dart2js.dart
+++ b/dart/sdk/lib/html/dart2js/html_dart2js.dart
@@ -35436,10 +35436,10 @@ EventTarget _convertNativeToDart_EventTarget(e) {
if (e == null) {
return null;
}
- // Assume it's a Window if it contains the setInterval property. It may be
+ // Assume it's a Window if it contains the postMessage property. It may be
// from a different frame - without a patched prototype - so we cannot
// rely on Dart type checking.
- if (JS('bool', r'"setInterval" in #', e)) {
+ if (JS('bool', r'"postMessage" in #', e)) {
var window = _DOMWindowCrossFrame._createSafe(e);
// If it's a native window.
if (window is EventTarget) {
« no previous file with comments | « no previous file | dart/tests/html/cross_domain_iframe_script.html » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698