@loet01 wrote:
I use $cordovaCapture for capturing images. The following code works perfect on iOS:
var options = {limit: 1}; $cordovaCapture.captureImage(options).then( function (imageData) { //store image data... }, function (err) { $log.log('error capturing image: ' + err); });
On iOS, I receive the imageData with file URI, which I can store and use for displaying the image.
But on android, instead of the camera, the gallery is opened. In order to activate the camera, I have then to cancel the gallery view. This opens the camera, but after taking the picture and quitting with 'ok', the promise is rejected (error function called).
Any idea, why it doesn't work on android?
Additional information: I've just found out, that the problem on android exists only, if the capturing is triggered from a button on a $ionicActionSheet. If triggered directly from the
<ion-content>
element, everything works fine on android as well.
Is this rather a $ionicActionSheet issue than a $cordovaCapture issue?
Posts: 4
Participants: 2