blukis opened a new issue #696:
URL: https://github.com/apache/cordova-plugin-camera/issues/696


   # Bug Report
   
   ## Problem
   Per "android quirks" section of readme, camera may return imageData via 
cordova "resume" event, when Android closes main app while camera is open.  I'm 
triggering this scenario manually using Android settings > System > Developer 
Options > "Don't keep activities".  In cordova-plugin-camera 4.1.0 imageData is 
returned per docs via "resume" event.  In cordova-plugin-camera 5.0.1, app 
crashes just after taking a picture, and before/as app is restored.
   
   ### What is expected to happen?
   App should not crash when it restores, per scenario above.  (Works per 
documentation in version 4.1.0)
   
   
   ### What does actually happen?
   App crashes after taking a picture.
   
   ## Information
   - version 4.1.0 works per docs
   - App doesn't appear to launch again at all.  (e.g. crash happens, and an 
alert("x") on the first line of JS never fires.)
   
   ### Command or Code
   - Camera call I'm using:
   ```
        navigator.camera.getPicture(
                function (imageData) { alert("Camera callback, normal way."); },
                function (msg) { alert('Camera error: ' + msg); },  // Error CB
                { quality:95, sourceType:Camera.PictureSourceType.CAMERA, 
destinationType:Camera.DestinationType.FILE_URI, correctOrientation:true, 
allowEdit:false, targetWidth:2000, targetHeight:2000 }
        );
   ```
   - I'm triggering this "manually" using [Android settings > System > 
Developer Options > "Don't keep activities"].  That setting is important to 
triggering this issue.  Unless there's another way to reliably trigger the 
"android quirks" scenario.
   
   
   ### Environment, Platform, Device
   Voltbuilder // Android // Sony Xperia ZX2 Compact
   
   
   ### Version information
   Building with Voltbuilder.  I didn't specify a cordova version, so I assume 
they're using something recent. 
   
   
   ## Checklist
   - [x] I searched for existing GitHub issues
   - [x] I updated all Cordova tooling to most recent version
   - [x] I included all the necessary information above
   


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
[email protected]



---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to