Index: lib/html/src/dart2js_Conversions.dart |
diff --git a/lib/html/src/dart2js_Conversions.dart b/lib/html/src/dart2js_Conversions.dart |
index 5ce880697f8c52c2fc2d5615e10af7b9ac195fec..bc4f39d886ff83e5b0b3f6871917a4d8ef7cc26d 100644 |
--- a/lib/html/src/dart2js_Conversions.dart |
+++ b/lib/html/src/dart2js_Conversions.dart |
@@ -27,7 +27,7 @@ |
// window as a parameter. |
Window _convertNativeToDart_Window(win) { |
- return _DOMWindowCrossFrameImpl._createSafe(win); |
+ return _DOMWindowCrossFrame._createSafe(win); |
} |
EventTarget _convertNativeToDart_EventTarget(e) { |
@@ -35,13 +35,13 @@ EventTarget _convertNativeToDart_EventTarget(e) { |
// from a different frame - without a patched prototype - so we cannot |
// rely on Dart type checking. |
if (JS('bool', r'"setInterval" in #', e)) |
- return _DOMWindowCrossFrameImpl._createSafe(e); |
+ return _DOMWindowCrossFrame._createSafe(e); |
else |
return e; |
} |
EventTarget _convertDartToNative_EventTarget(e) { |
- if (e is _DOMWindowCrossFrameImpl) { |
+ if (e is _DOMWindowCrossFrame) { |
return e._window; |
} else { |
return e; |
@@ -75,7 +75,7 @@ ImageData _convertNativeToDart_ImageData(nativeImageData) { |
// We can get rid of this conversion if _TypedImageData implements the fields |
// with native names. |
_convertDartToNative_ImageData(ImageData imageData) { |
- if (imageData is _ImageDataImpl) return imageData; |
+ if (imageData is ImageData) return imageData; |
Anton Muhin
2012/11/02 12:55:47
this looks sketchy: you declare imageData to be of
blois
2012/11/02 19:25:28
Good catch.
sra1
2012/11/02 20:14:10
My bad. The function is passed a plain JS object o
blois
2012/11/02 20:30:15
That's the convertNativeToDart function. Anton is
|
return JS('Object', '{data: #, height: #, width: #}', |
imageData.data, imageData.height, imageData.width); |
} |
@@ -231,33 +231,15 @@ _convertDartToNative_PrepareForStructuredClone(value) { |
// TODO(sra): The JavaScript objects suitable for direct cloning by the |
// structured clone algorithm could be tagged with an private interface. |
- if (e is _FileImpl) return e; |
- if (e is File) { |
- throw const NotImplementedException('structured clone of File'); |
- } |
- |
- if (e is _BlobImpl) return e; |
- if (e is Blob) { |
- throw const NotImplementedException('structured clone of Blob'); |
- } |
- |
- if (e is _FileListImpl) return e; |
+ if (e is File) return e; |
+ if (e is Blob) return e; |
+ if (e is _FileList) return e; |
Anton Muhin
2012/11/02 12:55:47
what's this _FileList?
blois
2012/11/02 19:25:28
Some types specify that they should not have inter
|
// TODO(sra): Firefox: How to convert _TypedImageData on the other end? |
- if (e is _ImageDataImpl) return e; |
- if (e is ImageData) { |
- throw const NotImplementedException('structured clone of ImageData'); |
- } |
- |
- if (e is _ArrayBufferImpl) return e; |
- if (e is ArrayBuffer) { |
- throw const NotImplementedException('structured clone of ArrayBuffer'); |
- } |
+ if (e is ImageData) return e; |
+ if (e is ArrayBuffer) return e; |
- if (e is _ArrayBufferViewImpl) return e; |
- if (e is ArrayBufferView) { |
- throw const NotImplementedException('structured clone of ArrayBufferView'); |
- } |
+ if (e is ArrayBufferView) return e; |
if (e is Map) { |
var slot = findSlot(e); |