aboutsummaryrefslogtreecommitdiff
path: root/src/runtime.js
diff options
context:
space:
mode:
authorAlon Zakai <alonzakai@gmail.com>2012-05-05 10:10:39 -0700
committerAlon Zakai <alonzakai@gmail.com>2012-05-05 10:10:39 -0700
commit11f749648a1246af4be025e94d17bea6e6e62b2c (patch)
tree92aa37637e3e2148ba9b51154aead9dfa403d6f0 /src/runtime.js
parentbfc041b6b56837ae1a4365fc2f7827dd35727f65 (diff)
rename Browser.getAsyncCall to Runtime.getFuncWrapper
Diffstat (limited to 'src/runtime.js')
-rw-r--r--src/runtime.js11
1 files changed, 11 insertions, 0 deletions
diff --git a/src/runtime.js b/src/runtime.js
index 51fbbdb3..6a251c46 100644
--- a/src/runtime.js
+++ b/src/runtime.js
@@ -323,6 +323,17 @@ var Runtime = {
}
},
+ funcWrappers: {},
+
+ getFuncWrapper: function(func) {
+ if (!Runtime.funcWrappers[func]) {
+ Runtime.funcWrappers[func] = function() {
+ FUNCTION_TABLE[func].apply(null, arguments);
+ };
+ }
+ return Runtime.funcWrappers[func];
+ },
+
#if RUNTIME_DEBUG
debug: true, // Switch to false at runtime to disable logging at the right times