You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ripple.apache.org by br...@apache.org on 2014/11/16 20:26:50 UTC

[1/4] incubator-ripple git commit: FIX added missing cordova 3.0 action File.requestAllPaths

Repository: incubator-ripple
Updated Branches:
  refs/heads/master cd50e4932 -> fbde6415b


FIX added missing cordova 3.0 action File.requestAllPaths


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

Branch: refs/heads/master
Commit: dc87bdf1a76e1081df46891e68fd87014ea8a94c
Parents: 2e208dc
Author: simon <si...@gmx.de>
Authored: Mon Jun 23 14:31:39 2014 +0200
Committer: simon <si...@gmx.de>
Committed: Mon Jun 23 14:31:39 2014 +0200

----------------------------------------------------------------------
 lib/client/platform/cordova/2.0.0/bridge/file.js | 19 +++++++++++++++++++
 1 file changed, 19 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-ripple/blob/dc87bdf1/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 0571419..41a6e12 100644
--- a/lib/client/platform/cordova/2.0.0/bridge/file.js
+++ b/lib/client/platform/cordova/2.0.0/bridge/file.js
@@ -49,6 +49,25 @@ module.exports = {
             }, fail);
         }
     },
+
+    requestAllPaths: function(win, fail, args) {
+
+        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());
+//
+//        }
+        win(ret);
+    },
+
     resolveLocalFileSystemURI: function (win, fail, args) {
         var uri = args[0],
             fulluri = fs.root.toURL();


[3/4] incubator-ripple git commit: FEATURE added dummy nfc module

Posted by br...@apache.org.
FEATURE added dummy nfc module


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

Branch: refs/heads/master
Commit: 5e4d7b7d069f6928ac9854ed7ef0f8af86cbc22b
Parents: e006296
Author: simon <si...@gmx.de>
Authored: Mon Jun 23 15:10:01 2014 +0200
Committer: simon <si...@gmx.de>
Committed: Mon Jun 23 15:10:01 2014 +0200

----------------------------------------------------------------------
 .../platform/cordova/3.0.0/bridge/nfcdummy.js   | 28 ++++++++++++++++++++
 lib/client/platform/cordova/3.0.0/spec.js       |  2 ++
 2 files changed, 30 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-ripple/blob/5e4d7b7d/lib/client/platform/cordova/3.0.0/bridge/nfcdummy.js
----------------------------------------------------------------------
diff --git a/lib/client/platform/cordova/3.0.0/bridge/nfcdummy.js b/lib/client/platform/cordova/3.0.0/bridge/nfcdummy.js
new file mode 100644
index 0000000..24558c3
--- /dev/null
+++ b/lib/client/platform/cordova/3.0.0/bridge/nfcdummy.js
@@ -0,0 +1,28 @@
+/*
+ *
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ *
+ */
+
+
+module.exports = {
+
+    init: function (win, fail, args) {
+        fail("nfc is not supported on ripple");
+    }
+};

http://git-wip-us.apache.org/repos/asf/incubator-ripple/blob/5e4d7b7d/lib/client/platform/cordova/3.0.0/spec.js
----------------------------------------------------------------------
diff --git a/lib/client/platform/cordova/3.0.0/spec.js b/lib/client/platform/cordova/3.0.0/spec.js
index f71c1a9..b89246f 100644
--- a/lib/client/platform/cordova/3.0.0/spec.js
+++ b/lib/client/platform/cordova/3.0.0/spec.js
@@ -57,6 +57,8 @@ module.exports = {
         // scandit barcode scanner @see https://github.com/Scandit/BarcodeScannerPlugin
         bridge.add("ScanditSDK", ripple('platform/cordova/3.0.0/bridge/scanditsdk'));
 
+        bridge.add("NfcPlugin", ripple('platform/cordova/3.0.0/bridge/nfcdummy'));
+
         honeypot.monitor(win, "cordova").andRun(get, set);
 
         //HACK: BlackBerry does vibration different


[4/4] incubator-ripple git commit: Merge PR: https://github.com/apache/incubator-ripple/pull/31

Posted by br...@apache.org.
Merge PR: https://github.com/apache/incubator-ripple/pull/31


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

Branch: refs/heads/master
Commit: fbde6415bb5d81651ceda953a684c3d7dd3a3bb5
Parents: cd50e49 5e4d7b7
Author: Brent Lintner <br...@gmail.com>
Authored: Sun Nov 16 14:22:38 2014 -0500
Committer: Brent Lintner <br...@gmail.com>
Committed: Sun Nov 16 14:22:38 2014 -0500

----------------------------------------------------------------------
 .../platform/cordova/2.0.0/bridge/file.js       | 27 +++++++++++++++++++
 .../platform/cordova/3.0.0/bridge/nfcdummy.js   | 28 ++++++++++++++++++++
 lib/client/platform/cordova/3.0.0/spec.js       |  2 ++
 3 files changed, 57 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-ripple/blob/fbde6415/lib/client/platform/cordova/3.0.0/spec.js
----------------------------------------------------------------------


[2/4] incubator-ripple git commit: FIX added missing cordova 3.0 action File.requestAllPaths (doc)

Posted by br...@apache.org.
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 <si...@gmx.de>
Authored: Mon Jun 23 14:34:06 2014 +0200
Committer: simon <si...@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);
     },