cordova-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From tim...@apache.org
Subject webworks commit: Updating javascript
Date Fri, 01 Feb 2013 21:45:16 GMT
Updated Branches:
  refs/heads/master f500bbac1 -> 5c3226f32


Updating javascript


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

Branch: refs/heads/master
Commit: 5c3226f32fc8806d058bd05117f3f6b685032186
Parents: f500bba
Author: Tim Kim <timk@adobe.com>
Authored: Fri Feb 1 13:45:08 2013 -0800
Committer: Tim Kim <timk@adobe.com>
Committed: Fri Feb 1 13:45:08 2013 -0800

----------------------------------------------------------------------
 javascript/cordova.blackberry.js |   27 ++++++++++++++++++---------
 1 files changed, 18 insertions(+), 9 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cordova-blackberry/blob/5c3226f3/javascript/cordova.blackberry.js
----------------------------------------------------------------------
diff --git a/javascript/cordova.blackberry.js b/javascript/cordova.blackberry.js
index d0d6073..1a8d943 100644
--- a/javascript/cordova.blackberry.js
+++ b/javascript/cordova.blackberry.js
@@ -1,6 +1,8 @@
-// commit 71223711fb1591b1255d871140d959fd9095f0c3
+// Platform: blackberry
 
-// File generated at :: Mon Jan 21 2013 16:21:41 GMT-0800 (PST)
+// commit d1b4a2002c48cd40aee55fc2ea6335fa5255b905
+
+// File generated at :: Fri Feb 01 2013 13:44:28 GMT-0800 (PST)
 
 /*
  Licensed to the Apache Software Foundation (ASF) under one
@@ -1418,6 +1420,7 @@ module.exports = {
         CELL_2G: "2g",
         CELL_3G: "3g",
         CELL_4G: "4g",
+        CELL:"cellular",
         NONE: "none"
 };
 
@@ -5345,7 +5348,7 @@ module.exports = {
                     model: "PlayBook",
                     name: "PlayBook", // deprecated: please use device.model
                     uuid: info.uuid,
-                    cordova: "2.4.0rc1"
+                    cordova: "2.4.0rc2"
                 });
             }),
             request = new blackberry.transport.RemoteFunctionCall("org/apache/cordova/getDeviceInfo");
@@ -5464,7 +5467,7 @@ define("cordova/plugin/air/platform", function(require, exports, module)
{
 
 module.exports = {
     id: "playbook",
-    initialize:function() {},
+    initialize:function() {}
 };
 
 });
@@ -9038,7 +9041,7 @@ module.exports = {
             model: "Dev Alpha",
             name: "Dev Alpha", // deprecated: please use device.model
             uuid: blackberry.identity.uuid,
-            cordova: "2.4.0rc1"
+            cordova: "2.4.0rc2"
         });
 
         return { "status" : cordova.callbackStatus.NO_RESULT, "message" : "Device info returned"
};
@@ -9788,8 +9791,13 @@ module.exports = {
 
         var id = args[0],
             src = args[1];
+        
+        if (typeof src == "undefined"){
+            audioObjects[id] = new Audio();
+        } else {
+            audioObjects[id] = new Audio(src);
+        }
 
-        audioObjects[id] = new Audio(src);
         return {"status" : 1, "message" : "Audio object created" };
     },
     startPlayingAudio: function (args, win, fail) {
@@ -9801,7 +9809,7 @@ module.exports = {
             audio = audioObjects[id],
             result;
 
-        if (args.length === 1) {
+        if (args.length === 1 || typeof args[1] == "undefined" ) {
             return {"status" : 9, "message" : "Media source argument not found"};
         }
 
@@ -9812,7 +9820,6 @@ module.exports = {
 
         audio = audioObjects[id] = new Audio(args[1]);
         audio.play();
-
         return {"status" : 1, "message" : "Audio play started" };
     },
     stopPlayingAudio: function (args, win, fail) {
@@ -9929,8 +9936,10 @@ module.exports = {
             result;
 
         if (audio) {
+            if(audio.src !== ""){
+                audio.src = undefined;
+            }
             audioObjects[id] = undefined;
-            audio.src = undefined;
             //delete audio;
         }
 


Mime
View raw message