Cordova Camera and Barcode scanner plugins not working



  • I have a quasar application, fresh from:

    quasar init
    

    and

    quasar dev -m cordova -T android
    

    I have installed the cordova camera plugin and (a variety of the) barcode scanning plugins that are available.

    In both cases nothing displays. In the case of the barcode scanning plugin, on the second click of my button to call the plugin action it provides an error message that states that Scan is already in progress.

    I can verify that the javascript components have been compiled in as navigator.camera etc exists as it should.

    I don’t know how to verify that the Java classes have been compiled in - can anybody tell me if that is possible?

    Using Chrome’s remote inspector, I have traced the call to an exec() method and (what might be a red herring) I see the following in the device log:

    D/CordovaBridge Ignoring exec() from previous page load
    

    I can’t find anything like this on the Internet which describes this issue for cordova or phonegap and so i thought I would start at the Quasar end first.

    Any pointers or help diagnosing would be gratefully received.

    With thanks

    Rob



  • I’ve done the following to create a standalone cordova test case …

    cordova create camtest
    cordova platform add android
    

    added

    navigator.camera.getPicture(...)
    

    within the deviceready event handler

    … and this test case without quasar works as expected.

    I wonder how quasar might be upsetting this particular functionality.



  • I think this may be down to the Android version, but is still quasar specific.

    The quasar app fails on Android 4.4 but works in 5.1 as expected.

    The basic cordova equivalent works on Android 4.4 as well.



  • This is in fact still a problem.

    I cannot get a quasar app to show camera capture plugins (Camera and Barcode Scanner etc) in Android 5.1 in Genymotion.

    I can use the Camera plugin in a basic cordova app, but in Quasar nothing happens.