You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cordova.apache.org by ia...@apache.org on 2013/12/13 17:18:00 UTC
[04/15] git commit: CB-5405: Use URL formatting for Entry.toURL
CB-5405: Use URL formatting for Entry.toURL
Project: http://git-wip-us.apache.org/repos/asf/cordova-plugin-file/repo
Commit: http://git-wip-us.apache.org/repos/asf/cordova-plugin-file/commit/abf2c05d
Tree: http://git-wip-us.apache.org/repos/asf/cordova-plugin-file/tree/abf2c05d
Diff: http://git-wip-us.apache.org/repos/asf/cordova-plugin-file/diff/abf2c05d
Branch: refs/heads/android-file
Commit: abf2c05dde49ed525ddff3165de88676d2783e73
Parents: 2685ae6
Author: Ian Clelland <ic...@chromium.org>
Authored: Sun Nov 24 22:43:59 2013 -0500
Committer: Ian Clelland <ic...@chromium.org>
Committed: Wed Dec 11 09:57:57 2013 -0500
----------------------------------------------------------------------
www/Entry.js | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/cordova-plugin-file/blob/abf2c05d/www/Entry.js
----------------------------------------------------------------------
diff --git a/www/Entry.js b/www/Entry.js
index bb4d753..223e2bc 100644
--- a/www/Entry.js
+++ b/www/Entry.js
@@ -169,8 +169,11 @@ Entry.prototype.copyTo = function(parent, newName, successCallback, errorCallbac
* Return a URL that can be used to identify this entry.
*/
Entry.prototype.toURL = function() {
+ if (this.filesystem && this.filesystem.__format__) {
+ return this.filesystem.__format__(this.fullPath);
+ }
// fullPath attribute contains the full URL
- return this.fullPath;
+ return "file://localhost" + this.fullPath;
};
/**