123456789101112131415161718192021222324252627282930313233343536373839404142434445464748 |
-
-
- FILESYSTEM_PROTOCOL = 'cdvfile';
-
- module.exports = {
- __format__: function (fullPath, nativeUrl) {
- var path;
- var contentUrlMatch = /^content:\/\//.exec(nativeUrl);
- if (contentUrlMatch) {
-
-
-
-
- path = nativeUrl.substring(contentUrlMatch[0].length - 1);
- } else {
- path = FileSystem.encodeURIPath(fullPath);
- if (!/^\//.test(path)) {
- path = '/' + path;
- }
-
- var m = /\?.*/.exec(nativeUrl);
- if (m) {
- path += m[0];
- }
- }
-
- return FILESYSTEM_PROTOCOL + '://localhost/' + this.name + path;
- }
- };
|