You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ripple.apache.org by ti...@apache.org on 2015/10/19 20:34:54 UTC

incubator-ripple git commit: ScanditSDK: Do not start the scanner twice.

Repository: incubator-ripple
Updated Branches:
  refs/heads/master e2c2f848e -> 6d8bfcff7


ScanditSDK: Do not start the scanner twice.

The scanner should never start twice even if from the application requested.


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

Branch: refs/heads/master
Commit: 6d8bfcff78a483fa4e4caa2aaa6f3263440d397d
Parents: e2c2f84
Author: Leo von Klenze <de...@leo-von-klenze.de>
Authored: Sat Aug 8 19:01:48 2015 +0200
Committer: Tim Barham <ti...@microsoft.com>
Committed: Mon Oct 19 11:34:40 2015 -0700

----------------------------------------------------------------------
 lib/client/platform/cordova/3.0.0/bridge/scanditsdk.js | 2 ++
 1 file changed, 2 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-ripple/blob/6d8bfcff/lib/client/platform/cordova/3.0.0/bridge/scanditsdk.js
----------------------------------------------------------------------
diff --git a/lib/client/platform/cordova/3.0.0/bridge/scanditsdk.js b/lib/client/platform/cordova/3.0.0/bridge/scanditsdk.js
index 9f47cb1..9c72cc1 100644
--- a/lib/client/platform/cordova/3.0.0/bridge/scanditsdk.js
+++ b/lib/client/platform/cordova/3.0.0/bridge/scanditsdk.js
@@ -30,6 +30,8 @@ module.exports = {
 
         if( !args.length || typeof args[0] != "string" ) throw new Error('Application key is required');
 
+        if( $('#dialog-requestbarcode').length > 0 ) return; // scan was already called and is not finished yet
+
         var barcode         = db.retrieve('lastBarcode', 'scanditsdk'),
             barcodeType,
             dialogContainer = $( dialogTmpl ).attr({