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

Unified Diff: tools/dom/templates/html/impl/impl_FileReader.darttemplate

Issue 180583002: Fix for FileReader.readAsArrayBuffer http://dartbug.com/17058 (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 6 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
« tests/html/filereader_test.dart ('K') | « tools/dom/scripts/systemhtml.py ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tools/dom/templates/html/impl/impl_FileReader.darttemplate
diff --git a/tools/dom/templates/html/impl/impl_Location.darttemplate b/tools/dom/templates/html/impl/impl_FileReader.darttemplate
similarity index 52%
copy from tools/dom/templates/html/impl/impl_Location.darttemplate
copy to tools/dom/templates/html/impl/impl_FileReader.darttemplate
index 5242f8a4288c262c770b67e11aa74ade9590a0d5..5895c2a7ec2e0cf35f2fd8bfe9b50893f02131a4 100644
--- a/tools/dom/templates/html/impl/impl_Location.darttemplate
+++ b/tools/dom/templates/html/impl/impl_FileReader.darttemplate
@@ -1,4 +1,4 @@
-// Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file
+// Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
@@ -6,15 +6,18 @@ part of $LIBRARYNAME;
@DocsEditable()
$(ANNOTATIONS)$(CLASS_MODIFIERS)class $CLASSNAME$EXTENDS$IMPLEMENTS$NATIVESPEC {
-$!MEMBERS
$if DART2JS
- @DomName('Location.origin')
- String get origin {
- if (JS('bool', '("origin" in #)', this)) {
- return JS('String', '#.origin', this);
+ @DomName('FileReader.result')
+ @DocsEditable()
+ Object get result {
+ var res = JS('Null|String|NativeByteBuffer', '#.result', this);
+ if (res is ByteBuffer) {
+ return new Uint8List.view(res);
}
- return '${this.protocol}//${this.host}';
+ return res;
}
$endif
+
+$!MEMBERS
}
« tests/html/filereader_test.dart ('K') | « tools/dom/scripts/systemhtml.py ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698