I have an app on Google Play market and I added
android:installLocation="preferExternal" to manifest.xml file and released long time ago. Now I would like to add Android home screen widget, so I need to change it to
android:installLocation="internalOnly". If I do that, what happens when a user upgrades? because a user already installed the old app on SD card. What is the best solution for this situation??
If someone has this kind of experience, please advise me.
Thanks in advance 🙂
When you set install location to preferExternal the application specific files are stored in .android_secure directory in external sdcard.
These type of application are not available when user mounts the SD Card as USB Mass Storage (feature removed from Android Jelly Bean).
Coming to the question, I believe in your case the application would be installed onto internal memory with the files from .android_secure moved to internal location.
You can confirm this by the following:
- Install the application from play store having install Location as preferExternal.
- Confirm that your application is installed in external SD card, you can use Settings->App to check that.
- Now create your new signed application package.
- Install using
adb install -r myapp.apk
- Again goto Settings->App and confirm the location.
- Run functional test to see if nothing is broken.