| Index: sky/engine/bindings-dart/core/dart/custom/DartFileReaderCustom.cpp
|
| diff --git a/LICENSE b/sky/engine/bindings-dart/core/dart/custom/DartFileReaderCustom.cpp
|
| similarity index 72%
|
| copy from LICENSE
|
| copy to sky/engine/bindings-dart/core/dart/custom/DartFileReaderCustom.cpp
|
| index 972bb2edb099e58b6a1939fa57f8e74391159c0c..2c42d6dd9d92ea5e7dd1685c4a215dee41c9cc0b 100644
|
| --- a/LICENSE
|
| +++ b/sky/engine/bindings-dart/core/dart/custom/DartFileReaderCustom.cpp
|
| @@ -1,4 +1,5 @@
|
| -// Copyright 2014 The Chromium Authors. All rights reserved.
|
| +// Copyright 2012, Google Inc.
|
| +// All rights reserved.
|
| //
|
| // Redistribution and use in source and binary forms, with or without
|
| // modification, are permitted provided that the following conditions are
|
| @@ -25,3 +26,24 @@
|
| // THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
|
| // (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
| // OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
| +
|
| +#include "config.h"
|
| +
|
| +#include "bindings/core/dart/DartFileReader.h"
|
| +
|
| +namespace blink {
|
| +
|
| +namespace DartFileReaderInternal {
|
| +
|
| +void resultGetter(Dart_NativeArguments args)
|
| +{
|
| + FileReader* receiver = DartDOMWrapper::receiver<FileReader>(args);
|
| + if (receiver->readType() == FileReaderLoader::ReadAsArrayBuffer)
|
| + Dart_SetReturnValue(args, DartUtilities::arrayBufferToDart(receiver->arrayBufferResult()));
|
| + else
|
| + Dart_SetReturnValue(args, DartUtilities::stringToDart(receiver->stringResult()));
|
| +}
|
| +
|
| +}
|
| +
|
| +}
|
|
|