I know the following happens in Windows [desktop]:
the system has an icon for each extension, and a default one for new ones.
When a new program is installed, it saves its icons to its extensions in the system [ex. upgrading Word 2007 to 2010 changes the icons for .docx files]
Now I want to know how to get those icons in android. I’m not sure if it follows the same scenario, BUT, i have a file explorer app which displays those icons. From my use of it, i know that those icons cannot be hard coded [except for the folder icon]. For example, after installing Tango, its icon took over the .ini files
My question is, How to get those icons? I’m kinda doing a file explorer app [that serves certain needs no other app does]
Android doesn’t provide that functionality. You have either hard-code drawables for most-used file types into your application or download them from Internet.