Android Launcher startup process "Launcher partial START process"

Source: Internet
Author: User
Tags aliyun

The research code starts with: Androidmanifest.xml, custom

When the Android system starts, the system needs a home application to be responsible for displaying the applications, that is, the application is intended to be the first application launched by the Android system. On Android, this default home application is launcher.

To use an application as a home, simply add a category to the Android.xml file:

<intent-filter>    <action android:name= "Android.intent.action.MAIN"/>    <category android: Name= "Android.intent.category.DEFAULT"/>    <category android:name= "Android.intent.category.HOME"/>    <category android:name= "Com.aliyun.ushell.action.detailpage"/></intent-filter>

For several property descriptions in the Androidmanifest.xml file:

<manifest    xmlns:android= ""    package= "Com.aliyun.ushell"  coreapp= "true" android:shareduserid= "Android.uid.system"    android:versioncode= "2"    android: Versionname= "1.2.3"     >

Where Android:shareduserid decides whether a system signature is required, Android:theme determines the theme and style;andrid:debuggable of the entire application and determines whether the application is in debug mode.


1. How is the launcher activated? Why does the Android system start launcher by default when booting?

2. What is the main job of launcher?

Android System opening Launcher,launcher is initiated by Activitymanager, while Activitymanager is initiated by Systemserver.

The value of the Intent-filter attribute added in the Androidmanifest.xml file is used here: Category_home. General bindings use the above three categories, that is, keywords: main/default/home.

The main work of launcher is to monitor the application's installation, update, deletion and other actions that cause launcher database changes. Launcher data is the use of ContentProvider to provide data, that is, the need to customize Contentresolver listen to the changes in the specified URI data.

private final contentobserver mobserver = new Contentobserver (new Handler ()) {@Ov Erride public void OnChange (Boolean selfchange, Uri uri) {final int nightswitch = Global.getint (Ushellapplicati        On.this.getContentResolver (), Switch_key,-1);        Final int nighton = Global.getint (UShellApplication.this.getContentResolver (), On_key,-1); Final Boolean Wallpaperon = (Global.getint (UShellApplication.this.getContentResolver (), Wallpaper_key, Default_        wallpaper) = = 1);        Mwallpaperon = Wallpaperon;            if (Readtime () | | Nightswitch! = Mnightswitch | | Nighton! = Mnighton) {mnightswitch = Nightswitch;            Mnighton = Nighton; if (!            Utilities.is_zhonghong) {ontimechanged ();            } else {onzhchanged (null); }        }    }};

Launcher start the process is to load the interface data and then display, the interface data are system app related data (may contain launcher database).

Android Launcher startup process "Launcher partial START process"

Contact Us

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: and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.