3

I have developed the launcher application, for the first time when I installed it on device android system pop up chooser dialogue with two options i.e. Always & Just once. I selected "Always" now my app becomes default launcher but issue is when I update the app, the system pop up the same chooser dialogue again, I don't want to show that pop up. How to make the app as a default system launcher? To achieve this, Do I need to create system level app?

I have used following permission to make the app a launcher

<intent-filter>
 <action android:name="android.intent.action.MAIN" />               
 <category android:name="android.intent.category.HOME" />
 <category android:name="android.intent.category.DEFAULT" />
 <category android:name="android.intent.category.MONKEY" />
</intent-filter>
Rahul Matte
  • 1,151
  • 2
  • 23
  • 54
  • I'm not sure if that is possible (at least without root, in which case I can't help sorry!), in the worse case scenario you can configure it like you could ask user to select your app as default the first time it runs – TomTsagk Oct 17 '14 at 10:07
  • @TomTsagk yes It's done. but after updating it is asking again which I want to avoid – Rahul Matte Oct 17 '14 at 10:11

1 Answers1

4

It is not possible to change the user preferences. Google does not allow developer to change user preferences.

A workaround may be useful, you can check for if your application is default launcher through a service and then prompt user to choose your application as default.

You can find how to check if your application is the default launcher from here (tried this one, it works for me) or here

Then you can prompt the user to select your application if it is not the default launcher. A workaround to do so is given here.

Community
  • 1
  • 1
layogm
  • 56
  • 4
  • while it makes itself default launcher, but when i press home button it opens the app, but pressing back button takes to previous default launcher, which i don't want to happen. – Vikas Pandey Oct 24 '17 at 14:49
  • @VikasPandey did you find any proper solution for "back press" issue? I have overridden the "onBackPressed" function with no "super.onBackPressed" call. Not sure if it's the best solution. – nayakasu Apr 10 '21 at 18:29