| Index: sdk/lib/_internal/compiler/js_lib/preambles/jsshell.js
|
| diff --git a/sdk/lib/_internal/compiler/js_lib/preambles/jsshell.js b/sdk/lib/_internal/compiler/js_lib/preambles/jsshell.js
|
| index 8f13bcc8f28fefa1adcad3488d1746cf590c35c1..e80401969c537aedb0e7fa34278aa3e9d0fa65d8 100644
|
| --- a/sdk/lib/_internal/compiler/js_lib/preambles/jsshell.js
|
| +++ b/sdk/lib/_internal/compiler/js_lib/preambles/jsshell.js
|
| @@ -1,4 +1,4 @@
|
| -// Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file
|
| +// Copyright (c) 2015, 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.
|
|
|
| @@ -11,9 +11,28 @@
|
| // Location (Uri.base)
|
|
|
| var workingDirectory = environment["PWD"];
|
| - self.location = { href: "file://" + workingDirectory + "/" };
|
|
|
| // Global properties. "self" refers to the global object, so adding a
|
| // property to "self" defines a global variable.
|
| self.self = self;
|
| +
|
| + self.location = { href: "file://" + workingDirectory + "/" };
|
| +
|
| + // Support for deferred loading.
|
| + self.dartDeferredLibraryLoader = function(uri, successCallback, errorCallback) {
|
| + try {
|
| + load(uri);
|
| + successCallback();
|
| + } catch (error) {
|
| + errorCallback(error);
|
| + }
|
| + };
|
| })(this)
|
| +
|
| +var getKeys = function(obj){
|
| + var keys = [];
|
| + for(var key in obj){
|
| + keys.push(key);
|
| + }
|
| + return keys;
|
| +}
|
|
|