Give user choice of setting default home page - android

I'm looking for a way to present the user a choice of setting the home page programmatically.
What I want is for my app to ask the user to pick their choice every time it starts up. Is there a way to do this? Or is there a work around for this?
Thank you

The only thing you can do is bring up the home screen. If the user has not already chosen a default home screen, and there is more than one home screen installed on the device, the chooser will let the user choose a default. The user is welcome to not choose a default as well, as it is their device, not yours.

Related

How to prompt the user to unlock the lockscreen, when he/she click on the lockscreen widget?

I have made one widget which basically shows the Rss-feed from a site. When it is clicked upon, it opens the respective link. All is good upto here.
Now when I place it on lockscreen, it responds exactly same like it is on homescreen. I want that when user clicks on the widget, it prompts user to first unlock the screen and then open the browser. How do I achieve this? Help is appreciated. Please let me know if any more information is required. Thanks.

How can I update a home application without being asked to redefine the default home?

I have developed an application set as a home onto my Android device. On my device I set it as the default home application. That way, each time I click the home button, I am redirected to this app.
The problem I have is that I have to produce some updates. But when the app has been updated, the device ask to define the default home once anew.
I would like the update to be performed without the user having to define the default home again.
There isnt a way to do this. Each time your app is updated the user will have the opportunity to chose whether they want to keep it as the default home application. It is a means of Android showing a user he or she is in control of there device at all times.
If im wrong someone please correct me.

Setting default App

My app have feature to send a mail. If user use this he will be prompted to open google-mail-app or another mail-app. But this selection haven't checkbox to set the current user option to default.
Is it possible to extend the selection with a default-checkbox?
I know this checkbox from another application such navigation.
thx
It's not possible to hardcode this into an application, however the user can do the following:
Tap the Menu button on your phone and
select the Android Settings option.
Scroll down to the Applications
section and tap it. On the next
screen, tap Manage Applications and
then the All tab on the subsequent
screen. Scroll down the list of apps
until you see the old browser listed
and tap that entry. On the next screen
look for the "Launch by default"
section and hit the Clear defaults
button.
Source: http://lifehacker.com/5637923/change-the-default-application-for-any-android-phone-task

Android: Launch Shortcut picker

I have looked everywhere for something related to this. I want to launch a shortcut, based on the shortcuts installed on a device.
A simple way of putting this is my user selects one of his shortcuts through my application. When the user initiates the shortcut through my app, it will perform the exact same thing as if he/she is on the home screen and selects the shortcut.
I can do this individually with the system shortcuts, but I want to have more flexibility for other shortcuts installed on the device.
So basically, I need to figure out how to bring up the shortcut picker (the same list that appears by long pressing a home screen and selecting shortcuts), get the intent to launch that shortcut and store that within my application data for use later. I don't want to actually initiate the shortcut when the user selects it, I just want to remember it for later.
Any help with this would be greatly appreciated :)
I think you are looking for this: https://developer.android.com/reference/android/content/Intent.html#ACTION_CREATE_SHORTCUT

How to set my App as default Home?

I'm developing a Android desktop app, and I would like that when it first starts it (confirm with user and) set itself as default action for Home button.
Currently, this option is given to the user by the Android system only when he first press the Home button after running my app.
Actually, I want the "back" button to not return to the default desktop, as my app will be the default desktop. Maybe the solution for this is the same of the one for the Home button?
Any idea how to do this?
You cannot do this.
Why not just let the system do it for you when the user presses the Home button for the first time. It's what the user is expecting. He/she doesn't expect it to change automatically and personally I would find that quite annoying if it did that since I like choosing my Home screen constantly.
As for the back button, simply add an onKeyDown/Up handler for the KeyEvent.KEYCODE_BACK event to return true (meaning handled by you, not the system). If you do that, it will not leave your app.

Categories

Resources