Display method and electronic device when display mode is switched
By obtaining and processing changes in display mode configuration information, determining and refreshing the interface, the problem of abnormal display when switching display modes is solved and the user experience is improved.
Patent Information
- Application Number
- CN202311225004.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2023-09-19
- Publication Date
- 2024-10-18
- Estimated Expiration
- 2043-09-19
AI Technical Summary
When the display mode is switched, the display content of the terminal may be abnormal, especially when the switching of the display mode causes the screen layout or display area parameters to change, resulting in a poor visual experience for the user.
By obtaining display mode information, it is determined that a switching event occurs on the screen, and based on the switching event type and change information, it is decided whether to refresh the target interface, ensuring that the interface adapts to the new display mode and layout, and avoiding display abnormalities when switching display modes. Specific steps include obtaining changes in display mode configuration information, filtering unnecessary information, generating refresh status information, and refreshing the interface to adapt to the new display mode when necessary.
It effectively avoids interface adaptation problems when switching display modes, improves the user's visual experience, and ensures that the target interface can fully display content after switching and adapt to the new display area.
Smart Images

Figure CN117348827B_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the technical field of electronic devices, and in particular to a display method and electronic device when a display mode is switched. Background Art
[0002] At present, with the continuous advancement of terminal technology and equipment, the styles and types of terminals are constantly enriched. For example, traditional terminals adopt a flat screen design. With the popularization of various applications, people's demand for large-screen mobile phones is becoming stronger and stronger. However, large-screen mobile terminals (such as mobile phones) are inconvenient to carry. Therefore, foldable screen mobile terminals with extendable and bendable screens are popular among users. For another example, the terminal can realize multiple screen displays by expanding the display device.
[0003] When the terminal's display content switches from one screen to another, or when the screen switches from one state to another, a display mode switching event occurs. If the parameters of the display area (screen) where the display content is located are different before and after the display mode switching, the display content may be abnormal. Summary of the invention
[0004] The display method and electronic device provided in the embodiments of the present application when switching display modes can avoid the problem of abnormal display content when switching display modes.
[0005] In a first aspect, an embodiment of the present application provides a display method when a display mode is switched, which is applied to a terminal, and the terminal includes a screen; the display method includes:
[0006] Get the display mode information of the terminal;
[0007] When it is determined according to the display mode information that a display mode switching event occurs on the screen, obtaining change information of the display mode configuration information corresponding to the display mode switching event;
[0008] When the type of the display mode switching event is the first type, obtaining state information for indicating a screen layout change event according to change information of the display mode configuration information;
[0009] When it is determined that the status information indicating the screen layout change event indicates that the screen layout information of the screen has changed, and the type of the switching event is the first type, refreshing the target interface of the application displayed on the screen;
[0010] According to the change information of the display mode configuration information, a refreshed target interface is displayed on the screen.
[0011] Generally, when a display mode switching event occurs, the WMS module of the terminal's application framework layer (Framework) obtains the change information of the display mode configuration information, and then processes the change information of the display mode configuration information according to the pre-configured processing flow, and finally further judges or reports the processed change information. Through the steps of the aforementioned display method, on the basis of the original processing logic of the terminal application framework layer, an operation of judging whether to refresh the target interface is added, thereby eliminating the need for large-scale adjustments to the original processing logic of the terminal application framework layer, thereby improving the convenience of the application.
[0012] In the event of a display mode switching event, the status information is first determined based on the change information of the display mode configuration information, and whether to refresh the target interface is determined based on the data items that have changed in the display mode configuration information. When the target interface needs to be refreshed, the status information is recorded, and when the change information of the display mode configuration information and the type of switching event meet the requirements for refreshing the target interface, the target interface is refreshed to avoid the situation where the target interface and the switched display mode are not sufficiently compatible when the display mode is switched, which affects the user's visual intuition and improves the visual effect when the user uses the application.
[0013] In one embodiment, the display method when the display mode is switched further includes:
[0014] When the status information for indicating the screen layout change event indicates that the screen layout of the screen has not changed, and the type of the switching event is the second type, filtering the change information of the display mode configuration information to obtain filtered first information;
[0015] The filtered first information is sent to the application layer, and the filtered first information is used to instruct the application to change the interface parameters of the target interface displayed on the screen.
[0016] Display mode switching events are not equivalent to screen layout change events. Display mode switching events may cause changes to multiple data items in the display mode configuration information, which may include data items corresponding to the screen layout change event. If the change information of the display mode switching event does not include data items corresponding to the screen layout change event, it means that the screen layout has not changed due to the switching of the display mode.
[0017] If the status information representing the screen layout change event indicates that the screen layout has not changed, the screen layout of the display mode before the switching event and the display mode after the switching event are the same, and there is no need to use the method of refreshing the target interface to adapt to the new screen layout, because the screen layout is the same before and after the switching event, and the corresponding target interface is displayed on the screen with the same aspect ratio and other parameters. Failure to refresh the target interface will not have an adverse effect on the user's intuitive vision of viewing the target interface. Therefore, if the screen layout has not changed and the type of the switching event is the second type, the target interface can be refreshed to reduce the operation of the terminal system.
[0018] In one embodiment, the display method when the display mode is switched further includes:
[0019] Filter the change information of the display mode configuration information to obtain filtered second information;
[0020] When the status information indicating the screen layout change event indicates that the screen layout of the terminal has changed, and the type of the switching event is the first type, generating new change information of the display mode configuration information according to the filtered second information;
[0021] According to the change information of the new display mode configuration information and the screen layout information, second change information of the display mode configuration information is obtained; the second change information of the display mode configuration information is used to obtain the refreshed target interface.
[0022] Generally, when a display mode switching event occurs, the change information of the display mode configuration information is obtained, and then the change information of the display mode configuration information is filtered to determine the data items that the application needs to pay attention to and refer to to modify the target interface, and the application is notified based on the remaining data items after filtering, so that the application modifies the target interface accordingly.
[0023] In the embodiment of the present application, when the status information indicating the screen layout change event indicates that the screen layout of the terminal has changed, and the type of the switching event is the first type, it is considered that the difference in display mode before and after the switching event occurs belongs to the first type, that is, according to the display mode before and after the switching event occurs, it is determined that the target interface needs to be refreshed. Then, in combination with whether the display mode configuration information contains the specified screen layout information, it is determined that the target interface needs to be refreshed, and then in combination with the result of the double condition determination, the second change information for obtaining the refreshed target interface is generated, so that the application can refresh the target interface according to the second change information.
[0024] In one implementation, refreshing a target interface of an application displayed on a screen includes:
[0025] A target interface refresh request and second change information of the display mode configuration information are sent to the application layer of the terminal, so that the application generates a refreshed target interface according to the second change information of the display mode configuration information.
[0026] The window management service of the terminal sends a refresh request for the target interface to the application. When sending the refresh request, the second change information is carried, so that the application of the terminal refreshes the target interface according to the second change information, and obtains the target interface adapted to the second change information of the display mode configuration information, thereby avoiding the problem that the target interface is displayed according to the parameters of the display mode before switching in the display mode after switching, resulting in the target interface being unable to fill the display area of the screen and the target interface being unable to display all the content in the display area after the display mode is switched.
[0027] In one implementation, obtaining second change information of the display mode configuration information according to the change information of the new display mode configuration information and the screen layout information includes:
[0028] The screen layout information is added to the change information of the new display mode configuration information to obtain the second change information of the display mode configuration information.
[0029] In general, each application will set corresponding filtering conditions. When the display mode configuration information changes, the change information of the display mode configuration information is obtained, and the change information is filtered according to the filtering conditions. The filtering conditions configured by each application are mainly used to filter the change information that does not require the application to pay attention to, so that when a display mode switching event occurs during the operation of the application, as few adjustments as possible are made to the generated target interface. However, sometimes, if some parameters of the target interface are not changed after a display mode switching event occurs in the terminal, certain display problems will occur.
[0030] In an embodiment of the present application, after the filtering step is executed, it is determined whether the obtained second change information needs to be changed based on the type of switching event and whether the change information includes data items corresponding to the screen layout information. If it is determined that a change is required, the screen layout information is added to the change information of the filtered new display mode configuration information. This ensures that the screen layout information that affects the display effect can be sent to the application when the target interface needs to be refreshed, so that the application will not ignore the change of the screen layout information due to filtering.
[0031] In one implementation, adding the screen layout information to the change information of the new display mode configuration information includes:
[0032] The screen layout information and the change information of the new display mode configuration information are connected by an OR operation instruction, so that the screen layout information is added to the change information of the new display mode configuration information.
[0033] The screen layout information contained in the change information of the display mode configuration information before filtering and the new display mode configuration information obtained after filtering are connected with an OR operation instruction, thereby ensuring that the application can also receive the screen layout information connected with the OR operation instruction when the new display mode configuration information is received, and then adjust the refreshed target interface according to the screen layout information, so that the refreshed target interface is adapted to the display area after the display mode is switched.
[0034] In one embodiment, the display method when the display mode is switched further includes:
[0035] In a case where the change information of the display mode configuration information includes screen layout information, determining that the state information indicating the screen layout change event indicates that the screen layout of the terminal has changed;
[0036] According to the display mode information, the type of the display mode switching event is obtained.
[0037] Before determining to refresh the target interface, it is necessary to determine whether the terminal meets two conditions: one is the type of the display mode switching event, and the other is whether the screen layout information changes when the display mode switching event occurs. If both conditions are met, it is determined to request the application to refresh the target interface.
[0038] In one implementation, determining state information for a screen layout change event according to change information of display mode configuration information includes:
[0039] When the change information of the display mode configuration information includes the screen layout information, a flag local variable is generated as the status information of the screen layout change event;
[0040] The flag local variable is assigned a first value to indicate that the status information of the screen layout change event indicates that the screen layout of the terminal has changed.
[0041] Since it has been determined that the type of the switching event is the first type, then when it is further determined that the change information of the display mode configuration information includes the screen layout information, the switching event is determined to be an event that requires the application's attention, and the screen layout information has also changed, thereby determining that the application can be requested to refresh the target interface. In general, a series of processing operations need to be performed on the change information of the display mode configuration information in the window management service module of the terminal, including judgment, filtering, sending, etc. In an embodiment of the present application, before filtering the change information of the display mode configuration information, a flag local variable is generated as an indication of whether to refresh the target interface, so that there is no need to change the normal processing flow of the window management service for the change information of the display mode configuration information, and the screen layout information and other information that play a decisive role in whether to refresh the target interface will not be lost due to the filtering of the change information of the display mode configuration information by the window management service module, thereby facilitating an accurate judgment on whether to refresh the target interface.
[0042] In one implementation, obtaining state information for indicating a screen layout change event according to change information of the display mode configuration information includes:
[0043] When the display mode configuration information change information does not include the screen layout information, the flag local variable is assigned a second value to indicate that the screen layout of the terminal indicated by the status information indicating the screen layout change event has not changed.
[0044] In a specific implementation, the flag local variable is assigned the second value by default, indicating that the target interface does not need to be refreshed. Therefore, when the display mode configuration information change information does not include the screen layout information, the flag local variable is not modified, and retains the second value.
[0045] In one embodiment, the screen is a folding screen; the folding screen can be folded to form at least two screens, the at least two screens include a first screen and a second screen, and when the folding screen is in an unfolded state, the first screen and the second screen are opposite to each other; the screen switching event includes: the target interface is switched from being displayed on the first screen to being displayed on the second screen; and the refreshed target interface is displayed on the screen, including:
[0046] The refreshed target interface is displayed on the second screen.
[0047] When the screen of the terminal is a folding screen, the screen position of the target interface is different before and after the display mode switching event, resulting in different display mode configuration information of the target interface on the terminal before and after the display mode switching event. Before the switching event occurs, the target interface is displayed on the first screen of the folding screen, and after the switching event occurs, the target interface is displayed on the second screen opposite to the first screen.
[0048] In one embodiment, when the change information of the display mode configuration information includes screen layout information, the screen layout information includes screen size level information and wide screen indication information before the display mode switching event, and screen size level information and wide screen indication information after the display mode switching event.
[0049] In the source code, when the folding screen switches the display mode, the values of the screen size, minimum screen size, and screen layout information in the change information of the display mode configuration information are filtered according to the threshold configured by the application. If the screen layout information is filtered out, some application interfaces will not adapt to the screen after the display mode is switched. In the embodiment of the present application, this scenario is judged, and then the value of the screen layout information is added back to the change information of the display mode configuration information. The window management service determines whether to refresh the target interface of the application based on the flag local variable, ensuring that the application interface before and after the switch adapts to the size of the screen.
[0050] In one embodiment, the display method when the display mode is switched further includes:
[0051] When the folding screen changes from an unfolded state to a folded state, or when the folding screen changes from a folded state to an unfolded state, determining that the screen switching event that occurs is of the first type;
[0052] When the folding screen changes from an unfolded state to a hovering state, or when the folding screen changes from a folded state to a hovering state, it is determined that the screen switching event that occurs is of the first type.
[0053] In this embodiment, the type of screen switching event can be determined according to the characteristics of the terminal with a foldable screen, so that when the foldable screen switches between the folded and unfolded states, it can be accurately determined whether to refresh the target interface.
[0054] In one embodiment, the display method when the display mode is switched further includes:
[0055] When the type of the display mode switching event is the second type, filtering the change information of the display mode configuration information to obtain filtered third information;
[0056] The filtered third information is reported to the application layer of the terminal, and the filtered third information is used to instruct the application to change the target interface displayed on the screen.
[0057] When the type of the switching event meets the condition of refreshing the target interface, but the change information of the display mode configuration information does not include the screen layout information, it is still considered that there is no need to refresh the target interface, and the filtered third information is directly reported.
[0058] In one implementation, the change information of the display mode configuration information includes at least one kind of information, and each kind of change information of the display mode configuration information records the parameters before the switching event of the display mode and the parameters after the switching event of the display mode; filtering the change information of the display mode configuration information includes:
[0059] For each display mode configuration information change information, when the parameters before the display mode switching event and the parameters after the display mode switching event are both greater than a preset threshold, the parameters before the display mode switching event and the parameters after the display mode switching event are filtered out;
[0060] For each display mode configuration information change information, when the parameters before the display mode switching event and the parameters after the display mode switching event are both less than a preset threshold, the parameters before the display mode switching event and the parameters after the display mode switching event are filtered out.
[0061] By performing one-sided filtering through a preset threshold, when the change in the display mode configuration information is not large enough, the application can ignore the change information, thereby minimizing unnecessary changes to the display parameters of the target interface.
[0062] In one implementation, the change information of the display mode configuration information includes: change information of the available screen size and change information of the physical screen size.
[0063] In an embodiment of the present application, the change information of the display mode configuration information may include multiple data items, and different data items are used to represent changes in different dimensions of the display mode configuration information.
[0064] In a second aspect, an embodiment of the present application provides an electronic device, including a processor, which is coupled to a memory, and the processor is used to execute a computer program or instruction stored in the memory so that the electronic device can implement a display method when switching a display mode as provided in any embodiment of the present application.
[0065] In a third aspect, an embodiment of the present application provides a computer-readable storage medium, which stores a computer program. When the computer program runs on an electronic device, the electronic device executes a display method when switching a display mode as provided in any embodiment of the present application.
[0066] It can be understood that the beneficial effects of the second to third aspects mentioned above can be found in the relevant description of the first aspect mentioned above, and will not be repeated here. BRIEF DESCRIPTION OF THE DRAWINGS
[0067] Figure 1 It is a terminal schematic diagram involved in the display method when the display mode is switched provided in an embodiment of the present application;
[0068] Figure 2 is another schematic diagram of a terminal involved in the display method when the display mode is switched provided in an embodiment of the present application;
[0069] Figure 3 is another schematic diagram of a terminal involved in the display method when the display mode is switched provided in an embodiment of the present application;
[0070] Figure 4 A schematic diagram of another product form of a terminal 41 with an inward folding screen 42 provided in an embodiment of the present application;
[0071] Figure 5 It is a schematic diagram of the hardware structure of an electronic device provided in an embodiment of the present application;
[0072] Figure 6 It is a hierarchical architecture diagram of a call module applicable to the embodiment of the present application;
[0073] Fig. 7A Schematic diagram of an application scenario of the display method when switching display modes provided in an embodiment of the present application Figure 1 ;
[0074] Figure 7B Schematic diagram of an application scenario of the display method when switching display modes provided in an embodiment of the present application Figure 2 ;
[0075] Figure 7C Schematic diagram of an application scenario of the display method when switching display modes provided in an embodiment of the present application Figure 3 ;
[0076] Figure 8 A flow chart of a display method when switching display modes provided in an embodiment of the present application;
[0077] Fig. 9A A schematic diagram showing that a target interface is blocked when a foldable screen terminal switches from a folded state to an unfolded state;
[0078] Fig. 9B When a foldable screen terminal switches from an unfolded state to a folded state, a blank schematic diagram appears on the screen;
[0079] Fig.10 A schematic diagram of signaling interaction of a display method when switching display modes provided in an embodiment of the present application;
[0080] Fig.11 A schematic diagram of the structure of a display device when a display mode is switched according to an embodiment of the present application;
[0081] Fig.12 A schematic diagram of an electronic device according to an embodiment of the present application.
[0082] The reference numerals in the above drawings are as follows:
[0083] 11. terminal; 12. screen; 13. first area; 14. second area; 15. dividing line; 21. first screen; 22. second screen; 31. terminal; 32. outer folding screen; 33. first screen; 34. second screen; 35. folding edge; 41. terminal; 42. inner folding screen; 43. first screen; 44. second screen; 45. third screen; 100. electronic device; 110. processor; 120. external memory interface; 121. internal memory; 130 , USB interface; 140, charging management module; 141, power management module; 142, battery; 1, antenna; 2, antenna; 150, mobile communication module; 160, wireless communication module; 170, audio module; 170A, speaker; 170B, receiver; 170C, microphone; 170D, headphone jack; 190, button; 191, motor; 192, indicator; 193, camera; 194, screen; 195, customer identification module card interface ; 180, sensor module; 180A, pressure sensor; 180B, gyroscope sensor; 180C, air pressure sensor; 180D, magnetic sensor; 180E, acceleration sensor; 180F, distance sensor; 180G, proximity light sensor; 180H, fingerprint sensor; 180J, temperature sensor; 180K, touch sensor; 180L, ambient light sensor; 180M, bone conduction sensor; 71, terminal; 72, folding screen; 73, Folding line; 74, first screen; 75, second screen; 76, application icon; 77, third screen; 901, blocked area; 902, blank area; 1101, display mode information acquisition module; 1102, change information acquisition module; 1103, status information determination module; 1104, refresh module; 1105, refresh display module; 1201, processor; 1202, memory; 1203, communication interface; 1204, communication line; 1205, processor. DETAILED DESCRIPTION
[0084] In order to make the objectives, technical solutions and advantages of the present application clearer, the implementation methods of the present application will be further described in detail below in conjunction with the accompanying drawings.
[0085] It should be understood that the "multiple" mentioned in this application refers to two or more. In the description of this application, unless otherwise specified, " / " means or, for example, A / B can mean A or B; "and / or" in this article is only a description of the association relationship of associated objects, indicating that there can be three relationships, for example, A and / or B can mean: A exists alone, A and B exist at the same time, and B exists alone. In addition, in order to facilitate the clear description of the technical solution of this application, the words "first" and "second" are used to distinguish between the same items or similar items with basically the same functions and effects. Those skilled in the art can understand that the words "first" and "second" do not limit the quantity and execution order, and the words "first" and "second" do not limit them to be different.
[0086] In the embodiments of the present application, words such as "exemplary" or "for example" are used to indicate examples, illustrations or descriptions. Any embodiment or design described as "exemplary" or "for example" in the embodiments of the present application should not be interpreted as being more preferred or more advantageous than other embodiments or designs. Specifically, the use of words such as "exemplary" or "for example" is intended to present related concepts in a specific way.
[0087] Before introducing the embodiments of the present application, some terms or concepts involved in the embodiments of the present application are first explained. It should be understood that the present application does not specifically limit the naming of the following terms. The following terms may have other names. The renamed terms still meet the following related term explanations.
[0088] A screen is a device or appliance used to display images and colors, also known as a display screen. It is widely used in mobile phones, computers, monitors, televisions, and other devices with image or text display functions.
[0089] Display mode switching is when the screen of the mobile terminal includes more than two display areas, the screen display is switched from one display area to another display area. In the case of a folding screen mobile terminal, the screen of the mobile terminal can be switched from a folded state to an unfolded state or from an unfolded state to a folded state. In the case of a mobile terminal including one screen, display mode switching can also be achieved by connecting other screens and changing the display range of the screen of the mobile terminal.
[0090] The display mode can also be called the display mode. The terminal can display in a variety of different display modes. When the display mode is switched, the display mode switches from one mode to another. For terminals with folding screens, the display mode may include an unfolding mode and a folding mode. In addition, the display mode may also include: an extended mode, a mirroring mode, a main screen mode, and a secondary screen mode. The extended mode is when the terminal is connected to an external screen, and the external screen and the screen of the terminal itself display the same picture together. In mirroring mode, the screen of the terminal and the external screen display the same picture synchronously, or at least two screens of the terminal display the same picture synchronously, and two or more screens produce a mirroring effect.
[0091] The screen layout change event refers to an event in which the display area on the screen changes due to switching of display modes or other reasons.
[0092] A foldable screen is a bendable screen, generally a flexible screen. In some cases, a foldable screen can also be realized by two or more rigid screens connected by hinges. In the unfolded state, two or more rigid screens are spliced into a larger screen. The foldable screen can have a folded and unfolded state. In the unfolded state, the foldable screen acts as a complete screen to display the terminal's screen (interface). In the folded state, there is a certain angle between one part of the foldable screen and another part of the foldable screen, and they are in different planes.
[0093] Figure 1 1 is a schematic diagram of a terminal involved in the display method when the display mode is switched provided in an embodiment of the present application. Figure 1 As shown, the terminal 11 includes a screen 12, and the screen 12 has more than two display modes. In different display modes, the area on the screen 12 for displaying pictures may be different.
[0094] For example, in the full-screen display mode, the terminal 11 runs the target screen of the news application, and the screen 12 is entirely used to display the first target screen that needs to be displayed. The first target screen displays the title of the day's news in the news application and the content summary of the news.
[0095] In the split-screen display mode, the screen 12 is divided into two areas, each area displays a target screen of the application, namely Figure 1 The first area 13 in the display shows the first target screen related to the title of the news application. Figure 1 The second area 14 in the display shows the second target screen related to the text. Figure 1 The full screen display mode is switched to Figure 1When the split-screen display mode is shown, a display mode switching event occurs, and a dividing line 15 representing the split screen is generated on the screen 12. The first target screen originally displayed in the entire area of the screen 12 is switched to the first area 13, and the second target screen related to the first target screen can be displayed in the second area 14.
[0096] Similarly, when the terminal 11 switches from the split-screen display mode to the full-screen display mode, a display mode switching event occurs. Thus, when a display mode switching event occurs in the terminal 11, the display method for display mode switching provided in any embodiment of the present application can be executed to display the refreshed target interface on the screen after the display mode is switched.
[0097] With the continuous development of electronic equipment technology, more and more terminals with screens are widely used in people's daily life and work, such as mobile phones with screens. It is not difficult to find that with the development of screen technology, the screens of terminals are becoming larger and larger to provide users with richer information and better user experience. However, if the screen of the terminal is too large, it will seriously affect its portability. Therefore, the terminals with folding screens (such as folding screen mobile phones) proposed in recent years are the direction of future electronic equipment development. Figure 2 is another schematic diagram of a terminal involved in the display method when the display mode is switched provided in an embodiment of the present application, Figure 2 The terminal shown is a mobile terminal with a folding screen. The folding screen can be folded into at least two screens, such as Figure 2 (a) Figure 2 (b) and Figure 2 The first screen 21 and the second screen 22 shown in (c) in FIG. 1 are shown in FIG. 2. After the folding screen is completely folded, as shown in FIG. Figure 2 As shown in (a), the first screen 21 and the second screen 22 are opposite. Generally speaking, the aspect ratio (i.e., height-to-width ratio) of the first screen 21 and the second screen 22 of the folding screen is similar to that of the ordinary non-folding screen, such as the aspect ratio can be 16:9, 18:9, 20:9 or 16:10 and other conventional ratios; and some current applications are designed for non-folding screens, and their interface layouts are adapted to non-folding screens. Therefore, after the folding screen is folded, the first screen or the second screen can also display various application interfaces normally.
[0098] Reference Figure 2 As shown in (b) of FIG. 1 , after the folding screen is unfolded, the display area of the folding screen includes the above-mentioned at least two screens, which are formed by splicing the first screen 21 and the second screen 22. The aspect ratio of the unfolded folding screen can be 1:1 or 16:18, etc. When the user watches a movie or plays a game, the terminal can be as follows Figure 2The form shown in (b) is fully unfolded, giving users an immersive experience. When the user wants to free their hands to use the terminal, the terminal can also be folded at a certain angle and placed in a stand-like manner, so that the user can use the terminal while handling other matters; for example, the user can take a photo while posing with both hands; the terminal can be placed in a stand-like manner, such as Figure 2 As shown in (c) in .
[0099] The folding screens in the embodiments of the present application can be divided into multiple different categories, including: folding screens that fold outward (referred to as outward folding screens) and folding screens that fold inward (referred to as inward folding screens). For example, when the folding screen can be folded to form a first screen and a second screen, after the outward folding screen is folded, the first screen and the second screen are opposite to each other; after the inward folding screen is folded, the first screen and the second screen are opposite to each other. Figure 2 That is, a schematic diagram of an inward-folding screen in an embodiment of the present application.
[0100] Figure 3 (a) is a schematic diagram of the terminal 31 with an outward folding screen 32 when it is fully unfolded. The outward folding screen 32 can be folded along the folding edge 35 according to Figure 3 The directions 301a and 301b shown in (a) are folded to form Figure 3 The first screen 33 and the second screen 34 shown in (b) are formed at the intersection of the planes of the first screen 33 and the second screen 34. The folding edge 35 is formed. The outward folding screen can continue along the folding edge 35, according to Figure 3 The directions 302a and 302b shown in (b) are folded to form Figure 3 The outward folding screen 32 is in the folded state shown in (c). Figure 3 As shown in (c) , after the outward folding screen 32 of the terminal 31 is completely folded, the first screen 33 and the second screen 34 are opposite to each other and are visible to the user.
[0101] Understandably, for Figure 3 For the terminal 31 with the outer folding screen 32 shown, when the outer folding screen 32 is in the folded state, the interface can be displayed on the first screen 33 and / or the second screen 34; when the outer folding screen 32 is in the unfolded state, the interface can also be displayed on the first screen 33 and / or the second screen 34. The description of the unfolded state and the folded state of the outer folding screen can refer to or be combined with the description in other embodiments, which will not be repeated here.
[0102] Figure 4 A schematic diagram of another product form of a terminal 41 with an inward-folding screen 42 provided in an embodiment of the present application. Figure 4 (a) is a schematic diagram of the terminal 41 with the inward folding screen 42 when it is fully unfolded. The terminal 41 can be folded along the folding edge according to Figure 4The curve shown in (a) is folded in the direction of the arrow to form Figure 4 The first screen 43 and the second screen 44 shown in (b) of FIG. 4 are formed by continuing to fold the terminal 41 along the folding direction corresponding to the curved arrow. Figure 4 (c) shows the state of the terminal 41 after being completely folded. After the terminal 41 is completely folded, the first screen 43 and the second screen 44 are opposite to each other, and the first screen 43 and the second screen 44 are invisible to the user. Figure 4 The folding edge shown in (c) is a line on the plane where the first screen 43 and the second screen 44 are in contact. In addition, the terminal 41 with the inward folding screen 42 may also include a third screen 45, and the third screen 45 is arranged on the back side opposite to the first screen 43 or the second screen 44. It can be understood that for the terminal 41 with the inward folding screen 42, when it is in a folded state, the third screen 45 is visible to the user. When the terminal 41 with the inward folding screen 42 is in a folded state, the target interface is displayed on the third screen 45, and when the terminal 41 with the inward folding screen 42 is in an unfolded state, the target interface can be displayed on the first screen 43 and the second screen 44.
[0103] The hardware structure involved in the above implementation environment is introduced below.
[0104] An embodiment of the present application provides an electronic device that can be used as a terminal involved in any embodiment of the present application.
[0105] For example, Figure 5 Schematic diagram of the hardware structure of an electronic device provided in an embodiment of the present application. Figure 5 As shown, the electronic device 100 may include: a processor 110, an external memory interface 120, an internal memory 121, a USB interface 130, a charging management module 140, a power management module 141, a battery 142, an antenna 1, an antenna 2, a mobile communication module 150, a wireless communication module 160, an audio module 170, a speaker 170A, a receiver 170B, a microphone 170C, an earphone interface 170D, a sensor module 180, a button 190, a motor 191, an indicator 192, a camera 193, a screen 194, and a subscriber identity module (SIM) card interface 195, etc. Among them, the sensor module 180 may include a pressure sensor 180A, a gyroscope sensor 180B, an air pressure sensor 180C, a magnetic sensor 180D, an acceleration sensor 180E, a distance sensor 180F, a proximity light sensor 180G, a fingerprint sensor 180H, a temperature sensor 180J, a touch sensor 180K, an ambient light sensor 180L, a bone conduction sensor 180M, etc.
[0106] It is to be understood that the structure illustrated in this embodiment does not constitute a specific limitation on the electronic device 100. In other embodiments of the present application, the electronic device 100 may include more or fewer components than shown in the figure, or combine some components, or split some components, or arrange the components differently. The components shown in the figure may be implemented in hardware, software, or a combination of software and hardware.
[0107] The processor 110 may include one or more processing units, for example, the processor 110 may include an application processor (AP), a modem processor, a graphics processor (GPU), an image signal processor (ISP), a controller, a video codec, a digital signal processor (DSP), a baseband processor (BP), a display processing unit (DPU), and / or a neural-network processing unit (NPU), etc. Among them, different processing units may be independent devices or integrated in one or more processors.
[0108] In some embodiments, the electronic device 100 may also include one or more processors 110. Among them, the processor may be the nerve center and command center of the electronic device 100. The processor may generate an operation control signal based on the instruction opcode and the timing signal to complete the control of fetching and executing instructions. A memory may also be provided in the processor 110 for storing instructions and data. In some embodiments, the memory in the processor 110 is a cache memory. The memory may store instructions or data used or recycled by the processor 110. If the processor 110 needs to use the instruction or data again, it may be directly called from the memory. This avoids repeated access, reduces the waiting time of the processor 110, and thus improves the efficiency of the electronic device 100.
[0109] In some embodiments, the processor 110 may include one or more interfaces. The interface may include an inter-integrated circuit (I2C) interface, an inter-integrated circuits sound (I2S) interface, a pulse code modulation (PCM) interface, a universal asynchronous receiver / transmitter (UART) interface, a mobile industry processor interface (MIPI), a general-purpose input / output (GPIO) interface, a subscriber identity module (SIM) interface, and / or a universal serial bus (USB) interface, etc.
[0110] It is understandable that the interface connection relationship between the modules illustrated in the embodiment of the present application is only a schematic illustration and does not constitute a structural limitation on the electronic device 100. In other embodiments of the present application, the electronic device 100 may also adopt different interface connection methods in the above embodiments, or a combination of multiple interface connection methods.
[0111] The charging management module 140 is used to receive charging input from a charger. The charger may be a wireless charger or a wired charger. In some wired charging embodiments, the charging management module 140 may receive charging input from a wired charger through the USB interface 130. In some wireless charging embodiments, the charging management module 140 may receive wireless charging input through a wireless charging coil of the electronic device 100. While the charging management module 140 is charging the battery 142, it may also power the mobile phone through the power management module 141.
[0112] The power management module 141 is used to connect 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, and supplies power to the processor 110, the internal memory 121, the external memory, the screen 194, the camera 193, and the wireless communication module 160. The power management module 141 can also be used to monitor parameters such as battery capacity, battery cycle number, battery health status (leakage, impedance), etc. In some other embodiments, the power management module 141 can also be set in the processor 110. In other embodiments, the power management module 141 and the charging management module 140 can also be set in the same device.
[0113] The wireless communication function of the electronic device 100 can be implemented by antenna 1, antenna 2, mobile communication module 150, wireless communication module 160, modulation and demodulation processor and baseband processor. Antenna 1 and antenna 2 are used to transmit and receive electromagnetic wave signals. Each antenna in the electronic device 100 can be used to cover a single or multiple communication frequency bands. Different antennas can also be reused to improve the utilization of the antenna. For example, antenna 1 can be reused as a diversity antenna of a wireless local area network. In some other embodiments, the antenna can be used in combination with a tuning switch.
[0114] The mobile communication module 150 can provide solutions for wireless communications including 2G / 3G / 4G / 5G, etc., applied to the electronic device 100. The mobile communication module 150 may include at least one filter, a switch, a power amplifier, a low noise amplifier, etc. The mobile communication module 150 can receive electromagnetic waves from the antenna 1, and filter, amplify, and process the received electromagnetic waves, and transmit them to the modulation and demodulation processor for demodulation. The mobile communication module 150 can also amplify the signal modulated by the modulation and demodulation processor, and convert it into electromagnetic waves for radiation through the antenna 1. In some embodiments, at least some of the functional modules of the mobile communication module 150 can be set in the processor 110. In some embodiments, at least some of the functional modules of the mobile communication module 150 can be set in the same device as at least some of the modules of the processor 110.
[0115] The modem processor may include a modulator and a demodulator. Among them, the modulator is used to modulate the low-frequency baseband signal to be sent into a medium-high frequency signal. The demodulator is used to demodulate the received electromagnetic wave signal into a low-frequency baseband signal. The demodulator then transmits the demodulated low-frequency baseband signal to the baseband processor for processing. After the low-frequency baseband signal is processed by the baseband processor, it is passed to the application processor. The application processor outputs a sound signal through an audio device (not limited to a speaker 170A, a receiver 170B, etc.), or displays an image or video through a screen 194. In some embodiments, the modem processor may be an independent device. In other embodiments, the modem processor may be independent of the processor 110 and be set in the same device as the mobile communication module 150 or other functional modules.
[0116] The wireless communication module 160 can provide wireless communication solutions including wireless local area networks (WLAN), Bluetooth (BT), global navigation satellite system (GNSS), frequency modulation (FM), near field communication (NFC), infrared technology (IR), etc., which are applied to the electronic device 100. The wireless communication module 160 can be one or more devices integrating at least one communication processing module. The wireless communication module 160 receives electromagnetic waves via the antenna 2, modulates the frequency of the electromagnetic wave signal and filters it, and sends the processed signal to the processor 110. The wireless communication module 160 can also receive the signal to be sent from the processor 110, modulate the frequency of it, amplify it, and convert it into electromagnetic waves for radiation through the antenna 2.
[0117] In some embodiments, the antenna 1 of the electronic device 100 is coupled to the mobile communication module 150, and the antenna 2 is coupled to the wireless communication module 160, so that the electronic device 100 can communicate with the network and other devices through wireless communication technology. The wireless communication technology may include GSM (Global System for Mobile Communications), GPRS (General Packet Radio Service), CDMA (Code Division Multiple Access), WCDMA (Wideband Code Division Multiple Access), TD-SCDMA (Time Division-Synchronous Code Division Multiple Access), LTE (Long Term Evolution), GNSS (Global Navigation Satellite System), WLAN, NFC (Near Field Communication), FM (Frequency Modulation), and / or IR (Infrared) technology, etc. The above-mentioned GNSS may include a global positioning system (GPS), a global navigation satellite system (GLONASS), a BeiDou navigation satellite system (BDS), a quasi-zenith satellite system (QZSS) and / or a satellite based augmentation system (SBAS).
[0118] The screen 194 is used to display images, videos, etc. The screen 194 includes a display panel. The display panel can be a liquid crystal display (LCD), an organic light-emitting diode (OLED), an active-matrix organic light emitting diode or an active-matrix organic light emitting diode (AMOLED), a flexible light-emitting diode (FLED), Miniled, MicroLed, Micro-oLed or a quantum dot light emitting diode (QLED). In some embodiments, the electronic device 100 may include 1 or N screens 194, where N is a positive integer greater than 1. In an embodiment of the present application, the screen 194 may include a display and a touch panel (TP). The display is used to output display content to the user, and the touch panel is used to receive touch events input by the user on the screen 194.
[0119] The electronic device 100 can realize the shooting function through ISP, camera 193, video codec, GPU, screen 194 and application processor.
[0120] ISP is used to process the data fed back by camera 193. For example, when taking a photo, the shutter is opened, and the light is transmitted to the camera photosensitive element through the lens. The light signal is converted into an electrical signal, and the camera photosensitive element transmits the electrical signal to ISP for processing and converts it into an image visible to the naked eye. ISP can also perform algorithm optimization on the noise, brightness, and skin color of the image. ISP can also optimize the exposure, color temperature and other parameters of the shooting scene. In some embodiments, ISP can be set in camera 193.
[0121] The camera 193 is used to capture still images or videos. The object generates an optical image through the lens and projects it onto the 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 optical signal into an electrical signal, and then passes the electrical signal to the ISP for conversion into a digital image signal. The ISP outputs the digital image signal to the DSP for processing. The DSP converts the digital image signal into an image signal in a standard RGB, YUV or other format. In some embodiments, the electronic device 100 may include 1 or N cameras 193, where N is a positive integer greater than 1. In one example, the camera 193 may include a wide-angle camera, a photographic camera, a 3D depth camera (e.g., a structured light camera, a time-of-flight depth (flignt, ToF) camera), a telephoto camera, etc.
[0122] In the embodiment of the present application, the camera 193 may include a front camera and a rear camera. The front camera may be arranged on the same side of the first screen 43 of the electronic device 100, and the rear camera may be arranged on the side of the electronic device 100 facing away from the first screen 43.
[0123] The digital signal processor is used to process digital signals, and can process not only digital image signals but also other digital signals. For example, when the electronic device 100 is selecting a frequency point, the digital signal processor is used to perform Fourier transform on the frequency point energy.
[0124] Video codecs are used to compress or decompress digital videos. The electronic device 100 may support one or more video codecs. Thus, the electronic device 100 may play or record videos in a variety of coding formats, such as Moving Picture Experts Group (MPEG) 1, MPEG2, MPEG3, MPEG4, etc.
[0125] 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 implement a data storage function. For example, data files such as music, photos, and videos are stored in the external memory card.
[0126] The internal memory 121 can be used to store one or more computer programs, which include instructions. The processor 110 can enable the electronic device 100 to perform various functional applications and data processing by running the above instructions stored in the internal memory 121. The internal memory 121 may include a program storage area and a data storage area. Among them, the program storage area can store an operating system; the program storage area can also store one or more applications (such as a gallery, contacts, etc.). The data storage area can store data (such as photos, contacts, etc.) created during the use of the electronic device 100. In addition, the internal memory 121 may include a high-speed random access memory, and may also include a non-volatile memory, such as at least one disk storage device, a flash memory device, a universal flash storage (UFS), etc. In some embodiments, the processor 110 can enable the electronic device 100 to perform various functional applications and data processing by running instructions stored in the internal memory 121 and / or instructions stored in a memory provided in the processor 110.
[0127] The electronic device 100 can implement audio functions such as music playing and recording through the audio module 170, the speaker 170A, the receiver 170B, the microphone 170C, the headphone jack 170D, and the application processor.
[0128] The audio module 170 is used to convert digital audio information into analog audio signal output, and is also used to convert analog audio input into digital audio signals. The audio module 170 can also be used to encode and decode audio signals. In some embodiments, the audio module 170 can be arranged in the processor 110, or some functional modules of the audio module 170 can be arranged in the processor 110.
[0129] The speaker 170A, also called a "speaker", is used to convert an audio electrical signal into a sound signal. The electronic device 100 can listen to music or listen to a hands-free call through the speaker 170A.
[0130] The receiver 170B, also called a "earpiece", is used to convert audio electrical signals into sound signals. When the electronic device 100 receives a call or voice message, the voice can be received by placing the receiver 170B close to the human ear.
[0131] Microphone 170C, also called "microphone" or "microphone", is used to convert sound signals into electrical signals. When making a call or sending a voice message, the user can speak by putting their mouth close to microphone 170C to input the sound signal into microphone 170C. The electronic device 100 can be provided with at least one microphone 170C. In other embodiments, the electronic device 100 can be provided with two microphones 170C, which can not only collect sound signals but also realize noise reduction function. In other embodiments, the electronic device 100 can also be provided with three, four or more microphones 170C to collect sound signals, reduce noise, identify the sound source, realize directional recording function, etc.
[0132] The earphone interface 170D is used to connect a wired earphone and can be a USB interface 130 or a 3.5 mm open mobile terminal platform (OMTP) standard interface or a cellular telecommunications industry association of the USA (CTIA) standard interface.
[0133] The pressure sensor 180A is used to sense the pressure signal and can convert the pressure signal into an electrical signal. In some embodiments, the pressure sensor 180A can be set on the screen 194. There are many types of pressure sensors 180A, such as resistive pressure sensors, inductive pressure sensors, capacitive pressure sensors, etc. The capacitive pressure sensor can be a parallel plate including at least two conductive materials. When a force acts on the pressure sensor 180A, the capacitance between the electrodes changes. The electronic device 100 determines the intensity of the pressure according to the change in capacitance. When a touch operation acts on the screen 194, the electronic device 100 detects the touch operation intensity according to the pressure sensor 180A. The electronic device 100 can also calculate the touch position according to the detection signal of the pressure sensor 180A. In some embodiments, touch operations acting on the same touch position but with different touch operation intensities can correspond to different operation instructions. For example: when a touch operation with a touch operation intensity less than the first pressure threshold acts on the short message application icon, an instruction to view the short message is executed. When a touch operation with a touch operation intensity greater than or equal to the first pressure threshold acts on the short message application icon, an instruction to create a new short message is executed.
[0134] The air pressure sensor 180C is used to measure air pressure. In some embodiments, the electronic device 100 calculates the altitude through the air pressure value measured by the air pressure sensor 180C to assist positioning and navigation.
[0135] The gyro sensor 180B can be used to determine the motion posture of the electronic device 100. In some embodiments, the angular velocity of the electronic device 100 around three axes (i.e., x, y, and z axes) can be determined by the gyro sensor 180B. The gyro sensor 180B can be used for anti-shake shooting. For example, when the shutter is pressed, the gyro sensor 180B detects the angle of the electronic device 100 shaking, calculates the distance that the lens module needs to compensate based on the angle, and allows the lens to offset the shaking of the electronic device 100 through reverse movement to achieve anti-shake. The gyro sensor 180B can also be used for navigation and somatosensory game scenes.
[0136] The acceleration sensor 180E can detect the magnitude of acceleration in various directions (generally three axes) of the electronic device 100. When the electronic device 100 is stationary, the magnitude and direction of gravity acceleration can be detected.
[0137] The magnetic sensor 180D includes a Hall sensor, a magnetometer, etc. The Hall sensor can detect the direction of the magnetic field; the magnetometer is used to measure the magnitude and direction of the magnetic field. The magnetometer can measure the strength of the ambient magnetic field. For example, the magnetometer can be used to measure the magnetic field strength and then obtain the azimuth information of the carrier of the magnetometer.
[0138] The touch control device can be used to detect the user's touch position. In some embodiments, the touch control device can detect the user's touch point on the electronic device 100, and then determine the user's current gripping posture of the mobile phone using a preset gripping algorithm based on the touch position.
[0139] The distance sensor 180F is used to measure the distance. The electronic device 100 can measure the distance by infrared or laser. In some embodiments, when shooting a scene, the electronic device 100 can use the distance sensor 180F to measure the distance to achieve fast focusing.
[0140] The proximity light sensor 180G may include, for example, a light emitting diode (LED) and a light detector, such as a photodiode. The light emitting diode may be an infrared light emitting diode. The electronic device 100 emits infrared light outward through the light emitting diode. The electronic device 100 uses a photodiode to detect infrared reflected light from nearby objects. When sufficient reflected light is detected, it can be determined that there is an object near the electronic device 100. When insufficient reflected light is detected, the electronic device 100 can determine that there is no object near the electronic device 100. The electronic device 100 can use the proximity light sensor 180G to detect that the user holds the electronic device 100 close to the ear to talk, so as to automatically turn off the screen to save power. The proximity light sensor 180G can also be used in leather case mode and pocket mode to automatically unlock and lock the screen.
[0141] The ambient light sensor 180L is used to sense the ambient light brightness. The electronic device 100 can adaptively adjust the brightness of the screen 194 according to the perceived ambient light brightness. The ambient light sensor 180L can also be used to automatically adjust the white balance when taking pictures. The ambient light sensor 180L can also cooperate with the proximity light sensor 180G to detect whether the electronic device 100 is in a pocket to prevent accidental touches.
[0142] The fingerprint sensor 180H is used to collect fingerprints. The electronic device 100 can use the collected fingerprint characteristics to implement fingerprint unlocking, access application locks, fingerprint photography, fingerprint call answering, etc.
[0143] The temperature sensor 180J is used to detect temperature. In some embodiments, the electronic device 100 uses the temperature detected by the temperature sensor 180J to execute a temperature processing strategy. For example, when the temperature reported by the temperature sensor 180J exceeds a threshold, the electronic device 100 reduces the performance of a processor located near the temperature sensor 180J to reduce power consumption and implement thermal protection. In other embodiments, when the temperature is lower than another threshold, the electronic device 100 heats the battery 142 to avoid abnormal shutdown of the electronic device 100 due to low temperature. In other embodiments, when the temperature is lower than another threshold, the electronic device 100 performs a boost on the output voltage of the battery 142 to avoid abnormal shutdown caused by low temperature.
[0144] The touch sensor 180K is also called a "touch panel". The touch sensor 180K can be set on the screen 194, and the touch sensor 180K and the screen 194 form a touch screen, also called a "touch screen". The touch sensor 180K is used to detect touch operations acting on or near it. The touch sensor can pass the detected touch operation to the application processor to determine the type of touch event. Visual output related to the touch operation can be provided through the screen 194. In other embodiments, the touch sensor 180K can also be set on the surface of the electronic device 100, which is different from the position of the screen 194.
[0145] The bone conduction sensor 180M can obtain a vibration signal. In some embodiments, the bone conduction sensor 180M can obtain a vibration signal of a vibrating bone block of the vocal part of the human body. The bone conduction sensor 180M can also contact the human pulse to receive a blood pressure beat signal. In some embodiments, the bone conduction sensor 180M can also be set in an earphone and combined into a bone conduction earphone. The audio module 170 can parse out a voice signal based on the vibration signal of the vibrating bone block of the vocal part obtained by the bone conduction sensor 180M to realize a voice function. The application processor can parse the heart rate information based on the blood pressure beat signal obtained by the bone conduction sensor 180M to realize a heart rate detection function.
[0146] The key 190 includes a power key, a volume key, etc. The key 190 may be a mechanical key or a touch key. The electronic device 100 may receive key input and generate key signal input related to user settings and function control of the electronic device 100.
[0147] Motor 191 can generate vibration prompts. Motor 191 can be used for incoming call vibration prompts, and can also be used for touch vibration feedback. For example, touch operations acting on different applications (such as taking pictures, audio playback, etc.) can correspond to different vibration feedback effects. For touch operations acting on different areas of the screen 194, motor 191 can also correspond to different vibration feedback effects. Different application scenarios (for example: time reminders, receiving messages, alarm clocks, games, etc.) can also correspond to different vibration feedback effects. The touch vibration feedback effect can also support customization.
[0148] Indicator 192 may be an indicator light, which may be used to indicate charging status, power changes, messages, missed calls, notifications, etc.
[0149] The SIM card interface 195 is used to connect a SIM card. The SIM card can be connected to and separated from the electronic device 100 by inserting it into the SIM card interface 195 or pulling it out from the SIM card interface 195. The electronic device 100 can support 1 or N SIM card interfaces, where N is a positive integer greater than 1. The SIM card interface 195 can support Nano SIM cards, Micro SIM cards, SIM cards, and the like. Multiple cards can be inserted into the same SIM card interface 195 at the same time. The types of the multiple cards can be the same or different. The SIM card interface 195 can also be compatible with different types of SIM cards. The SIM card interface 195 can also be compatible with external memory cards. The electronic device 100 interacts with the network through the SIM card to implement functions such as calls and data communications. In some embodiments, the electronic device 100 uses an eSIM, i.e., an embedded SIM card. The eSIM card can be embedded in the electronic device 100 and cannot be separated from the electronic device 100.
[0150] The most important function of electronic devices, or terminals, in people's lives is calling. The calling module (Telephony) in the Android system is the core module of the calling function. The calling module mainly provides voice, SMS, data link, SIM card management, phone book and other functions.
[0151] The call module adopts a layered architecture design, and its business applications span AP (Application Processor) and BP (Baseband Processor), and AP and BP communicate with each other. Figure 6This is a layered architecture diagram of a call module applicable to the embodiment of the present application. In this layered architecture, the call module spans the application layer (application layer), application framework layer (application framework layer), and hardware abstraction layer of the Android system, and involves the driver layer of the BP end, including the modem module.
[0152] The application layer is user-oriented and relies on the application framework layer. It presents specific functions to users by accessing the business modules of the application framework layer. The application layer includes the call interface module (IncallUI) and the call management module, which are used to display and update the call interface, query call information, and simple logic, such as answering / hanging up, etc., and also used to start ringtone playback. The application layer can include a series of application packages.
[0153] like Figure 6 As shown, the application package may include camera, gallery, calendar, call, map, navigation, WLAN, Bluetooth, music, video, short message and other applications.
[0154] The application framework layer provides an application programming interface (API) and a programming framework for the applications in the application layer. The application framework layer includes some predefined functions.
[0155] like Figure 6 As shown, the application framework layer may include display policy management service, power management service (powermanager service, PMS), display management service (display manager service, DMS). Of course, the application framework layer may also include timing management service (alarm manager service, AMS), window management service (windowmanager service, WMS), content provider, view system, phone manager, resource manager, notification manager, etc., and the embodiment of the present application does not impose any restrictions on this.
[0156] Among them, the display policy management service is used to control the display policy of the electronic device. In the embodiment of the present application, when the display policy management service obtains from the bottom layer that the screen of the electronic device (which may be a flexible screen) is in a bent state, the WMS can be notified through the DMS to control the application on the electronic device to display on the screen according to the method provided in the embodiment of the present application.
[0157] The power management service can be used to control the screen of the electronic device to be turned on or off. For example, in some cases, the power management service can control the first screen and / or the second screen and / or the third screen of the electronic device to be turned on or off.
[0158] The timing management service is used to manage timers, alarms, etc.
[0159] The window management service is used to manage window programs. The window manager can obtain the screen size, determine whether there is a status bar, lock the screen, capture the screen, etc.
[0160] Content providers are used to store and retrieve data and make it accessible to applications. The data can include videos, images, audio, calls made and received, browsing history and bookmarks, phone books, etc.
[0161] The view system includes visual controls, such as controls for displaying text, controls for displaying images, etc. The view system can be used to build applications. A display interface can be composed of one or more views. For example, a display interface including a text notification icon can include a view for displaying text and a view for displaying images.
[0162] The phone manager is used to provide communication functions for electronic devices, such as the management of call status (including answering, hanging up, etc.).
[0163] The resource manager provides various resources for applications, such as localized strings, icons, images, layout files, video files, and so on.
[0164] The notification manager enables applications to display notification information in the status bar. It can be used to convey notification-type messages and can disappear automatically after a short stay without user interaction. For example, the notification manager is used to notify download completion, message reminders, etc. The notification manager can also be a notification that appears in the system top status bar in the form of a chart or scroll bar text, such as notifications of applications running in the background, or a notification that appears on the screen in the form of a dialog window. For example, a text message is displayed in the status bar, a prompt sound is emitted, an electronic device vibrates, an indicator light flashes, etc.
[0165] The system library can include multiple functional modules, such as status monitoring services, sensor services, surface managers, media libraries, 3D graphics processing libraries (such as OpenGL ES), 2D graphics engines (such as SGL), etc.
[0166] The status monitoring service can be used to identify various states of a terminal (such as a mobile phone); for example, the shape of the terminal (including the unfolded state, bent state and folded state of a terminal with a foldable screen), the user's gripping posture of the terminal, the relative position of the terminal and the user, etc.
[0167] The sensor service is used to store and process sensor-related data, for example, to provide the output data of each sensor and to fuse the output data of multiple sensors.
[0168] The surface manager is used to manage the display subsystem and provide the fusion of 2D and 3D layers for multiple applications.
[0169] The media library supports playback and recording of a variety of commonly used audio and video formats, as well as static image files, etc. The media library can support a variety of audio and video encoding formats, such as: MPEG4, H.264, MP3, AAC, AMR, JPG, PNG, etc.
[0170] The 3D graphics processing library is used to implement 3D graphics drawing, image rendering, synthesis, and layer processing.
[0171] A 2D graphics engine is a drawing engine for 2D drawings.
[0172] The kernel layer is the layer between hardware and software. The kernel layer contains at least display driver, camera driver, audio driver, and sensor driver.
[0173] Fig. 7A The figure is a schematic diagram of an application scenario of the display method when the display mode is switched according to an embodiment of the present application. The terminal 71 has a folding screen 72, which is a flexible screen and can be folded around a folding line 73 in the direction indicated by the curved arrow. Further, the folding screen 72 includes a first screen 74, a second screen 75 and a third screen. Fig. 7A In the expanded state shown, the first screen 74 and the second screen 75 are in the same plane, the angle between the first screen 74 and the second screen 75 is close to 0°, and the third screen is opposite to the first screen 74 or the second screen 75. Correspondingly, the display mode of the terminal 71 is the display mode of the expanded state. The first screen 74 and the second screen 75 form a complete large screen, and the content to be displayed is displayed on the large screen. When the user switches the display screen of the terminal 71 to the desktop, the terminal 71 displays the desktop background and the application icons 76 of multiple applications arranged on the desktop. The user touches and clicks one of the multiple application icons 76 to start the application, and the corresponding interface of the application is displayed on the large screen, such as Figure 7B shown.
[0174] exist Figure 7B In the expanded state shown, the target interface corresponding to the application can occupy the entire large screen area.
[0175] In another implementation, in the expanded state, Figure 7B As shown, the target interface corresponding to the application can be displayed in the first area corresponding to the first screen 74 and the second area corresponding to the second screen 75. In the first area, the home page, menu display page, tab page, etc. corresponding to the application can be displayed. In the second area, the landing page corresponding to the specific option selected by the user in the first area can be displayed.
[0176] In the scenario where the folding screen 72 is an outward folding screen, the user folds the folding screen 72 outward along the folding line 73 so that the first screen 74 and the second screen 75 are opposite to each other, and the terminal 71 is in a folded state. In the folded state, one of the first screen 74 and the second screen 75 is off and the other is lit. In the folded state, the first screen 74 or the second screen 75 that is lit displays the target interface of the application.
[0177] For the scenario where the folding screen 72 is an inward folding screen, the folding screen 72 of the terminal 71 includes a third screen 77, such as Figure 7C The user folds the folding screen 72 inward along the folding line so that the first screen and the second screen are opposite (at Figure 7C The terminal 71 is in a folded state (not shown in the figure because of being blocked). In the folded state, the first screen and the second screen are both off, and the third screen 77 is lit and displays the target interface of the application opposite to the first screen and the second screen.
[0178] See also Figure 8 The embodiment of the present application provides a display method when the display mode is switched, which is applied to a terminal, and the terminal includes a screen; the display method includes the following steps: Figure 8 Steps S801 to S805 are shown.
[0179] In step S801, the display mode information of the terminal is obtained.
[0180] In the embodiments of the present application, the terminal includes but is not limited to electronic devices such as laptop computers, desktop computers, PDAs, tablet computers, mobile phones, and wearable smart devices. The terminal has at least one screen, and the at least one screen may belong to the same display or different displays. In one embodiment, the screen included in the terminal may be an external screen of the host device of the terminal, or the screen included in the terminal may be a screen of a display fixedly configured for the host device of the terminal.
[0181] The terminal runs a corresponding system and can display a certain target interface, which can be started when the application runs in the terminal system. The terminal has at least two display modes, and in different display modes, the area used to display the target interface is different.
[0182] In a specific implementation, the terminal may include a first display mode and a second display mode. In the first display mode, the distance between the upper and lower edges of the target interface in the visual direction when the user is in use is greater than the distance between the left and right edges. In the second display mode, the distance between the upper and lower edges of the target interface in the visual direction when the user is in use is less than the distance between the left and right edges.
[0183] In another specific implementation, the terminal may include a third display mode and a fourth display mode. The third display mode and the fourth display mode have different resolutions, resulting in different areas covered by the target interface on the screen of the terminal. For example, in the third display mode, the screen resolution is 2560x1440. In the fourth display mode, the screen resolution is 3840x2160.
[0184] In another specific implementation, the terminal may include a fifth display mode and a sixth display mode. In the sixth display mode, one screen of the terminal is entirely used to display the target screen, and when the application is running, the target interface of the application covers the entire area of the screen. In the fifth display mode, one screen of the terminal is partially used to display the target screen, and the other part displays at least one of a keyboard, a touchpad operation interface, and a mouse operation interface. The target interface of the application currently running on the terminal is displayed in the first area of the screen, and a black screen is displayed in the second area of the screen to indicate that the second area can be used as a touchpad.
[0185] In another specific implementation, the terminal may include a seventh display mode. In the seventh display mode, based on the fifth display mode, the screen is divided into a first split screen and a second split screen. A split screen line is displayed between the first split screen and the second split screen, and the split screen line divides the display area of the screen into the first split screen and the second split screen. In the first split screen and the second split screen, the user can run different applications according to his own wishes. For example, the first split screen runs a shopping application and displays a target interface of the shopping application, including multiple products and corresponding brief information of the products. The second split screen runs a social application and displays a target interface of the social application, including multiple social friends and chat lists corresponding to the social friends.
[0186] In another specific implementation, the terminal may include an eighth display mode and a ninth display mode. In the eighth display mode, the terminal uses a screen that is fixedly matched with the terminal host to display the target interface. The laptop computer displays the target interface of the desktop through a fixedly matched screen. In the eighth display mode, the terminal can display the fixedly matched screen using any one of the aforementioned first to seventh display modes. In the ninth display mode, the terminal displays through a screen that is fixedly matched with the terminal host and an external screen of the terminal. The laptop computer displays the target interface of the desktop through a fixedly matched screen and a screen of an external display, and the fixedly matched screen and the screen of the external display can respectively achieve functions similar to the first split screen and the second split screen in the aforementioned seventh display mode.
[0187] In another specific implementation, the screen of the terminal is a flexible screen. The flexible screen includes a first screen and a second screen, and the terminal may include a tenth display mode and an eleventh display mode. In the tenth display mode, the flexible screen is unfolded, the first screen and the second screen are basically in the same plane, and the angle between the two screens is close to 0°. The display areas of the first screen and the second screen are spliced and used as a complete large screen. In the eleventh display mode, the flexible screen is folded outward, the first screen and the second screen are facing each other, one of the first screen and the second screen is lit to display the target interface, and the other is off.
[0188] In another specific implementation, the screen of the terminal is a flexible screen, and the flexible screen includes a first screen, a second screen, and a third screen. The terminal may have a twelfth display mode on the basis of the tenth display mode. In the tenth display mode, the flexible screen is unfolded, the third screen and the large screen formed by the first screen and the second screen are opposite to each other, and the large screen formed by the first screen and the second screen is lit to display the target interface. In the twelfth display mode, the first screen and the second screen are folded inward, and the first screen and the second screen are facing each other. The third screen is lit to display the target interface.
[0189] In other possible implementations, the terminal may have more display modes, or a combination of two or more display modes among the aforementioned first to twelfth display modes.
[0190] In step S802, when it is determined according to the display mode information that a display mode switching event occurs on the screen, change information of the display mode configuration information corresponding to the display mode switching event is obtained.
[0191] The display mode switching event is an event generated when the display mode of the screen switches from one to another, and can be determined by monitoring the mode information displayed on the screen. When the display mode switching event occurs, the terminal may have changes in the screen-related hardware devices, or only changes in the screen-related software parameters may occur.
[0192] In order to monitor the changes of screen-related hardware devices, multiple groups of sensors can be set on the terminal. For example, when the terminal has a folding screen, sensor modules are respectively set on the first screen and the second screen of the folding screen.
[0193] Exemplarily, the folding screen of the terminal includes a first screen and a second screen. The first screen is provided with an accelerometer (ACC) (1) and a gyroscope (GYRO) (1), and the second screen of the terminal is provided with an accelerometer (2) and a gyroscope (2). The terminal can obtain the acceleration of the movement of the first screen and the angular velocity of the rotation of the first screen by reading the data of ACC (1) and GYRO (1), and then obtain the magnitude and direction of the gravity acceleration G1 of the first screen. The terminal can obtain the acceleration of the movement of the second screen and the angular velocity of the rotation of the second screen by reading the data of ACC (2) and GYRO (2), and then obtain the magnitude and direction of the gravity acceleration G2 of the second screen, and detect the switching event of the display mode. The terminal can also obtain parameters such as the angle α between the first screen and the second screen according to G1 and G2. The specific method for the terminal to obtain the gravity acceleration G and the angle α between the first screen and the second screen according to the data of ACC and GYRO can refer to the description in the conventional technology, which will not be repeated here. Alternatively, if a sensor A is used to detect the magnitude and direction of gravity acceleration G, the sensor A can be respectively provided on the first screen and the second screen. For example, an acceleration sensor and a gyroscope sensor can be integrated into one sensor (A+G sensor) and provided on the first screen and the second screen respectively.
[0194] Exemplarily, a plurality of groups of touch devices may be respectively provided on the first screen and the second screen of the terminal, so as to judge the gripping posture of the user when using the terminal, and further determine the display mode of the terminal.
[0195] In each display mode, display mode configuration information is provided to determine the display-related parameters in the display mode. Exemplarily, the display mode configuration information may include display area size, ratio, resolution, layout information of the display area, etc. After the terminal is started, the terminal may determine the display mode according to the default display mode configuration information, or determine the display mode according to the state of the screen when the terminal is started. In the case of a change in the display mode, the display mode configuration information is determined to have different contents in different display modes, i.e., change information of the display mode configuration information. For example, in the first display mode, the display mode configuration information includes vertical and horizontal direction information, screen size information, number of screens information, etc. When switching from the first display mode to the second display mode, the vertical and horizontal direction information changes, and the content corresponding to the vertical and horizontal direction information is used as the change information of the display mode configuration information.
[0196] In step S803, when the type of the display mode switching event is the first type, state information for indicating a screen layout change event is obtained according to the change information of the display mode configuration information.
[0197] In a specific embodiment, the type of the display mode switching event represents the display mode before switching and the display mode after switching. The types of display mode switching events can be divided by definition. For example, it can be defined that when the display mode before switching is the aforementioned tenth display mode and the display mode after switching is the aforementioned eleventh display mode or the twelfth display mode, the type of the display mode switching event is the first type. For another example, it can be defined that when the display mode before switching is the aforementioned first display mode and the display mode after switching is the aforementioned second display mode, the type of the display mode switching event is the second type.
[0198] In a specific embodiment, when a display mode switching event occurs, the screen layout will always change accordingly, but when certain types of switching events occur, ignoring the change in the screen layout will not affect the user's intuitive visual experience of viewing the target interface. The status information used to indicate the screen layout change event is used to indicate with the highest priority whether the screen layout change event needs to cause the target interface to be refreshed. If ignoring the change in the screen layout when the current switching event occurs will affect the user's intuitive visual experience of viewing the target interface, then the status information indicates that the target interface needs to be refreshed because of the current screen layout change event, so as to avoid display abnormalities caused by displaying the target interface in the new display mode according to the display mode configuration information before the switch.
[0199] Determining the state information for indicating the screen layout change event may include determining whether to perform a refresh operation on the target interface according to the screen layout change event so that the target interface is displayed according to the display mode configuration information under the new display mode.
[0200] In step S804, when it is determined that the status information indicating the screen layout change event indicates that the screen layout information of the screen has changed and the type of the switching event is the first type, the target interface of the application displayed on the screen is refreshed.
[0201] Exemplarily, when it is determined that the status information used to indicate a screen layout change event indicates that the screen layout information of the screen has changed, and the type of the switching event is the first type, it is considered necessary to refresh the target interface according to the screen layout change event so that the target interface is displayed according to the display mode configuration information under the new display mode. The type of the switching event can be determined based on the display mode before the switching event occurs and the display mode after the switching event occurs. The display mode before and after the switching event occurs can be determined based on the display mode information (Display Mode) of the terminal screen.
[0202] In a specific embodiment, refreshing the target interface of an application displayed on the screen includes: sending a refresh request from a WMS module of the terminal to an application layer, so that the application refreshes the target interface according to change information of the display mode configuration information to obtain a refreshed target interface, and at the same time, parameters of the refreshed target interface are adapted to the change information of the display mode configuration information.
[0203] Generally, when a display mode switching event occurs, the WMS module of the terminal's application framework layer (Framework) obtains the change information of the display mode configuration information, and then processes the change information of the display mode configuration information according to the pre-configured processing flow, and finally further judges or reports the processed change information. Through steps S801 to S804, on the basis of the original processing logic of the terminal application framework layer, an operation of judging whether to refresh the target interface is added, thereby eliminating the need for large-scale adjustments to the original processing logic of the terminal application framework layer, thereby improving the convenience of the application.
[0204] By determining the state information, there is no need to separately record whether the screen layout event is changed, or whether the type of the switching event is the first type, which can reduce the processing operations of data judgment.
[0205] In step S805, the refreshed target interface is displayed on the screen according to the change information of the display mode configuration information.
[0206] In a specific embodiment, a refreshed target interface is displayed on the screen according to the change information of the display mode configuration information, including: displaying the refreshed target interface on the screen after the display mode is switched, wherein the refreshed target interface is regenerated by the application according to the change information of the display mode configuration information, and the screen after the display mode is switched is determined based on the display mode before the switching event occurs and the display mode after the switching event occurs.
[0207] In this embodiment, the refreshed target interface is obtained by adjusting the target interface before the refresh according to the change information of the display mode configuration information.
[0208] Therefore, in the embodiment of the present application, the screen includes at least one screen, and the at least one screen is used to display the target interface before and after the switching event occurs.
[0209] In an embodiment of the present application, when a display mode switching event occurs, the status information is first determined based on the change information of the display mode configuration information, and whether to refresh the target interface is determined based on the data items that have changed in the display mode configuration information. When the target interface needs to be refreshed, the status information is recorded, and when the change information of the display mode configuration information and the type of switching event meet the requirements corresponding to refreshing the target interface, the target interface is refreshed to avoid the situation where the target interface and the switched display mode are not sufficiently compatible when the display mode is switched, thereby affecting the user's visual intuition and improving the visual effect when the user uses the application.
[0210] In one embodiment, the display method when the display mode is switched further includes:
[0211] When the status information for indicating the screen layout change event indicates that the screen layout of the screen has not changed, and the type of the switching event is the second type, filtering the change information of the display mode configuration information to obtain filtered first information;
[0212] The filtered first information is reported to the application layer of the terminal, and the filtered first information is used to instruct the application to change the interface parameters of the target interface displayed on the screen.
[0213] In a specific implementation, whether the screen layout is changed can be determined by whether the display mode configuration information includes screen layout information. The screen mode configuration information includes multiple data items, and the change information of the screen mode configuration information includes data items that are changed when the screen mode is switched.
[0214] Filtering the change information of the display mode configuration information to obtain the filtered first information may include using the data items of the change information remaining after filtering as the first information.
[0215] In this embodiment, the display mode switching event is not equivalent to the screen layout change event. The display mode switching event may cause multiple data items in the display mode configuration information to change, which may include the data items corresponding to the screen layout change event. If the change information of the display mode switching event does not include the data items corresponding to the screen layout change event, it indicates that the screen layout has not changed due to the switching of the display mode.
[0216] If the status information representing the screen layout change event indicates that the screen layout has not changed, the screen layout of the display mode before the switching event and the display mode after the switching event are the same, and there is no need to use the method of refreshing the target interface to adapt to the new screen layout, because the screen layout is the same before and after the switching event, and the corresponding target interface is displayed on the screen with the same aspect ratio and other parameters. Failure to refresh the target interface will not have an adverse effect on the user's intuitive vision of viewing the target interface. Therefore, if the screen layout has not changed and the type of the switching event is the second type, the target interface can be refreshed to reduce the operation of the terminal system.
[0217] In one embodiment, the display method when the display mode is switched further includes:
[0218] Filter the change information of the display mode configuration information to obtain filtered second information;
[0219] When the status information indicating the screen layout change event indicates that the screen layout of the terminal has changed, and the type of the switching event is the first type, generating new change information of the display mode configuration information according to the filtered second information;
[0220] According to the change information of the new display mode configuration information and the screen layout information, second change information of the display mode configuration information is obtained; the second change information of the display mode configuration information is used to obtain the refreshed target interface.
[0221] Generally, when a display mode switching event occurs, the change information of the display mode configuration information is obtained, and then the change information of the display mode configuration information is filtered to determine the data items that the application needs to pay attention to and refer to to modify the target interface, and the application is notified based on the remaining data items after filtering, so that the application modifies the target interface accordingly.
[0222] In the embodiment of the present application, when the status information indicating the screen layout change event indicates that the screen layout of the terminal has changed, and the type of the switching event is the first type, it is considered that the difference in display mode before and after the switching event occurs belongs to the first type, that is, according to the display mode before and after the switching event occurs, it is determined that the target interface needs to be refreshed. Then, in combination with whether the display mode configuration information contains the specified screen layout information, it is determined that the target interface needs to be refreshed, and then in combination with the result of the double condition determination, the second change information for obtaining the refreshed target interface is generated, so that the application can refresh the target interface according to the second change information.
[0223] In one implementation, refreshing a target interface of an application displayed on a screen includes:
[0224] A target interface refresh request and second change information of the display mode configuration information are sent to an application of the terminal, so that the application generates a refreshed target interface according to the second change information of the display mode configuration information.
[0225] In this embodiment, a refresh request for the target interface is sent to the application. When the refresh request is sent, the second change information is carried, so that the application of the terminal refreshes the target interface according to the second change information, and obtains a target interface that is adapted to the second change information of the display mode configuration information, thereby avoiding the problem that the target interface is displayed in the display mode after switching according to the parameters of the display mode before switching, resulting in the target interface being unable to fill the display area of the screen and the target interface being unable to display all the content in the display area after the display mode is switched.
[0226] In one implementation, obtaining second change information of the display mode configuration information according to the change information of the new display mode configuration information and the screen layout information includes:
[0227] The screen layout information is added to the change information of the new display mode configuration information to obtain the second change information of the display mode configuration information.
[0228] In general, each application will set corresponding filtering conditions. When the display mode configuration information changes, the change information of the display mode configuration information is obtained, and the change information is filtered according to the filtering conditions. The filtering conditions configured by each application are mainly used to filter the change information that does not need to be paid attention to by the application, so that when the display mode switching event occurs during the operation of the application, as few adjustments as possible are made to the generated target interface.
[0229] However, sometimes, if some parameters of the target interface are not changed after the terminal displays the display mode, it will cause certain display problems. Fig. 9A As shown, in the case of a folding screen terminal, if the display mode corresponding to the folded state is switched to the display mode of the unfolded state, the display is performed according to the display mode configuration information corresponding to the folded state, which may cause the target interface of the application to be blocked, resulting in a blocked area 901. Fig. 9B As shown, if the terminal switches from the display mode corresponding to the expanded state to the display mode corresponding to the folded state, display is performed according to the display mode configuration information corresponding to the expanded state, which may cause the target interface of the application to fail to completely cover the display area and a blank area 902 may appear.
[0230] In an embodiment of the present application, after the filtering step is executed, it is determined whether the obtained second change information needs to be changed based on the type of switching event and whether the change information includes data items corresponding to the screen layout information. If it is determined that a change is required, the screen layout information is added to the change information of the filtered new display mode configuration information. This ensures that the screen layout information that affects the display effect can be sent to the application when the target interface needs to be refreshed, so that the application will not ignore the change of the screen layout information due to filtering.
[0231] In one implementation, adding the screen layout information to the change information of the new display mode configuration information includes:
[0232] The screen layout information and the change information of the new display mode configuration information are connected by an OR operation instruction, so that the screen layout information is added to the change information of the new display mode configuration information.
[0233] In an embodiment of the present application, the screen layout information contained in the change information of the display mode configuration information before filtering and the new display mode configuration information obtained after filtering are connected with an OR operation instruction, thereby ensuring that the application can also receive the screen layout information connected with the OR operation instruction when the new display mode configuration information is obtained, and then adjust the refreshed target interface according to the screen layout information, so that the refreshed target interface is adapted to the display area after the display mode is switched.
[0234] In one embodiment, the display method when the display mode is switched further includes:
[0235] In the case where the change information of the display mode configuration information includes screen layout information, determining that the status information indicating the screen layout change event indicates that the screen layout of the terminal has changed;
[0236] The type of the display mode switching event is determined according to the display mode information.
[0237] In a specific implementation, before determining to refresh the target interface, it is necessary to determine whether the terminal meets two conditions: one is the type of the display mode switching event, and the other is whether the screen layout information changes when the display mode switching event occurs. If both conditions are met, it is determined to request the application to refresh the target interface.
[0238] In one implementation, determining state information for a screen layout change event according to change information of display mode configuration information includes:
[0239] When the change information of the display mode configuration information includes the screen layout information, a flag local variable is generated as the status information of the screen layout change event;
[0240] The flag local variable is assigned a first value to indicate that the status information of the screen layout change event indicates that the screen layout of the terminal has changed.
[0241] In one embodiment, since the type of the switching event has been determined to be the first type, when it is further determined that the change information of the display mode configuration information includes the screen layout information, the switching event is determined to be an event that requires the application's attention, and the screen layout information has also changed, thereby determining that the application can be requested to refresh the target interface. In general, a series of processing operations need to be performed on the change information of the display mode configuration information in the WMS module of the terminal, including judgment, filtering, and sending. In an embodiment of the present application, before filtering the change information of the display mode configuration information, a flag local variable is generated as an indication of whether to refresh the target interface, thereby eliminating the need to change the normal processing flow of the WMS for the change information of the display mode configuration information, and also eliminating the loss of information such as the screen layout information that plays a decisive role in whether to refresh the target interface due to the filtering of the change information of the display mode configuration information by the WMS, thereby facilitating accurate judgment of whether to refresh the target interface.
[0242] In one implementation, obtaining state information for indicating a screen layout change event according to change information of the display mode configuration information includes:
[0243] When the display mode configuration information change information does not include the screen layout information, the flag local variable is assigned a second value to indicate that the screen layout of the terminal indicated by the status information indicating the screen layout change event has not changed.
[0244] In a specific implementation, the flag local variable is assigned the second value by default, indicating that the target interface does not need to be refreshed. Therefore, when the display mode configuration information change information does not include the screen layout information, the flag local variable is not modified, and retains the second value.
[0245] When the change information of the display mode configuration information does not include the screen layout information, it means that although the type of the switching event conforms to the first type, the screen layout has not changed before and after the switching. Therefore, there is no need to refresh the target interface to meet the requirement that the target interface adapts to the screen layout after the switch.
[0246] In one embodiment, the screen is a folding screen; the folding screen can be folded to form at least two screens, the at least two screens include a first screen and a second screen, and when the folding screen is in an unfolded state, the first screen and the second screen are opposite to each other; the screen switching event includes: the target interface is switched from being displayed on the first screen to being displayed on the second screen; and the refreshed target interface is displayed on the screen, including:
[0247] The refreshed target interface is displayed on the second screen. The first screen and the second screen in this embodiment are not completely consistent with the first screen and the second screen in the above embodiment, but are named just to distinguish different screens.
[0248] In the case where the terminal is a mobile phone including a folding screen, the state of the terminal may include an unfolded state and a folded state, and the folding screen includes a first screen and a second screen that can be folded. In the unfolded state, the target interface of the application is displayed on a large screen formed by the first screen and the second screen, and in the folded state, the target interface of the application is displayed on a small screen using the first screen or the second screen. Generally, the width of the small screen is about half of the large screen. In-application split-screen display is a feature of the unfolded state of a mobile phone with a folding screen. In the large screen, the two target interfaces of an application are displayed in a split-screen format, and generally the split-screen ratio is one-half. In the unfolded state, the two target interfaces of the application are displayed in the form of an in-application split-screen, and in the folded state, a single target interface of the application is displayed. The display mode of the target interface will be switched when the display mode is switched. However, when the width of the small screen differs greatly from half of the width of the large screen, the width of the target interface of the application will not match the screen width before and after the screen mode is switched. For example, refer to greater than. Fig. 9A When the terminal is converted from the folded state to the expanded state, the target interface of the application is blocked. When the terminal is converted from the expanded state to the folded state, the target interface of the application is left blank. Fig. 9B shown.
[0249] The reason for this problem is that when the screen is folded, WMS sends a configuration change (change information of the display mode configuration information), which carries size change information (that is, multiple data items in the aforementioned embodiment). The size change information includes screenSize (screen size), smallestScreenSize (minimum screen size), and screenLayout (screen layout information).
[0250] screenSize indicates the change information of the current available screen size. This value indicates the change of the current available size relative to the current aspect ratio. It changes when the user switches between landscape mode and portrait mode.
[0251] The smallestScreenSize indicates the change in the physical screen size. This value indicates a size change that is independent of the orientation, so it changes only when the actual physical screen size changes (such as switching from the terminal's own display to an externally connected display).
[0252] Changes to screenLayout screen layout information may occur when other screens become active.
[0253] screenLayout includes multiple sub-data items: screen size level, widescreen indication information, screen orientation information, and rounded corner screen indication information. Among them, the screen size level includes four possible contents: SCREENLAYOUT_SIZE_SMALL (small screen layout size), SCREENLAYOUT_SIZE_NORMAL (normal screen layout size), SCREENLAYOUT_SIZE_LARGE (large screen layout size), and SCREENLAYOUT_SIZE_XLARGE (extra large screen layout size), corresponding to four preset screen levels of different sizes. Whether it is a widescreen indication information is used to indicate whether the screen is wider or taller than a normal screen. The screen orientation information is used to indicate whether the screen is displayed from left to right or from right to left. Whether it is a rounded corner screen indication information is used to indicate whether the screen has rounded corners.
[0254] WMS will decide whether to relaunch (refresh) the target interface of the application or directly dispatch the change information of the display mode configuration information to the application, so that the application can refresh the interface according to the change information of the display mode configuration information sent by WMS. However, in order to receive the change information of the display mode configuration information only when necessary, the application will configure the thresholds of screenSize, smallestScreenSize, and screenLayout changes, so that WMS can filter the multiple data items included in the change information of the display mode configuration information and filter out the unnecessary data items. Before and after the terminal is expanded and folded, WMS judges and filters according to the threshold provided by the application. If the change of a data item is on the same side of the corresponding threshold, the data item is filtered out in the configuration change and will not be sent to the application, and then the target interface will not be refreshed according to the filtered data item. If the filtered data item is screen layout information, and there is a large screen layout change on the terminal display before and after the display mode is switched, it may cause the target interface of the application to not be updated before and after the display mode of the terminal is switched, and then there will be Fig. 9A , Fig. 9B The situation shown is covered or left blank.
[0255] In this solution, when WMS determines that the current device is a foldable screen and is in a screen switching scenario, if the configurationchange contains information about the screen size change screenLayout, a flag local variable (FLAG1) is set to true (i.e., the first value). If it does not contain information about the screen layout, FLAG1 is set to false (i.e., the second value), and then the procedure for filtering the change information of the display mode configuration information is performed. If the foldable screen is not satisfied and it is a screen switching scenario, such as multi-window deformation, from full screen to floating window, or from full screen to split screen, the procedure for filtering the change information is performed directly; after filtering, new change information is calculated. If FLAG1 is true, CONFIG_SCREEN_LAYOUT is added to the change value calculated based on the filtering. Finally, WMS determines whether to relaunch based on the latest change value, or directly distribute the change information of the new display mode configuration information to the application.
[0256] In the source code, when the folding screen switches the display mode, the values of screenSize, smallestScreenSize, and screenLayout in the configuration change are filtered according to the threshold configured by the application. If screenLayout is filtered out, some application interfaces will not adapt to the screen after the display mode is switched. In the embodiment of the present application, this scenario is judged, and then the value of screenLayout is added back to the change information of the display mode configuration information. WMS determines whether to relaunch the target interface of the application based on the flag local variable, ensuring that the application interface before and after the switch adapts to the size of the screen.
[0257] In one embodiment, when the change information of the display mode configuration information includes screen layout information, the screen layout information includes screen size level information and wide screen indication information before the display mode switching event, and screen size level information and wide screen indication information after the display mode switching event.
[0258] In a specific implementation, the screen layout information, as a data item included in the change information of the display mode configuration information, may further include more sub-data items. When performing a filtering operation, a portion of the sub-data items in the screen layout information may be filtered out, while another portion may not be filtered out. In this case, if the target interface needs to be refreshed, the screen layout information before filtering is still added to the change information after filtering in an OR operation.
[0259] In one embodiment, the display method for switching the display mode further includes:
[0260] When the folding screen changes from an unfolded state to a folded state, or when the folding screen changes from a folded state to an unfolded state, determining that the screen switching event that occurs is of the first type;
[0261] When the folding screen changes from an unfolded state to a hovering state, or when the folding screen changes from a folded state to a hovering state, it is determined that the screen switching event that occurs is of the first type.
[0262] In one embodiment, the display method for switching the display mode further includes:
[0263] When the type of the display mode switching event is the second type, filtering the change information of the display mode configuration information to obtain filtered third information;
[0264] The filtered third information is reported to the application layer of the terminal, and the filtered third information is used to instruct the application to change the target interface displayed on the screen.
[0265] In one implementation, the change information of the display mode configuration information includes at least one kind of information, and each kind of change information of the display mode configuration information records the parameters before the switching event of the display mode and the parameters after the switching event of the display mode; filtering the change information of the display mode configuration information includes:
[0266] For each display mode configuration information change information, when the parameters before the display mode switching event and the parameters after the display mode switching event are both greater than a preset threshold, the parameters before the display mode switching event and the parameters after the display mode switching event are filtered out;
[0267] For each display mode configuration information change information, when the parameters before the display mode switching event and the parameters after the display mode switching event are both less than a preset threshold, the parameters before the display mode switching event and the parameters after the display mode switching event are filtered out.
[0268] In one implementation, the change information of the display mode configuration information includes: change information of the available screen size and change information of the physical screen size.
[0269] Fig.10 The signaling interaction diagram shown shows the signaling interaction process of the display method according to an embodiment of the present application, including steps S1001 to S1013.
[0270] In step S1001: the system library of the terminal obtains the display mode information of the terminal.
[0271] In step S1002: the WMS determines, based on the display mode information, that a display mode switching event occurs.
[0272] In step S1003: the WMS obtains change information of the display mode configuration information.
[0273] In step S1004: the WMS determines the type of the display mode switching event according to the display modes before and after the display mode switching event.
[0274] In step S1005: the WMS determines that the type of the display mode switching event is the type of switching between folding and unfolding of the folding screen (ie, the first type in the aforementioned embodiment), and further determines whether the change information of the display mode configuration information includes screen layout information.
[0275] In step S1006: WMS generates a flag local variable.
[0276] In step S1007: when the change information of the display mode configuration information includes the screen layout information, the WMS assigns the flag local variable to "true".
[0277] In step S1008: when the change information of the display mode configuration information does not include the screen layout information, the WMS assigns the flag local variable to "false".
[0278] In step S1009: the WMS filters the change information of the display mode configuration information.
[0279] In step S1010: the WMS adds the screen layout information to the filtered change information according to the value "true" assigned to the flag local variable.
[0280] In step S1011: the WMS sends a target interface refresh request to the application according to the change information of the added screen layout information.
[0281] In step S1012: WMS reports the filtered change information to the application layer according to the value "false" assigned to the flag local variable.
[0282] In step S1013 , after receiving the target interface refresh request, the application refreshes the target interface according to the change information of the added screen layout information.
[0283] The present application also provides a display device, which is applied to a terminal, and the terminal includes a screen, such as Fig.11 As shown, the display device includes:
[0284] The display mode information acquisition module 1101 is used to acquire the display mode information of the terminal;
[0285] The change information obtaining module 1102 is used to obtain the change information of the display mode configuration information corresponding to the display mode switching event when it is determined according to the display mode information that a display mode switching event occurs on the screen;
[0286] The state information determining module 1103 is used to obtain state information indicating a screen layout change event according to the change information of the display mode configuration information when the type of the display mode switching event is the first type;
[0287] A refresh module 1104, configured to refresh a target interface of the application displayed on the screen when the determined type is the first type;
[0288] The refresh display module 1105 displays the refreshed target interface on the screen according to the change information of the display mode configuration information.
[0289] In one embodiment, the display device further includes:
[0290] A first filtering module, configured to filter the change information of the display mode configuration information to obtain filtered first information when the status information indicating the screen layout change event indicates that the screen layout of the screen has not changed and the type of the switching event is the second type;
[0291] The first information sending module is used to report the filtered first information to the application layer of the terminal, and the filtered first information is used to instruct the application to change the interface parameters of the target interface displayed on the screen.
[0292] In one embodiment, the display device further includes:
[0293] A second filtering module, used for filtering the change information of the display mode configuration information to obtain filtered second information;
[0294] a change information generating module, configured to generate change information of new display mode configuration information according to the filtered second information when the status information indicating the screen layout change event indicates that the screen layout of the terminal has changed and the type of the switching event is the first type;
[0295] The second change information obtaining module is used to obtain the second change information of the display mode configuration information according to the change information of the new display mode configuration information and the screen layout information; the second change information of the display mode configuration information is used to obtain the refreshed target interface.
[0296] In one embodiment, the refresh module includes:
[0297] The second change information sending unit is used to send a target interface refresh request and second change information of the display mode configuration information to the application layer of the terminal, so that the application generates a refreshed target interface according to the second change information of the display mode configuration information.
[0298] In one implementation, the second change information sending unit is further configured to:
[0299] The screen layout information is added to the change information of the new display mode configuration information to obtain the second change information of the display mode configuration information.
[0300] In one implementation, the second change information sending unit is further configured to:
[0301] The screen layout information and the change information of the new display mode configuration information are connected by an OR operation instruction, so that the screen layout information is added to the change information of the new display mode configuration information.
[0302] In one embodiment, the display device further includes:
[0303] a state information analysis module, for determining that the state information indicating the screen layout change event indicates that the screen layout of the terminal has changed when the change information of the display mode configuration information includes the screen layout information;
[0304] The type determination module is used to determine the type of the display mode switching event according to the display mode information.
[0305] In one embodiment, the status information determination module includes:
[0306] A local variable generating unit, used for generating a flag local variable as status information of a screen layout change event when the change information of the display mode configuration information includes the screen layout information;
[0307] The first assignment unit is used to assign a flag local variable to a first value to indicate that the status information of the screen layout change event indicates that the screen layout of the terminal has changed.
[0308] In one embodiment, the status information determination module includes:
[0309] The second assignment unit is used to assign the flag local variable to a second value when the display mode configuration information change information does not include the screen layout information, so as to indicate that the screen layout of the terminal indicated by the status information indicating the screen layout change event has not changed.
[0310] In one embodiment, the screen is a folding screen; the folding screen can be folded to form at least two screens, the at least two screens include a first screen and a second screen, and when the folding screen is in an unfolded state, the first screen and the second screen are opposite to each other; the screen switching event includes: the target interface is switched from being displayed on the first screen to being displayed on the second screen; the refresh display module includes:
[0311] The second screen display unit is used to display the refreshed target interface on the second screen.
[0312] In one embodiment, when the change information of the display mode configuration information includes screen layout information, the screen layout information includes screen size level information and wide screen indication information before the display mode switching event, and screen size level information and wide screen indication information after the display mode switching event.
[0313] In one embodiment, the display device further includes:
[0314] a first switching event determining module, configured to determine that a screen switching event of the first type occurs when the folding screen changes from an unfolded state to a folded state, or when the folding screen changes from a folded state to an unfolded state;
[0315] The second switching event determination module is used to determine that the screen switching event that occurs is of the first type when the folding screen changes from an unfolded state to a hovering state, or when the folding screen changes from a folded state to a hovering state.
[0316] In one embodiment, the display device further includes:
[0317] A third filtering module, configured to filter the change information of the display mode configuration information when the type of the display mode switching event is the second type, to obtain filtered third information;
[0318] The third information sending module is used to report the filtered third information to the application layer of the terminal, and the filtered third information is used to instruct the application to change the target interface displayed on the screen.
[0319] In one embodiment, the change information of the display mode configuration information includes at least one information, and each change information of the display mode configuration information records the parameters before the switching event of the display mode and the parameters after the switching event of the display mode; the first filtering module, the second filtering module or the third filtering module also includes:
[0320] A first filtering unit is used for filtering out the parameters before the display mode switching event and the parameters after the display mode switching event for each display mode configuration information change information when both the parameters before the display mode switching event and the parameters after the display mode switching event are greater than a preset threshold;
[0321] The second filtering unit is used to filter out the parameters before the display mode switching event and the parameters after the display mode switching event for the change information of each display mode configuration information when the parameters before the display mode switching event and the parameters after the display mode switching event are both less than a preset threshold.
[0322] In one implementation, the change information of the display mode configuration information includes: change information of the available screen size and change information of the physical screen size.
[0323] Fig.12 A schematic diagram of the hardware structure of another electronic device provided in an embodiment of the present application is shown in FIG. Fig.12 As shown, the electronic device includes a processor 1201, a communication line 1204 and at least one communication interface ( Fig.12 The communication interface 1203 is used as an example for explanation).
[0324] The processor 1201 may be a general-purpose central processing unit (CPU), a microprocessor, an application-specific integrated circuit (ASIC), or one or more integrated circuits for controlling the execution of the program of the present application.
[0325] Communications link 1204 may include circuitry to transmit information between the above-described components.
[0326] The communication interface 1203 uses any transceiver or other device for communicating with other devices or communication networks, such as Ethernet, wireless local area networks (WLAN), etc.
[0327] Possibly, the electronic device may further include a memory 1202 .
[0328] The memory 1202 may be a read-only memory (ROM) or other types of static storage devices that can store static information and instructions, a random access memory (RAM) or other types of dynamic storage devices that can store information and instructions, or an electrically erasable programmable read-only memory (EEPROM), a compact disc read-only memory (CD-ROM) or other optical disc storage, optical disc storage (including compressed optical disc, laser disc, optical disc, digital versatile disc, Blu-ray disc, etc.), a magnetic disk storage medium or other magnetic storage device, or any other medium that can be used to carry or store the desired program code in the form of instructions or data structures and can be accessed by a computer, but is not limited thereto. The memory may exist independently and be connected to the processor via a communication line 1204. The memory may also be integrated with the processor.
[0329] The memory 1202 is used to store computer-executable instructions for executing the solution of the present application, and the execution is controlled by the processor 1201. The processor 1201 is used to execute the computer-executable instructions stored in the memory 1202, thereby implementing the method provided by the embodiment of the present application.
[0330] Possibly, the computer-executable instructions in the embodiments of the present application may also be referred to as application code, and the embodiments of the present application do not specifically limit this.
[0331] In a specific implementation, as an embodiment, the processor 1201 may include one or more CPUs, such as Fig.12 CPU0 and CPU1 in.
[0332] In a specific implementation, as an embodiment, the electronic device may include multiple processors, such as Fig.12 1 and 1205. Each of these processors may be a single-CPU processor or a multi-CPU processor. A processor herein may refer to one or more devices, circuits, and / or processing cores for processing data (e.g., computer program instructions).
[0333] The computer program product includes one or more computer instructions. When the computer program instructions are loaded and executed on the computer, the process or function according to the embodiment of the present application is generated in whole or in part. The computer may be a general-purpose computer, a special-purpose computer, a computer network or other programmable device. The computer instructions may be stored in a computer-readable storage medium, or transmitted from one computer-readable storage medium to another computer-readable storage medium. For example, the computer instructions may be transmitted from one website, computer, server or data center to another website, computer, server or data center by wired (e.g., coaxial cable, optical fiber, digital subscriber line (DSL)) or wireless (e.g., infrared, wireless, microwave, etc.) means. The computer-readable storage medium may be any available medium that a computer can store or a data storage device such as a server or data center that includes one or more available media integrated. For example, the available medium may include a magnetic medium (e.g., a floppy disk, a hard disk or a tape), an optical medium (e.g., a digital versatile disc (DVD)), or a semiconductor medium (e.g., a solid state disk (SSD)), etc.
[0334] The present application also provides a computer program product including instructions. The computer program product may be a software or program product including instructions that can be run on a computing device or stored in any available medium. When the computer program product is run on at least one computing device, the at least one computing device executes the method provided in any of the above embodiments.
[0335] The embodiment of the present application also provides a computer-readable storage medium. The computer-readable storage medium can be any available medium that can be stored by a computing device or a data storage device such as a data center containing one or more available media. The available medium can be a magnetic medium (e.g., a floppy disk, a hard disk, a tape), an optical medium (e.g., a DVD), or a semiconductor medium (e.g., a solid-state hard disk). The computer-readable storage medium includes instructions that instruct the computing device to execute the method provided in any of the above embodiments.
[0336] Computer-readable media may include computer storage media and communication media, and may also include any medium that can transfer a computer program from one place to another. Storage media may be any target media that can be accessed by a computer.
[0337] In one possible implementation, a computer-readable medium may include random access memory (RAM), read-only memory (ROM), compact disc read-only memory (CD-ROM) or other optical disk storage, magnetic disk storage or other magnetic storage devices, or any other medium that is intended to carry or store the desired program code in the form of instructions or data structures and can be accessed by a computer. Moreover, any connection is appropriately referred to as a computer-readable medium. For example, if the software is transmitted from a website, server or other remote source using a coaxial cable, fiber optic cable, twisted pair, digital subscriber line (DSL) or wireless technology (such as infrared, radio and microwave), the coaxial cable, fiber optic cable, twisted pair, DSL or wireless technology such as infrared, radio and microwave are included in the definition of medium. Disks and optical disks as used herein include optical disks, laser disks, optical disks, digital versatile discs (DVD), floppy disks and Blu-ray discs, where disks usually reproduce data magnetically, while optical disks reproduce data optically using lasers. Combinations of the above should also be included in the scope of computer-readable media.
[0338] The embodiment of the present application further provides a chip, including a processor. The processor is used to read and execute a computer program stored in a memory to execute a call method provided by any embodiment of the present application.
[0339] Optionally, the chip also includes a memory, and the memory is connected to the processor via a circuit or wire.
[0340] The embodiment of the present application further provides a chip system, including a processor. The processor is used to read and execute a computer program stored in a memory to execute a call method provided by any embodiment of the present application.
[0341] Optionally, the chip system also includes a memory, and the memory is connected to the processor via circuits or wires.
[0342] The embodiments of the present application are described with reference to the flowcharts and / or block diagrams of the methods, devices (systems), and computer program products according to the embodiments of the present application. It should be understood that each process and / or box in the flowchart and / or block diagram, as well as the combination of the processes and / or boxes in the flowchart and / or block diagram, can be implemented by computer program instructions. These computer program instructions can be provided to a processing unit of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable device to generate a machine, so that the instructions executed by the processing unit of the computer or other programmable data processing device generate instructions for implementing the processes in the flowchart and / or block diagram. Figure 1A process or multiple processes and / or boxes Figure 1 A device that provides the functions specified in a block or multiple blocks.
[0343] A person skilled in the art will understand that all or part of the steps to implement the above embodiments may be accomplished by hardware or by instructing related hardware through a program, and the program may be stored in a computer-readable storage medium, and the above-mentioned storage medium may be a read-only memory, a disk or an optical disk, etc.
[0344] The embodiments described above are only used to illustrate the technical solutions of the present application, rather than to limit them. Although the present application has been described in detail with reference to the aforementioned embodiments, a person skilled in the art should understand that the technical solutions described in the aforementioned embodiments may still be modified, or some of the technical features may be replaced by equivalents. Such modifications or replacements do not deviate the essence of the corresponding technical solutions from the spirit and scope of the technical solutions of the embodiments of the present application, and should all be included in the protection scope of the present application.
Claims
1. A display method for switching display modes, applied to a terminal, wherein the terminal includes a screen; characterized in that: The method comprises: Acquiring display mode information of the terminal; In the case where it is determined according to the display mode information that a display mode switching event occurs on the screen, obtaining change information of the display mode configuration information corresponding to the display mode switching event; in different display modes, the area used to display the target interface is different; In the case where the type of the display mode switching event is the first type, obtaining state information for indicating a screen layout change event according to the change information of the display mode configuration information; the screen layout change event is an event of a change in the display area on the screen; When it is determined that the status information for indicating a screen layout change event indicates that the screen layout information of the screen has changed, and the type of the switching event is a first type, refreshing a target interface of the application displayed on the screen; the refreshing of the target interface of the application displayed on the screen comprises: sending a refresh request from a window management module of the terminal to an application layer, so that the application refreshes the target interface according to the change information of the display mode configuration information; A refreshed target interface is displayed on the screen according to the change information of the display mode configuration information.
2. The method according to claim 1, characterized in that The method further comprises: When the status information for indicating a screen layout change event indicates that the screen layout of the screen has not changed, and the type of the switching event is the second type, filtering the change information of the display mode configuration information to obtain filtered first information; The filtered first information is sent to an application layer, where the filtered first information is used to instruct the application to change interface parameters of the target interface displayed on the screen.
3. The method according to claim 1, characterized in that The method further comprises: filtering the change information of the display mode configuration information to obtain filtered second information; When the status information for indicating a screen layout change event indicates that the screen layout of the terminal has changed, and the type of the switching event is the first type, generating new display mode configuration information change information according to the filtered second information; According to the change information of the new display mode configuration information and the screen layout information, second change information of the display mode configuration information is obtained; the second change information of the display mode configuration information is used to obtain the refreshed target interface.
4. The method according to claim 3, characterized in that The refreshing of the target interface of the application displayed on the screen includes: A target interface refresh request and the second change information of the display mode configuration information are sent to the application layer of the terminal, so that the application generates a refreshed target interface according to the second change information of the display mode configuration information.
5. The method according to claim 3, characterized in that: The obtaining, according to the change information of the new display mode configuration information and the screen layout information, second change information of the display mode configuration information comprises: The screen layout information is added to the change information of the new display mode configuration information to obtain second change information of the display mode configuration information.
6. The method according to claim 5, characterized in that The adding the screen layout information to the change information of the new display mode configuration information includes: The screen layout information and the change information of the new display mode configuration information are connected by an OR operation instruction, so that the screen layout information is added to the change information of the new display mode configuration information.
7. The method according to claim 3, characterized in that The method further comprises: In a case where the change information of the display mode configuration information includes screen layout information, determining that the status information for indicating a screen layout change event indicates that a screen layout of the terminal has changed; The type of the display mode switching event is obtained according to the display mode information.
8. The method according to claim 1, characterized in that The obtaining, according to the change information of the display mode configuration information, state information for indicating a screen layout change event comprises: In the case where the change information of the display mode configuration information includes screen layout information, generating a flag local variable as status information of the screen layout change event; The flag local variable is assigned a first value to indicate that the status information of the screen layout change event indicates that the screen layout of the terminal has changed.
9. The method according to claim 8, characterized in that The obtaining, according to the change information of the display mode configuration information, state information for indicating a screen layout change event comprises: When the change information of the display mode configuration information does not include screen layout information, the flag local variable is assigned a second value to indicate that the status information for indicating a screen layout change event indicates that the screen layout of the terminal has not changed.
10. The method according to claim 1, characterized in that The screen is a foldable screen; the foldable screen can be folded to form at least two screens, the at least two screens include a first screen and a second screen, and when the foldable screen is in an unfolded state, the first screen and the second screen are opposite to each other; the screen switching event includes: the target interface is switched from being displayed on the first screen to being displayed on the second screen; the displaying of the refreshed target interface on the screen includes: The refreshed target interface is displayed on the second screen.
11. The method according to claim 10, characterized in that When the change information of the display mode configuration information includes screen layout information, the screen layout information includes screen size level information and wide screen indication information before the display mode switching event, and screen size level information and wide screen indication information after the display mode switching event.
12. The method according to claim 10, characterized in that The method further comprises: When the folding screen changes from an unfolded state to a folded state, or when the folding screen changes from a folded state to an unfolded state, determining that the screen switching event is of the first type; When the folding screen changes from an unfolded state to a hovering state, or when the folding screen changes from a folded state to a hovering state, it is determined that the screen switching event that occurs is of the first type.
13. The method according to claim 1, characterized in that The method further comprises: When the type of the display mode switching event is the second type, filtering the change information of the display mode configuration information to obtain filtered third information; The filtered third information is reported to the application layer of the terminal, and the filtered third information is used to instruct the application to change the target interface displayed on the screen.
14. The method according to any one of claims 2, 3 and 13, characterized in that: The change information of the display mode configuration information includes at least one kind of information, and each kind of change information of the display mode configuration information records the parameters before the switching event of the display mode and the parameters after the switching event of the display mode; The filtering of the change information of the display mode configuration information includes: For each display mode configuration information change information, when the parameters before the display mode switching event and the parameters after the display mode switching event are both greater than a preset threshold, the parameters before the display mode switching event and the parameters after the display mode switching event are filtered out; For each display mode configuration information change information, when the parameters before the display mode switching event and the parameters after the display mode switching event are both less than a preset threshold, the parameters before the display mode switching event and the parameters after the display mode switching event are filtered out.
15. The method according to claim 14, characterized in that The change information of the display mode configuration information includes: change information of the available screen size and change information of the physical screen size.
16. An electronic device, characterized in that: The electronic device comprises a processor coupled to a memory, wherein the processor is configured to execute a computer program or instruction stored in the memory, so that the electronic device implements the method according to any one of claims 1 to 15.
17. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores a computer program, and when the computer program is executed on an electronic device, the electronic device executes the method according to any one of claims 1 to 15.
Citation Information
Patent Citations
Screen switching method and device, computer readable storage medium and electronic equipment
CN115525180A
