Android 13.0 SystemUI's QSPanel adds date layout

1 Overview

 In the system product development of 13.0, customized development is also common in SystemUI. Recently, product projects require customized development for the drop-down status bar and notification bar. To modify the common functions of the UI, the product needs to slide down to expand the status bar
. When adding the time display function in the QSPanel part, the date can be displayed in the drop-down status bar, so the first choice is to analyze the
QSPanel layout of the drop-down status bar in the systemUI to realize the date addition

2. The QSPanel of SystemUI adds the core class of date layout

frameworks/base/packages/SystemUI/src/com/android/systemui/qs/QSPanel.java

3. SystemUI's QSPanel adds date layout core function analysis and implementation

In the relevant source code of the drop-down status bar of Systemui, the shortcut setting menu options after the drop-down of the QSPanel in the shortcut setting area and the click event process analysis SystemUI are also a type of SystemUI; its loading is also loaded with the loading of PhoneStatusBar
, In the drop-down status bar of systemui,
Quick Quick Settings is the preferred display in the area of ​​the qs panel , and Quick Settings will be displayed in the second drop-down, so next, analyze the relevant source code of QSPanel.java

The QS panel actually has a variety of states, including:
• Quick Quick Settings (QQS): It is the primary expanded panel, which is a simplified version of the QS panel that can be seen once the panel is pulled down, and contains a small number of switches, as shown in the left figure below • Quick Settings
( QS) : Complete QS panel, which is the completed QS panel seen in the secondary drop-down panel, which contains more switches, as shown in the figure on the right. There
is also a switch editing panel, which
is called the notification bar drop-down panel switch in the switch detail page SystemUI The single switch in the area is Tile.
In the drop-down status bar, QSPanel.java is responsible for drawing the page. For increasing the date layoutÿ

おすすめ

転載: blog.csdn.net/baidu_41666295/article/details/132253413