You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The image capture request should resolve successfully while another photo taking application is installed on the device.
What does actually happen?
The image capture request is considered as cancelled (Error code 3) while the user has successfully taken the photo.
Information
To reproduce, you need to have another photo taking application installed (Like Professional HD Camera for instance) so that Android is showing you an intent to chose the application to use.
You don't even need to use this other application, the problem occurs whether you use the default camera app or not.
The problem occurs on Android 8, 9 and 10.
It does not occur on Android 11, 12 and 13.
I don't know for versions prior to 8.
This is a duplicate of #139, but as it's tagged as Invalid, I'm recreating the issue here with more information.
The resultCode received by the activity result is indeed Activity.RESULT_CANCELED, but the file at the imageUri location contains well the photo taken.
I also noticed that the intent is null, which is not the case when you only have one photo taking app installed. We can descrimine on that to handle this case. The intent is always null when it has been cancelled.
bmarsaud
added a commit
to bmarsaud/cordova-plugin-media-capture
that referenced
this issue
Apr 15, 2024
Bug Report
Problem
What is expected to happen?
The image capture request should resolve successfully while another photo taking application is installed on the device.
What does actually happen?
The image capture request is considered as cancelled (Error code 3) while the user has successfully taken the photo.
Information
To reproduce, you need to have another photo taking application installed (Like Professional HD Camera for instance) so that Android is showing you an intent to chose the application to use.
You don't even need to use this other application, the problem occurs whether you use the default camera app or not.
The problem occurs on Android 8, 9 and 10.
It does not occur on Android 11, 12 and 13.
I don't know for versions prior to 8.
This is a duplicate of #139, but as it's tagged as Invalid, I'm recreating the issue here with more information.
Command or Code
Nothing special here, a simple :
will do.
Environment, Platform, Device
Devices : Android SDK Emulator and various physical devices on Android 8, 9, 10
Dev env OS : Ubuntu 22.04 LTS
Version information
Cordova : 12.0.0
Cordova Platforms : Android 12.0.1, iOS 6.3.0
Checklist
The text was updated successfully, but these errors were encountered: