ripple-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From brentlint...@apache.org
Subject [2/4] incubator-ripple git commit: FIX added missing cordova 3.0 action File.requestAllPaths (doc)
Date Sun, 16 Nov 2014 19:26:51 GMT
FIX added missing cordova 3.0 action File.requestAllPaths (doc)


Project: http://git-wip-us.apache.org/repos/asf/incubator-ripple/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-ripple/commit/e0062961
Tree: http://git-wip-us.apache.org/repos/asf/incubator-ripple/tree/e0062961
Diff: http://git-wip-us.apache.org/repos/asf/incubator-ripple/diff/e0062961

Branch: refs/heads/master
Commit: e0062961e5a95d4fa6d2f91b9bb971c56106268a
Parents: dc87bdf
Author: simon <simon.thiel@gmx.de>
Authored: Mon Jun 23 14:34:06 2014 +0200
Committer: simon <simon.thiel@gmx.de>
Committed: Mon Jun 23 14:34:06 2014 +0200

----------------------------------------------------------------------
 .../platform/cordova/2.0.0/bridge/file.js       | 24 +++++++++++++-------
 1 file changed, 16 insertions(+), 8 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-ripple/blob/e0062961/lib/client/platform/cordova/2.0.0/bridge/file.js
----------------------------------------------------------------------
diff --git a/lib/client/platform/cordova/2.0.0/bridge/file.js b/lib/client/platform/cordova/2.0.0/bridge/file.js
index 41a6e12..cd49652 100644
--- a/lib/client/platform/cordova/2.0.0/bridge/file.js
+++ b/lib/client/platform/cordova/2.0.0/bridge/file.js
@@ -51,20 +51,28 @@ module.exports = {
     },
 
     requestAllPaths: function(win, fail, args) {
+        //inspired by https://github.com/apache/cordova-plugin-file/blob/master/src/android/FileUtils.java
+
+        //TODO FIXME
+        //provide valid directories - based on actual app context
 
         var ret = {};
         ret["applicationDirectory"] = "file:///android_asset/";
         ret["applicationStorageDirectory"] = "file://tmp/ripple/appstore";
         ret["dataDirectory"] = "file://tmp/ripple/data";
         ret["cacheDirectory"] = "file://tmp/";
-//        if (Environment.getExternalStorageState().equals(Environment.MEDIA_MOUNTED)) {
-//
-//            ret["externalApplicationStorageDirectory"] = toDirUrl(context.getExternalFilesDir(null).getParentFile());
-//            ret["externalDataDirectory"] = toDirUrl(context.getExternalFilesDir(null));
-//            ret["externalCacheDirectory"] = toDirUrl(context.getExternalCacheDir());
-//            ret["externalRootDirectory"] = toDirUrl(Environment.getExternalStorageDirectory());
-//
-//        }
+
+        //TODO FIXME
+        //add optional part based on context
+
+        //        if (Environment.getExternalStorageState().equals(Environment.MEDIA_MOUNTED))
{
+        //
+        //            ret["externalApplicationStorageDirectory"] = toDirUrl(context.getExternalFilesDir(null).getParentFile());
+        //            ret["externalDataDirectory"] = toDirUrl(context.getExternalFilesDir(null));
+        //            ret["externalCacheDirectory"] = toDirUrl(context.getExternalCacheDir());
+        //            ret["externalRootDirectory"] = toDirUrl(Environment.getExternalStorageDirectory());
+        //
+        //        }
         win(ret);
     },
 


Mime
View raw message