Display method, electronic equipment and storage medium
By responding to user operations in the foldable device, acquiring and storing the editing data of shortcut switches, and generating a display interface, the problem of fixed types and quantities of shortcut switches is solved, improving user operation efficiency and experience.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- HONOR DEVICE CO LTD
- Filing Date
- 2024-10-16
- Publication Date
- 2026-04-17
AI Technical Summary
In existing electronic devices, the types and number of quick switches are fixed and cannot be changed by users, which affects the user experience.
By responding to user actions in the folding device, the system acquires and stores the editing data of shortcut switches, and generates a display interface based on this data, allowing users to change the type, quantity, and order of shortcut switches in both folded and unfolded states.
It improves the user's operating efficiency and experience on foldable devices and meets the user's personalized needs.
Smart Images

Figure CN121879875A_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of smart terminal technology, and in particular to a display method, electronic device and storage medium. Background Technology
[0002] With the development of technology, electronic devices (such as mobile phones and tablets) are becoming increasingly powerful. Currently, electronic devices can display frequently used media playback and quick-switch functions through a control center, thereby improving the ease of user operation.
[0003] Users can quickly enable or disable certain functions, such as Wi-Fi, Bluetooth, mobile data, and airplane mode, through quick switches in the control center without having to navigate through complex settings menus, thus saving time and improving operational efficiency.
[0004] However, in existing electronic devices, the types and number of quick switches are usually fixed, and users cannot change the types and number of quick switches, thus affecting the user experience. Summary of the Invention
[0005] To address the aforementioned technical problems, embodiments of this application provide a display method, an electronic device, and a storage medium. In this method, the electronic device can change the shortcut switches of the folding device display according to user needs, allowing users to easily enable or disable the functions corresponding to the shortcut switches, thereby more conveniently and quickly meeting user needs and improving user operating efficiency and user experience.
[0006] In a first aspect, embodiments of this application provide a display method applied to a foldable device. The method includes: the foldable device, in response to a first operation, acquiring first data corresponding to the first operation and storing the first data in a database; the foldable device, upon detecting a change in data in the database, acquiring second data corresponding to the first data from the database; the foldable device generating third data based on the second data, and in response to a second operation, generating a first display interface based on the third data; and the foldable device, in response to a third operation, displaying the first display interface on a first display screen of the foldable device.
[0007] The first operation refers to the operation performed in the first mode of the foldable device. The first mode can be the full-screen mode of the foldable device, or it can be the mode when the foldable device is in its unfolded state.
[0008] In this application, the first operation may be the user editing the shortcut switches in the full-screen mode of the foldable device (that is, when the foldable device is in the unfolded state).
[0009] The first data, also known as the shortcut switch editing data, can be the data of the shortcut switches that the user edits.
[0010] For example, such as Figure 6 As shown in (3), the user can move the "Sports Health" shortcut switch 323, so the first data can be the data corresponding to the "Sports Health" shortcut switch.
[0011] Specifically, users can edit shortcut switches in the full-screen mode of the foldable device. The foldable device responds to the user's operation and obtains the edit data of the shortcut switch corresponding to the user's operation.
[0012] The second type of data, namely the storage data of the shortcut switches, can be the data of the shortcut switches that the user wants to display on the control center interface, which are stored in the database.
[0013] The third data point is the information on the quick switch displayed in the second mode of the foldable device. The second mode can be the half-screen mode of the foldable device, or it can be the mode when the foldable device is in a folded state.
[0014] In this application, the third data, namely the first data to be displayed for the quick switch, can be the quick switch data that can be displayed in the control center interface on the outer screen of the folding device in the half-screen mode of the folding device (that is, when the folding device is in a folded state).
[0015] The second operation is to switch the folding device from the first mode to the second mode.
[0016] Specifically, the second operation can be the operation of switching the unfolded folding device to the folded state, that is, the user folding the folding device.
[0017] The first display interface can be the interface for displaying the control center of the quick switch in the second mode of the foldable device.
[0018] The third operation is the operation in the second mode of the folding device.
[0019] In this application, the third operation can be a user swiping down on the screen in the half-screen mode of the foldable device (i.e., when the foldable device is folded).
[0020] The first display screen can be the outer screen of a foldable device.
[0021] Specifically, the foldable device can respond to the user's folding operation and generate a first display interface based on third data. In this case, if the user swipes down on the screen while the foldable device is folded, the foldable device can respond to the user's pull-down operation and display the first display interface on the outer screen of the foldable device.
[0022] In this way, the folding device can change the quick switches displayed in the control center interface on the outer screen of the folding device according to user needs, so that users can easily enable or disable the functions corresponding to the quick switches when the folding device is in the folded state, thereby more conveniently and quickly meeting user needs, and thus improving user operating efficiency and user experience.
[0023] According to the first aspect, the folding device storing the first data in the database may include: the folding device acquiring the fourth data stored in the database; and generating the second data corresponding to the first data based on the first data and the fourth data.
[0024] The fourth type of data, namely the original data of the shortcut switches stored in the database, can be the system default data of the shortcut switches or the historical data of the shortcut switches. This application does not limit this type of data.
[0025] Understandably, the fourth data is the data of the currently displayed shortcut switches, that is, the data of the shortcut switches displayed before the user edits the shortcut switches.
[0026] In this way, the folding device can generate stored data of shortcut switches corresponding to the user's editing operations based on the original data and edit data of shortcut switches stored in the database, thereby obtaining the data of shortcut switches that the user wants to display on the control center interface.
[0027] According to the first aspect, or any implementation of the first aspect above, before the folding device obtains the fourth data stored in the database, it may further include: when the folding device is first started, obtaining the first configuration data; the folding device parses the first configuration data to obtain the fourth data, and stores the fourth data in the database.
[0028] The first configuration data can be the system configuration data for shortcut switches in the system configuration file.
[0029] At this point, the fourth data is the system default data for the shortcut switch.
[0030] In this way, when the folding device is first started, the data of the shortcut switches that have not been edited by the user (that is, the system default data of the shortcut switches) is stored in the database. Thus, when the user edits the shortcut switches, the edited data of the shortcut switches can be stored on the basis of the original data of the shortcut switches.
[0031] It's understandable that if the user edited the shortcut before this edit, the fourth data could be historical data of the shortcut. In this case, the second data corresponding to the user's previous first data can be determined as the fourth data stored in the database at the time of this first operation.
[0032] According to the first aspect, or any implementation of the first aspect above, the folding device generates second data corresponding to the first data based on the first data and the fourth data, which may include: the folding device determining the first target data; the folding device inserting the first target data into the fourth data based on the target information in the first data and the target information of each data in the fourth data; and the folding device updating the target information of each data in the fourth data to obtain the second data.
[0033] The first target data refers to data that exists in the first data set but does not exist in the fourth data set. In other words, the first target data is the data of newly added shortcut switches in the currently displayed shortcut switches.
[0034] The target information can be the location information of the shortcut switch, that is, the location of the shortcut switch when it is displayed in the control center interface.
[0035] For example, such as Figure 7c As shown, the original data is also the fourth data, and the edited data is also the first data. Data 7 and data 10 exist in the first data but not in the fourth data; therefore, data 7 and data 10 are the first target data. Thus, based on the position information of the first target data (data 7 and data 10) and the position information of each data item in the fourth data, the first target data can be sequentially inserted into the fourth data. Then, by updating the position information of each data item in the fourth data, the stored data, i.e., the second data, can be obtained.
[0036] In this way, the folding device can change the type and number of shortcut switches displayed in the control center interface on the outer screen of the folding device according to the user's needs.
[0037] According to the first aspect, or any implementation of the first aspect above, the folding device generates second data corresponding to the first data based on the first data and the fourth data, and may further include: the folding device determining the second target data; the folding device updating the target information of the second target data in the fourth data based on the target information in the first data of the second target data to obtain the second data.
[0038] The second target data is data that exists in both the first and fourth data sets. In other words, the second target data is the data of the shortcut switches whose order has been changed only in the currently displayed shortcut switches.
[0039] For example, such as Figure 7bAs shown, the original data is also the fourth data, and the edited data is also the first data. Data 2 and data 4 exist in both the first and fourth data; therefore, data 2 and data 4 are the second target data. Thus, based on the position information of the second target data in the first data, the position information of the second target data in the fourth data can be updated to obtain the stored data, i.e., the second data.
[0040] In this way, the folding device can change the order of the shortcut switches displayed in the control center interface on the outer screen of the folding device according to the user's needs.
[0041] According to the first aspect, or any implementation of the first aspect above, the folding device generates third data based on the second data, which may include: after the first listener detects a change in the data in the database, the folding device generates third data based on the second data.
[0042] In this way, when the first listener detects a change in the data in the database, the foldable device can retrieve the second data corresponding to the first data from the database and generate the third data based on the second data. When the user performs the second operation, the first display interface is generated based on the third data, so that when the user performs the third operation, the first display interface can be displayed on the first screen of the foldable device.
[0043] According to the first aspect, or any implementation of the first aspect above, the folding device generates third data based on the second data, which may include: the folding device acquiring fifth data corresponding to the folding device; and the folding device generating third data based on the second data and the fifth data.
[0044] The fifth piece of data is the whitelist data for quick switches. Specifically, the whitelist data for quick switches can be the data on quick switches that are supported for display when the foldable device is in a folded state (i.e., in half-screen mode).
[0045] In this way, the foldable device can determine which quick switches can be displayed in the half-screen mode of the foldable device based on the quick switches that the user wants to display and the quick switches that the system supports displaying.
[0046] According to the first aspect, or any implementation of the first aspect above, before the folding device obtains the fifth data corresponding to the folding device, it may further include: when the folding device is first started, the folding device obtains the second configuration data; the folding device parses the second configuration data to obtain the fifth data.
[0047] The second configuration data can be the whitelist configuration data of the shortcut switches in the system configuration file.
[0048] In this way, the foldable device can obtain whitelist data by parsing the whitelist configuration data when the foldable device is first started, thereby determining the quick switch that the system supports displaying when the foldable device is in a folded state.
[0049] According to the first aspect, or any implementation of the first aspect above, the folding device generates third data based on the second data and the fifth data, which may include: the folding device determining the third target data and defining the third target data as data in the third data; the folding device sorting each data in the third data according to the target information of the third target data in the second data; and the folding device updating the target information of each data in the third data.
[0050] The third target data is data that exists in the second data and also exists in the fifth data.
[0051] In other words, the data in the third data are the shortcut switches that exist simultaneously in the second and fifth data.
[0052] Specifically, the data in the third data can be arranged according to their positions in the second data, and the position information of each data can be updated according to the current position after the arrangement.
[0053] In this way, the folding device can accurately determine the data of the shortcut switch displayed in the second mode of the folding device.
[0054] According to the first aspect, or any implementation of the first aspect above, the folding device generates a first display interface based on the third data, which may include: the folding device determining the number of data in the third data, and determining a first rule corresponding to the first display interface based on the number of data and preset conditions; the folding device arranging each data in the third data according to the first rule to obtain the first display interface.
[0055] The preset conditions can be pre-defined conditions for the quick switch to be displayed on the external screen of the foldable device.
[0056] The first rule, also known as the first display rule, can be the rule that displays quick switches in the control center interface on the outer screen of the foldable device when the foldable device is in a folded state.
[0057] In this way, the folding device can determine the rules for displaying quick switches in the control center interface on the outer screen of the folding device, and thus determine the control center interface when the folding device is in the folded state based on the display rules.
[0058] According to the first aspect, or any implementation of the first aspect above, before the folding device arranges the data in the third data according to the first rule to obtain the first display interface, it may further include: the folding device loading the first layout corresponding to the first display interface;
[0059] The folding device arranges the data in the third data according to the first rule to obtain the first display interface, which may include: the folding device arranging the data in the third data in the first layout according to the first rule to obtain the first display interface.
[0060] The first layout could be the layout when the control center interface is displayed on the outer screen of the foldable device while it is in a folded state.
[0061] In this way, the folding device can arrange the shortcut switches to be displayed in the first layout, thereby further determining the display of the control center interface when the folding device is in the folded state.
[0062] According to the first aspect, or any implementation of the first aspect above, the folding device arranges the data in the third data in the first layout according to the first rule to obtain the first display interface, which may include: the folding device determining the target information of each data in the third data; the folding device arranging the data in the third data in the first layout in sequence according to the first rule and the target information of each data in the third data to obtain the first display interface.
[0063] Specifically, the folding device can arrange the data in the third data in the first layout according to the position information of each data in the third data.
[0064] According to the first aspect, or any implementation of the first aspect above, after the folding device obtains the second data corresponding to the first data from the database, it may further include: the folding device determining the second data as the sixth data; the folding device responding to the fourth operation generating a second display interface based on the sixth data; and the folding device responding to the fifth operation displaying the second display interface on the second display screen of the folding device.
[0065] The sixth data point is the data for the quick switch displayed in the first mode of the foldable device.
[0066] In this application, the sixth data, namely the second data to be displayed for the quick switch, can be the quick switch data that can be displayed in the control center interface of the inner screen of the folding device in the full-screen mode of the folding device (that is, when the folding device is in the unfolded state).
[0067] The fourth operation is to switch the folding device from the second mode to the first mode.
[0068] Specifically, the fourth operation can be the operation of switching the folded device from a folded state to an unfolded state, that is, the user unfolding the folded device.
[0069] The second display interface can be the interface that displays the control center for quick switches in the first mode of the foldable device.
[0070] The fifth operation is an operation performed in the first mode of the folding device.
[0071] In this application, the fifth operation can be a user swiping down on the screen in the full-screen mode of the foldable device (i.e., when the foldable device is in the unfolded state).
[0072] The second display screen can be the inner screen of the foldable device.
[0073] Specifically, the foldable device can respond to the user's unfolding operation and generate a second display interface based on the sixth data. In this case, if the user swipes down on the screen while the foldable device is in the unfolded state, the foldable device can respond to the user's pull-down operation and display the second display interface on the inner screen of the foldable device.
[0074] In this way, the folding device can change the quick switches displayed in the control center interface of the folding device's inner screen according to user needs, so that users can easily enable or disable the functions corresponding to the quick switches when the folding device is in the unfolded state.
[0075] It is understandable that after the foldable device retrieves the second data corresponding to the first data from the database, if the user does not perform the second operation (that is, the user does not switch the foldable device from full-screen mode to half-screen mode), the foldable device can directly determine the second data as the sixth data and generate a second display interface based on the sixth data. Thus, when the user swipes down on the screen, the device responds to the user's pull-down operation and displays the second display interface on the inner screen of the foldable device.
[0076] According to the first aspect, or any implementation of the first aspect above, the folding device determines the second data as the sixth data, which may include: after the second listener detects a change in the data in the database, the folding device determines the second data as the sixth data.
[0077] In this way, when the second listener detects a change in the data in the database, the foldable device can retrieve the second data corresponding to the first data from the database and determine the second data as the sixth data. When the user performs the fourth operation, the second display interface is generated based on the sixth data, so that when the user performs the fifth operation, the second display interface can be displayed on the second screen of the foldable device.
[0078] According to the first aspect, or any implementation of the first aspect above, the folding device generates a second display interface based on the sixth data, which may include: the folding device determining the second rule corresponding to the second display interface and loading the second layout corresponding to the second display interface; the folding device arranging the data in the sixth data in the second layout according to the second rule to obtain the second display interface.
[0079] The second rule, also known as the second display rule, can be a rule that displays quick switches in the control center interface of the foldable device's inner screen when the foldable device is in the unfolded state.
[0080] The second layout could be the layout when the foldable device is in the unfolded state, displaying the control center interface on the inner screen of the foldable device.
[0081] In this way, the folding device can determine the rules for displaying quick switches in the control center interface of the folding device's inner screen, and thus determine the control center interface when the folding device is in the unfolded state based on the display rules and the second layout.
[0082] According to the first aspect, or any implementation of the first aspect above, in the multi-user scenario of the foldable device, after the foldable device obtains the first data corresponding to the first operation, it may further include: the foldable device obtaining the current user ID corresponding to the first operation;
[0083] The folding device stores the first data in the database, which may include: the folding device storing the first data in the database based on the current user ID;
[0084] When the foldable device detects a change in data in the database, it retrieves the second data corresponding to the first data from the database. This may include: when the foldable device detects a change in data in the database, it determines the target user ID corresponding to the changed data in the database; when the target user ID matches the current user ID, the foldable device retrieves the second data corresponding to the target user ID from the database.
[0085] Multi-user scenarios for foldable devices, also known as multi-user modes for foldable devices.
[0086] The current user ID can be the user ID currently used by the folding device when editing the shortcut switches.
[0087] Specifically, for multi-user scenarios of foldable devices, the foldable device responds to the first operation, obtains the first data corresponding to the first operation, and obtains the current user ID corresponding to the first operation, so as to store the first data in the database according to the current user ID.
[0088] The target user ID can be the user ID corresponding to the data that has changed in the database.
[0089] Specifically, when the foldable device detects a change in the database, it can determine the target user ID corresponding to the changed data in the database. Therefore, if the target user ID matches the current user ID, it can retrieve the second data corresponding to the target user ID from the database, which is the changed data in the database.
[0090] Understandably, if the target user ID is different from the current user ID, then the monitoring of data changes in the database can continue.
[0091] In this way, the foldable device can process data based on the relationship between user ID and quick switch data in a multi-user scenario, thereby enabling different users to change the quick switches displayed in the control center interface on the outer screen of the foldable device according to their own different needs.
[0092] According to the first aspect, or any implementation of the first aspect above, the folding device stores the first data in the database based on the current user ID, which may include: the folding device obtaining the seventh data stored in the database based on the current user ID; and the folding device generating the second data corresponding to the current user ID based on the first data and the seventh data.
[0093] Among them, the user ID corresponding to the seventh data is the current user ID.
[0094] Specifically, the seventh data can be the raw data of the shortcut switch corresponding to the current user ID stored in the database.
[0095] In this way, the folding device can generate stored data for the shortcut switches corresponding to the current user ID based on the original data and edited data of the shortcut switches stored in the database.
[0096] Secondly, embodiments of this application provide an electronic device. The electronic device includes: one or more processors; a memory; and one or more computer programs, wherein the one or more computer programs are stored in the memory, and when executed by the one or more processors, the electronic device performs the display method of the first aspect and any one thereof.
[0097] The second aspect and any implementation thereof correspond to the first aspect and any implementation thereof, respectively. The technical effects of the second aspect and any implementation thereof are similar to those of the first aspect and any implementation thereof, and will not be repeated here.
[0098] Thirdly, embodiments of this application provide a computer-readable storage medium. This computer-readable storage medium includes a computer program that, when executed on an electronic device, causes the electronic device to perform the display method of the first aspect and any one thereof.
[0099] The third aspect and any implementation thereof correspond to the first aspect and any implementation thereof, respectively. The technical effects of the third aspect and any implementation thereof are similar to those of the first aspect and any implementation thereof, and will not be repeated here.
[0100] Fourthly, embodiments of this application provide a computer program product, including a computer program that, when run, causes a computer to perform a display method as described in the first aspect or any one of the first aspects.
[0101] The fourth aspect and any implementation thereof correspond to the first aspect and any implementation thereof, respectively. The technical effects of the fourth aspect and any implementation thereof are similar to those of the first aspect and any implementation thereof, and will not be repeated here.
[0102] Fifthly, this application provides a chip including a processing circuit and transceiver pins. The transceiver pins and the processing circuit communicate with each other via an internal connection path. The processing circuit executes a display method as described in the first aspect or any one thereof, to control the receiving pin to receive signals and to control the transmitting pin to transmit signals.
[0103] The fifth aspect and any implementation thereof correspond to the first aspect and any implementation thereof, respectively. The technical effects of the fifth aspect and any implementation thereof are similar to those of the first aspect and any implementation thereof, and will not be repeated here. Attached Figure Description
[0104] Figure 1 A schematic diagram of the hardware structure of an electronic device as an example;
[0105] Figure 2 A schematic diagram of the software structure of an electronic device as an example;
[0106] Figure 3 This is an example of an application scenario;
[0107] Figure 4 A flowchart illustrating one possible display method;
[0108] Figure 5 This is a schematic diagram illustrating the module interaction of a display method as an example.
[0109] Figure 6 The user interface shown is an example of a user editing a shortcut switch;
[0110] Figures 7a-7c This is a schematic block diagram illustrating the storage data for generating shortcut switches;
[0111] Figures 8a-8b This is a schematic block diagram illustrating the generation of the first set of data to be displayed for a shortcut switch;
[0112] Figure 9 The user interface under the first display rule is shown as an example;
[0113] Figure 10 This is a schematic diagram illustrating another display method as an example;
[0114] Figure 11 This is an exemplary block diagram illustrating another method for generating storage data for shortcut switches;
[0115] Figure 12 This is a schematic diagram illustrating the process of monitoring data changes in a database. Detailed Implementation
[0116] The technical solutions of the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of this application, not all embodiments. Based on the embodiments of this application, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of this application.
[0117] In this article, the term "and / or" is merely a description of the relationship between related objects, indicating that there can be three relationships. For example, A and / or B can represent three situations: A exists alone, A and B exist simultaneously, and B exists alone.
[0118] The terms "first" and "second," etc., used in the specification and claims of this application are used to distinguish different objects, not to describe a specific order of objects. For example, "first target object" and "second target object," etc., are used to distinguish different target objects, not to describe a specific order of target objects.
[0119] In the embodiments of this application, the terms "exemplary" or "for example" are used to indicate that something is an example, illustration, or description. Any embodiment or design that is described as "exemplary" or "for example" in the embodiments of this application should not be construed as being more preferred or advantageous than other embodiments or design. Specifically, the use of the terms "exemplary" or "for example" is intended to present the relevant concepts in a specific manner.
[0120] In the description of the embodiments in this application, unless otherwise stated, "multiple" means two or more. For example, multiple processing units means two or more processing units; multiple systems means two or more systems.
[0121] To better understand the embodiments of this application, the structure of the electronic device of this application is described below:
[0122] like Figure 1 The diagram shown is a structural schematic of the electronic device 100. Optionally, the electronic device 100 can be a terminal, also known as a terminal device. The terminal can be a cellular phone, tablet, wearable device, or Internet of Things device, or any other device with a display function. This application does not impose any limitations on this.
[0123] It should be understood that, Figure 1 The electronic device 100 shown is only one example of an electronic device, and the electronic device 100 may have more or fewer components than shown in the figure, may combine two or more components, or may have different component configurations. Figure 1 The various components shown can be implemented in hardware, software, or a combination of hardware and software, including one or more signal processing and / or application-specific integrated circuits.
[0124] Electronic device 100 may 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, antenna 1, antenna 2, a mobile communication module 150, a wireless communication module 160, an audio module 170, a speaker 170A, a receiver 170B, a microphone 170C, a headphone jack 170D, a sensor module 180, buttons 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 may include pressure sensors, gyroscope sensors, accelerometers, temperature sensors, motion sensors, barometric pressure sensors, magnetic sensors, distance sensors, proximity sensors, fingerprint sensors, touch sensors, ambient light sensors, bone conduction sensors, etc.
[0125] Processor 110 may include one or more processing units, such as: application processor (AP), modem processor, graphics processing unit (GPU), image signal processor (ISP), controller, memory, video codec, digital signal processor (DSP), baseband processor, and / or neural network processing unit (NPU), etc. Different processing units may be independent devices or integrated into one or more processors.
[0126] The controller can be the nerve center and command center of the electronic device 100. The controller can generate operation control signals according to the instruction opcode and timing signals to complete the control of instruction fetching and execution.
[0127] The processor 110 may also include a memory for storing instructions and data. In some embodiments, the memory in the processor 110 is a cache memory.
[0128] The wireless communication function of electronic device 100 can be realized through antenna 1, antenna 2, mobile communication module 150, wireless communication module 160, modem processor and baseband processor, etc.
[0129] Antenna 1 and antenna 2 are used to transmit and receive electromagnetic wave signals. Each antenna in electronic device 100 can be used to cover one or more communication frequency bands. Different antennas can also be multiplexed to improve antenna utilization. For example, antenna 1 can be multiplexed as a diversity antenna for a wireless local area network. In some other embodiments, the antennas can be used in conjunction with tuning switches.
[0130] The mobile communication module 150 can provide solutions for wireless communication, including 2G / 3G / 4G / 5G, applied to the electronic device 100. The mobile communication module 150 may include at least one filter, switch, power amplifier, low noise amplifier (LNA), etc.
[0131] The wireless communication module 160 can provide solutions for wireless communication applications on the electronic device 100, including wireless local area networks (WLAN) (such as wireless fidelity (Wi-Fi) networks), Bluetooth (BT), global navigation satellite system (GNSS), frequency modulation (FM), near field communication (NFC), infrared (IR) technology, etc.
[0132] In some embodiments, antenna 1 of electronic device 100 is coupled to mobile communication module 150, and antenna 2 is coupled to wireless communication module 160, so that electronic device 100 can communicate with networks and other devices through wireless communication technology.
[0133] Electronic device 100 implements display functions through a GPU, a display screen 194, and an 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 and for graphics rendering. Processor 110 may include one or more GPUs, which execute program instructions to generate or modify display information.
[0134] The display screen 194 is used to display images, videos, etc. The display screen 194 includes a display panel. In some embodiments, the electronic device 100 may include one or N display screens 194, where N is a positive integer greater than 1.
[0135] Electronic device 100 can achieve shooting functions through an ISP, camera 193, video codec, GPU, display 194, and application processor. The ISP processes data fed back from the camera 193. The camera 193 captures still images or videos. An object passes through a lens to generate an optical image that is projected onto a photosensitive element. The photosensitive element can be a charge-coupled device (CCD) or a complementary metal-oxide-semiconductor (CMOS) phototransistor. The photosensitive element converts the light signal into an electrical signal, which is then passed to the ISP for conversion into a digital image signal. The ISP outputs the digital image signal to a DSP for processing. The DSP converts the digital image signal into image signals in standard RGB, YUV, or other formats.
[0136] In some embodiments, the electronic device 100 may include one or N cameras 193, where N is a positive integer greater than 1.
[0137] The external memory interface 120 can be used to connect an external memory card, such as a Micro SD card, to expand the storage capacity of the electronic device 100. The external memory card communicates with the processor 110 through the external memory interface 120 to perform data storage functions.
[0138] Internal memory 121 can be used to store computer executable program code, which includes instructions. Processor 110 executes various functional applications and data processing of electronic device 100 by running the instructions stored in internal memory 121, such as causing electronic device 100 to implement the **method** in the embodiments of this application. Internal memory 121 may include a program storage area and a data storage area. The program storage area may store the operating system, at least one application program required for a function (such as sound playback function, image playback function, etc.), etc. The data storage area may store data created during the use of electronic device 100 (such as audio data, phone book, etc.).
[0139] In addition, the internal memory 121 may include high-speed random access memory, and may also include non-volatile memory, such as at least one disk storage device, flash memory device, universal flash storage (UFS), etc.
[0140] Electronic device 100 can implement audio functions, such as music playback and recording, through audio module 170, speaker 170A, receiver 170B, microphone 170C, headphone jack 170D, and application processor.
[0141] A pressure sensor is used to sense pressure signals and can convert these signals into electrical signals. In some embodiments, the pressure sensor may be located on the display screen 194. The electronic device 100 may also calculate the position of a touch based on the detection signal from the pressure sensor.
[0142] A touch sensor, also known as a "touch panel," can be located on the display screen 194. The touch sensor and display screen 194 together form a touchscreen, also called a "touch display." The touch sensor detects touch operations applied to or near it. The touch sensor can then transmit the detected touch operation to the application processor to determine the type of touch event. In some embodiments, the touch display can be a foldable screen.
[0143] A battery may include one or more batteries that can be used to power a load.
[0144] The charging management module 140 receives charging input from a charger. The charger can be a wireless charger or a wired charger. In some wired charging embodiments, the charging management module 140 receives charging input from the wired charger via the USB interface 130. In some wireless charging embodiments, the charging management module 140 receives wireless charging input via the wireless charging coil of the electronic device 100. While charging the battery 142, the charging management module 140 can also supply power to the electronic device via the power management module 141.
[0145] The charging management module 140 may include multiple charging chips, wherein the multiple charging chips may be connected to a battery, or each chip may be connected to a battery, so that the charging management module 140 can charge the battery through the charging chips.
[0146] The power management module 141 connects the battery 142, the charging management module 140, and the processor 110. The power management module 141 receives input from the battery 142 and / or the charging management module 140, providing power to the processor 110, memory 121, display screen 194, camera 193, and wireless communication module 160, etc. The power management module 141 can also monitor parameters such as battery capacity, battery cycle count, and battery health status (leakage current, impedance). In some other embodiments, the power management module 141 may also be located within the processor 110. In other embodiments, the power management module 141 and the charging management module 140 may be located in the same device.
[0147] The software system of electronic device 100 can adopt a layered architecture, event-driven architecture, microkernel architecture, microservice architecture, or cloud architecture. This application embodiment uses the layered architecture Android system as an example to exemplify the software structure of electronic device 100.
[0148] Figure 2 This is a software structure block diagram of the electronic device 100 according to an embodiment of this application.
[0149] The layered architecture of the electronic device 100 divides the software into several layers, each with a clear role and division of labor. Layers communicate with each other through software interfaces. In some embodiments, the Android system is divided into five layers, from top to bottom: the application layer, the application framework layer, the Android Runtime and system libraries, the hardware abstraction layer (HAL), and the kernel layer.
[0150] The application layer can include a series of application packages.
[0151] like Figure 2 As shown, the application package may include a camera, gallery, and third-party applications with camera functionality. For example, the application package may include applications such as camera, gallery, calendar, call, map, navigation, WLAN, Bluetooth, music, video, and SMS.
[0152] In some embodiments, the application layer may also include SystemUI (system user interface).
[0153] In this embodiment, SystemUI may include a shortcut toggle editing module, a database module, a data loading module, a cache, and a shortcut toggle display module.
[0154] The quick switch editing module responds to user actions in editing quick switches and retrieves the edited data. The database module stores this edited data. The data loading module loads the data to be displayed for the quick switches based on the database. The cache stores whitelist data and data to be displayed for the quick switches. The quick switch display module generates a display interface based on the data to be displayed for the quick switches and then displays it on the screen.
[0155] The application framework layer provides application programming interfaces (APIs) and a programming framework for applications in the application layer, including various components and services to support Android development. The application framework layer includes some predefined functions.
[0156] like Figure 2 As shown, the application framework layer may include a window manager, content provider, view system, resource manager, notification manager, camera service, etc.
[0157] The window manager is used to manage windowed applications. It can retrieve screen size, determine the presence of a status bar, lock the screen, and capture screenshots, among other things.
[0158] Content providers store and retrieve data, making that data accessible to applications. This data can include videos, images, audio, phone calls made and received, browsing history and bookmarks, phone books, and more.
[0159] A view system includes visual controls, such as controls for displaying text and controls for displaying images. View systems can be used to build applications. A display interface can consist of one or more views. For example, a display interface including a text notification icon could include views for displaying text and views for displaying images.
[0160] The file explorer provides applications with various resources, such as localized strings, icons, images, layout files, video files, and more.
[0161] The notification manager allows applications to display notifications in the status bar. These notifications can be used to deliver informational messages and can disappear automatically after a short pause, requiring no user interaction. For example, the notification manager can be used to notify users of download completion or message alerts. The notification manager can also display notifications as icons or scrolling text in the top status bar, such as notifications from background applications, or as dialog boxes on the screen. Examples include displaying text messages in the status bar, emitting sounds, vibrating electronic devices, and flashing indicator lights.
[0162] The Android Runtime consists of core libraries and a virtual machine. The Android Runtime is responsible for the scheduling and management of the Android system.
[0163] The core library consists of two parts: one part is the functionalities that need to be called by the Java language, and the other part is the Android core library.
[0164] The application layer and application framework layer run in a virtual machine. The virtual machine executes the Java files of the application layer and application framework layer as binary files. The virtual machine is used to perform functions such as object lifecycle management, stack management, thread management, security and exception management, and garbage collection.
[0165] System libraries can include multiple functional modules. For example: surface manager, media libraries, 3D graphics processing libraries (e.g., OpenGL ES), 2D graphics engines (e.g., SGL), etc.
[0166] The Surface Manager is used to manage the display subsystem and provides the blending of 2D and 3D layers for multiple applications.
[0167] The media library supports playback and recording of various common audio and video formats, as well as still image files. It supports multiple audio and video encoding formats, such as MPEG4, H.264, MP3, AAC, AMR, JPG, and PNG.
[0168] The 3D graphics processing library is used to implement 3D graphics drawing, image rendering, compositing, and layer processing.
[0169] A 2D graphics engine is a graphics engine for 2D drawing.
[0170] The HAL layer is the interface layer located between the operating system kernel and the hardware circuitry. The HAL layer includes, but is not limited to, a camera HAL module and an audio HAL module. The camera HAL module processes the image stream, while the audio HAL module processes the audio stream (e.g., performs noise reduction, directional enhancement, etc.).
[0171] The kernel layer is the layer between hardware and software. The kernel layer includes at least display drivers, audio drivers, camera drivers, and sensor drivers.
[0172] The hardware includes at least a processor, display, camera, and ISP. Understandably, Figure 2 The layers in the illustrated software structure and the components contained in each layer do not constitute a specific limitation on the electronic device 100. In other embodiments of this application, the electronic device 100 may include more or fewer layers than illustrated, and each layer may include more or fewer components; this application does not impose any limitations.
[0173] It is understood that, in order to implement the display method in the embodiments of this application, the electronic device includes hardware and / or software modules that perform various functions. Based on the algorithm steps of the examples described in conjunction with the embodiments disclosed herein, this application can be implemented in hardware or a combination of hardware and computer software. Whether a function is executed in hardware or by computer software driving hardware depends on the specific application and design constraints of the technical solution. Those skilled in the art can use different methods to implement the described functions for each specific application in conjunction with the embodiments, but such implementation should not be considered beyond the scope of this application.
[0174] The following describes an application scenario of an interface display method provided by an embodiment of this application.
[0175] User interface display is a common application scenario for mobile phones and other electronic devices. As users' demands for electronic devices increase, the interface display functions of these devices are becoming more sophisticated. For example, electronic devices can display frequently used media playback, quick switches, and other functions through the control center, thereby improving the convenience of user operation. Users can quickly enable or disable certain functions, such as Wi-Fi, Bluetooth, mobile data, and airplane mode, through the quick switches in the control center, without having to navigate through complex settings menus, thus saving time and improving operational efficiency.
[0176] In this scenario, a foldable phone will be used as an example for explanation.
[0177] Mobile phones are widely used in daily life, and users can choose from various form factors, such as foldable phones. In terms of portability, foldable phones are compact and easy to carry, easily fitting into a pocket or small bag, meeting users' needs for lightweight electronic devices. In terms of design, foldable phones offer unique innovation and a fashionable look, attracting consumers who pursue individuality and trends, becoming a fashion accessory. Functionally, the folding design allows for a larger screen when unfolded, satisfying users' demands for large-screen operation and visual experience, while maintaining a compact form when folded, achieving a balance between portability and a large-screen experience.
[0178] Foldable phones can include an outer screen and an inner screen. When the phone is folded, users can quickly handle simple tasks using the interface displayed on the outer screen. When the phone is unfolded, users can perform more complex office tasks using the interface displayed on the inner screen, improving work efficiency.
[0179] Both the outer and inner screens of foldable phones can display frequently used media playback, quick switches, and other functions through the control center, thereby improving user convenience. Users can quickly enable or disable certain functions, such as Wi-Fi, Bluetooth, mobile data, and airplane mode, through the quick switches in the control center interface displayed on the outer or inner screen, without having to navigate through complex settings menus, thus saving time and improving operational efficiency.
[0180] As is understood, the term "user interface" in the specification, claims, and drawings of this application refers to the medium interface through which an application or operating system interacts and exchanges information with the user. It realizes the conversion between the internal form of information and a form acceptable to the user. A common form of user interface is the graphical user interface (GUI), which refers to a user interface related to computer operation displayed graphically. It can be an icon, window, control, or other interface element displayed on the screen of an electronic device. Controls can include visual interface elements such as icons, buttons, menus, tabs, text boxes, dialog boxes, status bars, navigation bars, and widgets.
[0181] Figure 3 An exemplary user interface for a foldable phone's external screen is shown. (Example...) Figure 3 As shown in (1), when the foldable phone is in the folded state, the user interface 210 of the outer screen 200 of the foldable phone displays a page 212 with application icons and a page 211 for displaying the time and date.
[0182] Continue to refer to Figure 3 In (1), the page 212 containing application icons may include multiple application icons (e.g., clock application icon, calendar application icon, gallery application icon, music application icon, camera application icon, calculator application icon, settings application icon, etc.). A page indicator may also be displayed below these multiple application icons to indicate the positional relationship between the currently displayed page and other pages. This application embodiment does not limit the content displayed on the user interface 210.
[0183] In user interface 210, the user can swipe down from the top of the screen in the direction of the arrow. The folding phone responds to the user's swipe-down action and displays, as shown below. Figure 3 User interface 220 is shown in (2) above. User interface 220 displays a control center page 222 and a page 221 for displaying time and date.
[0184] Understandable Figure 3 The user interface 210 shown in (1) is merely an illustrative example. That is, the swipe operation by the user to move down the screen in the direction of the arrow can be an operation in the user interface 210 or an operation in other user interfaces (such as the lock screen user interface). This application does not limit this.
[0185] Continue to refer to Figure 3In (2), the control center page 222 may include component cards for displaying and managing "Wireless Network", "Bluetooth", "Brightness", "Volume", and quick switch component card 223. Multiple quick switches may be set in quick switch component card 223, such as quick switches for "Flashlight", "Personal Hotspot", "Mute", "Mobile Data", "Camera", and "Power Saving Mode".
[0186] Users can quickly enable or disable a function through the quick switch in quick switch component card 223. For example, users can turn the flashlight function on or off by clicking the control of the "flashlight" quick switch.
[0187] It should be noted that the types and quantities of quick switches in quick switch component card 223 are merely illustrative examples. This application embodiment does not limit the quick switches displayed in quick switch component card 223 on page 222 of the control center.
[0188] For existing foldable phones, when folded, the outer screen does not support displaying quick switches in the control center interface, or it only supports displaying a fixed number and type of quick switches in the quick switch component card. Users cannot change the type and number of quick switches displayed in the control center interface on the outer screen. This makes it difficult for users to quickly enable or disable certain functions when the phone is folded, resulting in cumbersome operation and a negative impact on the user experience.
[0189] To address the aforementioned technical problems, this application provides a display method. In this method, a user can edit quick switches. The foldable phone responds to the user's editing operation by storing the edited data in a database. The foldable phone monitors changes in the database and, when changes occur, retrieves the stored quick switch data from the database. Based on this stored data, it determines the data to be displayed for the quick switches and stores this data in a cache.
[0190] When a user folds the phone, placing it in the folded state, the foldable phone can respond to this action, retrieve the cached quick settings data to be displayed, and generate the first display interface based on this data. Thus, when the phone is folded, the user can swipe down from the top of the screen to access the control center interface, and the foldable phone will respond to this swipe by displaying the first display interface on the outer screen.
[0191] In this way, foldable phones can change the quick switches displayed in the control center interface on the outer screen of the foldable phone according to user needs (including changing the type, number, and order of quick switches), so that users can easily enable or disable the functions corresponding to the quick switches when the foldable phone is in the folded state, thereby more conveniently and quickly meeting the needs of users, and thus improving the user's operating efficiency and user experience.
[0192] The following describes the flow of a display method provided in an embodiment of this application, using a specific scenario as an example. Figure 4 An exemplary flowchart of a display method is shown. For example... Figure 4 As shown in the figure, the flow of a display method provided in this application embodiment may include:
[0193] Users can access the shortcut editing interface to edit the shortcuts. Specifically, users can edit the shortcuts displayed in the control center interface according to their actual needs. That is, users can edit frequently used shortcuts to make them appear in the control center interface. Similarly, users can edit unused shortcuts to make them not appear in the control center interface.
[0194] The quick switch editing module responds to user actions in editing quick switches, retrieves the edited data, and stores it in the database. Specifically, the quick switch edit data refers to the data of the quick switches displayed in the control center interface, which the user edits according to their needs. For example, if a user wants to display a "Flight Mode" quick switch in the control center interface, the quick switch editing module can retrieve the edited data for the "Flight Mode" quick switch after the user edits it.
[0195] After the shortcut switch editing data is stored in the database, the database module can generate new stored data based on the shortcut switch editing data and the original data stored in the database. It can be understood that the original data stored in the database can be the shortcut switch data stored in the database before the shortcut switch editing data was stored there.
[0196] The data loading module can monitor data changes in the database. When the data in the database changes (i.e., after the shortcut switch editing module stores the edited data of the shortcut switches in the database, and the database module generates new stored data), it retrieves the new stored data from the database, determines the data to be displayed for the shortcut switches based on the new stored data, and stores the data to be displayed for the shortcut switches in the cache. Specifically, the data to be displayed for the shortcut switches can be the data of the shortcut switches to be displayed in the control center interface.
[0197] It's understandable that the number of quick switches in the data to be displayed can be equal to or less than the number of quick switches in the newly stored data in the database. Specifically, due to system limitations or other factors, some quick switches (such as the screen recording quick switch) cannot be displayed on the outer screen of a foldable phone. Therefore, it's possible that the number of quick switches in the data to be displayed will be less than the number of quick switches in the newly stored data in the database.
[0198] In this scenario, if the user folds the phone, putting it in a folded state, the data display module can respond to the user's folding action and retrieve the data to be displayed for the quick switches from the cache.
[0199] The data display module can generate a first display interface based on the data to be displayed from the quick switch, and send the first display interface to the first display screen, so that when the user pulls down the control center interface on the first display screen, the first display interface is displayed in the control center interface.
[0200] The following specific example explains the detailed process of a display method provided in an embodiment of this application. (Refer to...) Figure 5 The display method provided in this application specifically includes:
[0201] S101. The quick switch editing module responds to the user's operation of editing quick switches, obtains the editing data of quick switches, and sends the editing data of quick switches to the database module.
[0202] The editing data for shortcut switches can include the data of the shortcut switches edited by the user, as well as the location information of the corresponding shortcut switch. The shortcut switch data can include, for example, the name, icon, or number of the shortcut switch. The location information of the shortcut switch can be the location of the shortcut switch when it is displayed in the control center interface.
[0203] Users can edit shortcut switches. The shortcut switch editing module can respond to the user's editing operation, obtain the editing data of the shortcut switches, and then send the obtained editing data of the shortcut switches to the database module.
[0204] Specifically, users can edit the quick switches displayed in the control center interface according to their actual needs when the foldable phone is in the unfolded state.
[0205] For example, Figure 6 The user interface diagram shown is an example. Figure 6As shown in (1), when the foldable phone is in the unfolded state, the user interface 310 of the inner screen 300 of the foldable phone displays a control center interface. Specifically, the user can swipe down from the top of the inner screen 300 of the foldable phone in the direction of the arrow, and the foldable phone can respond to the user's pull-down operation and display as shown in (1). Figure 6 User interface 310 shown in (1) of the document.
[0206] The user interface 310 may include setting controls, editing controls 311, various component cards, and extended controls 313.
[0207] The component cards of the user interface 310 may include component cards for displaying and managing "Wireless Network", component cards for displaying and managing "Bluetooth", component cards for displaying and managing "Brightness", component cards for displaying and managing "Volume", component cards for displaying and managing "Media Playback Function", and quick switch component card 312.
[0208] Understandably, when there are many quick switches that need to be displayed, and the quick switch component card 312 in the user interface 310 cannot be fully displayed, the user can click the extension control 313. The folded phone responds to the user's click operation and can display more quick switches (not shown in the figure).
[0209] In such Figure 6 In the user interface 310 shown in (1), the user can click the edit control 311. The folding phone can respond to the user's click operation and pop up a window 314 in the user interface 310, such as Figure 6 As shown in (2) of the text.
[0210] Reference Figure 6 In (2), the window 314 in the user interface 310 includes an "Edit shortcut switch" control 315 and a "Display trust ring" control.
[0211] It should be noted that, Figure 6 The window 314 in the user interface 310 shown in (2) is merely an illustrative example and is not intended to limit the scope of this application. That is, the controls included in the window 314 do not constitute a specific limitation on the window 314. The window 314 may also include other controls, such as the "Edit Smart Device" control, and is not intended to limit the scope of this application.
[0212] In such Figure 6 In the user interface 310 shown in (2), the user can click the "Edit Shortcut Switch" control 315 in window 314. The folding phone can respond to the user's click operation and display as shown in the image. Figure 6 User interface 320 is shown in (3) above. User interface 320 is the interface used to edit shortcut switches.
[0213] like Figure 6 As shown in (3), the user interface 320 includes a display area 321 and a display area 322. The shortcut switches displayed in the display area 321 can be shortcut switches that can be displayed in the user interface 310 (including shortcut switches displayed on the shortcut switch component card 312 and shortcut switches displayed by clicking the extended control 313). The shortcut switches displayed in the display area 322 can be shortcut switches that the foldable phone supports but are not displayed in the user interface 310.
[0214] It is understandable that the shortcut switches in display area 322 can be moved to display area 321 or replaced in display area 321 by dragging. Similarly, the shortcut switches in display area 321 can also be moved to display area 322 by dragging. Furthermore, the display order of the shortcut switches in display area 321 can be changed by dragging.
[0215] like Figure 6 As shown in (3), in the user interface 320, the user can move the "Health" shortcut switch 323 in the display area 322 to the front of the "Flashlight" shortcut switch in the display area 321 in the direction of the arrow.
[0216] After the user moves the "Health & Fitness" shortcut switch 323, they can get the following: Figure 6 User interface 320 is shown in (4) of the diagram. (See diagram 320 for example.) Figure 6 As shown in (4), the display area 321 of the user interface 320 includes a "Health" shortcut switch 323, and the positions of the "flashlight" shortcut switch in the display area 321 and the shortcut switches behind it have changed.
[0217] Based on the above scenario, the editing data for shortcut switches can include the data for the "Sports & Health" shortcut switch and the location information of that shortcut switch.
[0218] S102. After receiving the edit data of the shortcut switch, the database module stores the edit data in the database to obtain the stored data of the shortcut switch.
[0219] It is understandable that the database can store the original data of the shortcut switches. Specifically, the original data of the shortcut switches stored in the database can be the system default data of the shortcut switches or the historical data of the shortcut switches; this application does not limit this.
[0220] The system default data for shortcut switches can be the default data configured in the system, that is, data that has not been edited by any user.
[0221] It is understandable that when a user first starts up the foldable phone, the foldable phone can obtain the system configuration data of the quick switches from the system configuration file, and parse the system configuration data of the quick switches to obtain the system default data of the quick switches.
[0222] In some alternative embodiments, the SystemUI may also include an initial data parsing module.
[0223] The initial data parsing module can be used to obtain the system configuration data of the quick switch when the foldable phone is first started, and to parse the system configuration data of the quick switch to obtain the system default data of the quick switch.
[0224] Specifically, when the initial data parsing module detects the first startup of the foldable phone, it retrieves the system configuration data of the quick switch from the system configuration file, parses the system configuration data to obtain the system default data of the quick switch, and then stores the system default data of the quick switch in the database.
[0225] Therefore, the database can store the original data of the shortcut switches.
[0226] The historical data for shortcut switches can be data stored in the database after the user last edited the shortcut switches.
[0227] Specifically, after receiving the edit data of the shortcut switch, the database module can store the edit data of the shortcut switch in the database, and then generate the storage data of the shortcut switch based on the edit data and the original data stored in the database.
[0228] It is understandable that the stored data for quick switches can be the data of quick switches that the user wants to display in the control center interface.
[0229] For example, such as Figure 7a As shown, the edited data of the shortcut switches and the original data in the database are combined to generate the stored data of the shortcut switches in the database.
[0230] Specifically, based on the edited data and the original data stored in the database, the storage data for the shortcut switches is generated, which can include two cases: the first case is that only the order of the currently displayed shortcut switches has been changed; the second case is that other shortcut switches have been added to the currently displayed shortcut switches.
[0231] In the first scenario, the database module can update the position information of each data point in the original data based on the position information of each data point in the edited data, thus obtaining the stored data.
[0232] For example, such as Figure 7b As shown, assume the original data stored in the edit data includes data 1 corresponding to shortcut switch 1, data 2 corresponding to shortcut switch 2, data 3 corresponding to shortcut switch 3, and data 4 corresponding to shortcut switch 4. The position information for data 1 is "Position 1". The position information for data 2 is "Position 2". The position information for data 3 is "Position 3". The position information for data 4 is "Position 4".
[0233] Continue to refer to Figure 7b Assume the editing data for the shortcut switches includes data 2 corresponding to shortcut switch 2 and data 4 corresponding to shortcut switch 4. The position information for data 2 is "position 4", and the position information for data 4 is "position 2".
[0234] Therefore, by updating the position information of each data point in the original data, the resulting stored data may include: data 1 corresponding to shortcut switch 1, data 2 corresponding to shortcut switch 2, data 3 corresponding to shortcut switch 3, and data 4 corresponding to shortcut switch 4. Specifically, the position information of data 2 is changed to "position 4," and the position information of data 4 is changed to "position 2."
[0235] In the second scenario, the data in the edited and original data are rearranged based on their corresponding positional information to obtain the stored data for the shortcut switches. It is understandable that the positional information of the data in the original data may change after this rearrangement.
[0236] For example, such as Figure 7c As shown, assume the original data stored in the database includes data 1 corresponding to shortcut switch 1, data 2 corresponding to shortcut switch 2, data 3 corresponding to shortcut switch 3, and data 4 corresponding to shortcut switch 4. The location information for data 1 is "Location 1". The location information for data 2 is "Location 2". The location information for data 3 is "Location 3". The location information for data 4 is "Location 4".
[0237] Continue to refer to Figure 7c Assume the editing data for the shortcut switches includes data 7 corresponding to shortcut switch 7 and data 10 corresponding to shortcut switch 10. The position information for data 7 is "position 2", and the position information for data 10 is "position 4".
[0238] Therefore, the stored data for the shortcut switches, obtained by rearranging the data according to the location information, can include data 1 corresponding to shortcut switch 1, data 7 corresponding to shortcut switch 7, data 2 corresponding to shortcut switch 2, data 10 corresponding to shortcut switch 10, data 3 corresponding to shortcut switch 3, and data 4 corresponding to shortcut switch 4. Specifically, the location information of data 2 changes from "location 2" to "location 3". The location information of data 3 changes from "location 3" to "location 5". The location information of data 4 changes from "location 4" to "location 6".
[0239] S103. The data loading module listens for changes in the data in the database and retrieves the stored data of the shortcut switches in the database when the data in the database changes.
[0240] It should be noted that the step of "the data loading module listens for data changes in the database" can be executed continuously. This embodiment does not limit the execution order of this step and steps S101-S102.
[0241] Specifically, the database module stores the editable data of shortcut switches in the database. Upon obtaining the stored data of the shortcut switches, the data loading module can determine that the data in the database has changed. After determining that the data in the database has changed, the data loading module can retrieve the stored data of the shortcut switches from the database.
[0242] In an optional embodiment, the data loading module can monitor whether the data in the database has changed through a quick switch data listener. When the quick switch data listener detects a change in the data in the database, it can notify the data loading module to retrieve the stored data of the quick switches in the database.
[0243] The quick switch data listener may include a first listener and a second listener.
[0244] The first listener can be used to generate a first instruction when data in the database changes. This first instruction is used to notify the data loading module to determine the data of the quick settings displayed on the foldable phone's outer screen in the control center interface when the foldable phone is in a folded state.
[0245] The second listener can be used to generate a second instruction when data in the database changes. This second instruction is used to notify the data loading module to determine the data of the quick settings displayed on the inner screen of the foldable phone in the control center interface when the foldable phone is in the unfolded state.
[0246] Understandably, the cached data will be cleared when the foldable phone restarts. Therefore, the data loading module can also monitor the foldable phone's restart and directly retrieve the stored data of the quick switches from the database upon restart.
[0247] S104. The data loading module obtains the whitelist data of the shortcut switches stored in the cache, determines the first data to be displayed for the shortcut switches based on the whitelist data and the stored data, and stores the first data to be displayed for the shortcut switches in the cache.
[0248] Understandably, some functions are restricted when a foldable phone is folded, meaning they cannot be used in this state, such as screen recording. Therefore, the shortcuts for these restricted functions cannot be displayed in the control center interface on the foldable phone's outer screen when it's folded. Thus, it's necessary to filter the shortcuts users want to see to obtain those that can be displayed in the control center interface on the foldable phone's outer screen.
[0249] The whitelist data for quick switches is the whitelist data for foldable phones in their folded state. Specifically, the whitelist data for quick switches can be the data on quick switches that are supported for display when the foldable phone is in its folded state.
[0250] In other words, if the whitelist of quick switches includes the data corresponding to a certain quick switch, it means that the foldable phone supports displaying that quick switch when folded, and thus the quick switch can be displayed in the control center interface when the foldable phone is folded. Conversely, if the whitelist of quick switches does not include the data corresponding to a certain quick switch, it means that the foldable phone does not support displaying that quick switch when folded, and thus the quick switch cannot be displayed in the control center interface when the foldable phone is folded.
[0251] For example, if the whitelist of quick settings does not include the "screen recording" quick setting, then the "screen recording" quick setting will not be displayed in the control center interface when the foldable phone is in the folded state.
[0252] It is understandable that when a user initially starts up the foldable phone, the foldable phone can obtain the whitelist configuration data of the quick switches from the system configuration file, and parse the whitelist configuration data to obtain the whitelist data of the quick switches.
[0253] In some optional embodiments, the initial data parsing module in SystemUI can also be used to obtain the whitelist configuration data of the shortcut switch and parse the whitelist configuration data of the shortcut switch to obtain the whitelist data of the shortcut switch.
[0254] Specifically, when the initial data parsing module detects the first startup of the foldable phone, it retrieves the whitelist configuration data of the quick switch from the system configuration file, parses the whitelist configuration data to obtain the whitelist data of the quick switch, and then stores the whitelist data of the quick switch in the cache.
[0255] Therefore, the data loading module can retrieve the whitelist data of the shortcut switches from the cache.
[0256] Specifically, when the first listener detects a change in the data in the database, it sends a first instruction to the data loading module. Upon receiving this first instruction, the data loading module can then retrieve the whitelist data of the shortcut switches stored in the cache.
[0257] It should be noted that the execution order of the steps "data loading module obtains whitelist data of shortcut switches stored in cache" and "data loading module obtains storage data of shortcut switches in database" is not limited in this embodiment of the application, and the two steps can be executed simultaneously.
[0258] The first data to be displayed for the quick switch is the data of the quick switch that can be displayed in the control center interface on the outer screen of the foldable phone when the phone is folded.
[0259] Specifically, based on the whitelist data and stored data of the shortcut switches, the first data to be displayed for the shortcut switches can be determined as follows: the data corresponding to the shortcut switches that exist simultaneously in the whitelist data and the stored data can be determined as the first data to be displayed for the shortcut switches, and the position information of each data in the first data to be displayed can be updated according to the position information of each data in the stored data.
[0260] In other words, if the whitelist data contains data corresponding to a certain shortcut switch, but the stored data does not include the corresponding data for that shortcut switch, it means that the user does not want to display that shortcut switch and has not edited it. Therefore, the first data to be displayed for the shortcut switch will not contain the corresponding data for that shortcut switch.
[0261] Similarly, if the whitelist data does not contain the data corresponding to a certain shortcut switch, but the stored data includes the data corresponding to that shortcut switch, it means that the foldable phone does not support displaying that shortcut switch when it is folded. Therefore, the first data to be displayed for the shortcut switch will not contain the data corresponding to that shortcut switch.
[0262] For example, such as Figure 8aAs shown, assuming the stored data for the shortcut switches includes data 1 corresponding to shortcut switch 1, data 7 corresponding to shortcut switch 7, data 2 corresponding to shortcut switch 2, data 10 corresponding to shortcut switch 10, data 3 corresponding to shortcut switch 3, and data 4 corresponding to shortcut switch 4. The whitelist data includes data 1 corresponding to shortcut switch 1, data 3 corresponding to shortcut switch 3, data 10 corresponding to shortcut switch 10, and data 13 corresponding to shortcut switch 13. Therefore, the first set of data to be displayed for the shortcut switches can include data 1 corresponding to shortcut switch 1, data 3 corresponding to shortcut switch 3, and data 10 corresponding to shortcut switch 10.
[0263] Furthermore, based on the position information of each data point in the stored data, the position information of each data point in the first set of data to be displayed is updated. Specifically, the data points can be arranged in ascending order according to their position information in the stored data, and the position information of each data point after arrangement is updated according to its current position. The updated position information is the position information of each data point in the first set of data to be displayed.
[0264] For example, such as Figure 8b As shown, assume that the first set of data to be displayed for the shortcut switches includes data 1 corresponding to shortcut switch 1, data 3 corresponding to shortcut switch 3, and data 10 corresponding to shortcut switch 10. Furthermore, data 1 is stored at position 1, data 3 at position 5, and data 10 at position 4. Therefore, the data arranged in ascending order of position information is "data 1 -> data 10 -> data 3".
[0265] Continue to refer to Figure 8b The position information of each data item after sorting is updated according to its current position. That is, the position information of data 10 is updated to 2, and the position information of data 3 is updated to 3. Therefore, in the first set of data to be displayed, the position information of data 1 is position 1, the position information of data 10 is position 2, and the position information of data 3 is position 3.
[0266] Optionally, the first set of data to be displayed stored in the cache can be stored in a linked structure. The position of each piece of data in the first set of data to be displayed within the linked structure can correspond to the position information of each piece of data.
[0267] For example, such as Figure 8b The first data to be displayed shown is as follows: data 1 corresponding to shortcut switch 1 can be placed at the beginning of the chain structure, data 10 corresponding to shortcut switch 10 can be placed after data 1, and data 3 corresponding to shortcut switch 3 can be placed at the end of the chain structure.
[0268] S105. The data loading module determines the second data to be displayed for the shortcut switch based on the stored data of the shortcut switch, and stores the second data to be displayed for the shortcut switch in the cache.
[0269] The second set of data to be displayed for the quick switch is the data of the quick switch that can be displayed in the control center interface on the inner screen of the foldable phone when the foldable phone is in the unfolded state.
[0270] Specifically, when the second listener detects a change in the data in the database, it sends a second instruction to the data loading module. Upon receiving this second instruction, the data loading module can then determine the second data to be displayed for the shortcut switches based on the stored data.
[0271] After users edit the shortcuts according to their needs, the foldable phone stores the edited data in the database and generates the stored shortcut data based on the edited data. In other words, the stored shortcut data is the data of the shortcuts that the user wants to display in the control center interface.
[0272] Therefore, in order to display all the shortcut switches that the user wants to see in the control center interface of the foldable phone's inner screen, the foldable phone can determine the stored data of the shortcut switches as the second set of data to be displayed.
[0273] S106. The data display module responds to the user's operation of folding the phone and retrieves the first data to be displayed for the quick switch from the cache.
[0274] When a user folds their phone, the data display module can respond to this action and retrieve the first set of data to be displayed from the cached shortcut switches.
[0275] S107. The data display module determines the first display rule for the quick switches based on the number of quick switches in the first data to be displayed.
[0276] The first display rule could be to display quick switches in the control center interface on the outer screen of the foldable phone when the phone is in a folded state.
[0277] Specifically, the data display module can determine the first display rule for the quick switch based on the quick switch data in the first data to be displayed and the pre-set conditions for displaying the quick switch on the foldable phone's outer screen.
[0278] The pre-defined conditions for displaying quick switches on the outer screen of a foldable phone can include: a maximum of 2 rows of quick switches can be directly displayed in the control center interface; more than 2 rows of quick switches can be displayed by the user clicking the extended controls in the control center interface; a maximum of 3 quick switches can be displayed in each row; the quick switches in each row are arranged from left to right according to their position information; only the icons of the quick switches are displayed, and the names of the quick switches are not displayed.
[0279] Specifically, the first display rules may include: when the number of shortcut switches in the first set of data to be displayed is 0, no shortcut switches are displayed on the control center interface; when the number of shortcut switches in the first set of data to be displayed is greater than 0 and less than or equal to 3, one row of shortcut switches is displayed on the control center interface; when the number of shortcut switches in the first set of data to be displayed is greater than 3 and less than or equal to 6, two rows of shortcut switches are displayed on the control center interface; when the number of shortcut switches in the first set of data to be displayed is greater than 6, two rows of shortcut switches are displayed on the control center interface, and an expandable control is also displayed.
[0280] For example, such as Figure 9 As shown in (1), when the number of shortcut switches in the first set of data to be displayed in the user interface 401 is 2, the shortcut switches can be displayed in the first row of the shortcut switch component card 402 in the control center interface, and arranged from left to right according to the position information. Since the number of shortcut switches in the first set of data to be displayed is less than 3, one shortcut switch is displayed in the first and second positions of the first row, and the third position is empty and no shortcut switch is displayed.
[0281] For example, such as Figure 9 As shown in (2), when the number of shortcut switches in the first set of data to be displayed in the user interface 501 is 5, shortcut switches can be displayed in the first and second rows of the shortcut switch component card 502 in the control center interface. Specifically, 3 shortcut switches can be displayed in the first row and 2 shortcut switches can be displayed in the second row. Since the number of shortcut switches in the first set of data to be displayed is 5, which is less than 6, the last position of the second row of the shortcut switch component card 502 is empty.
[0282] For example, such as Figure 9 As shown in (3), in the user interface 601, when the number of shortcut switches in the first set of data to be displayed is greater than 6, 6 shortcut switches can be displayed in the shortcut switch component card 602 in the control center interface, as well as the extension control 603. The user can click the extension control 603, and the folding phone can respond to the user's operation by displaying more shortcut switches, such as... Figure 9 As shown in (4) of the text.
[0283] For example, such as Figure 9As shown in (4), when the number of quick switches in the first set of data to be displayed is greater than 6, the foldable phone can display more quick switches in the quick switch component card 702 of the user interface 701. The user can move up and down in the direction of the arrow to slide and display the quick switch component card 702 page. The user can also click the extension control 703, and the foldable phone will respond to the user's operation and return to the previous screen. Figure 9 User interface 601 shown in (3) of the document.
[0284] S108. The data display module loads the first layout and arranges the shortcut switches in the first data to be displayed in the first layout according to the first display rules to obtain the first display interface.
[0285] The first layout can be the layout when the foldable phone is in a folded state and the control center interface is displayed on the outer screen of the foldable phone. The first layout can include at least the first component card.
[0286] The first component card can be a component card that displays quick switches in the control center interface of the foldable phone's outer screen. That is, the data display module can load a first layout to display the quick switches from the first set of data to be displayed in the first component card of the first layout.
[0287] For example, such as Figure 3 As shown in (2) in the first layout, the first component card in the first layout can be the quick switch component card 223.
[0288] Specifically, after loading the first layout, the data display module can update the configuration information of the first component card and update the card height of the first component card according to the first display rules, so that the shortcut switches in the first data to be displayed can be arranged in the first component card of the first layout, thereby obtaining the first display interface.
[0289] It should be noted that the relevant processing procedures for "updating the configuration information of the first component card" can be found in existing technologies and will not be repeated here.
[0290] S109. The data display module sends the first display interface to the first display screen. When the user pulls down to display the control center, the first display screen responds to the user's operation and displays the first display interface.
[0291] The first display screen can be the outer screen of a foldable phone.
[0292] When the foldable phone is folded, users can swipe down on the screen. The foldable phone will respond to the user's swipe down and display the first display interface on the outer screen of the foldable phone.
[0293] S110 The data display module responds to the user's operation of unfolding the phone and retrieves the second data to be displayed for the quick switch from the cache.
[0294] When a user unfolds their foldable phone, the phone switches from a folded state to an unfolded state. The data display module can then respond to this action by retrieving the second set of data to be displayed from the cached shortcut switches.
[0295] It is understood that in this embodiment of the application, when the user edits the shortcut switch, the foldable phone is in the unfolded state. At this time, the data display module can directly obtain the second data to be displayed for the shortcut switch from the cache without waiting for the foldable phone to switch states.
[0296] S111 The data display module determines the second display rule for the shortcut switches and loads the second layout. According to the second display rule, the shortcut switches in the second data to be displayed are arranged in the second layout to obtain the second display interface.
[0297] The second display rule could be to display quick switches in the control center interface on the inner screen of the foldable phone when the phone is in the unfolded state.
[0298] For example, the second display rule may include: each row can display 4 shortcut switches, and the shortcut switch icon includes the shortcut switch name, etc. This application does not limit this.
[0299] It should be noted that the relevant processing flow for "determining the second display rule for shortcut switches" can be found in existing technologies and will not be repeated here.
[0300] The second layout could be the layout when the foldable phone is in its unfolded state, displaying the control center interface on the inner screen of the foldable phone. The second layout could include at least a second component card.
[0301] The second component card can be a component card that displays quick switches in the control center interface of the foldable phone's inner screen. That is, the data display module can load a second layout to display the quick switches from the second set of data to be displayed in the second component card of the second layout.
[0302] For example, such as Figure 6 As shown in (1), the second component card in the second layout can be the quick switch component card 312.
[0303] Specifically, after loading the second layout, the data display module can update the configuration information of the second component card and update the card height of the second component card according to the second display rules, so that the shortcut switches in the second data to be displayed can be arranged in the second component card of the second layout, thereby obtaining the second display interface.
[0304] It should be noted that the relevant processing procedures for "updating the configuration information of the second component card" can be found in existing technologies and will not be repeated here.
[0305] S112, The data display module sends the second display interface to the second display screen. When the user pulls down to display the control center, the second display screen responds to the user's operation and displays the second display interface.
[0306] The second display screen can be the inner screen of a foldable phone.
[0307] When the foldable phone is in the unfolded state, the user can swipe down on the screen. The foldable phone responds to the user's swipe down and displays a second display interface on the inner screen of the foldable phone.
[0308] The above describes the display process of a foldable phone in single-user mode. The following explains the specific process of the display process of a foldable phone in multi-user mode.
[0309] For foldable phones that support multi-user mode, multiple users can use the same foldable phone and create their own user IDs (accounts) on it. The foldable phone can store data about a user's usage, such as browsing history and downloaded applications, under the user ID they created.
[0310] Reference Figure 10 The process of the display method for a foldable phone in multi-user mode provided in this application specifically includes:
[0311] S201. The quick switch editing module responds to the user's operation of editing quick switches, obtains the editing data of the quick switches and the current user ID corresponding to the editing data, and sends the editing data of the quick switches and the current user ID to the database module.
[0312] The current user ID can be the user ID currently used by the foldable phone when editing the shortcut switches.
[0313] S202. After receiving the edit data of the shortcut switch and the current user ID, the database module stores the edit data of the shortcut switch in the database according to the current user ID, and obtains the stored data of the shortcut switch corresponding to the current user ID.
[0314] For multi-user scenarios, the database can store the original data of shortcut switches corresponding to each user ID. That is, the original data of shortcut switches stored in the database corresponds one-to-one with each user, and each user has the original data of shortcut switches corresponding to them.
[0315] For example, such as Figure 11As shown, assuming that the user IDs created in the foldable phone include user A, user B, and user C, then the database can store the original data of the shortcut switches corresponding to user A, user B, and user C.
[0316] Specifically, the original data of the shortcut switches corresponding to each user stored in the database can be the system default data of the shortcut switches or the historical data of the shortcut switches corresponding to each user. This application does not limit this.
[0317] The system default data for each user's shortcut switches can also be obtained by parsing the system configuration data of the shortcut switches in the system configuration file.
[0318] Specifically, when a user creates a new user ID, the foldable phone can obtain the system default data of the shortcut switches obtained by parsing the system configuration data of the shortcut switches in the system configuration file, and then use the system default data of the shortcut switches as the original data of the shortcut switches corresponding to the new user ID.
[0319] The historical data for each user's shortcut switches can be the data stored in the database after each user edited the shortcut switches when using the foldable phone under their created user ID.
[0320] Specifically, in a multi-user scenario, after receiving the edit data of the shortcut switch and the current user ID, the database module can determine the original data stored in the database corresponding to the current user ID based on the current user ID, and then generate the storage data of the shortcut switch corresponding to the current user ID based on the original data corresponding to the current user ID and the edit data of the shortcut switch.
[0321] For example, such as Figure 11 As shown, assuming user A edits the shortcut switch, after the shortcut switch editing module sends the edited data of the shortcut switch corresponding to user A to the database module, the database module can determine the original data corresponding to user A, and generate the stored data of the shortcut switch corresponding to user A based on the edited data and the original data.
[0322] Understandably, in a multi-user scenario, if one user edits a shortcut switch, only the original data of that user's shortcut switch in the database will change; the original data of the shortcut switches for other users who did not edit their shortcut switches will not change.
[0323] S203. The data loading module monitors data changes in the database and determines the target user ID corresponding to the changed data when changes occur. If the current user ID matches the target user ID, the data loading module retrieves the stored data of the shortcut switch corresponding to the target user ID from the database.
[0324] The target user ID can be the user ID corresponding to the data that has changed in the database.
[0325] For multi-user scenarios, after determining that the data in the database has changed, the data loading module can determine the target user ID corresponding to the changed data and check whether the current user ID is consistent with the target user ID.
[0326] If the current user ID matches the target user ID, the data loading module can retrieve the stored data of the shortcut switch corresponding to the target user ID from the database.
[0327] If the current user ID does not match the target user ID, the data loading module can continue to monitor changes in the database until the current user ID matches the target user ID.
[0328] For example, such as Figure 12 As shown, the data loading module monitors whether the data in the database has changed. Assuming user A's data has changed, the data loading module determines whether the current user is user A. If the current user is user A, the data loading module can retrieve user A's stored data from the database. If the current user is not user A, the data loading module continues to monitor whether the data in the database has changed.
[0329] Understandably, the cached data will be cleared when the foldable phone restarts or the user changes their user ID. Therefore, the data loading module can monitor for foldable phone restarts and user ID changes, and directly retrieve the stored data of the quick settings switches from the database when the foldable phone restarts or the user ID changes.
[0330] S204. The data loading module obtains the whitelist data of the shortcut switches stored in the cache, determines the first data to be displayed for the shortcut switches based on the whitelist data and the stored data, and stores the first data to be displayed for the shortcut switches in the cache.
[0331] S205. The data loading module determines the second data to be displayed for the shortcut switch based on the stored data of the shortcut switch, and stores the second data to be displayed for the shortcut switch in the cache.
[0332] S206. The data display module responds to the user's operation of folding the phone and retrieves the first data to be displayed for the quick switch from the cache.
[0333] S207. The data display module determines the first display rule for the quick switches based on the number of quick switches in the first data to be displayed.
[0334] S208. The data display module loads the first layout and, according to the first display rules, arranges the shortcut switches in the first data to be displayed in the first layout to obtain the first display interface.
[0335] S209. The data display module sends the first display interface to the first display screen. When the user pulls down to display the control center, the first display screen responds to the user's operation and displays the first display interface.
[0336] S210 The data display module responds to the user's operation of unfolding the phone and retrieves the second data to be displayed for the quick switch from the cache.
[0337] S211. The data display module determines the second display rule for the shortcut switches and loads the second layout. According to the second display rule, the shortcut switches in the second data to be displayed are arranged in the second layout to obtain the second display interface.
[0338] It should be noted that the processing flow of steps S204-S211 is the same as that of steps S105-S111, and will not be described again here.
[0339] It should be noted that the above embodiments are explained using a foldable phone as an example. The same applies to other electronic devices with foldable functions, and will not be elaborated further here.
[0340] This embodiment also provides a computer storage medium storing computer instructions. When the computer instructions are executed on an electronic device, the electronic device performs the aforementioned related method steps to implement the display method in the above embodiment.
[0341] This embodiment also provides a computer program product that, when run on a computer, causes the computer to perform the aforementioned steps to implement the display method described in the above embodiment.
[0342] In addition, embodiments of this application also provide an apparatus, which may specifically be a chip, component, or module. The apparatus may include a connected processor and a memory; wherein the memory is used to store computer execution instructions, and when the apparatus is running, the processor may execute the computer execution instructions stored in the memory to cause the chip to execute the display methods in the above-described method embodiments.
[0343] In this embodiment, the electronic devices (such as mobile phones), computer storage media, computer program products or chips are all used to execute the corresponding methods provided above. Therefore, the beneficial effects they can achieve can be referred to the beneficial effects in the corresponding methods provided above, and will not be repeated here.
[0344] Through the above description of the embodiments, those skilled in the art will understand that, for the sake of convenience and brevity, only the division of the above functional modules is used as an example. In actual applications, the above functions can be assigned to different functional modules as needed, that is, the internal structure of the device can be divided into different functional modules to complete all or part of the functions described above.
[0345] In the several embodiments provided in this application, it should be understood that the disclosed apparatus and methods can be implemented in other ways. For example, the apparatus embodiments described above are merely illustrative; for instance, the division of modules or units is only a logical functional division, and in actual implementation, there may be other division methods. For example, multiple units or components may be combined or integrated into another apparatus, or some features may be ignored or not executed. Furthermore, the mutual coupling or direct coupling or communication connection shown or discussed may be through some interfaces; the indirect coupling or communication connection between apparatuses or units may be electrical, mechanical, or other forms.
[0346] The above-described embodiments are only used to illustrate the technical solutions of this application, and are not intended to limit it. Although this application has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some of the technical features. Such modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the scope of the technical solutions of the embodiments of this application.
Claims
1. A display method, characterized in that, Applied to folding devices, the method includes: In response to a first operation, first data corresponding to the first operation is acquired and the first data is stored in a database; wherein the first operation is an operation in a first mode of the folding device; When a change is detected in the database, second data corresponding to the first data is retrieved from the database. Based on the second data, third data is generated; wherein, the third data is data of the shortcut switch displayed in the second mode of the folding device; In response to the second operation, a first display interface is generated based on the third data; wherein the second operation is the operation of switching the folding device from the first mode to the second mode; In response to a third operation, the first display interface is displayed on the first display screen of the folding device; wherein the third operation is an operation in the second mode of the folding device.
2. The method according to claim 1, characterized in that, The step of storing the first data in the database includes: Retrieve the fourth data stored in the database; Based on the first data and the fourth data, the second data corresponding to the first data is generated.
3. The method according to claim 2, characterized in that, Before obtaining the fourth data stored in the database, the method further includes: When the folding device is first started, first configuration data is acquired; The first configuration data is parsed to obtain the fourth data, and the fourth data is stored in the database.
4. The method according to claim 2, characterized in that, The step of generating the second data corresponding to the first data based on the first data and the fourth data includes: Determine the first target data; wherein the first target data is data that exists in the first data and does not exist in the fourth data; Based on the target information of the first target data in the first data and the target information of each data in the fourth data, the first target data is inserted into the fourth data; The target information of each data in the fourth data is updated to obtain the second data.
5. The method according to claim 2, characterized in that, The step of generating the second data corresponding to the first data based on the first data and the fourth data further includes: Determine the second target data; wherein the second target data is data that exists in the first data and also exists in the fourth data; Based on the target information of the second target data in the first data, the target information of the second target data in the fourth data is updated to obtain the second data.
6. The method according to claim 1, characterized in that, The step of generating third data based on the second data includes: After the first listener detects a change in the data in the database, it generates the third data based on the second data.
7. The method according to claim 1 or 6, characterized in that, The step of generating third data based on the second data includes: Obtain the fifth data corresponding to the folding device; The third data is generated based on the second data and the fifth data.
8. The method according to claim 7, characterized in that, Before acquiring the fifth data corresponding to the folding device, the method further includes: When the folding device is first started, the second configuration data is acquired; The second configuration data is parsed to obtain the fifth data.
9. The method according to claim 7, characterized in that, The step of generating the third data based on the second data and the fifth data includes: Determine the third target data; wherein, the third target data is data that exists in the second data and also exists in the fifth data; The third target data is determined to be the data in the third data; Based on the target information of the third target data in the second data, sort the data in the third data; The target information of each data in the third data is updated.
10. The method according to claim 1, characterized in that, The step of generating the first display interface based on the third data includes: Determine the number of data in the third data, and determine the first rule corresponding to the first display interface based on the number of data and preset conditions; According to the first rule, the data in the third data are arranged to obtain the first display interface.
11. The method according to claim 10, characterized in that, Before arranging the data in the third data according to the first rule to obtain the first display interface, the method further includes: Load the first layout corresponding to the first display interface; The step of arranging the data in the third data according to the first rule to obtain the first display interface includes: According to the first rule, the data in the third data are arranged in the first layout to obtain the first display interface.
12. The method according to claim 11, characterized in that, The step of arranging the data in the third data in the first layout according to the first rule to obtain the first display interface includes: Determine the target information for each data point in the third data set; Based on the first rule and the target information of each data in the third data, the data in the third data are arranged sequentially in the first layout to obtain the first display interface.
13. The method according to claim 1, characterized in that, After retrieving the second data corresponding to the first data from the database, the method further includes: The second data is determined as the sixth data; wherein, the sixth data is the data of the shortcut switch displayed in the first mode of the folding device; In response to the fourth operation, a second display interface is generated based on the sixth data; wherein the fourth operation is the operation of switching the folding device from the second mode to the first mode; In response to the fifth operation, the second display interface is displayed on the second display screen of the folding device; wherein the fifth operation is an operation in the first mode of the folding device.
14. The method according to claim 13, characterized in that, The step of determining the second data as the sixth data includes: After the second listener detects a change in the data in the database, the second data is identified as the sixth data.
15. The method according to claim 13, characterized in that, The step of generating a second display interface based on the sixth data includes: Determine the second rule corresponding to the second display interface, and load the second layout corresponding to the second display interface; According to the second rule, the data in the sixth data are arranged in the second layout to obtain the second display interface.
16. The method according to claim 1, characterized in that, In the multi-user scenario of the folding device, After acquiring the first data corresponding to the first operation, the method further includes: Obtain the current user ID corresponding to the first operation; The step of storing the first data in the database includes: The first data is stored in the database based on the current user ID; When a change is detected in the database, retrieving second data corresponding to the first data from the database includes: When a change is detected in the database, the target user ID corresponding to the changed data in the database is determined; When the target user ID matches the current user ID, the second data corresponding to the target user ID is retrieved from the database.
17. The method according to claim 16, characterized in that, The step of storing the first data in the database according to the current user ID includes: Based on the current user ID, obtain the seventh data stored in the database; wherein the user ID corresponding to the seventh data is the current user ID; Based on the first data and the seventh data, generate second data corresponding to the current user ID.
18. An electronic device, characterized in that, include: One or more processors; Memory; And one or more computer programs, wherein the one or more computer programs are stored on the memory, and when the computer programs are executed by the one or more processors, cause the electronic device to perform the display method as described in any one of claims 1-17.
19. A computer-readable storage medium comprising a computer program, characterized in that, When the computer program is run on an electronic device, it causes the electronic device to perform the display method as described in any one of claims 1-17.