execution process to the application A,android program to start running.The newly generated application A will use the connection information for the library and resources that already have the zygote parent process, so it runs fast.In addition, for zygote startup, the DVM is initialized and run, and then the required classes and resources are loaded into memory.The fork () is then called to create the zygote ' child process, and then the child proce
The Android operating system displays an activity for
In addition, if the user wants to add a shortcut to the appliance's home screen, the app's icon can be launcher in the Android system, and it will automatically add a shortcut to the home screen for the application. The name and icon are the same as in launcher.
Supports thawing and freezing apps
Support to hide specified app in the app list
Support detection system core app to prevent delayed freezing causing cell phone to become brick
Support Cleanup App Cache
Support Force Stop App
APK file is only 47KB
Personal
Today the main analysis of the Android Launcher source code in the relationship between some important classes, the basic loading process. Take a look at a class diagram firstLauncher.java is the primary activity that initializes the Launchermode instance within the OnCreate method.Launcherapplication app = ((launcherapplication) getapplication ());Mmodel = App.s
Android operating system for In addition, if the user wants to add an app shortcut to the device's home screen, you can press and hold the app's icon in launcher, and the Android system will automatically add a shortcut to the app on the home screen. The name and icon are th
has to prevent the restart ....Luck is really good, just have this attribute:android:configchanges=["MCC", "MNC", "locale", "touchscreen", "keyboard", "Keyboardhidden", "Navigation", " Screenlayout "," Fontscale "," Uimode "," orientation "," screensize "," Smallestscreensize "]The official explanation is this:Lists configuration changes that the activity would handle itself. When a-configuration change occurs at runtime, the activity was shut down and restarted by default, but declaring a Conf
Packagemanagerservice. See later ):
Each apk file is an archive file, which contains the android application configuration file Androidmanifest.xml, which is mainly to resolve this configuration file. Once the profile is obtained from the APK archive, the application is parsed by calling another external version of the Parsepackage function: parsing the individual tags in the androidmanifest.xml file , such as the parsing of application tags, this
The main thing in launcher is to get the portals and icons for all the app lists, and there are two ways to get them:PackageInfoResolveInfoRun get launcher of all apps and allow click events to go to the appThe following two methods are used to obtain a list of all apps:Establish basic data:Pakagemod.javapublic class Pakagemod {public String pakagename;public str
When we click on an application icon in the Launcher interface, we start a program, so what happens to this process? Let us follow launcher source code to analyze it.First on the flowchart:650) this.width=650; "Src=" http://img.blog.csdn.net/20140509134103500?watermark/2/text/ ahr0cdovl2jsb2cuy3nkbi5uzxqva2luym9z/font/5a6l5l2t/fontsize/400/fill/i0jbqkfcma==/dissolve/70/gravity/ Southeast "alt=" Southeast "/
get down to the truth. If we want to write the same launcher ourselves, we have to look at the simulator or the Android system first, so that we can look at this simple but hidden starter that starts the first one each time. Through some tossing, You can roughly divide the functions implemented by launcher into the following:
1. Long-pressed in an empty position
= context;This.resinfo = Resinfo;}@Overridepublic int GetCount () {TODO auto-generated Method Stubreturn Resinfo.size ();}@OverridePublic Object getItem (int position) {TODO auto-generated Method Stubreturn Resinfo.get (position);}@Overridepublic long getitemid (int position) {TODO auto-generated Method Stubreturn position;}The purpose of this place with Viewholder is to improve the app's speed by not having to reconstruct our convertview and find ImageView and textview every time.@OverridePubl
This article describes the development process for Android boot auto-start application.1: Add self-launch permissionsAdd Permissions in Androidmanifest.xmlandroid:name= "Android.permission.RECEIVE_BOOT_COMPLETED"/>2: Add self-initiated receive, decide which broadcastreceiver to use as the application entranceAdd a portal to Androidmanifest.xmlreceiverAndroid:name= "Com.zpd.scanadapter.BootUp" >Intent-filter> ActionAndroid:name= "Android.intent.acti
When doing a mobile phone adaptation, encountered a very strange problem, in 1080x720 's phone can display the replacement ic_launcher.png icon, but in 1920x1080 's phone display ic_ Launcher.png is still the default icon, and after checking that it does not include the default Ic_launcher.png icon throughout the project, what is the icon displayed?The first possibility of Baidu, found the same problem others have encountered, they are directly replaced by the default Ic_launcher.png icon, re-in
1. Create a new class that inherits Broadcastreceive Public class extends Broadcastreceiver { public startboot () { } @Override public void OnReceive (Context context, Intent Intent) { new Intent (context,mainactivity. Class);// Intent2.setflags (intent.flag_activity_new_task);// context . StartActivity (Intent2); }}2. Modify Androidmanifest.xml receiverAndroid:name=". Startboot "> Intent-filter> ActionAndroid:name=
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.