[DEV] Save file with Storage access framework - Android General

Hello, how to save for example bitmap to external storage with SAF but without opening "save as" dialog? For example I open picture with ACTION_OPEN_DOCUMENT in this picture I make any changes and I want save this picture with different name to the same location but I don't want to show dialog with save as information. I want save this new file directly in to the location where is original file.
Thank you, MG

Related

Change Camera save folder

If you want to change the location folder where pictures taken will be stored instead of My Pictures, create a new folder in My Documents (such Camera) in your Storage Card and in your main memory. (\Storage Card\My Documents\Camera) and change the following string value:
HKLM\Software\HTC\Camera\P1\SaveFolder
Change the string value to the folder name you want (Camera in this example).
You can also do the same for Videos, the registry is:
HKLM\Software\HTC\Camera\P2\SaveFolder
Change this in the same manner as above, or you can even make videos and images to be saved in the same folder.
You can use the same technique to also cause the pictures to NOT go into "My Documents" on the card. I found it annoying the camera program would create "My Documents" on the card, which essentially adds "My Documents" as a folder to every application.
Anyway, instead of putting the directory name in the SaveFolder registry key, put in "..\<dirname>" (without the quotes, of course).
So, on my unit:
HKLM\Software\HTC\Camera\P1\SaveFolder = ..\My Pictures
Now images save directly to \Storage Card\My Pictures

facebook apps issue or photo album display issue

Hi
i use Hd2 and got the microsoft facebook apps installed. i discovered that i now have many photo folder existed when i open the photos tab and then click "albums" and "albums" again.
i realize all photo folder show under the "My Device" tab is due to the photos downloaded due to my facebook apps. is there anyway we can hide the unnecessary folder shown at the photo apps?
dan97
I too have found out that the facebook app is copying the profile pic of each FB person in the recent news etc, and putting into my albums
Hiding folders in htc albums
from pocketnow.com
If somehow HTC Album on your device is displaying pictures or folders as Albums you'd prefer to hide from various reasons, this could be easily achieved with a Registry tweak that instructs HTC Album to ignore a specific folder.
You need to edit your registry by going to HKEY_LOCAL_MACHINE\Software\HTC\HTCAlbum\Ignored. This is the place where all the folders to be ignored and not displayed in the Album application are stored. Say you have a folder called Project you'd like to hide from the application then create a new string in HKEY_LOCAL_MACHINE\Software\HTC\HTCAlbum\Ignored and set its name to Project and its value to the path of your folder (i.e.: \Storage Card\Project). This will hide all subsequent folders as well so make sure to hide only the folder you want to keep from Album application. Add as many string values as you wish.
Note: Additionally, if you want to hide a specific picture, just set its attributes to hidden and it will not be shown in the Album application. Do that for all individual pictures you want to keep from the program.
i would have put a link but im not alowed.
think you need to hide \Temp or at least thats what took my facebook pictures off albums
Peter
thank you
THANK YOU prob1. my problem is solved.

Best way to hide some photos in Gallary

Hello, I like to take photos and videos using my Note PRO 12.2 However, it has happened a few times that when I showed people photos/videos in Gallary, those that I did not want to show also showed up. What is the best way to hide these videos/photos? I am using an un-rooted device. Thanks.
Rename those files (or folder containing them) to start with "."
They should not show up on your gallery.
Spere said:
Rename those files (or folder containing them) to start with "."
They should not show up on your gallery.
Click to expand...
Click to collapse
Create a new empty file and name it ".nomedia" without the quotes. It will hide any media in the folder that you place it from any gallery/media app.
Thanks. In the case of putting confidential photos and videos in the folder called .nomedia , how do I view those files?
I guess the above approach is very good if everything is in one folder. If I organize the files into folders like "Summer trip to the US", "winter 2014", "school", "research", etc., it may be a bit inconvenience to move selected files from each folder to one big .nomedia folder or create one such folder inside each bigger folders.
Alternatively, is there a good photos/videos viewer that allows me to drag and drop files or folder to it so that they are perhaps password protected?
Try Quickpic. Under its settings there is a browse menu where you can exclude certain folders.
Sent from my SM-P900 using Tapatalk
petercohen said:
Thanks. In the case of putting confidential photos and videos in the folder called .nomedia , how do I view those files?
I guess the above approach is very good if everything is in one folder. If I organize the files into folders like "Summer trip to the US", "winter 2014", "school", "research", etc., it may be a bit inconvenience to move selected files from each folder to one big .nomedia folder or create one such folder inside each bigger folders.
Alternatively, is there a good photos/videos viewer that allows me to drag and drop files or folder to it so that they are perhaps password protected?
Click to expand...
Click to collapse
You're mistaking two things for eachother.
A .nomedia file is a file. You can find one, for example, in the Android folder. It excludes the content of the folder it is located in, as well as any subfolders, from the MediaScanner/Indexing Service process. (Thus the solution for excessive Media battery usage). This excludes the files from the gallery, no matter the gallery setting.
Renaming a folder with .[foldername] does not require it to be called NoMedia, you can call it anything you want. This excludes the folder from apps that have the settings 'exclude folders starting with .' to hide the folder. Meaning you can also show the folders if you want.
Folders with a .nomedia file in it will not show up in the gallery or mediaviewer, but the files can still be opened the normal way from a file explorer.
I've excluded all folders with media in it except for the Alarms, Ringtones and Notifications folders (or the alarm/ringtone won't go off), and opening videos, pdf's and images is done by simply opening the file through a file explorer.
Basically, you can either make a .[foldername] folder and drop them all in there, or make a regular folder, drop all the images in there and copy a .nomedia file into it. The effect will be the same, except that you can choose to show or hide them if you use a .[folder]. .nomedia can not be disabled in the regular gallery. (It can in Quickpic.)

What's the stock text editor app on your Huawei mobile phone?

When I selected and tapped a .txt file in Files app, the text file would be opened with a stock editor app, WPS Office.
But when I tapped that floppy disk icon to save after editing, it seemed that it couldn't save and update that .txt file. It would rather 'Save as' another file.
I wonder why I could not save and update a .txt file directly.
Thank you in advance.

MIUI Gallery reverse engineered

In the MIUI Gallery app data we have a picture database /data/user/0/com.miui.gallery/databases/gallery.db containing information such as timestamp, exif data and file name.
There is a cache directory /mnt/runtime/write/emulated/0/Android/data/com.miui.gallery/files/gallery_disk_cache/full_size containing thumbnails in 1080x1440 resolution.
How does the MIUI Gallery app know which preview belongs to which picture?
I am looking for information about the missing link. I have attached example app data for one picture. The original example picture is included.
The goal is to recover metadata of pictures. I lost the phone and MicroSD Card so the original photos are lost. But I have a f2fs disk dump of userdata partition, that allowed my to restore at least thumbnails of lost pictures. The goal is to find the link to the database entries, so I can at least restore the timestamp and file names.
My first attempt was to simply rename the files by mtime (see shell script) but unfortunately that doesn't reflect the correct timestamp, because that is only the creation date of the thumbnail (when first opened a picture in gallery)

Categories

Resources