You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cordova.apache.org by ag...@apache.org on 2013/07/30 20:58:11 UTC
[04/13] js commit: [win8] Move commandProxy.js into windows8/
[win8] Move commandProxy.js into windows8/
Doesn't look to be used by any other platform.
Project: http://git-wip-us.apache.org/repos/asf/cordova-js/repo
Commit: http://git-wip-us.apache.org/repos/asf/cordova-js/commit/c7839aed
Tree: http://git-wip-us.apache.org/repos/asf/cordova-js/tree/c7839aed
Diff: http://git-wip-us.apache.org/repos/asf/cordova-js/diff/c7839aed
Branch: refs/heads/master
Commit: c7839aed7ac9201bdfb8add89668cb6b8217958d
Parents: 0ec3a5f
Author: Andrew Grieve <ag...@chromium.org>
Authored: Tue Jul 30 10:20:25 2013 -0400
Committer: Andrew Grieve <ag...@chromium.org>
Committed: Tue Jul 30 10:20:25 2013 -0400
----------------------------------------------------------------------
lib/common/commandProxy.js | 46 ------------------------------
lib/windows8/exec.js | 2 +-
lib/windows8/platform.js | 2 +-
lib/windows8/windows8/commandProxy.js | 46 ++++++++++++++++++++++++++++++
4 files changed, 48 insertions(+), 48 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/cordova-js/blob/c7839aed/lib/common/commandProxy.js
----------------------------------------------------------------------
diff --git a/lib/common/commandProxy.js b/lib/common/commandProxy.js
deleted file mode 100644
index e640003..0000000
--- a/lib/common/commandProxy.js
+++ /dev/null
@@ -1,46 +0,0 @@
-/*
- *
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- *
-*/
-
-
-// internal map of proxy function
-var CommandProxyMap = {};
-
-module.exports = {
-
- // example: cordova.commandProxy.add("Accelerometer",{getCurrentAcceleration: function(successCallback, errorCallback, options) {...},...);
- add:function(id,proxyObj) {
- console.log("adding proxy for " + id);
- CommandProxyMap[id] = proxyObj;
- return proxyObj;
- },
-
- // cordova.commandProxy.remove("Accelerometer");
- remove:function(id) {
- var proxy = CommandProxyMap[id];
- delete CommandProxyMap[id];
- CommandProxyMap[id] = null;
- return proxy;
- },
-
- get:function(service,action) {
- return ( CommandProxyMap[service] ? CommandProxyMap[service][action] : null );
- }
-};
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/cordova-js/blob/c7839aed/lib/windows8/exec.js
----------------------------------------------------------------------
diff --git a/lib/windows8/exec.js b/lib/windows8/exec.js
index 46343bd..4583594 100644
--- a/lib/windows8/exec.js
+++ b/lib/windows8/exec.js
@@ -20,7 +20,7 @@
*/
var cordova = require('cordova');
-var commandProxy = require('cordova/commandProxy');
+var commandProxy = require('cordova/windows8/commandProxy');
/**
* Execute a cordova command. It is up to the native side whether this action
http://git-wip-us.apache.org/repos/asf/cordova-js/blob/c7839aed/lib/windows8/platform.js
----------------------------------------------------------------------
diff --git a/lib/windows8/platform.js b/lib/windows8/platform.js
index 2e3618e..7e3766f 100755
--- a/lib/windows8/platform.js
+++ b/lib/windows8/platform.js
@@ -36,7 +36,7 @@ module.exports = {
modulemapper.loadMatchingModules(/cordova.*\/plugininit$/);
modulemapper.loadMatchingModules(/cordova.*\/symbols$/);
- modulemapper.clobbers('cordova/commandProxy', 'cordova.commandProxy');
+ modulemapper.clobbers('cordova/windows8/commandProxy', 'cordova.commandProxy');
modulemapper.mapModules(window);
http://git-wip-us.apache.org/repos/asf/cordova-js/blob/c7839aed/lib/windows8/windows8/commandProxy.js
----------------------------------------------------------------------
diff --git a/lib/windows8/windows8/commandProxy.js b/lib/windows8/windows8/commandProxy.js
new file mode 100644
index 0000000..e640003
--- /dev/null
+++ b/lib/windows8/windows8/commandProxy.js
@@ -0,0 +1,46 @@
+/*
+ *
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ *
+*/
+
+
+// internal map of proxy function
+var CommandProxyMap = {};
+
+module.exports = {
+
+ // example: cordova.commandProxy.add("Accelerometer",{getCurrentAcceleration: function(successCallback, errorCallback, options) {...},...);
+ add:function(id,proxyObj) {
+ console.log("adding proxy for " + id);
+ CommandProxyMap[id] = proxyObj;
+ return proxyObj;
+ },
+
+ // cordova.commandProxy.remove("Accelerometer");
+ remove:function(id) {
+ var proxy = CommandProxyMap[id];
+ delete CommandProxyMap[id];
+ CommandProxyMap[id] = null;
+ return proxy;
+ },
+
+ get:function(service,action) {
+ return ( CommandProxyMap[service] ? CommandProxyMap[service][action] : null );
+ }
+};
\ No newline at end of file