cordova-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From agri...@apache.org
Subject [3/4] ios commit: [CB-2276] Remove CDVViewController from CDVSound
Date Thu, 14 Feb 2013 16:07:00 GMT
[CB-2276] Remove CDVViewController from CDVSound


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

Branch: refs/heads/master
Commit: 53a839cfd9fc44c7c75a16c43c99260584e9ce92
Parents: 70af80b
Author: Andrew Grieve <agrieve@chromium.org>
Authored: Thu Feb 14 10:52:47 2013 -0500
Committer: Andrew Grieve <agrieve@chromium.org>
Committed: Thu Feb 14 11:06:21 2013 -0500

----------------------------------------------------------------------
 CordovaLib/Classes/CDVSound.m |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cordova-ios/blob/53a839cf/CordovaLib/Classes/CDVSound.m
----------------------------------------------------------------------
diff --git a/CordovaLib/Classes/CDVSound.m b/CordovaLib/Classes/CDVSound.m
index e6f729a..96812ca 100644
--- a/CordovaLib/Classes/CDVSound.m
+++ b/CordovaLib/Classes/CDVSound.m
@@ -18,7 +18,6 @@
  */
 
 #import "CDVSound.h"
-#import "CDVViewController.h"
 #import "NSArray+Comparisons.h"
 #import "CDVJSON.h"
 
@@ -44,7 +43,8 @@
         NSLog(@"Will use resource '%@' from the Internet.", resourcePath);
         resourceURL = [NSURL URLWithString:resourcePath];
     } else if ([resourcePath hasPrefix:DOCUMENTS_SCHEME_PREFIX]) {
-        filePath = [resourcePath stringByReplacingOccurrencesOfString:DOCUMENTS_SCHEME_PREFIX
withString:[NSString stringWithFormat:@"%@/", [CDVViewController applicationDocumentsDirectory]]];
+        NSString* docsPath = NSSearchPathForDirectoriesInDomains(NSDocumentDirectory, NSUserDomainMask,
YES)[0];
+        filePath = [resourcePath stringByReplacingOccurrencesOfString:DOCUMENTS_SCHEME_PREFIX
withString:[NSString stringWithFormat:@"%@/", docsPath]];
         NSLog(@"Will use resource '%@' from the documents folder with path = %@", resourcePath,
filePath);
     } else {
         // attempt to find file path in www directory


Mime
View raw message