A card display method, an electronic device and a computer readable storage medium
By generating the card frame in advance during the power-on process of the electronic device and displaying it when unlocking, the problem of slow card loading speed after unlocking the electronic device is solved, thus improving the user experience.
Patent Information
- Application Number
- CN202410246005.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-02-29
- Publication Date
- 2025-11-21
- Estimated Expiration
- 2044-02-29
AI Technical Summary
In existing technologies, electronic devices are slow to load third-party application cards after unlocking, resulting in a poor user experience.
During the power-on process of electronic devices, the card frame is generated in advance and displayed directly upon unlocking, avoiding the need to generate the frame after unlocking.
It speeds up card loading and display, reduces user waiting time, and improves user experience.
Smart Images

Figure CN119248390B_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The present application relates to the technical field of terminal, and in particular, to a card display method, an electronic device and a computer readable storage medium. BACKGROUND
[0002] A card corresponding to a third-party application (TPA) can be displayed in the desktop of a smart terminal. Through the card, content related to the third-party application can be presented to the user (for example, a card corresponding to a news-type third-party application can display key information such as news information of the day), so as to facilitate the user to quickly obtain the content related to the third-party application in the fragmented time without opening the third-party application.
[0003] At present, the electronic device loads and displays the card corresponding to the third-party application after unlocking. In this card display scheme, the loading speed of the card is slow, which leads to a long time for presenting the card corresponding to the third-party application in the desktop of the electronic device, and further leads to a poor user experience. SUMMARY
[0004] The present application provides a card display method, an electronic device and a computer readable storage medium, which can generate the frame of the card in advance before the electronic device is unlocked, thereby accelerating the display speed of the card in the case of unlocking the electronic device, further shortening the waiting time of the user in the case of unlocking the electronic device, and improving the user experience.
[0005] In a first aspect, the present application provides a card display method, which is applied to an electronic device, and the electronic device is installed with a first application and a second application, and the first application and the second application are different applications; the method comprises the following steps:
[0006] receiving a first instruction, and the electronic device performs a power-on operation;
[0007] starting a first process in the process of powering on the electronic device; the first process is a process corresponding to the first application;
[0008] obtaining first information based on the first process; the first information is used to represent a page layout related to the display of the first card; the first card is a to-be-displayed card corresponding to the second application;
[0009] generating a first frame based on the first information; the first frame is a widget frame used when the first card is displayed in the first application;
[0010] displaying a first interface in the case of unlocking the electronic device; the first interface comprises a first display area, and the first display area at least comprises the first card; the first card adopts the first frame.
[0011] The application can enable the electronic device to perform a boot operation by receiving the first instruction. In the process of booting the electronic device, the process corresponding to the first application, i.e., the first process, can be started. On this basis, the first information, i.e., the page layout related to the display of the first card, is obtained based on the first process, and the first information can be obtained in advance before the electronic device is unlocked. Further, based on the obtained first information, the first frame is generated, and the first frame can be generated in advance before the electronic device is unlocked. Further, in the case that the electronic device is unlocked, the first interface can be displayed, and the first card using the first frame can be directly displayed in the first interface, without generating the first frame in the case that the electronic device is unlocked. Thus, the user can view the frame of the card corresponding to the application without waiting for the electronic device to be unlocked, saving the time for the user to wait for the display of the frame of the card in the case that the electronic device is unlocked, thereby accelerating the loading speed and display speed of the card in the case that the electronic device is unlocked, further shortening the time for the user to wait for the display of the complete card after the electronic device is unlocked, and improving the user experience.
[0012] In some possible implementation manners, in the case that the electronic device is unlocked, the first interface is displayed, including:
[0013] In the case that the electronic device is unlocked, the second process is started; the second process is a process corresponding to the second application;
[0014] The second information is obtained based on the second process; the second information is used to represent the content to be displayed in the second application;
[0015] The second interface is displayed; the second interface includes a second display area, and the second display area at least includes the first card, and the content displayed in the first card is generated based on the second information.
[0016] In the above implementation manners, in the case that the electronic device is unlocked, the second process is started, and then the electronic device can obtain the second information through the second process; further, the electronic device can generate the content displayed in the first card based on the second information, and display the content displayed in the first card in the second display area of the second interface. As can be seen, in the case that the electronic device is unlocked, the first card can directly use the first frame generated in advance before the electronic device is unlocked, without generating the first frame. The electronic device can generate the content displayed in the first card based on the display of the first frame, and display the first card on the second interface. Thus, the loading speed and display speed of the card in the case that the electronic device is unlocked are accelerated, and the user experience is improved.
[0017] In some possible implementation manners, before the second interface is displayed, the method further includes:
[0018] In a case where the display content of the first card is empty content or preset content, the content in the first card is refreshed based on the second information.
[0019] In the above implementation, before the process of the second application corresponding to the first card (i.e., the second process) is started, the display content of the first card can be empty content or preset content, which can facilitate the electronic device to refresh (or update) the empty content or the preset content to content (such as real-time push content) in the second application based on the second information after the second process is started.
[0020] In some possible implementation, before the first information is acquired based on the first process, the method further includes:
[0021] The first application is authenticated based on preset authentication information, and the preset authentication information includes a preset signature and / or a preset package name.
[0022] The first information is acquired based on the first process, including:
[0023] The first information is acquired based on the first process in a case where the first application passes the authentication.
[0024] In the above implementation, by authenticating the first application, it is ensured that the application program (such as the first application) with high permission in the electronic device can acquire the first information in a case where the electronic device is not unlocked, and the security of acquiring the first information is ensured.
[0025] In some possible implementation, the first application is authenticated based on preset authentication information, including:
[0026] It is determined whether the signature of the first application is same as a preset signature.
[0027] And / or, it is determined whether the package name of the first application is same as a preset package name.
[0028] In the above implementation, multiple authentication manners are provided, and the first application is authenticated from multiple aspects, and the security of acquiring the first information is further ensured.
[0029] In some possible implementation, before the first application is authenticated, the method further includes:
[0030] The value of a first variable is acquired.
[0031] In a case where the value of the first variable is a first logical value, the authentication is started.
[0032] In the implementation manner, the trigger condition of identity authentication is set, and the electronic device starts identity authentication only when the value of the first variable is the first logic value, so that the electronic device can be prevented from starting identity authentication in a scenario where identity authentication is not needed.
[0033] In some possible implementation manners, before the value of the first variable is acquired, the method further includes:
[0034] determining whether the electronic device is in a locked state;
[0035] acquiring the value of the first variable, including:
[0036] acquiring the value of the first variable in a case where the electronic device is in the locked state.
[0037] In the implementation manner, the trigger condition of acquiring the value of the first variable is set as the electronic device being in the locked state, so that it can be ensured that the first frame is generated before the electronic device is unlocked.
[0038] In some possible implementation manners, the electronic device further includes a card management service and a task management service; and in a case where the electronic device is unlocked, the second process is started, including:
[0039] in a case where the electronic device is unlocked, sending, by the card management service, the first broadcast signal to the task management service;
[0040] starting, by the task management service, the second process upon receiving the first broadcast signal.
[0041] In the implementation manner, in a case where the electronic device is unlocked, the electronic device can receive the first broadcast signal sent by the card management service through the task management service to start the second process, so as to prepare for generating the display content of the first card.
[0042] In some possible implementation manners, the second information is acquired based on the second process, including:
[0043] receiving, by the second process, the second broadcast signal, and generating a second instruction based on the second broadcast signal; the second instruction includes the second information;
[0044] receiving, by the first process, the second instruction from the second process, and analyzing the second instruction to obtain the second information.
[0045] In the implementation manner, the electronic device can receive the second broadcast signal sent by the card management service through the second process; further, the second process can generate the second instruction based on the second broadcast signal; and further, the electronic device analyzes the second instruction from the second process through the first process to obtain the second information, so as to provide a data basis for updating the display content of the card.
[0046] In some possible implementation manners, before displaying the first interface, the method further includes:
[0047] In response to a first operation of the user, the electronic device performs an unlocking operation; the first operation is used to trigger the electronic device to switch from a lock screen state to an unlocked state.
[0048] In some possible implementation manners, the first information is obtained based on the first process, including:
[0049] The database is queried by the first process to obtain the first information, and the database stores the related information of the to-be-displayed card corresponding to the second application.
[0050] In the implementation manners described above, the electronic device can obtain the first information stored in the database by querying the database through the first process, thereby providing a data basis for subsequent generation of the first frame.
[0051] In some possible implementation manners, the first information is obtained based on the first process, and the method further includes:
[0052] The third instruction is received by the first process, and the first information is obtained by analyzing the third instruction.
[0053] In the implementation manners described above, the electronic device can obtain the third instruction by querying the database through the first process. The third instruction includes the first information obtained from the database. On this basis, the electronic device can analyze the third instruction to obtain the first information, thereby providing a data basis for subsequent generation of the first frame.
[0054] In some possible implementation manners, the first information includes one or more of the following: a position of the first card displayed in the first application, a size of the first card, a style of the first card, and a package name of the second application.
[0055] In the implementation manners described above, the application program (for example, the second application) corresponding to the first card can be determined through the first information, thereby preparing for subsequent generation of the display content of the first card.
[0056] In some possible implementation manners, the first application is a desktop application in a system application program; and the second application is a third-party application program.
[0057] In some possible implementation manners, the first instruction is received, and the electronic device performs a power-on operation, including:
[0058] The first instruction is received in response to a second operation of the user, and the electronic device performs a power-on operation based on the received first instruction.
[0059] In the implementation manner, the first information can be acquired in advance before the electronic device is unlocked by performing the power-on operation, and the first frame is generated in advance based on the acquired first information, thereby providing a secure running environment.
[0060] In a second aspect, the present application provides an electronic device, which comprises one or more processors and a memory; the memory is coupled to the one or more processors, and is configured to store computer program codes, the computer program codes comprising computer instructions; the one or more processors are configured to invoke the computer instructions to enable the electronic device to perform the card display method in the first aspect and any possible design of the first aspect.
[0061] In a third aspect, the present application provides a chip system, which is applied to an electronic device; the chip system comprises one or more processors; the one or more processors are configured to invoke computer instructions to enable the electronic device to perform the card display method in the first aspect and any possible design of the first aspect.
[0062] In the chip system, one chip can be included, or a plurality of chips can be included; when the chip system includes a plurality of chips, the type and number of the chips are not limited.
[0063] In a fourth aspect, the present application provides a computer readable storage medium, which comprises instructions; when the instructions are run on an electronic device, the electronic device is enabled to perform the card display method in the first aspect and any possible design of the first aspect.
[0064] In a fifth aspect, the present application provides a computer program product, which is enabled to perform the card display method in the first aspect and any possible design of the first aspect when the computer program product is run on a computer.
[0065] It can be understood that the beneficial effects of the second aspect to the fifth aspect can be referred to the related description in the first aspect, and will not be repeated here. BRIEF DESCRIPTION OF DRAWINGS
[0066] In order to more clearly illustrate the technical solutions in the embodiments of the present application, the drawings needed in the embodiments or prior art description will be briefly introduced. Obviously, the drawings in the following description are only some embodiments of the present application, and other drawings can be obtained by those skilled in the art without creative labor.
[0067] Figure 1 An application scenario diagram of a card display method provided by an embodiment of the present application is shown in the following figure.
[0068] Figure 2A schematic diagram of the principle of a card display method provided by an embodiment of the present application is shown in FIG. 1.
[0069] Figure 3 A schematic diagram of the application of a card display method provided by an embodiment of the present application is shown in FIG. 2.
[0070] Figure 4 A schematic diagram of the application of a card display method provided by an embodiment of the present application is shown in FIG. 2.
[0071] Figure 5 A schematic diagram of the hardware system of an electronic device provided by an embodiment of the present application is shown in FIG. 3.
[0072] Figure 6 A schematic diagram of the software system of an electronic device provided by an embodiment of the present application is shown in FIG. 4.
[0073] Figure 7 A signaling interaction diagram of a card display method provided by an embodiment of the present application is shown in FIG. 5.
[0074] Figure 8 A signaling interaction diagram of a card display method provided by an embodiment of the present application is shown in FIG. 5.
[0075] Figure 9 A signaling interaction diagram of a card display method provided by an embodiment of the present application is shown in FIG. 5.
[0076] Figure 10 A flowchart of a card display method provided by an embodiment of the present application is shown in FIG. 6.
[0077] Figure 11 A schematic diagram of a card display effect provided by an embodiment of the present application is shown in FIG. 7.
[0078] Figure 12 A flowchart of a card display method provided by an embodiment of the present application is shown in FIG. 6.
[0079] Figure 13 A signaling interaction diagram of a card display method provided by an embodiment of the present application is shown in FIG. 5. DETAILED DESCRIPTION
[0080] The technical solutions in the embodiments of the present application will be described below with reference to the drawings in the embodiments of the present application. In the description of the embodiments of the present application, “ / ” represents the meaning of or unless otherwise specified, for example, A / B can represent A or B; “and / or” in this document only represents a description of the association relationship of the associated objects, which means that there can be three relationships, for example, A and / or B, which means that there are three cases of A alone, A and B together, and B alone. In addition, in the description of the embodiments of the present application, “multiple” means two or more than two.
[0081] The "at" in the embodiments of the present application can be the moment when a certain condition occurs, or a period of time after a certain condition occurs, which is not limited in the embodiments of the present application.
[0082] Hereinafter, the terms "first", "second", "third" are only for descriptive purposes, and cannot be understood as indicating or implying relative importance or implicitly indicating the number of indicated technical features. Therefore, the features defined with "first", "second", "third" can explicitly or implicitly include one or more features.
[0083] In order to introduce the scheme of the embodiments of the present application, the terms or concepts involved in the embodiments of the present application are explained before the embodiments of the present application are introduced.
[0084] 1、widget is a derivative of web2.0, similar to a small application program, which can be applied to the field of electronic devices. "Window widget", "card", "card stack" are all forms of widget, which are used to display various related information, such as text, image, video, button and map. Widget can be displayed in the form of widget card in electronic devices. The widget card is a card component in the electronic device (for example, the electronic device with Android operating system) which can be embedded into other host application (for example, desktop application). The widget card is developed in advance by the provider of the third-party application, and corresponds to the card of the third-party application.
[0085] It should be understood that the third-party application refers to the application developed by external developers or external development companies independent of the operating system developer of the electronic device, which needs to be downloaded and installed in the electronic device by the user. The third-party application can provide specific services for the user.
[0086] It should be noted that the third-party application in the embodiments of the present application can also be referred to as widget APP.
[0087] It should also be understood that the host application refers to the position where the card (including but not limited to widget card) is displayed.
[0088] It should be noted that the host application can also be the negative one screen of the electronic device or the intelligent service assistant in the electronic device, and the embodiments of the present application do not limit this.
[0089] It should also be noted that the desktop application can be referred to as desktop, desktop application or desktop launcher, etc. For ease of description, the embodiments of the present application are collectively referred to as desktop application.
[0090] Optionally, in some embodiments, the widget card can conveniently show the user the push content related to the third-party application, and can also show the content of a certain service in the third-party application. Specifically, the widget card is used to show the content of the third-party application without opening the third-party application. In other words, the display content of the widget card comes from the data provided after the process of the third-party application (or the process of the widget APP) is started. Exemplarily, the display content of the widget card can include pictures, texts, videos, links and the like related to the third-party application, and the embodiments of the present application are not limited thereto.
[0091] Exemplarily, in the case where the third-party application is a travel application, the content displayed by the widget card can be hotel order information, ticket information (e.g., bullet train ticket information and train ticket information, etc.) and the like. The hotel order information can include the user's check-in time, total check-in days and check-out time, etc. The ticket information can include flight number, seat number, departure time and arrival time, etc. The train ticket information can include train number, seat number, departure time and arrival time, etc.
[0092] Optionally, in another embodiment, the widget card can also serve as an operation entrance of the third-party application, so that the user can realize quick control of the third-party application through the widget card. In other words, in response to the user's click or swipe operation on the widget card, the electronic device can open the operation interface of the third-party application corresponding to the widget card, so that the user can perform subsequent operations on the third-party application.
[0093] Exemplarily, when the widget card is a news push card, in response to the user's click operation on the news push card, the electronic device can directly open the news application corresponding to the news push card. At this time, the electronic device can display the operation interface of the news application, so that the user can view the complete content of the news in the operation interface of the news application.
[0094] 2, Negative one screen
[0095] The negative one screen, also known as "-1 screen", refers to the user interface displayed by the electronic device when the main screen (or main interface) of the electronic device is swiped to the left until it is swiped to the leftmost split screen. The negative one screen can include shortcut service functions and messages. Exemplarily, the negative one screen can include a shortcut entrance of a certain application in the electronic device. Alternatively, the negative one screen can also include a widget card corresponding to a certain third-party application.
[0096] It can be understood that the above entering the negative one screen is only exemplary, and the embodiments of the present application are not limited thereto. For example, in response to the user opening the negative one screen in the setting application of the electronic device, the electronic device can enter the negative one screen and display the corresponding user interface.
[0097] The card display method of the embodiments of the present application can be applied to the scenario of optimizing the display of the card set in the electronic device. By obtaining the page layout of the card set in the electronic device when displayed in the first application in advance before the electronic device is unlocked, and generating the frame of the to-be-displayed card (such as the first card) in advance based on the obtained page layout, the frame of the card (such as the first frame) can be directly displayed in the first application of the electronic device when the electronic device is unlocked, thereby accelerating the loading speed and display speed of the card corresponding to the second application (such as the widget card) under the condition that the electronic device is unlocked, greatly shortening the time for the user to wait for the card to be loaded and displayed under the condition that the electronic device is unlocked, and greatly improving the user experience.
[0098] Optionally, in some embodiments, the first application and the second application are applications installed in the electronic device, and the first application and the second application are different applications. The first application can be a host application program of the second application. For example, the first application is a desktop application program in the system application program of the electronic device, and the second application is a third-party application program in the electronic device.
[0099] It should be noted that the first application can also be a negative one screen or the like in other third-party application programs or system application programs other than the second application, and the embodiments of the present application do not limit this.
[0100] It should be further noted that the card set in the electronic device can be one or multiple. Each card (such as the first card) corresponds to a unique application program (such as the second application) installed in the electronic device, that is, each card corresponds to a different application program. In the case that the card set in the electronic device is multiple cards, the multiple cards can be displayed in a tiled manner in the desktop application program of the electronic device, or can be displayed in a stacked manner in the desktop application program of the electronic device, and the embodiments of the present application do not limit this.
[0101] Optionally, in some embodiments, each card includes a frame of the card and display content of the card. The frames of different cards can be the same or different. The display content of different cards is different.
[0102] It should be noted that the shape of any card's frame can be rectangular, rounded rectangle, circle, or square, etc. For example, the size of the card's frame can be 4*2 or 4*4, etc. The content displayed on the card can include images, icons, text, videos, links, and interactive controls, etc. The content displayed on any card can be real-time content from the application corresponding to that card, or it can be key content that the user is interested in from the application corresponding to that card. This application does not impose specific limitations on the card's frame or the content displayed on the card.
[0103] The card display method provided in this application can be applied to electronic devices. Electronic devices can also be referred to as terminals, user equipment (UE), mobile stations (MS), or mobile terminals (MT), etc. Optionally, in some embodiments, the electronic device can be an electronic device with display hardware and corresponding software support. For example, the electronic device can be a mobile phone, foldable screen, smart screen, tablet computer, wearable electronic device, in-vehicle electronic device, augmented reality (AR) device, virtual reality (VR) device, laptop computer, ultra-mobile personal computer (UMPC), netbook, personal digital assistant (PDA), home appliance, projector, etc. This application does not limit the specific type of electronic device.
[0104] Considering that electronic devices may have multiple applications installed (including a host application and other applications besides the host application), in order to allow users to quickly access the content of an application from the host application without opening the specific application, the electronic device can load a card corresponding to that application within the host application. This allows users to quickly access the content of that application and, more importantly, quickly access it through the card set within the host application.
[0105] It should be noted that multiple applications can be system applications or third-party applications installed by the user; this application does not limit this.
[0106] The following is combined with Figures 1 to 3 Taking a mobile phone as an example and a desktop application in the electronic device as a host application, the application scenario of the embodiments of this application will be explained.
[0107] Please see Figure 1, Figure 1 An application scenario of a card display method provided in an embodiment of the present application is shown. In the case where a desktop application, an application 1, an application 2, an application 3 and an application 4 are installed in an electronic device 100, the electronic device 100 can display an interface 11 as shown in (1) of FIG. 1. Figure 1
[0108] Optionally, in some embodiments, the interface 11 is any one of the display interfaces (for example, a main interface) of the desktop application, and the interface 11 can include a card corresponding to each of the plurality of applications. As shown in (1) of FIG. 1, the interface 11 can include a card 101 corresponding to the application 1, a card 102 corresponding to the application 2, a card 103 corresponding to the application 3, and a card 104 corresponding to the application 4. Figure 1
[0109] That is, the electronic device 100 can enable the user to quickly know the relevant content in the application 1 from the desktop application through the card 101 in the interface 11, and also enable the user to quickly access the application 1 from the desktop application. Exemplarily, the application 1 can be a weather application, and the card 101 is a weather card. The application 2 can be a sports health application, and the card 102 is a widget card corresponding to the sports health application. The application 3 can be a memo application, and the card 103 is a widget card corresponding to the memo application. The application 4 can be a news application, and the card 104 is a widget card corresponding to the news application. The embodiments of the present application are not limited in this regard.
[0110] As shown in (1) of FIG. 1, in response to a triggering operation (for example, a long-press operation, etc.) of a control 105 on the electronic device 100 by the user, the electronic device 100 can enter a restart (or, in other words, a reboot) process. Figure 1
[0111] Optionally, in some embodiments, as shown in (1) of FIG. 1, at t0, in response to the restart operation (or, in other words, the triggering operation of the control 105) of the user, the electronic device 100 can restart the system service. In the t0-t1 stage, the electronic device 100 can restart the system service. After the electronic device 100 is restarted, the electronic device 100 can display an interface 12 as shown in (2) of FIG. 1. The interface 12 is a display interface for inputting a password in the electronic device 100. Optionally, in some embodiments, the interface 12 can include a control 106 for inputting an unlocking password of the electronic device 100. Exemplarily, the control 106 can be a soft keyboard. Figure 2 Figure 1
[0112] It should be noted that the unlock password of the electronic device 100 can be set by the user according to actual needs, and this application does not impose any restrictions on it.
[0113] Optionally, in some embodiments, in response to a user's triggering operation on control 106, the desktop application in electronic device 100 may display, as shown in the image. Figure 1 The interface 13 shown in Figure (3) is included. The interface 13 may include video applications, settings applications, camera applications, and phone applications.
[0114] During the restart process of electronic device 100, the device needs to run many tasks, resulting in a high load on the device. This leads to longer card loading times and slower card display. Therefore, the multiple cards set in the desktop application are not directly displayed on the interface 13 after the electronic device 100 is unlocked.
[0115] Optionally, in some embodiments, in response to a user's triggering operation on the control 106, the desktop application in the electronic device 100 can sequentially obtain page layout information related to the frame of each card and generate the corresponding card frame.
[0116] Alternatively, in another embodiment, such as Figure 2 As shown, after the electronic device 100 restarts the system service, it can launch the desktop application process through the system service. That is, during stages t1 to t2, the electronic device 100 can launch the desktop application process through the system service. Furthermore, at time t2, in response to the user's unlock operation (or the trigger operation on control 106), the electronic device 100 can sequentially generate the frame of the card corresponding to each application through the desktop application. That is, during stages t2 to t3, the electronic device 100 can generate the frame of the card displayed in the desktop application.
[0117] The following is combined with Figure 3 Briefly explain the implementation process of the current card display method.
[0118] like Figure 3 As shown, Figure 3 In this code, identifier A represents user operations, identifier B represents operations performed by the desktop application process, identifier C represents operations performed by the card management service, and identifier D represents operations performed by third-party applications.
[0119] Optionally, in some embodiments, in response to a user's unlocking operation (such as...) Figure 3As shown in A1), the electronic device 100 can query the database in the card management service through the process of the desktop application (such as Figure 3 As shown in B1), information related to card display (such as first information) is acquired. After acquiring the information related to card display, the electronic device 100 can generate the frame of the card through the process of the desktop application (such as Figure 3 As shown in B2).
[0120] As shown in response to the user's unlocking operation (such as Figure 3 As shown in A1), the electronic device 100 can send a start broadcast signal (such as Figure 3 As shown in C1) to the third-party application through the card management service. After receiving the start broadcast signal, the electronic device 100 can start the process of the third-party application (such as Figure 3 As shown in D1). After the process of the third-party application is started, the electronic device 100 can send an update broadcast signal (such as Figure 3 As shown in C2) to the third-party application through the card management service. After receiving the update broadcast signal, the electronic device 100 can send a content refresh instruction (such as Figure 3 As shown in D2) to the card management service through the third-party application. Further, the electronic device 100 can pass the content refresh instruction (such as Figure 3 As shown in C3) to the process of the desktop application through the card management service. After receiving the content refresh instruction, the electronic device 100 can update the display content of the card based on the content refresh instruction through the process of the desktop application (such as Figure 3 As shown in B3). Figure 3 It should be noted that,
[0121] The generation process of the card frame (including B1 and B2) and the update process of the display content of the card (including C1, C2, D1, D2, C3 and B3) are completely independent and do not affect each other. That is, the generation process of the card frame and the update process of the display content of the card can be performed at the same time (such as Figure 3 As shown), or the frame of the card can be generated first and the display content of the card can be updated second, or the frame of the card can be generated second and the display content of the card can be updated first. Figure 7 It should also be noted that,
[0122] The specific implementation process of the above can be referred to the description of Figure 8 and Figure 2 below, which will not be repeated here. It can be understood that, Figure 2 Figure 1 t0 < t1 < t2 < t3, and the specific time values of the four time points can be any time when the electronic device 100 is in use, which is not limited in the present application.
[0123] It should be noted that the time point at which the user performs the unlocking operation on the electronic device can be t2, or can be any time point between t2 and t3 after the electronic device 100 starts the process of the desktop application, which is not limited in the present embodiment. Further, if the time point at which the user performs the unlocking operation on the electronic device is any time point between t2 and t3, then Figure 1 The t2 to t3 stage in the above formula is changed to any time point between t2 and t3 to t3. At this time, in the stage of any time point between t2 and t3 to t3, the electronic device 100 can generate the frame of the card displayed in the desktop application.
[0124] For example, the electronic device 100 can first obtain the page layout information related to the frame of the card 103, and generate the frame of the card 103. Further, since the process of the application 3 corresponding to the card 103 has not been started, the display content in the card 103 is empty. At this time, the electronic device 100 can display the interface 14 as shown in (4) of the above formula. Figure 1
[0125] It should be noted that in the case where the process of the application corresponding to the card has not been started, the display content in the card can also be a preset content (or default content) in the electronic device 100, which is not limited in the present embodiment.
[0126] It should be further noted that in the case where the user normally uses the electronic device 100, the user uninstalls the application 4, and then the electronic device 100 does not display the card 104 corresponding to the application 4 after the electronic device 100 is restarted.
[0127] Optionally, in some embodiments, after the desktop application in the electronic device 100 generates the frame of the card corresponding to each application in turn, the electronic device 100 can display the interface 15 as shown in (5) of the above formula. The interface 15 can include the frame of the card 101, the frame of the card 102, the frame of the card 103, and the frame of the card 104, etc. Figure 2
[0128] It is evident that there is a delay between unlocking the electronic device 100 and displaying multiple cards in the desktop application of the electronic device 100. Therefore, when the electronic device 100 is unlocked, it takes a certain amount of time for the frame of each card to be displayed, resulting in a poor user experience as the user has to wait for a certain period of time when the electronic device is unlocked.
[0129] Optionally, in some embodiments, as the process of the application corresponding to each card is launched, the electronic device 100 may display, as shown in the image. Figure 1 The interface 16 is shown in Figure (6). It should be noted that interface 16 is the same as interface 11. For details on interface 16, please refer to the relevant description of interface 11 above. It will not be repeated here.
[0130] Optionally, in another embodiment, in response to a user's triggering operation on control 106, electronic device 100 can launch the process of the application corresponding to each card via a desktop application, thereby updating the displayed content of each card based on the relevant content of the application corresponding to each card. For example... Figure 1 As shown, at time t2, in response to the user's unlocking operation (or the triggering operation of control 106), the electronic device 100 can also launch the process of the application corresponding to each card through the desktop application to update the displayed content of each card. That is, the electronic device 100 can update the displayed content of the card from empty content or preset content to the content to be displayed in the application corresponding to the card.
[0131] It should be noted that the displayed content of the card can be divided into a title area, a content area, and an operation area, etc. The specific content, layout, and operation controls of each area can be pre-set by those skilled in the art according to actual usage needs, and this application does not limit this. For example, such as Figure 1 As shown in Figure (1), card 101 is titled "Current City or Region," and its contents include time, date, and temperature. Card 102 is titled "Health," and its contents include steps, calories, and kilometers. The operation controls in card 103 include an add control. The operation controls in card 104 include an add control and a search control.
[0132] In summary, when an electronic device is 100% unlocked, it takes a certain amount of time to display the frame of each card among multiple cards, and even longer to start the process of the application corresponding to each card. Therefore, displaying multiple cards in the desktop application requires a long loading time, resulting in a slow card display speed. This further leads to excessively long waiting times for users when the electronic device is unlocked, resulting in a poor user experience.
[0133] It should be understood that each interface and the controls in each interface described above are examples and do not limit the interface in the embodiments of the present application. In another embodiment of the present application, based on different application scenarios, each interface can include more or fewer controls than the controls in the above examples, which are not specifically limited in the present application. For example, as shown in (1) of FIG. 1, the interface 11 can further include system application programs (including but not limited to video application programs, setting application programs, camera application programs, and telephone application programs, etc.) pre-installed in the electronic device. For another example, as shown in (2) of FIG. 1, the controls 106 in the interface 12 can include controls of emergency calls and deletion controls, etc., which are not limited in the embodiments of the present application. Figure 4 Figure 4
[0134] Therefore, the card display method provided in the embodiments of the present application acquires the related information of the card (such as the page layout when the card is displayed in the host application program) in the booting process of the electronic device. Further, based on the related information of the card, the frame of the card to be displayed (such as the first card) is generated. Furthermore, in the case that the electronic device is unlocked, the card with the above generated frame can be directly displayed in the interface of the electronic device. Thus, by advancing the step of generating the frame of the card to be displayed to before the electronic device is unlocked, the loading speed and the display speed of the card corresponding to the application program (such as the first card corresponding to the second application) after the electronic device is unlocked can be accelerated, and thus the user experience can be greatly improved.
[0135] The implementation process of the card display method in the embodiments of the present application will be briefly described below with reference to Figure 4
[0136] As shown in FIG. 1, the electronic device 100 can include a card management service 101, a host application program 102, and a desktop application program 103. Figure 4 Figure 4 In the embodiments of the present application, the identifier E represents the user operation, the identifier F represents the operation performed by the process of the desktop application program, the identifier G represents the operation performed by the card management service, and the identifier H represents the operation performed by the third-party application program.
[0137] Optionally, in some embodiments, in response to the restart operation of the user (E1 as shown in FIG. 1), the electronic device 100 can start the process of the desktop application program (F1 as shown in FIG. 1). Figure 4 Figure 4
[0138] As shown in FIG. 1, after starting the process of the desktop application program, the electronic device 100 can query the database in the card management service through the process of the desktop application program (G1 as shown in FIG. 1). Figure 4 Figure 4 As shown in F1), the electronic device 100 obtains information related to card display (e.g., first information). After obtaining the information related to card display, the electronic device 100 can generate the card frame (e.g., ...) through the process of the desktop application. Figure 4 (as shown in F2).
[0139] like Figure 4 As shown, in response to the user's unlocking operation (such as...) Figure 4 As shown in E2), electronic device 100 can send a start broadcast signal to a third-party application (such as...) through a card management service. Figure 4 (G1 shown). After receiving the start broadcast signal, the electronic device 100 can start the process of a third-party application (such as G1). Figure 4 (H1 shown). After the process of the third-party application starts, the electronic device 100 can send update broadcast signals to the third-party application through the card management service (such as H1). Figure 4 (G2 shown). After receiving the update broadcast signal, electronic device 100 can send a content refresh command to the card management service via a third-party application (such as G2). Figure 4 (H2 shown). Furthermore, the electronic device 100 can pass content refresh instructions (such as...) to the desktop application process via a card management service. Figure 4 (G3 shown). After receiving a content refresh command, the electronic device 100 can update the displayed content of the card (e.g., G3) based on the content refresh command through the desktop application process. Figure 9 (F3 as shown).
[0140] It should be noted that, Figure 4 The process of generating the card frame (including F1, F2, and F3) is performed before the electronic device is unlocked 100, while the process of updating the displayed content of the card (including G1, H1, G2, H2, G3, and F4) is performed when the electronic device is unlocked.
[0141] It should also be noted that, Figure 3 For details on the implementation process, please refer to the following text. Figure 4 The description of that is omitted here.
[0142] Figure 5 and Figure 5 The difference is that, Figure 5 The electronic device 100 generates the card frame in advance before unlocking the electronic device 100. By loading and generating the card frame in advance, the card frame can be displayed directly when the electronic device is unlocked, thereby speeding up the card display and greatly reducing the waiting time for users when the electronic device is unlocked, thus improving the user experience.
[0143] The application embodiments relate to the application scenarios, and the card display method of the application embodiments is introduced as follows. The execution subject involved in the application embodiments, i.e., the electronic device, is introduced first. Figure 5 The hardware system of the electronic device in the application embodiments is introduced in detail.
[0144] Please refer to Figure 5 , Figure 5 The hardware system of the electronic device in the application embodiments is introduced in detail.
[0145] As shown in Figure 5 , the electronic device 100 can include a processor 110, an external memory interface 120, an internal memory 121, a universal serial bus (USB) interface 130, a charging management module 140, a power management module 141, a battery 142, an antenna 1, an antenna 2, a mobile communication module 150, a wireless communication module 160, an audio module 170, a loudspeaker 170A, a receiver 170B, a microphone 170C, a headset interface 170D, a sensor module 180, a key 190, a motor 191, an indicator 192, a camera 193, a display screen 194, and a subscriber identification module (SIM) card interface 195, etc. The sensor module 180 can include a pressure sensor 180A, a gyroscope sensor 180B, a barometric pressure sensor 180C, a magnetic sensor 180D, an acceleration sensor 180E, a distance sensor 180F, a proximity light sensor 180G, a fingerprint sensor 180H, a temperature sensor 180J, a touch sensor 180K, an ambient light sensor 180L, and a bone conduction sensor 180M, etc.
[0146] It should be noted that Figure 5 the structure shown does not constitute a specific limitation on the hardware system of the electronic device 100. In other embodiments of the application, the hardware system of the electronic device 100 can include more or fewer components than those shown in Figure 5 , or the hardware system of the electronic device 100 can include a combination of some of the components shown in Figure 5 , or the hardware system of the electronic device 100 can include sub-components of some of the components shown in Figure 5 . For example, Figure 1 the proximity light sensor 180G shown can be optional. Figure 1 The components shown can be implemented in hardware, software, or a combination of software and hardware.
[0147] The processor 110 can include one or more processing units. For example, the processor 110 can include at least one of the following processing units: an application processor (AP), a modem processor, a graphics processing unit (GPU), an image signal processor (ISP), a controller, a video codec, a digital signal processor (DSP), a baseband processor, a neural-network processing unit (NPU). Among them, different processing units can be independent devices or integrated devices.
[0148] The controller can generate operation control signals according to the instruction operation code and the timing signal, and complete the control of fetching and executing instructions.
[0149] The processor 110 can also be provided with a memory for storing instructions and data. In some embodiments, the memory in the processor 110 is a cache memory. The memory can save instructions or data that have just been used or are used repeatedly by the processor 110. If the processor 110 needs to use the instructions or data again, it can directly call from the memory. Avoiding repeated access, reducing the waiting time of the processor 110, thus improving the efficiency of the system.
[0150] Figure 5 The connection relationship between the modules shown is only illustrative and does not constitute a limitation on the connection relationship between the modules of the electronic device 100. Alternatively, the modules of the electronic device 100 can also use a combination of the above-mentioned various connection modes.
[0151] The electronic device 100 can realize the display function through the GPU, the display screen 194 and the application processor. The GPU is a microprocessor for image processing, connected to the display screen 194 and the application processor. The GPU is used to perform mathematical and geometric calculations for graphics rendering. The processor 110 can include one or more GPUs that execute program instructions to generate or change display information.
[0152] The display screen 194 can be used to display images or videos. The display screen 194 includes a display panel. The display panel can adopt a liquid crystal display (LCD), an organic light-emitting diode (OLED), an active-matrix organic light-emitting diode (AMOLED), a flexible light-emitting diode (FLED), a mini light-emitting diode (Mini LED), a micro light-emitting diode (Micro LED), a micro OLED, or a quantum dot light emitting diode (QLED).
[0153] In some embodiments, the electronic device 100 can include one or N display screens 194, where N is a positive integer greater than 1. In some embodiments, the unfolded state of the display screen 194 can be any one of the six states shown in (1) to (6) of FIG. 1. Figure 1 Figure 6 In some embodiments, the electronic device 100 can include one or N display screens 194, where N is a positive integer greater than 1. In some embodiments, the unfolded state of the display screen 194 can be any one of the six states shown in (1) to (6) of FIG. 1.
[0154] The electronic device 100 can implement a photographing function through an ISP, the camera 193, a video codec, a GPU, the display screen 194, and an application processor, etc.
[0155] The electronic device 100 can implement an audio function, such as music playing and recording, through an audio module 170, a speaker 170A, a microphone 170B, a microphone 170C, an earphone interface 170D, and an application processor, etc.
[0156] The touch sensor 180K, also referred to as a touch device. The touch sensor 180K can be disposed on the display screen 194, and the touch screen, also referred to as a touch screen, is composed of the touch sensor 180K and the display screen 194. The touch sensor 180K is used to detect touch operations acting on or near it. The touch sensor 180K can pass the detected touch operation to the application processor to determine the touch event type. In other embodiments, the touch sensor 180K can also be disposed on the surface of the electronic device 100 and disposed at a different position from the display screen 194.
[0157] Exemplarily, the touch sensor 180K can receive an operation of a user moving or modifying a card in the display screen 194, and deliver a detected operation of moving or modifying the card to the application processor, so that the application processor performs a corresponding processing based on the operation of moving or modifying the card.
[0158] The key 190 includes a power-on key and a volume key. The key 190 can be a mechanical key or a touch key. The electronic device 100 can receive a signal input by the key 190 and implement a function related to the signal input by the key 190.
[0159] It should be noted that, Figure 6 The key 190 in the electronic device 100 corresponds to the control 105 in the (1) figure of the electronic device 100. Figure 6 That is, in response to a triggering operation of the user on the key 190, the electronic device 100 can perform a power-on operation.
[0160] The motor 191 can generate vibration. The motor 191 can be used for incoming call prompt or touch feedback. The motor 191 can generate different vibration feedback effects for touch operations acting on different application programs. The motor 191 can also generate different vibration feedback effects for touch operations acting on different regions of the display screen 194. Different application scenarios (for example, time reminder, receiving information, alarm clock and game) can correspond to different vibration feedback effects. The touch vibration feedback effect can also support customization.
[0161] Optionally, in some embodiments, the processor 110 is configured to obtain relevant information of the card in advance (such as a page layout when the card is displayed in the first application) before the electronic device is unlocked, and generate a frame of the card to be displayed (such as the first card) based on the obtained relevant information of the card. Thus, the frame of the card can be directly displayed in the first application of the electronic device when the electronic device is unlocked, and the loading speed and display speed of the card corresponding to the second application (such as the widget card) can be accelerated when the electronic device is unlocked, which greatly shortens the time for the user to wait for the card to be loaded and displayed when the electronic device is unlocked, and greatly improves the user experience.
[0162] The hardware system of the electronic device 100 is described in detail above, and the software system of the electronic device 100 is introduced below. The software system can adopt a layered architecture, an event-driven architecture, a microkernel architecture, a microservice architecture or a cloud architecture. The embodiment of the present application takes the layered architecture as an example to exemplarily describe the software system of the electronic device 100.
[0163] Please refer to Figure 6 , Figure 1 A software system schematic diagram of an electronic device provided by an embodiment of the present application is shown.
[0164] The software system of the electronic device 100 can be divided into several layers, each layer having a clear role and division of labor. Layers communicate with each other through software interfaces. In some embodiments, as shown, the software system of the electronic device 100 can be an Android system architecture, which can be divided into five layers, from top to bottom, an application layer (APP), an application framework layer, a system layer, a Linux kernel layer, and a hardware layer. Figure 1
[0165] The application layer can include a plurality of applications installed in the electronic device 100. For example, the plurality of applications can be a phone application, a desktop application, a camera application, a calendar application, a music application, a gallery application, and a news application, etc.
[0166] It can be understood that the plurality of applications in the application layer can be third-party applications installed by the user (such as the second application), or system applications (such as the first application), and the first application can be a desktop application.
[0167] As shown, the desktop application can include a card management module. Figure 6
[0168] Optionally, in some embodiments, the card management module is configured to query, from a database of the card management service, a page layout of the card when the card is displayed in the desktop application.
[0169] Optionally, in another embodiment, before the loading task file sends the query instruction to the card management service, the loading task file can also send a start listening instruction to the card management service. The start listening instruction is configured to listen to the interaction between the process of the desktop application and the card management service.
[0170] It should be noted that the above query instruction and start listening instruction only need to be sent once each time the electronic device performs a power-on operation.
[0171] The application framework layer is a framework layer for supporting the running of multiple applications in the application layer. The application framework layer can provide an application programming interface (API) and a programming framework for the multiple applications in the application layer. Exemplarily, the programming framework can be an open graphics library for embedded systems framework (OpenGL ES framework). The open graphics library for embedded systems framework can include multiple base classes for creating and operating graphics.
[0172] Optionally, in some embodiments, the electronic device 100 can render the card by a rendering tool. Exemplarily, the rendering tool can be an open graphics library (OpenGL).
[0173] The application framework layer (or, system services) can include a window manager, a content manager, a phone manager, a resource manager, a view system, a widget manager service, and an activity manager service.
[0174] The window manager is used to manage window programs. The window manager is also used to feed back the operation of the user on the electronic device to the desktop application, so that the desktop application performs corresponding operations according to the operation of the user on the electronic device.
[0175] The content manager is used to store and obtain data, and make the data accessible to the application. Exemplarily, the data stored in the content manager can include videos, images, audios, browsing history, ticket information, and hotel information, etc.
[0176] The phone manager is used to provide the communication function of the electronic device. For example, the management of the call state (including call connection or hang-up, etc.).
[0177] The view system is used to build an application. The view system can include visual controls. Exemplarily, the visual controls can be controls for displaying text and controls for displaying pictures, etc.
[0178] The resource manager can provide various resources for the application. Exemplarily, the resources provided by the resource manager can include localized strings, icons, pictures, layout configuration files, and video files, etc.
[0179] Optionally, in some embodiments, the card management service is used to centrally manage cards (e.g., widget cards, suggestion cards, and weather cards), storing card IDs and information about the applications corresponding to the cards (e.g., the signature of the application corresponding to the card and the package name of the application corresponding to the card). Widget cards can be... Figure 6 The weather cards shown in Figure (1) are cards 102, 103, or 104, etc. Weather cards can be... Figure 6 Card 101 is shown in Figure (1).
[0180] like Figure 6 As shown, the card management service may include a concrete implementation class of the card service interface (app widgetservice impl). The concrete implementation class of the card service interface may include a scheme configuration switch module and / or a custom authentication module. The scheme configuration switch is used to set logical values and, based on the set logical values, determine whether to adopt the card display method of this application embodiment or whether to initiate identity authentication.
[0181] It should be noted that the logical value can be set to either true or false.
[0182] When the card management service includes both a scheme configuration switch module and a custom authentication module, and the logical value in the scheme configuration switch module is set to true, the card management service can activate the custom authentication module to complete the identity authentication of the desktop application. When the card management service includes both a scheme configuration switch module and a custom authentication module, and the logical value in the scheme configuration switch module is set to false, the card management service can report a query failure to the desktop application, and the steps of the card display method in this embodiment of the application terminate.
[0183] When the card management service includes a scheme configuration switch module, if the card management service determines that the logical value in the scheme configuration switch module is set to true, the card management service can report the page layout of the queried card displayed in the desktop application to the card management module in the desktop application. If the card management service includes a scheme configuration switch module, and the card management service determines that the logical value in the scheme configuration switch module is set to false, the card management service can report a query failure to the card management module in the desktop application, and the steps of the card display method in this embodiment of the application terminate.
[0184] It should be noted that, in order to ensure the normal operation of the card display method in this application embodiment, the logic value in the scheme configuration switch module is usually set to true.
[0185] In the case that the card management service comprises the custom authentication module, the card management service can start the custom authentication module to complete the identity authentication of the desktop application.
[0186] Illustratively, the card management service can determine whether the signature of the desktop application is the same as the preset signature in the custom authentication module. In the case that the signature of the desktop application is the same as the preset signature in the custom authentication module, it indicates that the identity authentication is passed, and the card management service can feed back the page layout of the card displayed in the desktop application to the card management module in the desktop application. In the case that the signature of the desktop application is different from the preset signature in the custom authentication module, it indicates that the identity authentication is not passed, and the card management service can feed back the query failure to the card management module in the desktop application, and the steps of the card display method of the embodiment of the application are terminated.
[0187] It should be noted that the above identity authentication is only illustrative, and the embodiment of the application is not limited thereto. For example, the card management service can also complete the identity authentication of the desktop application through the package name of the desktop application, and the implementation principle is the same as that of the identity authentication through the signature of the desktop application, and reference can be made to the related description above, and details are not described herein.
[0188] Optionally, in another embodiment, the card management service is configured to receive operation information of the card in the desktop application and save the operation information of the card. The card management service is further configured to provide a calling interface for the desktop application to query the related information of the card.
[0189] As shown in Figure 6 The card management service can further comprise a database. The database is configured to store the related information of the card, such as the page layout of the card displayed in the desktop application and the third-party application corresponding to the card.
[0190] It should be noted that the above examples are described with the database integrated in the card management service, and the embodiment of the application is not limited thereto. Illustratively, the database can also be independently arranged in the application framework layer of the software system as shown in Figure 6 .
[0191] Optionally, in some embodiments, the task management service is configured to start the process of each application in the application layer.
[0192] The application framework layer can further comprise a third-party application manager (app widget manager). The third-party application manager is configured to provide an interface for setting the card in the desktop application, and is responsible for the generation of the card and the update of the display content of the card, etc.
[0193] It should be noted that the third-party application manager can generate a unique identifier (such as a card ID) for each card, so that the user performs a corresponding triggering operation (such as clicking, moving, or modifying, etc.) on the card, and the third-party application manager can learn in time which card is operated.
[0194] The system layer can include a system library and an Android runtime. The system library can include a plurality of functional modules. Exemplarily, the system library can include a three-dimensional graphics processing library (OpenGL ES), a font library, a surface manager, media libraries, a two-dimensional graphics engine, and a first component, etc.
[0195] The three-dimensional graphics processing library is used to implement three-dimensional graphics drawing, image rendering, image synthesis, and layer processing, etc. The font library is used to implement the input of different fonts.
[0196] The surface manager is used to manage the display subsystem and provides a plurality of applications with the fusion of 2D and 3D layers.
[0197] The media library supports a plurality of commonly used audio, video format playback and recording, and static image files, etc. The media library can support a plurality of audio and video coding formats, such as MPEG4, H.264, MP3, AAC, AMR, JPG, or PNG, etc.
[0198] The two-dimensional graphics engine is a drawing engine for 2D drawing.
[0199] The first component is used to implement the rendering and display of a graphical user interface (GUI). Exemplarily, the first component can be a surface flinger.
[0200] It should be noted that when the card is displayed in the desktop application, the desktop application can also call the three-dimensional graphics processing library, the font library, and the media library, etc. in the application framework layer to complete the rendering of the card.
[0201] The Android runtime can include a core library and a virtual machine. The Android runtime is responsible for the scheduling and management of the Android operating system. The core library includes functional functions required by the java language and the core library of Android. The application layer and the application framework layer run in the virtual machine. The virtual machine executes the java files in the application layer and the application framework layer into binary files. The virtual machine is used to perform functions such as management of object life cycle, stack management, thread management, security and exception management, and garbage collection, etc.
[0202] It should be noted that when the card display method of the embodiments of the present application is implemented by using the Java language, the three files of the desktop file (launcher.java), the loading template file (loader model.java), and the loading task file (loader task.java) can be Java files. The specific implementation class of the card service interface (app widget service impl.java) can be a Java class. Those skilled in the art can also implement the above card display method by using other languages according to requirements, and the embodiments of the present application do not limit this.
[0203] The kernel layer is an abstraction layer between hardware and software. For example, the kernel layer can include a graphic processor driver (GPU driver), a display driver, a camera driver, an audio driver, and a sensor driver, and the like.
[0204] The hardware layer includes a display screen and the like. The hardware layer is used to define the connection hardware between each module (such as a display screen) and a processor. The hardware layer includes a display screen, a hardware interface, and the like. For example, the hardware interface can be a USB interface or a UART interface.
[0205] The card display method of the embodiments of the present application can be executed in the application layer and the application program framework layer. In some embodiments, before the electronic device is unlocked, the first application (such as a desktop application program) obtains, from the database of the card management service, the page layout of the card that has been set in the electronic device when the card is displayed in the first application in advance, and generates the frame of the card (such as the first card) to be displayed based on the page layout of the card when the card is displayed in the first application in advance. Thus, the frame of the card can be directly displayed in the first application of the electronic device when the electronic device is unlocked, and the loading speed and the display speed of the card (such as a widget card) corresponding to the second application (such as a third-party application program) can be accelerated when the electronic device is unlocked, which greatly shortens the time for the user to wait for the card to be loaded and displayed when the electronic device is unlocked, and greatly improves the user experience.
[0206] It should be understood that, Figure 7 The layered structure shown does not constitute a specific limitation on the software system of the electronic device 100. In other embodiments of the present application, the software system of the electronic device 100 can include more or less architecture than the layered architecture shown, or each layer of the software system of the electronic device 100 can include more or less structure than the constituent structure shown, and the embodiments of the present application are not limited thereto. Figure 7 The layered structure shown does not constitute a specific limitation on the software system of the electronic device 100. In other embodiments of the present application, the software system of the electronic device 100 can include more or less architecture than the layered architecture shown, or each layer of the software system of the electronic device 100 can include more or less structure than the constituent structure shown, and the embodiments of the present application are not limited thereto. Figure 7 The layered structure shown does not constitute a specific limitation on the software system of the electronic device 100. In other embodiments of the present application, the software system of the electronic device 100 can include more or less architecture than the layered architecture shown, or each layer of the software system of the electronic device 100 can include more or less structure than the constituent structure shown, and the embodiments of the present application are not limited thereto.
[0207] Based on the above description of the software system, the following describes the hardware system of the electronic device 100 in combination with Figure 13, introduces the specific implementation process of the current card display method. Please refer to Figure 7 , Figure 2 The signaling interaction diagram of the current card display is shown. The signaling interaction diagram of the embodiment of the application is Figure 2 , please refer to the relevant description below.
[0208] It should be understood that Figure 5 The signaling interaction process provided in the Figure 7 application can be applied to Figure 5 . Taking the electronic device 100 in the Figure 7 application as an example, it is assumed that the first application and the second application are installed in the electronic device 100, and the first application is a desktop application program and the second application is a third-party application program, in the software architecture layer of the electronic device 100 shown in Figure 1 , the desktop application program in the Figure 5 application can be located in the application layer in the software system as shown in
[0209] As shown in Figure 5 , the specific steps of displaying the card corresponding to the third-party application program in the desktop application program in the embodiment of the application are as follows:
[0210] Step 11, after setting the card corresponding to the third-party application program in the desktop application program, the user can restart the electronic device 100.
[0211] Taking the interface 11 shown in (1) of the Figure 5 application as an example, the user can long press the control 105 on the electronic device 100, so that the electronic device 100 restarts in response to the long press operation of the user.
[0212] It should be understood that the above example is only described by taking the user long pressing the control 105 on the electronic device 100 as an example, and the embodiment of the application is not limited thereto. The electronic device 100 can also be restarted by other means. For example, the user controls the electronic device 100 to restart by voice.
[0213] Step 12, in response to the restart operation of the user on the electronic device 100, the electronic device 100 can execute the re-boot process, and in the re-boot process of the electronic device 100, the electronic device 100 can start the system service (system server). The system service is equivalent to the application framework layer in the software system shown in Figure 5 .
[0214] Step 13, after starting the system service, the electronic device 100 can start the process of the desktop application program through the task management service in the system service. The task management service is located in the application framework layer in the software system as shown in Figure 5 . The desktop application program is located in the application layer in the software system as shown inFigure 7 application layer in the software system as shown.
[0215] Step 14, after the process of the desktop application is started, the user can unlock the electronic device 100. The process of the desktop application is located in the application layer in the software system as shown. Figure 8 application layer in the software system as shown.
[0216] Step 15, in response to the user's unlocking operation on the electronic device 100, the electronic device 100 can query the database in the card management service through the desktop application. The card management service is located in the application framework layer in the software system as shown. Figure 8 application framework layer in the software system as shown.
[0217] Step 16, the electronic device 100 can feed back the page layout when the card is displayed to the desktop application through the card management service.
[0218] Step 17, after receiving the page layout when the card is displayed, the electronic device 100 can generate the frame of the card based on the page layout when the card corresponding to the third-party application is displayed through the desktop application.
[0219] Step 18, in response to the user's unlocking operation on the electronic device 100, the electronic device 100 can send a start broadcast signal to the task management service in the system service through the card management service in the system service.
[0220] Step 19, after receiving the start broadcast signal, the electronic device 100 can start the process of the third-party application through the task management service in the system service.
[0221] Step 20, after starting the process of the third-party application, the electronic device 100 can send an update broadcast signal to the third-party application through the card management service in the system service.
[0222] Step 21, after receiving the update broadcast signal, the third-party application can generate a refresh instruction. The refresh instruction includes the display content of the card to be updated.
[0223] Step 22, after generating the refresh instruction, the electronic device 100 can send the card refresh instruction to the desktop application through the third-party application.
[0224] Optionally, in some embodiments, the electronic device 100 can send the card refresh instruction to the card management service through the third-party application. The electronic device 100 can pass the card refresh instruction to the desktop application through the card management service. So that the desktop application can receive the card refresh instruction and continue to perform subsequent operations.
[0225] Step 23, after receiving the card refreshing instruction, the electronic device 100 can parse the card refreshing instruction, and update the display content of the card based on the parsing result.
[0226] It should be understood that the embodiments of the present application are not limited to the execution sequence between steps 15 to 17 and steps 18 to 23 shown in the above Figure 2 application scenarios. For example, steps 15 to 17 can be performed first, and steps 18 to 23 can be performed later. For another example, steps 15 to 17 can be performed later, and steps 18 to 23 can be performed first. For another example, step 12 and steps 18 to 23 can be performed simultaneously.
[0227] Step 24, the card with updated display content is displayed in the application program of the electronic device 100. The card with updated display content adopts the frame of the card generated in step 17.
[0228] It should be understood that the above is only an example of triggering the starting of the system service in step 12 by restarting the electronic device in step 11, and the embodiments of the present application are not limited thereto. For example, the user can also trigger the starting of the system service in step 12 by turning on the electronic device by long pressing the electronic device when the electronic device has been turned off.
[0229] Based on the description of the above signaling interaction diagram, it can be known that in the case that the electronic device is unlocked, the user needs to wait for a certain period of time before the frame of the card corresponding to the third-party application is displayed in the desktop application program of the electronic device. Moreover, since the complete card also includes the display content of the card, displaying the display content of the card in the generated frame of the card needs to start the third-party application corresponding to the card, which leads to that the user needs to wait for a longer period of time to view the complete card in the desktop application program, resulting in a poor user experience.
[0230] The following will be described in detail Figure 9 with the first process as an example to introduce the specific implementation process of the current card display method.
[0231] It should be understood that Figure 2 the signaling interaction process provided in the above Figure 8 application scenarios. Figure 6 the signaling interaction process provided in the above Figure 6 application scenarios.
[0232] For example, the signaling interaction process provided in the above Figure 8As shown, the process of the desktop application can include a desktop file (or launcher file), a loading template file (or loader model file), and a loading task file, etc. The third-party application manager is located in the application framework layer of the software system as shown in Figure 8 The specific implementation class of the card service interface is located in the application framework layer of the software system as shown in Figure 8
[0233] Please refer to Figure 1 , Figure 8 The signaling interaction diagram of the current card display is shown.
[0234] As shown in Figure 8 , the current specific steps of displaying the card corresponding to the third-party application in the desktop application are as follows:
[0235] Step 31, in the case that the electronic device 100 is unlocked, the electronic device 100 can send a start loader instruction to the loading template file in the desktop application through the desktop file in the process of the desktop application.
[0236] It should be noted that the triggering premise of step 31 is that the electronic device is unlocked, in other words, the triggering operation of step 31 is that the user inputs the password in the (2) figure in the above Figure 8 In the case that the electronic device 100 is in a not unlocked state, step 31 will not be triggered, and the subsequent steps will not be triggered.
[0237] Step 32, after receiving the start loader instruction, the electronic device 100 can send a run instruction to the loading task file in the process of the desktop application through the loading template file.
[0238] Step 33, after receiving the run instruction, the electronic device 100 can send an acquisition instruction to the specific implementation class of the card service interface in the card management service through the task loading file. The acquisition instruction is used to acquire the configuration file of the installed third-party application in the electronic device 100 (get installed providers for profile). The configuration file of the third-party application includes the page layout of the card corresponding to the third-party application when the card is displayed in the desktop application.
[0239] In some embodiments, as Figure 9 As shown, the electronic device 100 can send a retrieval instruction to a third-party application manager through a task loading file, and then pass the retrieval instruction to the specific implementation class of the card service interface through the third-party application manager, so that the specific implementation class of the card service interface can obtain the retrieval instruction.
[0240] Step 34: After receiving the acquisition instruction, the electronic device 100 can obtain the configuration file of the installed third-party application from the database of the card management service, the specific implementation class of the card service interface.
[0241] Step 35: Electronic device 100 can send the configuration file of the installed third-party application to the loading task file through the specific implementation class of the card service interface.
[0242] In some embodiments, such as Figure 9 As shown, the electronic device 100 can send the configuration file of the installed third-party application to the third-party application manager through the specific implementation class of the card service interface, and pass the configuration file to the loading task file through the third-party application manager so that the loading task file can obtain the configuration file.
[0243] Step 36: Electronic device 100 can load and bind workspace by loading a task file based on the configuration file of the installed third-party application. In other words, electronic device 100 can generate the frame of the card corresponding to the third-party application by loading a task file based on the configuration file of the installed third-party application.
[0244] In summary, when the electronic device is unlocked, a frame corresponding to a third-party application is generated and displayed in the desktop application. Figure 9 The current card display method shown results in a slow card display speed after the electronic device is unlocked, which further leads to excessively long waiting time for users and a poor user experience.
[0245] The following is combined with Figure 9 This application describes the specific implementation process of the card display method in the embodiments.
[0246] Please see Figure 1 , Figure 9 This illustration shows a signaling interaction diagram for a card display provided in an embodiment of this application.
[0247] like Figures 10 to 13 As shown in the embodiment of this application, the specific steps for displaying the card corresponding to the third-party application in the desktop application are as follows:
[0248] Step 41, in the stage (or oncreate stage) of creating a user interface by a desktop application in the electronic device 100, the electronic device 100 can send a start loading instruction to the loading template file in the desktop application through the desktop file in the process of the desktop application.
[0249] It should be noted that the trigger premise of step 41 is that the electronic device 100 is powered on, in other words, the trigger operation of step 41 is the trigger operation of the user in the above (1) figure of the control 105. In the off state of the electronic device 100, step 41 will not be triggered, and the subsequent steps will not be triggered. Figure 10
[0250] Step 42, after receiving the start loading instruction, the electronic device 100 can send a running instruction to the loading task file in the process of the desktop application through the loading template file.
[0251] Step 43, after receiving the running instruction, the electronic device 100 can send an acquisition instruction to the specific implementation class of the card service interface in the card management service through the task loading file.
[0252] It should be understood that the specific implementation process of step 43 is the same as that of step 33, and the related description of step 33 can be referred to, and will not be repeated here.
[0253] Step 44, after receiving the acquisition instruction, the electronic device 100 can verify the permission (ensure permission) of the desktop application through the specific implementation class of the card service interface, to ensure that the desktop application has the permission to acquire the configuration file of the installed third-party application.
[0254] Step 45, in the case that the desktop application has the acquisition permission, the electronic device 100 can acquire the configuration file of the installed third-party application from the database of the card management service through the specific implementation class of the card service interface.
[0255] Step 46, the electronic device 100 can send the acquired configuration file of the installed third-party application to the loading task file through the specific implementation class of the card service interface.
[0256] It should be understood that the specific implementation process of step 46 is the same as that of step 35, and the related description of step 33 can be referred to, and will not be repeated here.
[0257] At step 47, the electronic device 100 can load and bind the workspace based on the obtained configuration file of the installed third-party application by loading the task file. In other words, the electronic device 100 can generate the frame of the card corresponding to the third-party application based on the obtained configuration file of the installed third-party application by loading the task file.
[0258] In summary, in the stage of creating the user interface of the desktop application in the electronic device 100, that is, before the electronic device 100 is unlocked, the frame of the card corresponding to the third-party application is generated in advance, so that the frame of the card corresponding to the third-party application can be directly displayed in the desktop application after the electronic device is unlocked, thereby accelerating the display speed of the card and further shortening the waiting time of the user and improving the user experience.
[0259] The above describes the specific implementation process of generating the frame of the card corresponding to the third-party application before the electronic device is unlocked. The card display method of the embodiments of the present application will be described in detail below. Figure 10 The above describes the specific implementation process of generating the frame of the card corresponding to the third-party application before the electronic device is unlocked. The card display method of the embodiments of the present application will be described in detail below. Figure 10
[0260] Please refer to Figure 5 , Figure 6 Fig. 1 shows a flowchart of a card display method according to an embodiment of the present application. As shown in Fig. 1, the card display method according to the embodiment of the present application can be applied to an electronic device as shown in Fig. 2. Figure 11 As shown in Fig. 2, the electronic device is installed with a first application and a second application. The first application and the second application are located in an application layer of a software system as shown in Fig. 3. Figure 11 As shown in Fig. 3, the software system includes an application layer, a system layer, and a kernel layer. Figure 1
[0261] In the case where the first application and the second application have been installed in the electronic device, the card display method according to the embodiment of the present application includes the following steps:
[0262] S101, receiving a first instruction, and the electronic device performs a start-up operation.
[0263] Optionally, in some embodiments, the first instruction can be a start-up instruction. In the case where the first instruction is the start-up instruction, the first instruction is used to trigger the start-up process of the electronic device.
[0264] Optionally, in another embodiment, the first instruction can also be a restart instruction. In the case where the first instruction is the restart instruction, the first instruction is used to trigger the restart process of the electronic device.
[0265] The electronic device can receive the first instruction from the user, and based on the received first instruction, the electronic device can perform the start-up operation.
[0266] Optionally, in some embodiments, asFigure 6 As shown in Figure (1), in interface 21, in response to a second user operation (e.g., a user triggering control 205 in interface 21), the electronic device can receive a first instruction from the user. After receiving the first instruction, the electronic device can perform a power-on operation based on the received first instruction.
[0267] It should be noted that the above description is based on the electronic device being in normal use. Since interface 21 is the display interface of the electronic device in normal use, the user's second operation is a restart operation, and correspondingly, the first instruction is a restart instruction. The implementation of this application embodiment is not limited to the electronic device being in normal use. For example, when the electronic device is in a powered-off state, the user's second operation is a power-on operation, and correspondingly, the first instruction is a power-on instruction.
[0268] It should also be noted that, Figure 5 For a description of the interface 21 shown in Figure (1), please refer to [link to relevant documentation]. Figure 11 The relevant description of interface 11 shown in Figure (1) is not repeated here.
[0269] In summary, the electronic device can be powered on normally after receiving the first instruction. Performing the power-on operation via the electronic device prepares for subsequent operational steps in the card display method of this application embodiment.
[0270] S102, during the power-on process of the electronic device, initiates the first process.
[0271] Optionally, in some embodiments, the first process is a process corresponding to a first application. The first process is located in, for example, Figure 11 In the application layer of the software system shown, for example, when the first application is a desktop application, the first process is the process corresponding to the desktop application.
[0272] During the power-on process of an electronic device, the device can launch a first process. By launching the first process, initialization operations can be performed on the first application (including but not limited to loading the first application's resource files, setting the user interface, and initializing network connections), thereby enabling the first application to run in the background of the electronic device.
[0273] Alternatively, in some embodiments, the electronic device can be via, for example... Figure 9 The software system shown uses a task management service to launch the first process. Since the electronic device is still locked during the power-on process, launching the first process before unlocking can speed up the acquisition of initial information, thereby improving the loading and display speed of the first card after unlocking.
[0274] S103, obtaining first information based on the first process.
[0275] Optionally, in some embodiments, the first information is used to represent a page layout related to display of the first card. The first card is a to-be-displayed card corresponding to the second application. The first card can be a weather card (such as the card 201 shown in (1) of FIG. 1), a suggestion card, or a widget card (such as the card 203 shown in (1) of FIG. 1), and the like, which are not limited in the embodiments of the present application. Figure 6 Figure 6 Optionally, in some embodiments, the first information at least includes one or more of the following: a position of the first card in the first application, a size of the first card, a style of the first card, and a package name of the second application.
[0276] Optionally, in another embodiment, the first information can further include a color of the first card, a transparency of the first card, and the like. For example, the first information can be a configuration file of the third-party application as shown in (2) of FIG. 1.
[0277] Figure 11 Optionally, in another embodiment, the first information can further include a color of the first card, a transparency of the first card, and the like. For example, the first information can be a configuration file of the third-party application as shown in (2) of FIG. 1.
[0278] For example, the package name of the second application, the color of the first card, and the transparency of the first card can be set in advance in the electronic device, and do not need to be manually modified by the user. In actual applications, the user can modify the fourth information that can be changed according to the use needs, which is not limited in the embodiments of the present application.
[0279] Optionally, the display content of the first card includes but is not limited to a title area, a content area, an operation area, and the like, which can be referred to the related description above. Since the display content of the first card is the content related to the second application, before the process of the second application is started, the display content of the first card is empty content; or the display content of the first card is preset content.
[0280] After starting the first process, the electronic device can obtain the first information in a plurality of possible implementation manners, two possible implementation manners of obtaining the first information by the electronic device are introduced below.
[0281] Method one:
[0282] The electronic device can query a database in a software system as shown in (3) of FIG. 1 through the first process to obtain the first information. The database stores the related information of the to-be-displayed card (or the first card) corresponding to the second application, that is, the first information. As shown in (4) of FIG. 1, the database is located in the application framework layer in the software system, and is located in the card management service in the application framework layer. Figure 11 Figure 11
[0283] The second way is as follows:
[0284] The electronic device can receive the third instruction through the first process and parse the received third instruction to obtain the first information.
[0285] Optionally, the third instruction is sent by the card management service, and the third instruction includes the first information.
[0286] In summary, the electronic device can obtain the first information. By obtaining the first information in advance when the electronic device is not unlocked, data basis can be provided for subsequent generation of the frame of the card in advance.
[0287] S104, generating a first frame based on the first information.
[0288] Optionally, in some embodiments, the first frame is a widget frame adopted by the first card when the first card is displayed in the first application. The first frame can include one or more. For example, as shown in (1) of FIG. 1, the first card can be card 203, the first frame can be the frame of card 203, and the first frame can include the title frame of card 203 and the content frame of card 203, etc. After obtaining the first information, the electronic device can generate the first frame based on the first information. By generating the first frame in advance when the electronic device is not unlocked, the speed of displaying the first frame in the first application when the electronic device is unlocked can be accelerated, and the user experience can be further improved. Figure 9
[0289] S105, displaying a first interface when the electronic device is unlocked.
[0290] Optionally, in some embodiments, the first interface is an interface related to the first application. The first interface can include a first display area (for example, as shown in (3) of FIG. 1). The first display area includes at least the first card (for example, card 203 as shown in (1) of FIG. 1). The first card adopts the first frame. For example, the first frame can be the workspace in step 47 as shown in (3) of FIG. 1. Figure 11 Figure 11 Figure 1
[0291] It should be noted that, as shown in (1) of FIG. 1, the first display area can also include other cards (for example, card 201, card 202, and card 204, etc.), which are not limited by the embodiments of the present application. Figure 11
[0292] It should also be noted that when the first application is a desktop application, the first interface can be the default interface of the desktop application pre-set in the electronic device (e.g., the main interface), or it can be another interface besides the main interface displayed after the electronic device is unlocked and a user triggers an operation on the desktop application (e.g., the interface displayed in response to the user's left swipe). When the first application is another application (e.g., a smart service assistant), the first interface can be the default interface of the smart service assistant pre-set in the electronic device, or it can be another interface besides the default interface displayed after the electronic device is unlocked and a user triggers an operation on the smart service assistant. This application embodiment does not limit this.
[0293] Optionally, in some embodiments, before displaying the first interface, the electronic device may perform an unlocking operation in response to a first user action. The first action is used to trigger the electronic device to switch from a locked screen state to an unlocked state. For example, as... Figure 11 As shown in Figure (2), the electronic device can perform an unlocking operation in response to the user's operation on the control 206 in the interface 22.
[0294] It should be noted that interface 22 can be found here. Figure 11 The relevant description of interface 12 shown in Figure (2) is not repeated here.
[0295] Optionally, in another embodiment, the electronic device may automatically unlock before displaying the first interface; this application embodiment does not limit this. For example, if the electronic device does not have a lock screen password, it may automatically unlock to successfully display the first interface.
[0296] When the electronic device is unlocked, it can display a first screen (e.g., Figure 11 Interface 23 is shown in Figure (3) of the document. For example, as shown in Figure (3) of the document. Figure 11 As shown in Figure (3), in response to user input... Figure 11 When the control 206 in interface 22 shown in Figure (2) is triggered, the electronic device can perform an unlocking operation and display... Figure 11 The interface 23 shown in Figure (3) is as follows. The interface 23 may include the frame of card 201, the frame of card 202, the frame of card 203 and the frame of card 204.
[0297] Because the first frame in the first interface (for example, Figure 11The first frame of the card 201, the first frame of the card 202, the first frame of the card 203, or the first frame of the card 204 shown in FIG. (3) in
[0298] In the case of displaying the first frame in the first interface, the electronic device can start a process of the second application corresponding to the first card, to generate the display content of the first card based on the process of the second application, so that the first card displays the content related to the second application. Since the process of the second application corresponding to the first card needs a certain time, and the updating process of the display content of the first card also needs a certain time, after the electronic device is unlocked for a period of time, the electronic device can display the interface 24 shown in FIG. (4) in Figure 11
[0299] In the second display area shown in FIG. (4) in Figure 1 The frame of the card 201 and the display content of the card 201 are both displayed, that is, the process of the application program 1 corresponding to the card 201 has been started. The frame of the card 202 is displayed, and the display content of the card 202 is not displayed, that is, the process of the application program 2 corresponding to the card 202 has not been started. The frame of the card 203 and the display content of the card 203 are both displayed, that is, the process of the application program 3 corresponding to the card 203 has been started. And the frame of the card 204 is displayed, and the display content of the card 204 is not displayed, and the process of the application program 4 corresponding to the card 104 has not been started.
[0300] After the processes corresponding to each card are started and the display content of each card is generated, the electronic device can display the interface 25 shown in FIG. (5) in Figure 1 Figure 11 In the third display area shown in FIG. (5) in
[0301] It should be understood that the interface 25 is similar to the interface 21 shown in FIG. (1) in Figure 11 and the interface 16 shown in FIG. (6) in Figure 12 Please refer to the related description of the interface 11, which will not be repeated here.
[0302] It should be noted that when an electronic device contains multiple applications, the device needs to sequentially launch the processes of each application and generate the displayed card content. In other words, after launching the process of one application (e.g., a second application), the electronic device can generate the displayed card content corresponding to that application through that application's process. After generating the displayed card content for that application, the electronic device can launch the process of the next application following that application according to a pre-set launch order and generate the displayed card content corresponding to that application. Therefore, as... Figure 12 Figure (3) in the middle Figure 6 As shown in Figure (5), there is a certain delay in the display of the content of card 201, card 202, card 203 and card 204.
[0303] The card display method in this embodiment enables an electronic device to power on by receiving a first instruction. During the power-on process, the process corresponding to the first application, i.e., the first process, is launched. Based on this, first information, i.e., the page layout related to the display of the first card, is obtained from the first process, allowing the first information to be obtained in advance before the electronic device is unlocked. Furthermore, based on the obtained first information, a first frame is generated, also in advance before the electronic device is unlocked. Further, when the electronic device is unlocked, a first interface can be displayed, and the first card using the first frame can be directly displayed on the first interface, without needing to generate the first frame only after the electronic device is unlocked. This allows users to view the frame of the card corresponding to the application without waiting when the electronic device is unlocked, saving the time spent waiting for the card frame to display, thus accelerating the card loading and display speed when the electronic device is unlocked, further shortening the time the user waits for the complete card display after the electronic device is unlocked, and improving the user experience.
[0304] Based on the above description, it can be seen that the electronic device obtains the first information in S103 before unlocking. Therefore, to ensure the secure operation of the electronic device, after executing S102 and before executing S103, the electronic device can perform security verification. The following will combine... Figure 12 This document details the specific implementation process of security verification for electronic devices in the embodiments of this application. For example, Figure 6 The specific implementation process of the security verification shown can be applied to, for example... Figure 6 The application framework layer in the software system shown can be specifically implemented by the card management service within the application framework layer.
[0305] likeFigure 9 As shown in FIG. 10, before performing S103, the card display method of the embodiments of the present disclosure further includes:
[0306] S201, starting a first process in the process of booting the electronic device.
[0307] It should be understood that S201 is the same as S102, and reference can be made to the related description of S102, which will not be repeated here.
[0308] S202, determining whether the electronic device is in a locked state after starting the first process.
[0309] After starting the first process, the electronic device can determine whether the electronic device is in a locked state at this time. By determining whether the electronic device is in a locked state, it can be ensured that the execution of S103 and S104 of the electronic device is completed when the electronic device is not unlocked, so as to achieve the purpose of speeding up the card display when the electronic device is unlocked.
[0310] If the electronic device is in a locked state, the electronic device can perform S203. If the electronic device is not in a locked state, the electronic device can perform S207.
[0311] Optionally, in another embodiment, the electronic device can further determine whether the first process is the first start in a one-time boot process after starting the first process. In the case that the first process is the first start in a one-time boot process, the electronic device can perform S203. By determining whether the first process is the first start in a one-time boot process, it can be ensured that the card display optimization of the card display method of the embodiments of the present disclosure is completed before the electronic device is unlocked.
[0312] S203, obtaining the value of the first variable in the case that the electronic device is in a locked state.
[0313] Optionally, the value of the first variable can be set in the application framework layer in the software system as shown in FIG. 11. For example, the value of the first variable can be set by a scheme configuration switch module in the card management service of the application framework layer. Figure 6
[0314] Optionally, the value of the first variable can be a first logical value or a second logical value. The first logical value or the second logical value is a value of the first variable pre-set in the electronic device.
[0315] Optionally, the first logical value is used to indicate that the electronic device can perform other subsequent steps of the card display method (such as starting identity authentication). The second logical value is used to indicate that the electronic device terminates the steps of the card display method. For example, the first logical value can be true, and the second logical value can be false.
[0316] It should be noted that in actual application, the first logic value and the second logic value can also be selected by the person skilled in the art according to actual needs or personal habits, and the present application does not limit this, for example, the first logic value is 1 and the second logic value is 0.
[0317] S204, determining whether the value of the first variable is the first logic value.
[0318] After obtaining the value of the first variable, the electronic device can determine whether the value of the first variable is the preset first logic value. If the value of the first variable is the first logic value, the electronic device can execute S205. If the value of the first variable is the second logic value, the electronic device can execute S207.
[0319] S205, starting identity authentication in the case that the value of the first variable is the first logic value.
[0320] In the case that the value of the first variable is the first logic value, the electronic device can start identity authentication through the custom authentication module in the software system as shown in Figure 6 . By starting identity authentication, the security of obtaining the first information before unlocking the electronic device can be improved.
[0321] It should be noted that in the case that the first application is a desktop application, the implementation process of S205 is the same as that of step 44 as shown in Figures 1 to 12 , and the related description of step 44 can be referred to, which will not be repeated here.
[0322] S206, identity authentication of the first application according to the preset authentication information.
[0323] Optionally, in some embodiments, the preset authentication information can include a preset signature and / or a preset package name.
[0324] After starting identity authentication, the electronic device can perform identity authentication of the first application according to the preset authentication information through the custom authentication module in the software system as shown in Figure 13 .
[0325] Based on the related description of S206, the electronic device can perform identity authentication of the first application through the custom authentication module in the software system as shown in Figure 13 may adopt the following three possible implementation ways.
[0326] Method one:
[0327] In the case that the preset authentication information includes a preset signature, the electronic device can determine whether the signature of the first application is the same as the preset signature to complete the identity authentication of the first application.
[0328] Mode two:
[0329] In a case where the preset authentication information includes the preset signature, the electronic device can determine whether the package name of the first application is the same as the preset package name, to complete the identity authentication of the first application.
[0330] Mode three:
[0331] In a case where the preset authentication information includes the preset signature and the preset package name, the electronic device can first determine whether the signature of the first application is the same as the preset signature, and in a case where the signature of the first application is the same as the preset signature, the electronic device can further determine whether the package name of the first application is the same as the preset package name. Alternatively, the electronic device can first determine whether the package name of the first application is the same as the preset package name, and in a case where the package name of the first application is the same as the preset package name, the electronic device can further determine whether the signature of the first application is the same as the preset signature, to complete the identity authentication of the first application.
[0332] It should be noted that the preset authentication information can further include other related information (such as the ID of the first application) for uniquely identifying the first application, in addition to the signature of the first application and the package name of the first application. Moreover, in a case where the preset authentication information includes multiple pieces, the order of using multiple pieces of preset authentication information for identity authentication is not limited in the embodiments of the present application.
[0333] In a case where the first application passes the identity authentication, the electronic device can perform S103, so that the electronic device can successfully obtain the first information before unlocking, and thus can provide a data basis for generating the first frame in advance before the electronic device is unlocked.
[0334] S207, terminate the execution of the card display method.
[0335] In a case where the electronic device is not in the locked screen state or the value of the first variable is not the first logic value, the electronic device can terminate the execution of the card display method.
[0336] In a case where the electronic device is not in the locked screen state, by terminating the execution of the card display method in the embodiments of the present application, it can be ensured that the card display optimization performed by the card display method in the embodiments of the present application is completed before the electronic device is unlocked, and thus the speed of card display in a case where the electronic device is unlocked is accelerated.
[0337] In a case where the value of the first variable is not the first logic value, by terminating the execution of the card display method in the embodiments of the present application, it can be ensured that in a case of user misoperation or process crash of the desktop application, the subsequent steps related to identity authentication in the card display method in the embodiments of the present application will not be triggered.
[0338] Based onFigure 13 The description, the following will be combined Figure 13 , detailed description of the card display method in the embodiment of the application.
[0339] Please refer to Figure 10 , Figure 13 shows a card display signaling interaction diagram provided by an embodiment of the application. Figure 12 The signaling interaction diagram provided can be applied in Figure 10 .
[0340] As Figure 13 shown, the card display method in the embodiment of the application specifically includes the following steps:
[0341] Step 51, after setting the first card corresponding to the second application in the desktop application, the user can restart the electronic device 100.
[0342] It should be understood that the implementation process of step 51 is the same as that of S101, and the related description of S101 can be referred to, and no further description is made here.
[0343] Step 52, in response to the user's restart operation of the electronic device 100, the electronic device 100 can execute the re-boot process, and in the re-boot process of the electronic device 100, the electronic device 100 can start the system service.
[0344] It should be understood that the specific implementation process of step 52 is the same as that of step 12, and the related description of step 12 can be referred to, and no further description is made here.
[0345] Step 53, after starting the system service, the electronic device 100 can start the first process through the task management service in the system service.
[0346] It should be understood that the implementation principle of step 53 is similar to that of step 13, and the description of step 13 can be referred to, and no further description is made here.
[0347] Step 54, after starting the first process, the electronic device can query the database in the card management service through the first process.
[0348] Step 55, the electronic device can authenticate the identity of the first application through the card management service.
[0349] It should be understood that the specific implementation process of step 55 is the same as that of S201 to S207 in Figure 10 , and the related description of S201 to S207 can be referred to, and no further description is made here.
[0350] The electronic device 100 can feed back the first information queried to the first process through the card management service.
[0351] It should be understood that step 54 and step 55 are equivalent to S103 in Figure 10 , and the related description of S103 can be referred to, and details are not described herein.
[0352] If the identity authentication of the first application is passed, the electronic device 100 can perform step 56. If the identity authentication of the first application is not passed, the electronic device 100 can send an instruction of query failure to the card management service (not shown in Figure 6 ).
[0353] In step 56, the electronic device 100 can send the queried first information to the first process through the card management service.
[0354] In step 57, after receiving the first information, the electronic device 100 can generate a first frame based on the first information through the first process.
[0355] It should be understood that step 57 is equivalent to S104 in Figure 13 , and the related description of S104 can be referred to, and details are not described herein.
[0356] In step 58, the user unlocks the electronic device 100.
[0357] It can be seen that steps 51 to 57 are completed in advance before the electronic device 100 is unlocked, so that the time for generating the first frame when the electronic device 100 is unlocked can be saved, and the display time of the first card is accelerated, the waiting time of the user in the case of unlocking the electronic device is shortened, and the user experience is greatly improved.
[0358] In step 59, in response to the unlocking operation of the user on the electronic device 100, the electronic device 100 can display the first frame in the first interface of the first application through the first process.
[0359] It should be understood that step 59 is equivalent to S105 in Figure 7 , and the related description of S105 can be referred to, and details are not described herein.
[0360] In step 60, in response to the unlocking operation of the user on the electronic device 100, the electronic device 100 can send a first broadcast signal to the task management service in the system service through the card management service in the system service. Thus, the task management service can receive the first broadcast signal in the case of unlocking the electronic device.
[0361] Optionally, the first broadcast signal is used to start a second process. The second process is a process corresponding to a second application. The second process is located in, for example, Figure 11The first broadcast signal can be an enable broadcast signal.
[0362] It should be understood that the embodiments of the present application are not limited to Figure 11 The execution sequence of steps 59 and 60 shown in FIG. 6 can depend on the actual application scenario. For example, step 59 can be performed first, and then step 60 can be performed. For another example, step 59 can be performed after step 60. For another example, step 59 and step 60 can be performed simultaneously.
[0363] It should be understood that the specific implementation principle of step 60 is the same as that of step 18, and the related description of step 18 can be referred to, and details are not described herein.
[0364] Step 61, in the case where the first broadcast signal is received, the electronic device 100 can start a second process based on the received first broadcast signal through a task management service in the system service.
[0365] It should be understood that the specific implementation principle of step 61 is the same as that of step 19, and the related description of step 19 can be referred to, and details are not described herein.
[0366] Step 62, after starting the second process, the electronic device 100 can send a second broadcast signal to the second process through a card management service in the system service.
[0367] Optionally, the second broadcast signal is used to update (or refresh) the content displayed in the first card. For example, the second broadcast signal can be an update broadcast signal.
[0368] It should be understood that the specific implementation principle of step 62 is the same as that of step 20, and the related description of step 20 can be referred to, and details are not described herein.
[0369] Step 63, after receiving the second broadcast signal, the electronic device can generate a second instruction based on the second broadcast signal.
[0370] Optionally, the second instruction includes second information. For example, the second instruction can be Figure 11 a refresh instruction in the second application.
[0371] Optionally, the second information is used to represent the content to be displayed in the second application. The second information includes but is not limited to pictures, texts, videos, links, etc.
[0372] It should be noted that the second information can be real-time push content in the second application, or content that the user is interested in in the second application, and the embodiments of the present application are not limited thereto.
[0373] It should be understood that the specific implementation principle of step 63 is the same as that of step 21, and the related description of step 21 can be referred to, and details are not described herein.
[0374] Step 64, after generating the second instruction, the electronic device 100 can send the second instruction to the first process through the second process. In other words, the electronic device 100 can receive the second instruction from the second process through the first process, so that the first process can perform corresponding operations based on the second instruction.
[0375] It should be understood that the specific implementation principle of step 64 is the same as that of step 22, and the related description of step 22 can be referred to, and details are not described herein.
[0376] Step 65, after receiving the second instruction, the electronic device 100 can parse the second instruction, and generate the content displayed in the first card based on the parsing result (or second information).
[0377] It should be understood that the specific implementation principle of step 65 is the same as that of step 23, and the related description of step 23 can be referred to, and details are not described herein.
[0378] It should be noted that the manner of obtaining the second information shown in steps 63 to 65 is only exemplary, and the embodiments of the present application are not limited thereto. For example, the electronic device 100 can also directly obtain the second information based on the second process to generate the content displayed in the first card. Moreover, the electronic device 100 can also directly send the obtained second information to the first process through the second process, so that the first process can obtain the second information and perform subsequent operations.
[0379] Optionally, in some embodiments, the first card can first display empty content (such as Figure 11 The first display area shown in (3) of FIG. 1), and then display the content generated in step 65 and displayed in the first card. Alternatively, the first card can first display preset content, and then display the content generated in step 65 and displayed in the first card. Alternatively, the first card can directly display the content generated in step 65 and displayed in the first card. Through the above three display modes, the electronic device 100 can update the content in the first card to ensure that the display content of the first card is the real-time pushed content in the second application or the core content that the user currently needs to pay attention to.
[0380] It should be noted that the manner in which the electronic device 100 updates the display content of the first card can be real-time updating, periodic updating (for example, setting an updating time), or updating each time the electronic device 100 is powered on, and the embodiments of the present application are not limited thereto.
[0381] Step 66: Display the second interface in the first process (or first application) of the electronic device 100. The second interface (e.g., as...) Figure 11 The interface 24 shown in Figure (4) may include a second display area (such as...) Figure 11 (as shown in Figure (4)). The second display area includes at least the first card, the contents of the first card (e.g., such as...). Figure 11 The content displayed on card 203 shown in Figure (4) is generated based on the second information. The first card uses the first frame generated in advance in step 57 before the electronic device is unlocked.
[0382] It should be understood that the specific implementation principle of step 66 is the same as that of step 24, and can be found in the relevant description of step 24, which will not be repeated here.
[0383] It should be noted that the optimization of the card display method in this application embodiment is only performed once each time the electronic device is powered on, and does not need to be re-optimized each time the user unlocks the electronic device, thus achieving a better optimization effect on the display of cards already set in the electronic device.
[0384] In summary, by acquiring first information through a first process before the electronic device unlocks, and generating a first frame based on that information, the system can display the first interface (e.g., ...) even when the electronic device is unlocked. The interface shown in Figure (3) 23) can directly display the first frame (e.g., the frame of card 203), without having to generate the first frame when the electronic device is unlocked. This speeds up the display of the first frame when the electronic device is unlocked, further speeds up the display of the first card, avoids long waiting times for users, and makes the user experience better.
[0385] Considering that in the above card display methods, the condition for triggering the launch of the application process corresponding to the card (e.g., the second process) is that the electronic device is unlocked, this will result in the display interface of the electronic device (e.g., ... When the card frame is displayed in the interface 23) shown in Figure (3), the display content of the card is empty because the process of the application corresponding to the card still needs some time to start. Therefore, in order to further speed up the display of the card when the electronic device is unlocked, this application embodiment also provides a possible implementation method.
[0386] Optionally, in some embodiments, a process (e.g., the second process) of an application corresponding to the card (e.g., the first card) is preloaded before the electronic device is unlocked. In the case that the electronic device is unlocked, the electronic device can directly generate the display content of the card through the process of the application corresponding to the card. Thus, the generation or update process of the display content of the card can be directly triggered in the case that the electronic device is unlocked without starting the process of the application corresponding to the card, saving the process startup time of the application corresponding to the card, further shortening the waiting time of the user in the case that the electronic device is unlocked, and greatly improving the user experience.
[0387] Exemplarily, the present application provides a computer-readable storage medium, which includes instructions, when the instructions are executed on the electronic device 100, causing the electronic device 100 to perform the method in the foregoing embodiments.
[0388] Exemplarily, the present application provides a chip system, which is applied to the electronic device 100; the chip system includes one or more processors; the one or more processors are configured to invoke computer instructions to cause the electronic device 100 to perform the method in the foregoing embodiments.
[0389] Exemplarily, the present application provides a computer program product, when the computer program product is executed on a computer, causing the electronic device 100 to perform the method in the foregoing embodiments.
[0390] In the above embodiments, all or part of the functions can be implemented by software, hardware, or a combination of software and hardware. When implemented by software, all or part of the functions can be implemented in the form of a computer program product. The computer program product includes one or more computer codes or instructions. When the computer program codes or instructions are loaded and executed on a computer, all or part of the processes or functions according to the present application are generated. The computer can be a general-purpose computer, a special-purpose computer, a computer network, or other programmable devices. The computer codes or instructions can be stored in a computer-readable storage medium. The computer-readable storage medium can be any available medium that can be accessed by a computer or a data storage device such as a server, data center, etc. integrated with one or more available media. The available medium can be a magnetic medium (e.g., a floppy disk, a hard disk, a magnetic tape), an optical medium (e.g., a DVD), or a semiconductor medium (e.g., a solid state disk (SSD)), etc.
[0391] Those skilled in the art can understand that all or part of the processes in the above-mentioned method embodiments can be implemented by a computer program instructing relevant hardware to complete, the program can be stored in a computer readable storage medium, and the program can include the processes of the above-mentioned method embodiments when executed. The aforementioned storage medium includes read only memory (ROM) or random access memory (RAM), a magnetic disc or an optical disc, and various media that can store program codes.
Claims
1. A card display method characterized by comprising: The method is applied to an electronic device in which a first application and a second application are installed, and the first application and the second application are different applications; the method comprises: receiving a first instruction, and the electronic device performing a start-up operation; starting a first process during the start-up of the electronic device; the first process is a process corresponding to the first application; during the start-up of the electronic device, the electronic device is in an unlocked state; obtaining first information based on the first process; the first information is used to represent a page layout related to a first card display; the first card is a to-be-displayed card corresponding to the second application; the first information at least comprises one or more of the following: a position of the first card displayed in the first application, a size of the first card, a style of the first card, and a package name of the second application; generating a first frame based on the first information when the electronic device is not unlocked; the first frame is a widget frame used when the first card is displayed in the first application; displaying a first interface when the electronic device is unlocked; the first interface comprises a first display area, and the first display area at least comprises the first card; the first card adopts the first frame.
2. The method of claim 1, wherein, The method further comprises: starting a second process when the electronic device is unlocked; the second process is a process corresponding to the second application; obtaining second information based on the second process; the second information is used to represent to-be-displayed content in the second application; displaying a second interface; the second interface comprises a second display area, and the second display area at least comprises the first card; content displayed in the first card is generated based on the second information.
3. The method of claim 2, wherein, Before displaying the second interface, the method further comprises: refreshing content in the first card based on the second information when the displayed content of the first card is empty content or preset content.
4. The method according to any one of claims 1 to 3, characterized in that, Before obtaining the first information based on the first process, the method further comprises: performing identity authentication on the first application according to preset authentication information; the preset authentication information comprises a preset signature and / or a preset package name; The method further comprises: obtaining the first information based on the first process when the first application passes the identity authentication.
5. The method of claim 4, wherein, The method further comprises: determining whether the signature of the first application is the same as the preset signature; and / or determining whether the package name of the first application is the same as the preset package name. Before performing the identity authentication on the first application, the method further comprises:
6. The method of claim 4, wherein, obtaining a value of a first variable; starting the identity authentication when the value of the first variable is a first logical value. Before obtaining the value of the first variable, the method further comprises:
7. The method of claim 6, wherein, determining whether the electronic device is in a locked state; The method further comprises: In a case where the electronic device is in a locked state, a value of the first variable is acquired.
8. The method of claim 2, 3, 5, or 7, wherein, The electronic device further comprises a card management service and a task management service; the starting the second process in a case where the electronic device is unlocked comprises: In a case where the electronic device is unlocked, a first broadcast signal is sent to the task management service by the card management service; Upon receiving the first broadcast signal, the second process is started by the task management service.
9. The method of claim 2, wherein, The second information is acquired based on the second process, comprising: A second broadcast signal is received by the second process, and second information is generated based on the second broadcast signal; the second information comprises the second information. The second information is obtained by analyzing the second instruction by the first process.
10. The method of claims 1, 2, 3, 5, or 7, wherein, Before displaying the first interface, the method further comprises: In response to a first operation of a user, the electronic device performs an unlocking operation; the first operation is used to trigger the electronic device to switch from a locked state to an unlocked state.
11. The method of claims 1, 2, 3, 5, or 7, wherein, The first information is acquired based on the first process, comprising: A database is queried by the first process to obtain the first information, and the database stores related information of a to-be-displayed card corresponding to the second application.
12. The method of claims 1, 2, 3, 5, or 7, wherein, The first information is acquired based on the first process, further comprising: A third instruction is received by the first process, and the first information is obtained by analyzing the third instruction.
13. The method of claims 1, 2, 3, 5, or 7, wherein, The first application is a desktop application in a system application program; and the second application is a third-party application program.
14. The method of claims 1, 2, 3, 5, or 7, wherein, The first instruction is received, and the electronic device performs a power-on operation, comprising: In response to a second operation of a user, the first instruction is received, and based on the received first instruction, the electronic device performs a power-on operation.
15. An electronic device, comprising: The electronic device comprises one or more processors and a memory; the memory is coupled to the one or more processors, the memory is used to store computer program code, the computer program code comprises computer instructions, and the one or more processors invoke the computer instructions to make the electronic device execute the method in any one of claims 1 to 14.
16. A computer readable storage medium characterized by: The computer readable storage medium comprises instructions which, when executed on an electronic device, cause the electronic device to execute the method in any one of claims 1 to 14.
17. A chip system, characterized by The chip system is applied to an electronic device; the chip system comprises one or more processors; the one or more processors are used to invoke computer instructions to make the electronic device execute the method in any one of claims 1 to 14.
Citation Information
Patent Citations
Desktop pre-starting control method and device and computer readable storage medium
CN110187925A
Card display method and terminal equipment
CN114968018A