Launcher3 has no icon problems, and launcher3 has no icon

Source: Internet
Author: User

Launcher3 has no icon problems, and launcher3 has no icon

Copyright. For more information, see the source:

Http://www.cnblogs.com/sickworm/p/3966820.html

 

MTK8382/8121 platform.

 

After the machine (8-inch, default portrait screen) is burned for the first time, it starts in a horizontal position and finds that the Launcher does not have an icon, but the portrait screen does not have this problem. During the test, we found that this problem also exists after setting clear data. Therefore, it can be preliminarily determined that it is a database initialization problem, because the database stores the data of favorite icon and workspace.

Compared with the database, it is found that the workspaces field is not written. View the output log and find that the biggest difference is that during the initialization process of step 1

setApplicationContext called twice!old=com.android.launcher3.LauncherApplication@41c76888 new=com.android.launcher3.LauncherApplication@41c76888

. Find the location of the warning output and find it in onCreate. That is to say, during the initialization process, Launcher3 onCreate twice.

 

We know that in order to re-layout, the Launcher will re-create onCreate each screen conversion. When the screen is placed on a horizontal screen, the screen is converted again in a short time in the default vertical screen state.

After reading AndroidManifest. xml, we found that the android: screenOrientation attribute is nosensor, so each start is default (portrait screen ). After changing to sensor, if the first initialization direction is the same as the actual direction, onCreate () will not be executed twice.

 

In LauncherModel. java, search "step 1" to find the process of initializing the workspace. This workspace Initialization is not protected by synchronized. As a result, a conflict occurs during database initialization, leading to write failure.


No response to the Launcher icon

After 3DM is installed, is it completely installed or only replaced with EXE?

Android Launcher icon problems, or those application icons I want to change

There is a column in the code for you to see

Related Article

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: info-contact@alibabacloud.com 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.