Pendant display method, terminal and program product

By communicating data between the widget process and the page process in the operating system, the problem of chaotic interaction logic and mutual interference caused by the coexistence of multiple application widgets is solved, achieving clear widget display and a smooth user experience.

CN119024989APending Publication Date: 2024-11-26SHENZHEN HEYTAP TECHNOLOGY CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411110635.7
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-08-13
Publication Date
2024-11-26

AI Technical Summary

Technical Problem

In the smartphone ecosystem, the coexistence of multiple application widgets can easily lead to visual overlap, confusing interaction logic, and mutual interference of functions, affecting the smoothness of the user experience.

Method used

By communicating data between the widget process and the page process in the operating system, widget data is transmitted, and the display of widgets on the page is controlled, thus avoiding confusion in the interaction logic of multiple application widgets and mutual interference in their functions.

Benefits of technology

It improves the efficiency of users obtaining information from the page, ensures a smooth user experience, and avoids clutter and interference in widget display.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119024989A_ABST
    Figure CN119024989A_ABST
Patent Text Reader

Abstract

The invention provides a pendant display method, a terminal and a program product, and belongs to the technical field of computers. In the method, the terminal can transmit pendant data through data communication between a pendant process and a page process in an operating system, and then a pendant is displayed in a page of the terminal. According to the method, under the condition that the pendants are mounted on the page, the display of the pendants in the page is controlled through the operating system, and the problems of interaction logic disorder, function mutual interference and the like caused by coexistence of the pendants of multiple application programs can be avoided, so that the fluency of user experience is guaranteed, and the efficiency of obtaining information from the page by a user is improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of computer technology, and in particular to a pendant display method, terminal and program product. Background Art

[0002] In the current smartphone ecosystem, all major mobile customization systems support applications to embed widgets in the lock screen interface and desktop interface to enhance the user experience. However, when widgets of multiple applications coexist, it may cause visual overlap, confusion in interaction logic, and interference between functions, which will seriously affect the smoothness of the user experience. Therefore, how to display the widgets of applications on the page to avoid interference between widgets of different applications is a technical problem that needs to be solved urgently. Summary of the invention

[0003] The embodiment of the present application provides a widget display method, terminal and program product. In the method, when a widget is mounted on a page, the terminal controls the display of the widget on the page through the operating system, which can avoid the problems of interaction logic confusion and mutual interference of functions caused by the coexistence of widgets of multiple applications, thereby improving the efficiency of users obtaining information from the page. The technical solution is as follows:

[0004] According to one aspect of an embodiment of the present application, a widget display method is provided, the method comprising:

[0005] Make sure the page has widgets installed;

[0006] Sending the widget data of the widget to the page process corresponding to the page in the operating system through the widget process of the operating system, wherein the page process is used to process the data associated with the page;

[0007] The widget is displayed on the page through the page process.

[0008] According to another aspect of an embodiment of the present application, a pendant display device is provided, the device comprising:

[0009] The determination module is used to determine whether a widget is mounted on the page;

[0010] A sending module, used for sending the widget data of the widget to the page process corresponding to the page in the operating system through the widget process of the operating system, and the page process is used for processing the data associated with the page;

[0011] The display module is used to display the widget in the page through the page process.

[0012] In some embodiments, the widget data includes view data and event data;

[0013] The display module is used to load the view data and the event data through the page process; based on the view data and the event data, the view object of the widget is displayed in the widget layer of the page, and the widget layer is a transparent layer for responding to various operations corresponding to the event data.

[0014] In some embodiments, the apparatus further comprises:

[0015] A first generating module, configured to generate an installation instruction of the widget through the widget process, wherein the installation instruction carries a widget identifier of the widget;

[0016] The parsing module is used to obtain the installation package of the widget through the widget process, parse the installation package of the widget, and obtain the widget data.

[0017] In some embodiments, the first generation module is used to determine the widget identifier of the widget and the page associated with the widget through the widget process; when other widgets are displayed on the page, based on the widget identifier of the widget and the widget identifiers of the other widgets, generate installation instructions for the widget, wherein the installation instructions are used to instruct to replace the other widgets with the widget; when no other widgets are displayed on the page, based on the widget identifier of the widget, generate installation instructions for the widget, wherein the installation instructions are used to instruct to display the widget on the page.

[0018] In some embodiments, the apparatus further comprises:

[0019] A second generation module is used to generate a plurality of intermediate project files based on a widget file and a template program by an annotation processing method, wherein the template program is used to define a standard communication interface between the widget process and the page process, and the widget file includes a widget script and a widget material;

[0020] A compiling module is used to compile the multiple intermediate project files based on the template program to obtain the installation package of the widget.

[0021] In some embodiments, the second generating module further includes:

[0022] A first parsing unit, comprising parsing the widget file based on the template program through the annotation processing method to obtain a preprocessing file, wherein the preprocessing file contains a reference relationship between the widget script and the widget material;

[0023] The second parsing unit comprises parsing the pre-processing file based on the template program through the annotation processing method to generate the multiple intermediate project files.

[0024] In some embodiments, the first parsing unit is used to parse the widget file based on the template program through the annotation processing method to obtain multiple types of attribute tags, and map the multiple types of attribute tags in the preprocessing file, wherein the multiple types of attribute tags include data tags, event tags, and view tags.

[0025] In some embodiments, the second parsing unit is used to parse the preprocessed file based on the template program through the annotation processing method to generate a first intermediate file, a second intermediate file and a third intermediate file, wherein the first intermediate file is a source file required in the page project of the operating system, the second intermediate file is a layout file required in the page project of the operating system, and the third intermediate file is a picture material file required in the page project of the operating system.

[0026] According to another aspect of an embodiment of the present application, a terminal is provided, comprising a processor and a memory; the memory stores at least one program code, and the at least one program code is used to be executed by the processor to implement the widget display method as described in the above aspect.

[0027] According to another aspect of an embodiment of the present application, a computer-readable storage medium is provided, wherein the storage medium stores at least one program code, and the at least one program code is used to be executed by a processor to implement the widget display method as described in the above aspect.

[0028] According to another aspect of an embodiment of the present application, a computer program product is provided. The computer program product stores at least one program code, and the at least one program code is used to be executed by a processor to implement the widget display method described in the above aspect.

[0029] The embodiment of the present application provides a widget display method, in which the terminal can transmit widget data through data communication between the widget process and the page process in the operating system, and then display the widget in the terminal page. In the case where the page is mounted with a widget, the above method controls the display of the widget in the page through the operating system, which can avoid problems such as confusion of interactive logic and mutual interference of functions caused by the coexistence of widgets of multiple applications, thereby ensuring the smoothness of the user experience and improving the efficiency of users obtaining information from the page. BRIEF DESCRIPTION OF THE DRAWINGS

[0030] In order to more clearly illustrate the technical solutions in the embodiments of the present application, the drawings required for use in the description of the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without creative work.

[0031] Figure 1 It is a schematic diagram of an implementation environment provided by an embodiment of the present application;

[0032] Figure 2 is a flow chart of a method for displaying a widget provided by an embodiment of the present application;

[0033] Figure 3 is a flow chart of another widget display method provided in an embodiment of the present application;

[0034] Figure 4 is a schematic diagram of a pendant form provided in an embodiment of the present application;

[0035] Figure 5 It is a schematic diagram of a widget display process provided by an embodiment of the present application;

[0036] Figure 6 It is a schematic diagram of a hanger layer provided in an embodiment of the present application;

[0037] Figure 7 It is a flow chart of a method for making a pendant installation package provided in an embodiment of the present application;

[0038] Figure 8 It is a schematic diagram of an installation package generation process provided by an embodiment of the present application;

[0039] Fig. 9 is a flow chart of another method for making a pendant installation package provided in an embodiment of the present application;

[0040] Fig.10 is a schematic diagram of a multi-level data exchange provided by an embodiment of the present application;

[0041] Fig.11 This is a schematic diagram of obtaining an intermediate engineering file provided in an embodiment of the present application;

[0042] Fig.12 It is a structural schematic diagram of a pendant display device provided in an embodiment of the present application;

[0043] Fig.13 is a structural schematic diagram of another pendant display device provided in an embodiment of the present application;

[0044] Fig.14 It is a structural block diagram of a terminal provided in an embodiment of the present application. DETAILED DESCRIPTION

[0045] In order to make the objectives, technical solutions and advantages of the present application clearer, the implementation methods of the present application will be further described in detail below with reference to the accompanying drawings.

[0046] In this article, "at least one" means one or more, and "plurality" means two or more. "And / or" describes the association relationship of the associated objects, indicating that three relationships can exist. For example, A and / or B can mean: A exists alone, A and B exist at the same time, and B exists alone. The character " / " generally indicates that the associated objects are in an "or" relationship.

[0047] It should be noted that the information (including but not limited to user device information, user personal information, etc.), data (including but not limited to data used for analysis, stored data, displayed data, etc.) and signals involved in this application are all authorized by the user or fully authorized by all parties, and the collection, use and processing of relevant data must comply with relevant laws, regulations and standards of relevant countries and regions. For example, the widget data involved in this application are all obtained with full authorization.

[0048] Figure 1 is a schematic diagram of an implementation environment provided by an embodiment of the present application. Figure 1 , the implementation environment includes a terminal 101 and a server 102. The terminal 101 can be directly or indirectly connected to the server 102 through wired or wireless communication.

[0049] In some embodiments, the terminal 101 can be a mobile phone, a desktop computer, a laptop computer, a tablet computer, a car computer and other types of terminals. The terminal 101 is installed or running a widget management center. The user can enter the widget management center through the terminal 101. The widget management center can be an application for managing widgets, or a functional module in the application for managing widgets. The widget management center is used to display widgets to be installed or manage installed widgets, etc. When the user uses the services provided by the widget management center through the terminal 101, the terminal 101 can generate installation instructions for the widget, and then obtain the installation package of the widget. The widget management center is associated with the server 102, and the server 102 provides background services. For example, the server 102 is used to store installation packages of multiple widgets, and the widget management center downloads and obtains the installation package of the widget from the server 102.

[0050] In some embodiments, server 102 is an independent physical server, or it can be a server cluster or distributed system composed of multiple physical servers. It can also be a cloud server that provides basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communications, middleware services, domain name services, security services, CDN (Content Delivery Network), as well as big data and artificial intelligence platforms.

[0051] In some embodiments, the server 102 undertakes the main computing work and the terminal 101 undertakes the secondary computing work; or, the server 102 undertakes the secondary computing work and the terminal 101 undertakes the main computing work; or, the server 102 and the terminal 101 adopt a distributed computing architecture to perform collaborative computing.

[0052] Figure 2 is a flowchart of a widget display method provided in an embodiment of the present application. The method is executed by a terminal, see Figure 2 , the method comprising:

[0053] 201. In response to a request for displaying a page, the terminal determines that a widget is mounted on the page.

[0054] In the embodiment of the present application, the page can at least be the lock screen page and the desktop home page of the operating system. The widget refers to a component of a basic application or a third-party application associated with the operating system in the terminal. The widget is used to jump and display a page in the basic application or the third-party application after triggering.

[0055] In some embodiments, the terminal determines the widget mounted on the page through the widget process in the operating system. Accordingly, in response to the request to display the page, the terminal determines whether there is a widget associated with the page in the widget process by executing a query command. If there is a widget associated with the page in the widget process, the widget is determined to be the widget mounted on the page.

[0056] 202. Based on the widget, the terminal sends the widget data of the widget to a page process corresponding to the page in the operating system through the widget process of the operating system. The page process is used to process data associated with the page.

[0057] In the embodiment of the present application, the terminal sends the widget data from the widget process to the page process through cross-process communication between the widget process and the page process.

[0058] Among them, the operating system (OS) is the underlying software in the terminal, which is used to manage terminal resources and provide basic services for various applications. Among them, resources include at least memory and disk. The terminal can create and delete processes through the operating system, and perform data communication and data synchronization between processes. In addition, the terminal creates, deletes, reads and modifies files through the operating system, and provides various user interfaces through the operating system for users to interact with the terminal.

[0059] Among them, the widget process in the operating system can perform various types of data processing associated with the widget, including at least data acquisition, data analysis, data management, and inter-process communication (IPC) for the widget. Widget data refers to data related to widget installation and widget display. For example, widget data includes data used to build a widget view in a page and data in response to user interactions. The page process in the operating system can perform various types of data processing associated with the page, including at least data acquisition, page updates, and inter-process communication for the page. The terminal updates the page through the page process by displaying the component view in the page and updating the page in response to the user's interactions.

[0060] 203. The terminal displays the widget on the page through the page process.

[0061] In an embodiment of the present application, when the page process receives widget data, the terminal displays a view of the widget in the page based on the widget data, and updates elements associated with the widget in the page in response to user interaction with the view of the widget.

[0062] The embodiment of the present application provides a widget display method, in which the terminal can transmit widget data through data communication between the widget process and the page process in the operating system, and then display the widget in the terminal page. In the case where the page is mounted with a widget, the above method controls the display of the widget in the page through the operating system, which can avoid problems such as confusion of interactive logic and mutual interference of functions caused by the coexistence of widgets of multiple applications, thereby ensuring the smoothness of the user experience and improving the efficiency of users obtaining information from the page.

[0063] Above Figure 2 This is a process of displaying a widget in this application. Figure 3 is a flowchart of another widget display method provided in an embodiment of the present application. The method is executed by the terminal, see Figure 3 , the method comprising:

[0064] 301. In response to a confirmation installation operation of a widget in a widget management center, a widget identifier of the widget and a page associated with the widget are determined through a widget process.

[0065] In an embodiment of the present application, the widget management center may be a widget mall type application, which is used to manage multiple widgets that can be displayed on a page; the widget management center may also be a widget function module in an application, which is used to manage widgets related to a certain application. Usually, multiple widgets are displayed in the widget management center. For ease of description, the widget management center may be referred to as a host, and the widget may also be referred to as a page plug-in. The widget identifier is a unique identifier used to identify and reference a widget. In the process of cross-process communication, the widget identifier is used to transfer information about the widget between different processes. The page associated with the widget refers to the display page of the widget, that is, the page used to mount the widget.

[0066] In some embodiments, the terminal can implement the process of determining the widget identifier of the widget and the page associated with the widget by any one of the following methods: method 1, method 2, and method 3.

[0067] Method 1: In response to the widget installation confirmation operation in the widget management center, the terminal determines the widget identification of the widget; when the widget identification is associated with a preset display page, the terminal determines the preset display page as the page associated with the widget.

[0068] In the above method, since the preset display page of the widget already exists, there is no need to select the widget-associated page again during the widget installation process. Through the above method, the widget installation efficiency is improved, and the human-computer interaction efficiency is improved.

[0069] Method 2: In response to the installation confirmation operation of the widget in the widget management center, the terminal determines the widget identifier of the widget; when the widget identifier is not associated with a preset display page, the terminal displays a selection page, which is used to display multiple alternative pages; in response to the selection operation of any alternative page in the selection page, the terminal determines the alternative page as the page associated with the widget.

[0070] In the above method, the terminal provides a function of selecting a page associated with the widget. Through the above method, the flexibility is higher, which is conducive to meeting diverse needs and improving the efficiency of human-computer interaction.

[0071] Mode three: in response to entering the widget management center from any page, the terminal determines the page as a page associated with the widget; in response to confirming the installation operation of the widget in the widget management center, the terminal determines the widget identifier of the widget.

[0072] In the above method, the terminal determines the page before entering the widget management center as the widget-related page, so that the widget-related page does not need to be selected again during the widget installation process. Through the above method, the widget installation efficiency is improved and the human-computer interaction efficiency is improved.

[0073] In some embodiments, the pendant includes a pendant main body portion and at least one pendant additional portion, and the pendant additional portion is a hideable portion associated with the pendant main body portion.

[0074] Optionally, the installation confirmation operation may include an operation of selecting a pendant and an operation of confirming the pendant; it may also include an operation of selecting a pendant, an operation of adjusting an additional part of the pendant, and an operation of confirming the adjusted pendant.

[0075] Accordingly, in response to a selection operation on any widget in the widget management center, the terminal displays the widget main body and the preset widget additional parts of the widget; in response to an adjustment operation on the preset widget additional parts, the terminal displays the widget consisting of the adjusted widget additional parts and the widget main body; in response to a confirmation operation on the widget, the terminal starts executing steps in response to confirming the installation operation.

[0076] It should be noted that by presetting the widget into a main part and an additional part, the widget function is more modularized, which facilitates widget management and expansion. The terminal meets the diverse needs of users and improves the efficiency of human-computer interaction by providing an adjustment method for the additional part of the widget.

[0077] It should be noted that the embodiments of the present application do not limit the functions implemented by the main part of the widget and the additional part of the widget. For example, when the main part of the widget is used to indicate the operating system level, the additional part of the widget can correspond to basic applications in the operating system such as a flashlight, photo album, and calculator, and the additional part of the widget can also correspond to a variety of third-party applications. Or when the main part of the widget corresponds to an application, the additional part of the widget can be used to indicate a variety of functional modules in the application. No further description or limitation is given here.

[0078] Among them, both the main part of the widget and the additional part of the widget support touch interaction, including at least click interaction, long press interaction and drag interaction. Accordingly, when the additional part of the widget is not displayed, the terminal responds to the click operation on the main part of the widget and displays the main part of the widget and the additional part of the widget on the page. Accordingly, when the additional part of the widget is displayed, the terminal responds to the drag operation on the widget and displays the main part of the widget and the additional part of the widget on the page and moves together with the drag operation. It should be noted that when the widget is displayed on different boundaries in the terminal screen, the shape of the widget may not be exactly the same. The terminal optimizes the page layout by displaying or hiding the additional part of the widget in response to the user's interactive operation, and also improves the efficiency of information display and human-computer interaction.

[0079] For the convenience of describing the pendant form, see Figure 4 As shown, Figure 4 is a schematic diagram of a pendant form provided in an embodiment of the present application. Figure 4 As shown in (a), the widget 401 is located at the lower left corner of the page. The "widget body" displayed in the widget 401 is the main part of the widget, and the "menu 1", "menu 2" and "menu 3" displayed in the widget 401 are the additional parts of the widget. In response to the dragging operation of the widget 401 from the lower left corner of the screen to the upper right corner of the screen, the terminal displays the widget 402 at the upper right corner of the page. At this time, the relative positions of the widget main part and the widget additional part change. In other words, the shape of the widget changes.

[0080] 302. When no other widgets are displayed on the page, the terminal generates a widget installation instruction based on the widget identifier of the widget, where the installation instruction is used to instruct to display the widget on the page.

[0081] In the embodiment of the present application, since there are no other widgets in the page, the terminal does not need to process the display logic between different widgets, and the terminal directly generates an installation instruction carrying the widget identifier. In some embodiments, when other widgets are displayed on the page, the terminal generates an installation instruction for the widget based on the widget identifier of the widget and the widget identifier of the widget already in the page, and the installation instruction is used to instruct to replace the existing widget in the page with the widget.

[0082] It should be noted that the terminal responds to the confirmation installation operation in the widget management center, identifies whether other widgets already exist in the page, and automatically generates installation instructions. In the above manner, the terminal not only improves the efficiency of widget installation, but also avoids problems such as confusion in interactive logic and mutual interference of functions caused by displaying widgets of multiple applications on the page at the same time, ensures the uniqueness of widgets displayed on the page, and optimizes the page layout.

[0083] To describe the overall process of installing and displaying widgets in the terminal, see Figure 5 As shown, Figure 5 1 is a schematic diagram of a widget display process provided by an embodiment of the present application. In response to the selection operation of the widget in the host, the terminal confirms that the widget is added to the page. The terminal queries the widget selected by the user and obtains the widget identifier of the widget. The terminal generates an installation instruction through the widget management module to facilitate the subsequent installation of the widget in the terminal.

[0084] 303. In response to the installation instruction for the widget, the terminal obtains the installation package of the widget through the widget process in the operating system based on the widget identifier carried in the installation instruction, parses the installation package of the widget, and obtains the widget data of the widget.

[0085] In an embodiment of the present application, the terminal sends a request to obtain the widget to the server, and receives the installation package of the widget returned by the server based on the request, and then implements the installation process of the widget based on the obtained widget data. At this time, the process of the terminal obtaining the widget data is the process of downloading the installation package. Accordingly, developers can make widgets separately and upload the installation packages of the widgets to the server corresponding to the widget management center, so that other clients can obtain the installation packages of the widgets from the server. The server is a storage server corresponding to the widget management center, which is used to store various data associated with the widget management center.

[0086] Optionally, the above step 302 is only an exemplary description of the terminal determining the widget data of the widget. In the case where the widget has been installed in the terminal in the past, the terminal can directly select the widget data of the widget in the local storage space without obtaining the installation package of the widget from the server again. At this time, the process of the terminal obtaining the widget data is the process of selecting the widget data. It should be noted that the process of installing and displaying the widget in the terminal is managed by the operating system.

[0087] It should be noted that the terminal can accurately locate and process the widgets confirmed to be installed by the user through the above method, making the installation and management process of the widgets more efficient and automated. At the same time, the installation and data loading of the widgets are managed through the widget process in the operating system, so that the operating system can formulate unified standards for the widgets and perform more stringent security checks and permission controls, which can not only avoid problems such as confusion in interactive logic caused by the simultaneous display of controls of multiple applications, but also improve overall security. In addition, the terminal obtains and parses the installation package through the widget process, thereby dynamically loading the widget data, which not only improves the flexibility of widget installation, but also facilitates the operating system to update or replace the widget, thereby improving the efficiency of widget management.

[0088] To facilitate the description of the process of the terminal obtaining the widget data, see Figure 5As shown. Among them, in the process of installing the widget, the terminal determines the widget selection information according to the installation instruction of the widget, that is, the terminal generates the installation instruction based on the user's selection operation to determine whether the existing widget in the page needs to be replaced or the new widget needs to be displayed in the page. Based on the widget identifier carried by the installation instruction, the terminal obtains the installation package corresponding to the widget and installs it to obtain the widget data of the widget. It should be noted that the developer can write the widget file and enable the terminal to automatically generate the widget installation package, and then put the widget installation package on the widget management center, that is, upload the widget installation package to the server corresponding to the host, which will not be elaborated here.

[0089] 304. The terminal determines that the widget is mounted on the page in response to a display request for the page associated with the widget.

[0090] In the embodiment of the present application, the process of the terminal determining whether a widget is mounted on a page is the same as the above step 201 and will not be repeated here.

[0091] 305. Based on the widget, the terminal sends the widget data of the widget to the page process corresponding to the page in the operating system through the widget process of the operating system. The page process is used to process the data associated with the page.

[0092] In the embodiment of the present application, the process of the terminal performing cross-process communication is the same as the above step 202 and will not be repeated here.

[0093] 306. The terminal loads the view data and event data in the widget data through the page process.

[0094] In the embodiment of the present application, the widget data includes at least view data and event data, wherein the view data refers to the data used to construct the view object of the widget in the page; the event data refers to the data used to respond to the user's interactive operation, etc.

[0095] 307. The terminal displays the view object of the widget in the widget layer of the page based on the view data and the event data. The widget layer is a transparent layer for responding to various operations corresponding to the event data.

[0096] In an embodiment of the present application, the widget layer is a widget container layer (ViewGroup), which can also be called a view container. In response to a new operation on the widget container layer, the terminal displays the newly added widget container layer in the native page of the operating system. Among them, the operating system is usually a native Android system. The widget container layer refers to a container component used to organize and manage view objects in the operating system. It should be noted that the background of the widget container layer is transparent, and the widget container layer is displayed above the container layer where information such as time and weather is located. The widget container layer is a carrier of widgets, and is used to respond to various operations corresponding to event data.

[0097] It should be noted that the above steps 305 and 306 are only an exemplary description of the view object of the terminal display widget. The terminal separates the view data and event data of the widget, making the display logic and user interaction logic of the widget clearer, and improving the flexibility of widget development and widget display. At the same time, the view data and event data are processed by the page process in the operating system to achieve data standardization and uniformity. When updating existing widgets or replacing new widgets, the widgets customized based on the standard of the operating system can better achieve docking with the page process, improving the uniformity of the widget's interactive experience and improving overall stability.

[0098] To facilitate the description of the process of displaying the view object of the terminal widget, see Figure 5 As shown. In the case where the terminal obtains the widget data through the widget process, the terminal performs cross-process communication and sends the widget data to the page process. The terminal loads the widget data through the page process and adds the widget view object to the widget container layer through the page process.

[0099] For the convenience of describing widget layers, see Figure 6 As shown, Figure 6 601 is a schematic diagram of a widget layer provided by an embodiment of the present application, wherein 601 is a container layer where information such as time and weather are located, 602 is a container layer where the widget is located, and 603 is a widget. 602 is displayed above 601, and the background is transparent.

[0100] The embodiment of the present application provides a widget display method, in which the terminal can transmit widget data through data communication between the widget process and the page process in the operating system, and then display the widget in the terminal page. In the case where the page is mounted with a widget, the above method controls the display of the widget in the page through the operating system, which can avoid problems such as confusion of interactive logic and mutual interference of functions caused by the coexistence of widgets of multiple applications, thereby ensuring the smoothness of the user experience and improving the efficiency of users obtaining information from the page.

[0101] It should be noted that, for the installation package of the widget obtained by the terminal in the above embodiment, this embodiment proposes a method for making an installation package without writing code. Figure 7 As shown, Figure 7 This is a flowchart of a method for making a widget installation package provided in an embodiment of the present application. The method is executed by a terminal, see Figure 7 , the method comprising:

[0102] 701. The terminal obtains a template program, where the template program is used to define a standard communication interface between the widget process and the page process.

[0103] In the embodiment of the present application, the template program is used to assist in cross-process communication within the operating system, so as to realize cross-process transmission of widget data. At the same time, the template program is used to realize the process of displaying the view object of the widget in the page together with the target control. Among them, the target control refers to SurfaceView (surface view). The target control is used to add the view object of the widget in the widget layer.

[0104] 702. The terminal generates a plurality of intermediate project files based on the widget file and the template program through an annotation processing method. The widget file includes a widget script and a widget material.

[0105] In the embodiment of the present application, the terminal adopts the annotation processing method, which means that the terminal uses an annotation processor (APT, Annotation Processing Tool) to process annotations. The annotation processor is a development tool for scanning and processing annotations. The annotation processor reads the annotations of the template program, and parses the widget file according to the definition and rules of the annotations, so as to automatically generate multiple intermediate project files.

[0106] Among them, the widget file refers to a predefined file that can generate the data required for the page project. The widget file includes a widget script for defining the widget's view and interactive response, as well as materials such as pictures and text required for rendering the widget's view. Among them, the widget script refers to a DSL script written based on a predefined DSL language (Domain Specific Language). DSL language is a programming language designed for specific fields, tasks or problems. Compared with general programming languages ​​(for example, Java, Python, etc.), the syntax and semantics of DSL language are simpler and easier to understand. Among them, widget materials include picture materials, animation materials, text materials, etc., and widget materials are used to compose the view objects of widgets.

[0107] 703. The terminal compiles the plurality of intermediate project files based on the template program to obtain an installation package of the widget.

[0108] In an embodiment of the present application, when the terminal obtains multiple intermediate project files, the terminal uses AAPT (Android Asset Packaging Tool) to process the intermediate project files to obtain the installation package of the widget. Among them, AAPT refers to an application tool for compiling and packaging resources within the Android system. The terminal can compile resource files into a binary format through AAPT, so that the Android system can efficiently load and use the resource files at runtime. It should be noted that in an embodiment of the present application, in addition to the intermediate project files, the resource files may also include other files, and the embodiment of the present application does not limit this. For example, the resource file may include all or part of the files of the intermediate project files and the template program at the same time.

[0109] To facilitate the description of the overall process of generating the installation package of the widget, see Figure 8 As shown, Figure 8 It is a schematic diagram of an installation package generation process provided by an embodiment of the present application. Among them, the terminal obtains a template program, and based on the annotations and annotation processing methods in the template program, parses the widget materials and widget scripts to obtain multiple intermediate project files. The terminal packages the intermediate project files and all or part of the files in the template program through a packaging tool to obtain an installation package for the widget. In other words, the terminal compiles the source files into an executable installation package through a packaging mechanism.

[0110] It should be noted that in the above method, since the template program defines the standard communication interface between the widget process and the page process, the communication between different widgets and between the widgets and the page is more standardized, which not only reduces the complexity and error rate of the development process, but also improves the reusability of the widgets and ensures the uniformity of widget management. At the same time, since the terminal automatically parses and compiles the widget files and generates the corresponding installation package, developers do not need to write code by themselves, but can directly write less professional widget scripts, which improves the widget development efficiency and widget iteration efficiency.

[0111] Above Figure 7 This is a process of a method for making a pendant installation package of the present application. Fig. 9 is a flowchart of another method for making a widget installation package provided in an embodiment of the present application. The method is executed by a terminal, see Fig. 9 , the method comprising:

[0112] 901. The terminal obtains a template program, where the template program is used to define a standard communication interface between a widget process and a page process.

[0113] In the embodiment of the present application, the process of the terminal obtaining the template program is the same as the above step 701 and will not be repeated here.

[0114] 902. The terminal parses the widget file based on the template program through an annotation processing method to obtain a preprocessing file, wherein the preprocessing file includes a reference relationship between the widget script and the widget material.

[0115] In the embodiment of the present application, the terminal parses the widget file according to the annotation in the template program through the annotation processing method. Accordingly, in the process of parsing the widget file according to the annotation in the template program, the terminal can read and parse the reference relationship between the widget script and the widget material.

[0116] In some embodiments, the widget script is not written in a general programming language, but is based on a lightweight DSL language. The DSL language is divided into a three-layer architecture design. The three layers are the rendering layer, the event layer, and the data layer. To facilitate the description of the relationship between the three layers, see Fig.10 As shown, Fig.10 It is a schematic diagram of a multi-level data exchange provided by an embodiment of the present application. Among them, in the data layer, the widget data is divided into two types of data. One type of data is used to construct the view object of the widget, that is, view data; the other type of data is used to respond to the user's interactive operations, that is, event data. For example, view data includes pictures, text, etc. used for view display. Event data includes parameters required for click jump, etc. In the rendering level, the terminal converts view data, etc. into view objects of the user interface. In the event level, the terminal adds response logic for interactive events to the view object. In other words, the view presentation and event interaction of the widget are both implemented based on this lightweight DSL language.

[0117] Among them, each level corresponds to a tag header, and each tag header is associated with multiple tags and attributes. Optionally, the tags and attributes associated with each tag header are basically consistent with the tags and attributes of the native controls in the Android system. Developers can quickly obtain the widget script by assembling tags under each tag header and setting attributes for the tags. In this way, developers can quickly obtain the initial file of the widget without writing code, thereby improving the development efficiency of the widget. For the convenience of describing the tag headers at each level, see Table 1 below.

[0118] Table 1 Various types of label headers

[0119]

[0120] Among them, PendantHost and PendantMenu are both view tags. Data is a data tag. Command is an event. To facilitate the description of various tags and properties associated with PendantHost and PendantMenu, please refer to Table 2 and Table 3. It should be noted that the contents in the following tables are only exemplary descriptions.

[0121] Table 2 Tags associated with PendantHost and PendantMenu

[0122]

[0123]

[0124] Table 3 Properties associated with PendantHost and PendantMenu

[0125] property Attribute meaning layout_width Width of the control layout_height The height of the control src Image source, dedicated to Image component text Text content, dedicated to the Text component background Background of the control

[0126] Among them, the above tags are used to represent the data structure associated with the view display. ViewGroup (widget container) is a special view object in the Android system, which is mainly used to contain and manage other view objects. Through the widget container, multiple subview objects can be placed in a separate layout, and the position, size, display and hiding properties of the subview objects can be controlled. Widget containers are the basis for building the user interface layout structure of the Android system. By combining different ViewGroups and Views, you can create a feature-rich user interface.

[0127] To facilitate the description of various tags and attributes associated with Data, see Table 4 and Table 5. It should be noted that the contents in the following tables are only exemplary.

[0128] Table 4 Data related tags

[0129] Label Label meaning Var variable VarArray Variable arrays ContentProviderBinder Get data across applications

[0130] Table 5 Data related attributes

[0131]

[0132]

[0133] The above tags are used to represent the data structure for data operations, which can indicate mechanisms such as variables, variable arrays, and cross-application data access. At the same time, the above attribute values ​​can specify the details of each data operation, such as variable name, query column, data provider type, query identifier, and query conditions.

[0134] To facilitate the description of various tags and attributes associated with Command, see Table 6 and Table 7. It should be noted that the contents in the following tables are only exemplary.

[0135] Table 6 Command-related tags

[0136] Label Label meaning IntentComand Jump Instructions Extra Carrying parameters

[0137] Table 7 Command-related properties

[0138] property Attribute meaning action Jump behavior attributes category Jump to category packageName The name of the application package to jump to targetClass Jump target class uri Identifier information carried name The name of the key that carries the parameter expression Carry parameter values, also supports expressions type Data type of the value

[0139] The above tags are used to represent the data structure associated with the event response. Intent Comand is used to represent the transmission of messages or requests between different components. Extra is used to represent the carrying of additional data to the target component.

[0140] In some embodiments, the terminal parses and obtains multiple types of attribute tags of the widget. Accordingly, the terminal parses the widget file based on the template program through the annotation processing method to obtain multiple types of attribute tags, and maps the multiple types of attribute tags in the preprocessing file. The multiple types of attribute tags include data tags, event tags, and view tags. It should be noted that the terminal automatically parses and obtains multiple types of attribute tags from the widget script and widget material, making the widget structure clearer and more modular, improving the widget development efficiency, reducing the widget maintenance cost, and improving the widget scalability.

[0141] Among them, data tags are various tags associated with Data. Event tags are various tags associated with Command. Optionally, Command can also be called Event. View tags include tags associated with Pendant Host and PendantMenu. To facilitate the description of the above process, see Fig.11 As shown, Fig.11 This is a schematic diagram of obtaining an intermediate engineering file provided by an embodiment of the present application. Among them, the terminal obtains view tags, data tags, event tags through widget scripts and widget materials, and temporarily stores the above attribute tags. Optionally, the terminal saves the above tags and corresponding attribute values ​​through a data structure (such as Map). The terminal maps the attribute tags in a layout file (such as Layout File) to obtain a preprocessed file.

[0142] 903. The terminal parses the preprocessing file based on the template program through the annotation processing method to generate multiple intermediate project files.

[0143] In an embodiment of the present application, after the terminal obtains the preprocessed file, the terminal processes the preprocessed file based on the annotations and annotation processing method in the template program, and converts the preprocessed file into an intermediate project file that can be read and recognized by the page project of the Android system. The terminal can obtain the intermediate project file more quickly through the combination of the annotation processing method and the template program. At the same time, when it is necessary to add a new widget or adjust an existing widget, it is sufficient to update the annotation or template program without modifying a large number of existing scripts, thereby improving the development efficiency of the widget. It should be noted that the above steps 902 and 903 are only an exemplary description of the terminal generating multiple intermediate project files.

[0144] In some embodiments, multiple intermediate project files are files required for the page project of the operating system. Accordingly, the terminal parses the preprocessed file based on the template program through the annotation processing method to generate a first intermediate file, a second intermediate file, and a third intermediate file. The first intermediate file is the source file required in the page project of the operating system, the second intermediate file is the layout file required in the page project of the operating system, and the third intermediate file is the image material file required in the page project of the operating system. It should be noted that the terminal automatically generates the resources required for the page project of the operating system through the annotation processing method, and the highly modular resource form described above is conducive to the subsequent maintenance and upgrading of the widgets. At the same time, the automatic generation of intermediate files by the terminal reduces the time for manual creation and configuration of configuration files, and improves the efficiency and quality of page development.

[0145] For example, see Fig.11 As shown, when the terminal obtains the layout file, the terminal further processes the layout file to obtain a first intermediate file, a second intermediate file, and a third intermediate file. Optionally, the first intermediate file refers to a material file such as a picture or text placed in a specified folder of the Android system. The second intermediate file refers to an xml layout file required for the Android system project. The third intermediate file refers to a java file that can be recognized by the Android system.

[0146] 904. The terminal compiles the plurality of intermediate project files based on the template program to obtain an installation package of the widget.

[0147] In the embodiment of the present application, the process of the terminal obtaining the installation package of the widget is the same as the above step 703 and will not be repeated here.

[0148] It should be noted that in the above method, since the terminal automatically parses and compiles the widget file and generates the corresponding installation package, the developer does not need to write the code by himself, but can directly write the widget script with less professionalism, which improves the widget development efficiency. At the same time, the terminal supports developers to dynamically update the layout style and interaction logic of the widgets in the widget management center, which improves the efficiency of widget iteration. In addition, the above method enables the collaborative development of applications and operating systems, ensuring the clarity and standardization of the page display logic.

[0149] All the above optional technical solutions can be arbitrarily combined to form optional embodiments of the present application, which will not be described one by one here.

[0150] The following are device embodiments of the present application, which can be used to execute the method embodiments of the present application. For details not disclosed in the device embodiments of the present application, please refer to the method embodiments of the present application.

[0151] Fig.12 is a structural diagram of a pendant display device provided in an embodiment of the present application. Fig.12 The device includes: a determination module 1201, a sending module 1202 and a display module 1203.

[0152] Determining module 1201, used to determine whether a widget is mounted on the page;

[0153] The sending module 1202 is used to send the widget data of the widget to the page process corresponding to the page in the operating system through the widget process of the operating system, and the page process is used to process the data associated with the page;

[0154] The display module 1203 is used to display the widget in the page through the page process.

[0155] In some embodiments, the widget data includes view data and event data;

[0156] Display module 1203 is used to load view data and event data through page process; based on the view data and event data, the view object of the widget is displayed in the widget layer of the page. The widget layer is a transparent layer used to respond to various operations corresponding to the event data.

[0157] In some embodiments, Fig.13 is a structural diagram of another pendant display device provided in an embodiment of the present application, see Fig.13 , the device further comprises:

[0158] The first generating module 1301 is used to generate a widget installation instruction through a widget process, where the installation instruction carries a widget identifier of the widget;

[0159] The parsing module 1302 is used to obtain the installation package of the widget through the widget process, parse the installation package of the widget, and obtain the widget data.

[0160] In some embodiments, the first generation module 1301 is used to respond to the confirmation installation operation of any widget in the widget management center, determine the widget identifier of the widget and the page associated with the widget through the widget process; when other widgets are displayed on the page, generate the widget installation instruction based on the widget identifier of the widget and the widget identifiers of other widgets, and the installation instruction is used to instruct to replace other widgets with the widget; when no other widgets are displayed on the page, generate the widget installation instruction based on the widget identifier of the widget, and the installation instruction is used to instruct to display the widget on the page.

[0161] In some embodiments, the apparatus further comprises:

[0162] The second generation module 1303 is used to generate multiple intermediate project files based on the widget file and the template program through the annotation processing method. The template program is used to define the standard communication interface between the widget process and the page process. The widget file includes the widget script and the widget material.

[0163] The compiling module 1304 is used to compile multiple intermediate project files based on the template program to obtain the installation package of the widget.

[0164] In some embodiments, the second generating module 1303 further includes:

[0165] The first parsing unit 13031 includes parsing the widget file based on the template program through an annotation processing method to obtain a pre-processing file, wherein the pre-processing file includes a reference relationship between the widget script and the widget material;

[0166] The second parsing unit 13032 includes parsing the pre-processing file based on the template program through the annotation processing method to generate multiple intermediate project files.

[0167] In some embodiments, the first parsing unit 13031 is used to parse the widget file based on the template program through an annotation processing method to obtain multiple types of attribute tags, and map the multiple types of attribute tags in a preprocessing file. The multiple types of attribute tags include data tags, event tags, and view tags.

[0168] In some embodiments, the second parsing unit 13032 is used to parse the preprocessed file based on the template program through the annotation processing method to generate a first intermediate file, a second intermediate file and a third intermediate file. The first intermediate file is the source file required in the page project of the operating system, the second intermediate file is the layout file required in the page project of the operating system, and the third intermediate file is the image material file required in the page project of the operating system.

[0169] The embodiment of the present application provides a widget display device, which can transmit widget data through data communication between the widget process and the page process in the operating system, and then display the widget in the terminal page. When the page is mounted with a widget, the above-mentioned device controls the display of the widget in the page through the operating system, which can avoid the problems of interaction logic confusion and mutual interference of functions caused by the coexistence of widgets of multiple applications, thereby ensuring the smoothness of the user experience and improving the efficiency of users obtaining information from the page.

[0170] It should be noted that the pendant display device provided in the above embodiment, when realizing its functions, only uses the division of the above functional modules as an example. In actual applications, the above functions can be assigned to different functional modules as needed, that is, the internal structure of the terminal is divided into different functional modules to complete all or part of the functions described above. In addition, the pendant display device provided in the above embodiment and the pendant display method embodiment belong to the same concept, and the specific implementation process is detailed in the method embodiment, which will not be repeated here.

[0171] An embodiment of the present application provides a terminal, which includes a processor and a memory; the memory stores at least one program code, and the at least one program code is used to be executed by the processor to implement the widget display method provided by the above-mentioned various method embodiments.

[0172] Fig.14 14 is a block diagram of a terminal provided in an embodiment of the present application. In some embodiments, the terminal 1400 is a terminal such as a smart phone, a tablet computer, a wearable device, etc. that can access a wireless local area network as a wireless station. The terminal 1400 in the present application includes at least one or more of the following components: a processor 1410, a memory 1420, and at least two wireless links 1430.

[0173] In some embodiments, the processor 1410 includes one or more processing cores. The processor 1410 uses various interfaces and lines to connect various parts of the entire terminal 1400, and executes various functions and processes data of the terminal 1400 by running or executing program codes stored in the memory 1420, and calling data stored in the memory 1420. In some embodiments, the processor 1410 is implemented in at least one hardware form of digital signal processing (DSP), field-programmable gate array (FPGA), and programmable logic array (PLA). The processor 1410 can integrate one or more combinations of central processing unit (CPU), graphics processing unit (GPU), neural network processor (NPU), modem, etc. Among them, the CPU mainly processes the operating system, user interface, and application programs; the GPU is responsible for rendering and drawing the content to be displayed on the display screen; the NPU is used to implement artificial intelligence (AI) functions; and the modem is used to process wireless communications. It is understandable that the above-mentioned modem may not be integrated into the processor 1410, but may be implemented by a separate chip.

[0174] In some embodiments, the processor 1410 is used to control the working conditions of at least two wireless links 1430. Accordingly, the processor 1410 is a processor integrated with a wireless fidelity (Wireless Fidelity, Wi-Fi) chip. The Wi-Fi chip is a chip with dual Wi-Fi processing capabilities. For example, the Wi-Fi chip is a dual-band dual concurrent (Dual Band Dual Concurrent, DBDC) chip, or a dual-band synchronous (Dual Band Simultaneous, DBS) chip, etc.

[0175] In some embodiments, the memory 1420 includes a random access memory (RAM), and in some embodiments, the memory 1420 includes a read-only memory (ROM). In some embodiments, the memory 1420 includes a non-transitory computer-readable storage medium. The memory 1420 can be used to store program codes. The memory 1420 may include a program storage area and a data storage area, wherein the program storage area may store instructions for implementing an operating system, instructions for at least one function (such as a touch function, a sound playback function, an image playback function, etc.), instructions for implementing the following various method embodiments, etc.; the data storage area may store data created according to the use of the terminal 1400 (such as audio data, a phone book), etc.

[0176] In some embodiments, the memory 1420 stores reception schemes for receiving beacon frames of different wireless links 1430, as well as identifiers of access nodes connected to different wireless links 1430, identifiers of wireless links 1430, and the like.

[0177] The at least two wireless links 1430 are used to connect different access points (APs) to receive downlink data sent by the APs, wherein the different access points are access points in the same router or access points in different routers.

[0178] In some embodiments, the terminal 1400 also includes a display screen. The display screen is a display component for displaying a user interface. In some embodiments, the display screen is a display screen with a touch function, through which the user can use any suitable object such as a finger or a touch pen to perform touch operations on the display screen. In some embodiments, the display screen is generally arranged on the front panel of the terminal 1400. In some embodiments, the display screen is designed to be a full screen, a curved screen, a special-shaped screen, a double-sided screen or a folding screen. In some embodiments, the display screen is also designed to be a combination of a full screen and a curved screen, a combination of a special-shaped screen and a curved screen, etc., which is not limited in this embodiment.

[0179] In addition, those skilled in the art will appreciate that the structure of the terminal 1400 shown in the above figures does not limit the terminal 1400, and the terminal 1400 includes more or fewer components than shown in the figure, or combines certain components, or arranges components differently. For example, the terminal 1400 also includes components such as a microphone, a speaker, an input unit, a sensor, an audio circuit, a module, a power supply, and a Bluetooth module, which will not be described in detail here.

[0180] The present application also provides a computer-readable storage medium, which stores at least one program code, and the at least one program code is loaded and executed by the processor to implement the widget display method shown in the above embodiments.

[0181] The present application also provides a chip, which includes a programmable logic circuit and / or program instructions. When the chip runs on a terminal, it is used to implement the widget display method shown in the above embodiments.

[0182] The present application also provides a computer program product, which stores at least one program code, and the at least one program code is used to be executed by a processor to implement the widget display method shown in the above embodiments.

[0183] The serial numbers of the above-mentioned embodiments of the present application are for description only and do not represent the advantages or disadvantages of the embodiments.

[0184] Those skilled in the art can understand that all or part of the steps in the method for displaying the pendant in the above embodiment can be completed by hardware, or by a program to instruct the relevant hardware to complete the steps. The program can be stored in a computer-readable storage medium, and the storage medium mentioned above can be a read-only memory, a disk or an optical disk, etc. The above are only optional embodiments of the present application and are not intended to limit the present application. Any modifications, equivalent substitutions, improvements, etc. made within the spirit and principles of the present application shall be included in the protection scope of the present application.

Claims

1. A method for displaying a pendant, characterized in that: The method comprises: Make sure the page has widgets installed; Sending the widget data of the widget to the page process corresponding to the page in the operating system through the widget process of the operating system, wherein the page process is used to process the data associated with the page; The widget is displayed on the page through the page process.

2. The method according to claim 1, characterized in that: The widget data includes view data and event data; and displaying the widget on the page through the page process includes: Loading the view data and the event data through the page process; Based on the view data and the event data, the view object of the widget is displayed in the widget layer of the page, and the widget layer is a transparent layer for responding to various operations corresponding to the event data.

3. The method according to claim 1, characterized in that The step of obtaining the widget data comprises: Generate an installation instruction of the widget through the widget process, wherein the installation instruction carries a widget identifier of the widget; The installation package of the widget is obtained through the widget process, and the installation package of the widget is parsed to obtain the widget data.

4. The method according to claim 3, characterized in that The step of generating the installation instruction of the widget through the widget process includes: Determining, through the widget process, a widget identifier of the widget and a page associated with the widget; In the case where other widgets are displayed on the page, generating an installation instruction for the widget based on the widget identifier of the widget and the widget identifiers of the other widgets, wherein the installation instruction is used to instruct to replace the other widget with the widget; In the case that no other widgets are displayed on the page, an installation instruction of the widget is generated based on the widget identifier of the widget, and the installation instruction is used to instruct to display the widget on the page.

5. The method according to claim 3, characterized in that: The steps of making the installation package of the pendant include: Generate multiple intermediate project files based on the widget file and the template program through the annotation processing method, wherein the template program is used to define the standard communication interface between the widget process and the page process, and the widget file includes a widget script and a widget material; Based on the template program, the multiple intermediate project files are compiled to obtain the installation package of the widget.

6. The method according to claim 5, characterized in that The annotation processing method generates multiple intermediate project files based on the widget file and the template program, including: By means of the annotation processing method, the widget file is parsed based on the template program to obtain a preprocessing file, wherein the preprocessing file contains a reference relationship between the widget script and the widget material; Through the annotation processing method, the preprocessing file is parsed based on the template program to generate the multiple intermediate project files.

7. The method according to claim 6, characterized in that The method of parsing the widget file based on the template program through the annotation processing method to obtain a preprocessed file includes: Through the annotation processing method, the widget file is parsed based on the template program to obtain multiple types of attribute tags, which are mapped in the preprocessing file. The multiple types of attribute tags include data tags, event tags, and view tags.

8. The method according to claim 6, characterized in that The method of parsing the preprocessing file based on the template program through the annotation processing method to generate the plurality of intermediate project files includes: Through the annotation processing method, the preprocessing file is parsed based on the template program to generate a first intermediate file, a second intermediate file and a third intermediate file. The first intermediate file is the source file required in the page project of the operating system, the second intermediate file is the layout file required in the page project of the operating system, and the third intermediate file is the image material file required in the page project of the operating system.

9. A terminal, characterized in that: The terminal includes a processor and a memory; the memory stores at least one program code, and the at least one program code is used to be executed by the processor to implement the widget display method according to any one of claims 1 to 8.

10. A computer program product, comprising a computer program, characterized in that The computer program product stores at least one program code, and the at least one program code is used to be executed by a processor to implement the widget display method according to any one of claims 1 to 8.