I am creating an android app in which I want to take screenshot of my device when i click on myapp icon and when myapp launch set the screenshot as background of myactivity, I searched alot but cant find any solution anyone please tell me how i can achieve this task?
When users click on the launcher icon (the icon of your application in the menu of your device) the application is launched.
This is managed by Android itself and you can't override/change this behavior.
It means that it is not possible to do something on the device before your application is launched.
Related
I have a nicely working widget.
I have an idea to add an option for the users to launch any (previously installed) app from the widget by pressing the dedicated button. So I want users to be able to choose 1-2 apps from their installed apps in the widget configuration part and be able to launch them from the widget.
Is there any way to add this functionality without declaring this widget a launcher?
If yes, could I get any hints, maybe some tuts, please?
I really appreciate any help you can provide.
Adam
Problem 1:
I have developed a app which works fine but when it is installed a shortcut gets created by default as in most android devices . The shortcut just has a logo and not the name of the app. Whereas the app does have name/label in menu.
Problem 2:
The app also doesn't shows up in the multi-task(when the box button is pressed --android L), the app quits on pressing the multi task button and when restarted it starts from where it was left. so the activity is not killed but still does not show among the background processes in multi task view.
If there is a need of any code , please ask for it.
Any help is appreciated.
Problem 1:
Did you set the name of the app?
Problem 2:
Don't have a lot to go with so...
What launchMode property are you using in the activity?
Sorry i didnt add the Android.manifest file, apparently i had a blank label for my launcher activity. Giving it a value made it work.
<activity... android:label=""/>
I want to know the exact method which invokes/starts all the apps. I basically want to block a certain set of apps using xposed module. Its ok if the app icon is visible but the app should not be launched after clicking on it. To be precise nothing should happen when the user clicks on the app icon.
So I want to know where the source code which invokes the apps.
PS : I would also like to know if there is any way to hide the icon of the app as well.
Make your own launcher app and replace it with the ones running on mobile phones.
You can check the sources of Laucher and Laucher2 currently running on Android system.
here i want to launch Android Home Screen
Can anybody tell me where to find information about how to write a custom home-screen application? and i want to remove android default home screen. and add my custom home screen code to source of android.
So very first i have to make application which launch as a home screen so any body can give me some tips or guidelines?
Thanks
create a home application , which is nothing but an application with home intent . Samples (../android-sdk-linux/samples/android-8) have a good example named "Home" .
once app install when user will click on homeScreen he will be prompted for select home among existing home apps (including your app too) , once user set it as default this will not be asked again .
In my android application as soon as the user clicks on the application icon from menu the app is getting launched.It is happening even if the application is open earlier.
I would like to maintain the state like if the application is opened then the app should show the default opened page and should not launch it again.
Please let me know your valuable suggestions.
Thanks in advance :)
Hey i solved this issue.Earlier i was using android:launchmode as single instance.When i removed this its working fine :)