Prevent Gallery to display the photos in certain folder

My children likes to play with my phone, they like to see what are the photos inside with Gallery. Problem is - sometime friends just sent me some photos via Whatsapp which are not really suitable for the viewing of children,

So I need a way to prevent these photos to be displayed in the Gallery. I know the location of these folder in my phone but how do I instruct Gallery not to display them?

A quick research from Google recommend two methods:

1. Put a dot in-front of the folder you want to hide. For example - .Test
2. Put a file with name of .nomedia on the folder where you want to hide.


Below just want to share my experience on implementing these two methods.


Method 1
The folder can be renamed via the File manager inside the phone. Alternatively you can download some 3rd party tool to do this.

Lastly you can connect the phone to your laptop and rename from Windows Explorer.

The result was actually instant. The moment you put a dot in-front of the folder, Gallery will not show it.

Note that it is also hidden from File Manager in the phone as well as from Windows Explorer on the PC.

On the PC, even if you configure to show hidden files, still it wont show.

You can configure to view the hidden file from the phone's File Manager.

If you change your mind by deleting the dot, Gallery will not show the folder back. This is especially true for external card installed on the phone. This is because Galley will not rescan the folder. You can remove and reinsert the card to initiate the scan.

Or you can rename the folder to something else and then rename it back to the original so that Gallery will think this is a new folder and will scan the content.

Method 2 
My first question on this : how do I create a .nomedia file? To be honest, I don't really know how to create a blank file in the phone. 

Some article mentioned there is utility from Play store what can help you to create the file. I tried with that method but I don't like it. 

Later I discovered the easiest way is : there are actually .nomedia files already exist inside the phone. Check you phone whether you can see folder with the name of Android. If you do, just copy and paste the file to folder you want.

Else do a search and I am sure you can see plenty of result. 

If you change you mind, just delete the file from the folder. 

Comments

Popular posts from this blog

2017年11月份讀書報告

2017年9月份讀書報告