Camera - Android - Not respecting SaveGallery Flag when set to False
See original GitHub issueDescription of the problem: Using Capacitor camera plugin and adding saveToGallery: false, the picture it’s being saved anyway on the galery, only happening on Android. Affected platform
- [ x ] Android
- iOS
- electron
- web
OS of the development machine
- Windows
- [ x] macOS
- linux
Other information:
Here’s my function :
async takePicture(metadata) { const milliseconds = new Date().getTime(); const timestamp = (milliseconds.toString()).substring(9, 13); const image = await Plugins.Camera.getPhoto({ quality: 70, resultType: CameraResultType.Uri, saveToGallery: false, source: CameraSource.Camera }); }
Capacitor version: 1.1.1 node version: v10.16.0 npm version: 6.9.0 CocoaPods version: 1.7.5
Steps to reproduce:
- Take a picture using Android.
- Go to pictures gallery the image will be there.
Link to sample project:
Issue Analytics
- State:
- Created 4 years ago
- Comments:8 (2 by maintainers)
Top Results From Across the Web
Change app permissions on your Android phone
To change a permission setting, tap it, then choose Allow or Don't allow. For location, camera, and microphone permissions, you may be able...
Read more >Cordova camera saves to gallery even on false - Stack Overflow
I have verified the same, but it works as expected. I had set saveToGallery flag to true. If I cancel, image is not...
Read more >Behavior changes: all apps - Android Developers
On Android 12, camera apps that request a specific screen orientation and are not resizable ( resizeableActivity="false" ) automatically enter inset ...
Read more >photo_manager | Flutter Package - Pub.dev
A Flutter plugin that provides assets abstraction management APIs without UI integration, you can get assets (image/video/audio) on Android, iOS and macOS.
Read more >Accessing the Camera and Stored Media - CodePath Cliffnotes
In your AndroidManifest.xml, add the following queries block: <manifest ...> <queries> <!-- Camera --> <intent> <action android:name="android.media.action.
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Hey guys, i’ve found out about this issue today as one client of my app was complaining of low storage space, which was weird as I was using base64 capture, thought that the temporary images were deleted after capture, but no, and if you don’t use Uri result type you don’t get the full path of the image, so in the meantime i’m just clearing the pictures folder content, hope that this helps someone:
Thanks for the issue! This issue is being locked to prevent comments that are not relevant to the original issue. If this is still an issue with the latest version of Capacitor, please create a new issue and ensure the template is fully filled out.