cordova-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bows...@apache.org
Subject [1/3] android commit: CB-3496: Fixed streaming audio, this is pretty important for mobile spec
Date Fri, 24 May 2013 18:31:36 GMT
Updated Branches:
  refs/heads/2.8.x f5232f4c2 -> 6b5535e91


CB-3496: Fixed streaming audio, this is pretty important for mobile spec


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

Branch: refs/heads/2.8.x
Commit: aa81966e0bf1460c6e40b9f5cc7290247cc84786
Parents: 38b769a
Author: Joe Bowser <bowserj@apache.org>
Authored: Fri May 24 11:29:28 2013 -0700
Committer: Joe Bowser <bowserj@apache.org>
Committed: Fri May 24 11:30:35 2013 -0700

----------------------------------------------------------------------
 framework/src/org/apache/cordova/AudioHandler.java |    5 ++++-
 1 files changed, 4 insertions(+), 1 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cordova-android/blob/aa81966e/framework/src/org/apache/cordova/AudioHandler.java
----------------------------------------------------------------------
diff --git a/framework/src/org/apache/cordova/AudioHandler.java b/framework/src/org/apache/cordova/AudioHandler.java
index 20c3c4e..ef20306 100644
--- a/framework/src/org/apache/cordova/AudioHandler.java
+++ b/framework/src/org/apache/cordova/AudioHandler.java
@@ -58,7 +58,10 @@ public class AudioHandler extends CordovaPlugin {
 
     public String getFilePath(String url, String source){
         DataResource dataResource = DataResource.initiateNewDataRequestForUri(url, this.webView.pluginManager,
cordova, source);
-        return dataResource.getRealFile().getPath();
+        if(dataResource.getUri().getScheme().equals("http") || dataResource.getUri().getScheme().equals("https"))
+            return dataResource.getUri().toString();
+        else
+            return dataResource.getRealFile().getPath();
     }
 
     /**


Mime
View raw message