cordova-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ste...@apache.org
Subject [08/38] js commit: [BlackBerry10] Update plugin path to support HTML pages outside of project root
Date Tue, 14 May 2013 21:12:47 GMT
[BlackBerry10] Update plugin path to support HTML pages outside of project root

Reviewed by: Danyi Lin <danylin@blackberry.com>


Project: http://git-wip-us.apache.org/repos/asf/cordova-js/repo
Commit: http://git-wip-us.apache.org/repos/asf/cordova-js/commit/ad806405
Tree: http://git-wip-us.apache.org/repos/asf/cordova-js/tree/ad806405
Diff: http://git-wip-us.apache.org/repos/asf/cordova-js/diff/ad806405

Branch: refs/heads/3.0.0
Commit: ad80640505f3749e9738e0d2c41accabf4faf1ed
Parents: e8f1e59
Author: Bryan Higgins <bhiggins@blackberry.com>
Authored: Fri Mar 22 16:31:52 2013 -0400
Committer: Bryan Higgins <bhiggins@blackberry.com>
Committed: Fri May 3 09:49:38 2013 -0400

----------------------------------------------------------------------
 .../plugin/blackberry10/pluginUtils.js             |    2 +-
 test/blackberry10/test.pluginUtils.js              |    2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cordova-js/blob/ad806405/lib/blackberry10/plugin/blackberry10/pluginUtils.js
----------------------------------------------------------------------
diff --git a/lib/blackberry10/plugin/blackberry10/pluginUtils.js b/lib/blackberry10/plugin/blackberry10/pluginUtils.js
index a07a665..8545c71 100644
--- a/lib/blackberry10/plugin/blackberry10/pluginUtils.js
+++ b/lib/blackberry10/plugin/blackberry10/pluginUtils.js
@@ -45,7 +45,7 @@ module.exports = {
             if (plugins.hasOwnProperty(plugin) && plugins[plugin].modules) {
                 for (i = 0; i < plugins[plugin].modules.length; i++) {
                     script = document.createElement('script');
-                    script.src = 'plugins/' + plugin + '/' + plugins[plugin].modules[i];
+                    script.src = 'local:///plugins/' + plugin + '/' + plugins[plugin].modules[i];
                     script.onload = function () {
                         if (--count === 0 && typeof callback === 'function') {
                             build(plugins);

http://git-wip-us.apache.org/repos/asf/cordova-js/blob/ad806405/test/blackberry10/test.pluginUtils.js
----------------------------------------------------------------------
diff --git a/test/blackberry10/test.pluginUtils.js b/test/blackberry10/test.pluginUtils.js
index 441ebcc..d298c43 100644
--- a/test/blackberry10/test.pluginUtils.js
+++ b/test/blackberry10/test.pluginUtils.js
@@ -52,7 +52,7 @@ describe('blackberry10 pluginUtils', function () {
             var plugins = { foo : { modules: ['bar.js'] } };
             pluginUtils.loadClientJs(plugins, callback);
             expect(document.createElement).toHaveBeenCalled();
-            expect(script.src).toEqual('plugins/foo/bar.js');
+            expect(script.src).toEqual('local:///plugins/foo/bar.js');
             expect(document.head.appendChild).toHaveBeenCalled();
             script.onload();
             expect(callback).toHaveBeenCalled();


Mime
View raw message