I'm working on an app for elderly people, it will show a big clock and show family pictures/videos posted by family.
The problem I have is that I need to lock the app's icon on a fixed place on the user's device so it can't be accidentally moved or deleted from the home screen.
How can I lock the icon in place programmatically?
Thanks!
How can I lock the icon in place programmatically?
Step #1: Write your own home screen/launcher app.
Step #2: Lock the icon in place in that launcher.
There are no requirements for any other launcher to even show an icon, let alone allow third-party apps to control anything about such an icon.
Related
I want to replace my icon in apps dock when after installing my developed app. That means when I install my app (dialer), it shows on apps dock by replacing an existing one (stock dialer).
There are many home screen implementations for Android. Not all of them have such a dock. There is no standard API for asking a home screen to replace something in a dock.
You are welcome to contact the developers of various home screens and see if they offer some API to allow you to replace an icon in their dock.
This is not possible for several reasons.
First, the dock is basically a small drawer. The user can put an icon there themselves and the default one is specified by the launcher app.
Secondly, there is no common interface to ask the current launcher to add an icon to the dock. Many launchers do not have a dock at all! :-(
So, you should just let the user decide whether they want to have your app on the dock :-) Alternatively, you can write your own launcher which will put your app in the dock by default! :-D
Usually the icon is fixed. But I want to make an application: when user presses the icon, it won't open any new UI but just change the icon itself. That means it has only two status and can be changed by users pressing on it.
Are some code examples available for this?
As you can see from below screenshots of my phone. The app icon represents a cleaner. When I press it, the 2nd picture shows that the icon changes and it won't enter any UI, just shows the percent of phone's processes cleaning status.
I want to make an app with this effect.
You cannot change your application icon at runtime, in terms of what is displayed by the home screen in its launcher.
You are welcome to write a home screen app widget that can respond to user input and can change its UI.
Is it possible to Display Information on the lock screen from an Android application.
I came across a few Apps which allow you to display Email and Calendar information on the screen but could not find which API to use for achieving the same.
Android 4.2 supports app widgets on the lockscreen.
according to the app you've mentioned (which has very poor description and quite low rating) , i suspect they disable the keyguard (the default lock screen) each time they get the event of power off (or on) .
maybe the activity that they are using has a transparent background and is above the normal lock screen .
there are many similar apps , such as "widget Locker" ,"magic Locker" and "quick Launch" , all do about the same thing to replace the keyguard . most of them also have the ability to replace the launcher (but will still show the launcher of the user, of course) , for smoother experience .
does the screenshot belong to the app you've mentioned , or to something you wish to achieve ?
You can learn how it can be done if you look at the sources of open source project contact owner that adds a message to the lock screen, too.
I would like to make an icon counter for andoid just like the Email and the Samsung Apps applications i have seen such requests from other developers, but you all say it can't be done.
if so how come those 2 apps and other apps can do it?
do i have to make like more than one icon image and swap them or something?
is it really cant be done and why?
thanks.
you all say it can't be done.
That is because it cannot be done, except by the maker of the home screen, or via an app widget (instead of a launcher icon).
if so how come those 2 apps and other apps can do it?
Because Samsung wrote the home screen and can do what it wants with its home screen.
do i have to make like more than one icon image and swap them or something?
That will not work, as you cannot change the launcher icon at runtime.
is it really cant be done and why?
It really can be done by making an app widget, or by making your own home screen.
I'm a web developer. I have an idea for an Android app, but before I dive in and start learning, could someone please answer the following:
Is it possible for a regular app (installed from the Market)...
to add/remove icons (of other apps) to/from the home screen?
to rearrange icons on the home screen?
to change the home screen's wallpaper?
To clarify: I don't want to replace the home screen application itself (I believe this is only possible on rooted phones?); I just want to programmatically customise the stock home screen. I know the user can do this themselves, but can an app do it?
If possible, please link to documentation of the relevant APIs.
Your answer to following question
Is it possible for a regular app (installed from the Market)...
to add/remove icons (of other apps) to/from the home screen? No, it can only add its own icon
to rearrange icons on the home screen? Again, no
to change the home screen's wallpaper? Yes, you can do that
As far as for rooted phone goes yes you can do it :)