Application and gesture navigation bar compatible operation method, graphical interface and related devices

By configuring appropriate gesture navigation bar height and avoidance information in the System UI, the compatibility problem of the application and gesture navigation bar that does not occupy screen space is solved, and the application is normal operation and white bar display is achieved.

CN118227026BActive Publication Date: 2025-04-11HONOR DEVICE CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202410266585.5
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2023-09-22
Publication Date
2025-04-11
Estimated Expiration
2043-09-22

AI Technical Summary

Technical Problem

When using a gesture navigation bar that does not occupy the screen display space, how to ensure that the application can adapt to this type of gesture navigation bar to ensure that the application runs compatible with the gesture navigation bar.

Method used

By configuring the gesture navigation bar height to be greater than 0 and less than the first threshold in the System UI of the electronic device, and after the application obtains the gesture navigation bar height information that is not 0, the corresponding service is successfully executed, and at the same time, the window management module obtains avoidance information, and modify it to 0, and return to the application to avoid displaying white bars.

Benefits of technology

While ensuring that the gesture navigation bar does not occupy the display space, ensure that the application can run normally, avoid white bar problems caused by avoiding layout, and meet the compatibility testing requirements of Google Framework.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118227026B_ABST
    Figure CN118227026B_ABST
Patent Text Reader

Abstract

The present application discloses a method for compatible operation of an application and a gesture navigation bar, a graphical interface and related devices. The method includes: configuring the gesture navigation bar height information to a value slightly greater than 0 in the system user interface (System UI) of the electronic device, the application of the electronic device receives a trigger operation, and the application successfully executes the service corresponding to the trigger operation after obtaining the gesture navigation bar height information slightly greater than 0. In addition, the application also obtains avoidance information from the window management module, and the window management module modifies the obtained avoidance information from non-0 to 0 based on the gesture navigation bar height information obtained from the System UI and returns it to the application, and the electronic device does not display a white bar in the process of successfully executing the above service.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of terminals, and in particular to a method for running an application compatible with a gesture navigation bar, a graphical interface, and related devices. Background Art

[0002] At present, the navigation bars used in electronic devices are three-button navigation and gesture navigation bars with prompt bars. Both types of navigation require screen display space. In order to improve the screen usage efficiency of electronic devices, a gesture navigation bar that does not occupy screen display space has emerged. So when using a gesture navigation bar that does not occupy screen display space, how to ensure that the application can adapt to this type of gesture navigation bar, that is, how to ensure that the application is compatible with the gesture navigation bar, is an urgent problem to be solved. Summary of the invention

[0003] The present application provides a method for compatible operation of an application and a gesture navigation bar, a graphical interface and related devices, which can ensure compatible operation of the application and the gesture navigation bar when a gesture navigation bar is used that does not occupy screen display space.

[0004] In a first aspect, a method for compatible operation of an application and a gesture navigation bar is provided, the method being applied to an electronic device including a first application, the method comprising: displaying a gesture navigation bar, the gesture navigation bar not including prompt information, the prompt information being used to prompt a user to navigate through gestures; the height of the gesture navigation bar being a first height, the first height being greater than 0; receiving a first operation on the first application; obtaining the height of the gesture navigation bar through the first application, and the first application executing a task corresponding to the first operation. Among them, the gesture navigation bar not including prompt information may include two situations: situation 1, the gesture navigation bar does not include a prompt line / prompt bar, or other prompt information; situation 2, the gesture navigation bar may include a prompt line / prompt bar, but because the height of the gesture navigation bar is extremely small, it is almost invisible on the display screen of the electronic device and cannot achieve the effect of prompting the user, and therefore it also belongs to the situation where the gesture navigation bar does not include prompt information.

[0005] By implementing the method provided in the first aspect, it is possible to ensure that the application can be compatible with the gesture navigation bar when a gesture navigation bar that occupies almost no screen display space is used, that is, the efficiency of using the electronic device screen is improved without affecting the normal operation of the application. In addition, the application does not need to make additional improvements, and the application can continue to maintain a version that meets Google standards, ensuring a good user experience.

[0006] In combination with the first aspect, the method implemented in the first aspect also includes: obtaining an avoidance area with a height of 0 through the first application; and displaying content of the first application outside the avoidance area with a height of 0.

[0007] In this way, since the avoidance area of ​​the application is used to display information including the navigation bar, the implementation of the present invention can achieve, when using a gesture navigation bar that almost does not take up screen display space, avoiding the electronic device from having a blank space or displaying a white bar in the avoidance area due to the avoidance layout of the application, thereby increasing the screen display occupancy rate of the application and bringing a good screen usage experience to the user.

[0008] In combination with the first aspect, in certain implementations of the first aspect, the electronic device also includes a window management module. Before obtaining the avoidance area with a height of 0 through the first application, the method also includes: requesting the window management module to obtain the avoidance area through the first application; obtaining the height of the gesture navigation bar through the window management module, and also obtaining the avoidance area with a height of 0 based on the height of the gesture navigation bar, and returning to the first application.

[0009] In this way, it can be specifically realized that the first application obtains the avoidance area height of 0, which improves the possibility of implementing the first aspect of the method, avoids the problem that the avoidance area height is not 0, which makes the avoidance area displayed larger and affects the screen occupancy of the application, and avoids the problem of white bars displayed in the avoidance area on the display screen, affecting the user experience.

[0010] In combination with the first aspect, in certain implementations of the first aspect, the method obtains the avoidance area with a height of 0 based on the height of the gesture navigation bar, specifically including modifying the height of the gesture navigation bar to 0 to obtain the avoidance area with a height of 0.

[0011] In this way, when obtaining the height of the gesture navigation bar, the obtained gesture navigation bar height data can be modified, so that in the case of different gesture navigation bar height values, for example, the gesture navigation bar height can be 1 or 2, the gesture navigation bar height value can be modified to 0, thereby improving the possibility of implementing the first aspect of the method and avoiding the problem that when the obtained gesture navigation bar height is not 0, the obtained avoidance area height is not 0, resulting in a larger avoidance area displayed on the display screen.

[0012] In combination with the first aspect, in certain implementations of the first aspect, the first application obtains the height of the gesture navigation bar, specifically including: requesting the height of the gesture navigation bar from a resource management module of the electronic device through the first application; obtaining the height of the gesture navigation bar from a system user interface in the electronic device through the resource management module as the first height, and returning the first height to the first application.

[0013] In this way, when the first application obtains the height of the gesture navigation bar, the resource management module obtains the height of the gesture navigation bar through the system user interface, thereby avoiding the problem that the resource management module cannot directly obtain the height of the gesture navigation bar.

[0014] In combination with the first aspect, in some implementations of the first aspect, the first height is preset in a system user interface in the electronic device.

[0015] In this way, after the first height is preset to the system user interface of the electronic device, the stability of the first height data in the electronic device is improved, the problem of temporarily configuring the height parameters of the gesture navigation bar when using the electronic device is avoided, and the problem of other applications or users modifying important system setting parameters is avoided.

[0016] In combination with the first aspect, in some implementations of the first aspect, the first height is also less than a first threshold.

[0017] In this way, under the restriction of the first threshold, it can be ensured that the first height is not 0 and is small enough, and under the restriction of the first height, the display area of ​​the gesture navigation bar is small enough so that the user can hardly see the gesture navigation bar. The screen occupancy rate of the application is improved, the problem of reduced space for users to operate the application is avoided, and the user experience is satisfied.

[0018] In combination with the first aspect, in some implementations of the first aspect, the first height is 1 device-independent pixel dp.

[0019] In this way, when the first height is 1dp, it can ensure that the actual display area of ​​the gesture navigation bar is small enough so that the user can hardly see the gesture navigation bar, thereby achieving a silent gesture navigation effect, expanding the specific scenarios for the silent gesture navigation bar, improving the screen occupancy of the application, and avoiding the problem of the gesture navigation bar height being set too large, affecting the user experience.

[0020] In combination with the first aspect, in some implementations of the first aspect, the first operation includes any one of the following: an operation of switching a camera, an operation of playing a voice message.

[0021] In this way, the operation can be guaranteed to respond normally in various application scenarios.

[0022] In combination with the first aspect, in some implementations of the first aspect, the first application is a system application or a third-party application.

[0023] In this way, the scope of the first application is indicated. Considering that any application that reads the height of the gesture navigation bar may have problems, the understanding of the scope of the first application is improved, and the problem of unclear scope of application programs that may have problems after reading the height of the gesture navigation bar is avoided.

[0024] In a second aspect, the present application provides an electronic device, comprising one or more memories and one or more processors; the memory is coupled to the one or more processors, the memory is used to store computer program code, the computer program code comprises computer instructions, and the one or more processors call the computer instructions so that the electronic device executes any one of the methods described in the first aspect above.

[0025] In a third aspect, the present application provides a chip, which is applied to an electronic device. The chip includes one or more processors, and the processor is used to call computer instructions so that the electronic device executes any method described in the first aspect above.

[0026] In a fourth aspect, the present application provides a computer-readable storage medium, comprising instructions. When the instructions are executed on an electronic device, the electronic device executes any method described in the first aspect. BRIEF DESCRIPTION OF THE DRAWINGS

[0027] Figure 1 A schematic diagram of an operation flow when an application obtains gesture navigation bar height information provided in an embodiment of the present application;

[0028] Figure 2 Another schematic diagram of an operation flow when an application obtains gesture navigation bar height information provided in an embodiment of the present application;

[0029] Figure 3 A schematic diagram of an operation flow when an application obtains avoidance information provided in an embodiment of the present application;

[0030] Figure 4 Another schematic diagram of an operation flow when an application obtains avoidance information provided in an embodiment of the present application;

[0031] Figure 5A-Figure 5B A schematic diagram of a user interface when a group of applications fail to run according to an embodiment of the present application;

[0032] Figure 6A-6B A schematic diagram of a user interface for a group of applications that are running normally but displaying a white bar provided in an embodiment of the present application;

[0033] Figure 7A-7B A schematic diagram of a user interface that is normally applied and displayed in a normal manner provided by an embodiment of the present application;

[0034] Figure 8 A software architecture block diagram of an electronic device provided in an embodiment of the present application;

[0035] Fig. 9 A block diagram of the hardware architecture of an electronic device provided in an embodiment of the present application. DETAILED DESCRIPTION

[0036] The technical solutions in the embodiments of the present application will be described clearly and in detail below in conjunction with the accompanying drawings. In the description of the embodiments of the present application, unless otherwise specified, " / " means or, for example, A / B can mean A or B; "and / or" in the text is only a description of the association relationship of the 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.

[0037] In the following, the terms "first" and "second" are used for descriptive purposes only and are not to be understood as suggesting or implying relative importance or implicitly indicating the number of the indicated technical features. Thus, a feature defined as "first" or "second" may explicitly or implicitly include one or more of the features, and in the description of the embodiments of the present application, unless otherwise specified, "plurality" means two or more.

[0038] Reference to "embodiments" in this application means that a particular feature, structure, or characteristic described in conjunction with the embodiments may be included in at least one embodiment of the present application. The appearance of the phrase in various locations in the specification does not necessarily refer to the same embodiment, nor is it an independent or alternative embodiment that is mutually exclusive with other embodiments. It is explicitly and implicitly understood by those skilled in the art that the embodiments described in this application may be combined with other embodiments.

[0039] The term "user interface (UI)" in the following embodiments of the present application refers to a medium interface for interaction and information exchange between an application or operating system and a user, which realizes the conversion between the internal form of information and the form that the user can receive. The user interface is a source code written in a specific computer language such as Java and extensible markup language (XML). The interface source code is parsed and rendered on an electronic device, and finally presented as content that the user can recognize. The commonly used form of user interface is a graphical user interface (GUI), which refers to a user interface related to computer operations that is displayed in a graphical manner. It can be a visual interface element such as text, icons, buttons, menus, tabs, text boxes, dialog boxes, status bars, navigation bars, widgets, etc. displayed on the display screen of an electronic device.

[0040] This application refers to the following terms:

[0041] Navigation bar refers to a system application of an electronic device. The display modes of the navigation bar include, for example: three-button navigation and gesture navigation bar with a prompt bar (such as a bottom navigation bar). Since the above two navigation bar display modes belong to the navigation types specified in the Google standard, and the height information of the two navigation bars is greater than 0 device-independent pixels (dp), and the height is large enough to display a navigation bar that the user can clearly see on the display screen. Therefore, in order to comply with Google standards, most applications only adapt to the processing logic of this type of three-button navigation and gesture navigation bar with a prompt bar.

[0042] The present application provides another display mode of a navigation bar, which is a gesture navigation bar that does not include prompt information (hereinafter, the gesture navigation bar that does not include prompt information will be referred to as a gesture navigation bar). The height information of the gesture navigation bar that does not include prompt information can be 0dp, or can be other values ​​slightly greater than 0dp, such as 1dp. When the gesture navigation is 0dp, the gesture navigation will not be displayed on the display screen; when the gesture navigation bar is a value slightly greater than 0dp, when the gesture navigation bar is displayed on the display screen, regardless of whether the gesture navigation bar includes a prompt bar / prompt line, since the gesture navigation bar occupies almost no display space, the user can hardly see the navigation bar, and thus cannot achieve the purpose of prompting the user to realize the navigation function through the gesture navigation bar. Therefore, this type of navigation bar can be called a gesture navigation bar that does not include prompt information. It can be seen that such a display mode of a gesture navigation bar can occupy almost no or a small display area while retaining the navigation function, thereby improving the screen usage efficiency and enhancing the user experience.

[0043] The gesture navigation bar height information may include the actual height value of the gesture navigation bar. Optionally, the gesture navigation bar height information may also include the gesture navigation bar frame height value. The actual height value of the gesture navigation bar refers to the height of the navigation bar displayed on the electronic device display screen, and the gesture navigation bar frame height refers to the height greater than or equal to the height of the gesture navigation bar displayed on the electronic device display screen, and the display area of ​​the gesture navigation bar frame in the electronic device display screen includes the display area of ​​the gesture navigation bar. The above height can be measured in dp numerical units and can be a numerical value scaled upward from the bottom of the display screen.

[0044] Third-party applications refer to applications that are not provided or developed by the manufacturer of the electronic device. The manufacturer of the electronic device may include the manufacturer, supplier, provider or operator of the electronic device.

[0045] The first application refers to an application program that is run in an electronic device using the method of the present invention, and the application program may include a system application, a third-party application, etc. Specifically, the first application may be shown as application A or application B in this embodiment.

[0046] In this application, the gesture navigation bar height information can be configured to 0 so that the gesture navigation bar does not occupy the screen display space, providing more display space for other applications, thereby improving screen usage efficiency. In this scenario, the specific operation process of the application obtaining the gesture navigation bar height information is as follows:

[0047] Figure 1 A schematic diagram of an operation flow when an application obtains gesture navigation bar height information is shown.

[0048] This operation process involves third-party applications, System UI, and system resource management modules. For the functions of third-party applications, System UI, and system resource management modules, please refer to the following Figure 8 Description of the software architecture of electronic devices in .

[0049] Specifically, the third-party application may be referred to as a first application.

[0050] Figure 1 Only taking a third-party application as an example, the method flow of obtaining a gesture navigation bar with a height of 0 is introduced. The operation flow when the system application obtains the height information of the gesture navigation bar is similar to the operation flow when the third-party application obtains the height information of the gesture navigation bar. Therefore, the operation flow of the system application obtaining the height information of the gesture navigation bar can refer to the operation flow of the third-party application obtaining the height information of the gesture navigation bar, which will not be repeated here.

[0051] like Figure 1 As shown, a method 200 for a third-party application to obtain gesture navigation bar height information specifically includes the following steps:

[0052] S201, System UI is configured with a gesture navigation bar whose height information is 0dp.

[0053] Specifically, the height information of the gesture navigation bar may be pre-configured to 0dp in the System UI, and the pre-configuration may be completed in the navigation bar resource configuration module in the System UI.

[0054] Specifically, configuring the gesture navigation bar height information to 0dp specifically includes configuring the gesture navigation bar actual height value to 0dp, and optionally, also includes configuring the gesture navigation bar frame height value to 0dp. For the definition of the gesture navigation bar actual height and the gesture navigation bar frame height, please refer to the above description.

[0055] Among them, the gesture navigation bar height information is configured as 0dp in SystemUI. The gesture navigation bar can provide users with the normal gesture navigation bar functions while providing more display space for applications, improving screen usage efficiency and giving users the ultimate user experience.

[0056] S202: The third-party application receives a user-triggered operation.

[0057] Specifically, the trigger operation received by the third-party application may include an operation of starting the third-party application, or may include an operation of triggering the third-party application to execute a specific service after the third-party application starts running.

[0058] Specifically, the user-triggered operation may be referred to as a first operation.

[0059] Specifically, the specific service depends on different applications. As long as it involves triggering the application to obtain the height information of the gesture navigation bar, the service performed by the electronic device can be called a specific service. For example, when application A performs the service of switching the front and rear cameras, or when application B performs the service of playing a voice message, it involves obtaining the height. Therefore, for application A, the service of switching the camera is a specific service, and for application B, the service of playing a voice message is also a specific service. Specifically, for the operation of triggering application A to switch the front and rear cameras, please refer to Figure 5A For the operation of application B triggering the device to play the voice message, please refer to Figure 5B The operation of a is shown.

[0060] Optionally, in S202, the third-party application may automatically execute a specific service during operation without being triggered by a user.

[0061] S203: The third-party application requests the system resource management module to obtain the height information of the gesture navigation bar.

[0062] Specifically, after the third-party application receives the above-mentioned trigger operation, the third-party application will execute a specific business. The execution of the specific business specifically includes: the third-party application requests the system resource management module to obtain the gesture navigation bar height information. When the obtained gesture navigation bar height information meets the conditions, the specific business is successfully executed. When the obtained gesture navigation bar height information does not meet the conditions, the specific business cannot be successfully executed, which is equivalent to a running failure of the third-party application (see the description in S206).

[0063] The specific implementation of the third-party application requesting the system resource management module to obtain the gesture navigation bar height information includes: the application calls a corresponding function to request to obtain the gesture navigation bar height information. Specifically, the function for obtaining the gesture navigation bar height information may include getResources(), getIdentifier(String name, String defType, String defPackage), and getDimensionPixelSize().

[0064] getResources() is used to obtain the system resource Resources object.

[0065] The three parameters in getIdentifier() are resource name, file type and package name. When the three parameters are navigation_bar_height, dimen and android, it means getting Android The navigation bar identifier called navigation_bar_height in the dimens.xml resource file used to define the size of the system application.

[0066] getDimensionPixelSize(int id) is used to obtain the pixel unit, which is used to determine the size of the id resource.

[0067] S204: The system resource management module obtains the gesture navigation bar height information as 0dp.

[0068] After receiving the request in S203, the system resource management module obtains the gesture navigation bar height information from the SystemUI. Specifically, the system resource management module executes the specific operation process in the getResources().getIdentifier() function and obtains the gesture navigation bar height information as 0dp.

[0069] Specifically, the gesture navigation bar height information is 0dp, including a configured gesture navigation bar actual height value of 0dp, and optionally, also including a configured gesture navigation bar frame height value of 0dp.

[0070] S205: The system resource management module returns the gesture navigation bar height information to the third-party application.

[0071] The system resource management module returns the gesture navigation bar height information to the third-party application, where the gesture navigation bar height information includes the actual height value of the gesture navigation bar and, optionally, also includes the gesture navigation bar frame height value.

[0072] S206: The third-party application determines that the height of the gesture navigation bar is not greater than 0 based on the acquired gesture navigation bar height information, and operates faultily in response to the triggering operation.

[0073] Specifically, the third-party application determines whether the gesture navigation bar height information is greater than 0 based on the acquired gesture navigation bar height information. If it is greater than 0, the corresponding specific service is executed in response to the trigger operation, that is, the third-party application can run normally. If it is not greater than 0, the specific service corresponding to the trigger operation cannot be successfully executed, that is, the third-party application fails to run.

[0074] Specifically, the above judgment on whether the height information of the gesture navigation bar is greater than 0 can be implemented by the following code:

[0075] intresourceId=getResources().getIdentifier("navigation_bar_height","dimen","android");

[0076] if(resourceId>0)

[0077] {

[0078] result=getResources().getDimensionPixelSize(resourceId);

[0079] }

[0080] The third-party application determines the rationality of the returned parameters by executing the above code. Specifically, it can determine whether the navigation bar identifier is greater than 0. If it is greater than 0, it is a reasonable navigation bar identifier, and fill in the navigation bar identifier in the corresponding function to obtain the gesture navigation bar height information returned by the function. If it is not greater than 0, it is not a reasonable navigation bar identifier, and the gesture navigation bar height information cannot be obtained, and the third-party application fails to run. Among them, judging the navigation bar identifier can be used as a way to implement the judgment of the gesture navigation bar height information. If the navigation bar identifier does not meet the conditions, it means that the gesture navigation bar height information does not meet the conditions.

[0081] In addition, when the third-party application fails to successfully respond to the trigger operation to execute the corresponding specific business, the third-party application can output an error prompt message, or not output a prompt message and do not respond. Figure 5A b and Figure 5B b is a description of the interface during operation failure.

[0082] In the aforementioned Figure 1In the method flow shown, the condition for third-party applications to determine whether they are running normally is whether the height of the gesture navigation bar is greater than 0. The reason is that in the native Google-defined system framework, the height of the navigation bar is greater than 0dp. Therefore, in order to adapt to the native Google-defined system framework, third-party applications have formulated processing logic for the navigation bar height greater than 0dp, and have not formulated processing logic for the gesture navigation bar height information value of 0dp. Therefore, third-party applications need to determine whether the navigation bar height is greater than 0dp to determine whether they are running normally.

[0083] Through the aforementioned Figure 1 According to the introduction, it can be found that when the gesture navigation bar is configured with a height of 0dp, although the navigation bar does not occupy the display area, thereby improving the screen usage efficiency, some applications are not compatible with the processing logic of this type of navigation bar, and then there will be operation failures, which brings a bad user experience. Especially for some applications with a large number of users at home and abroad, once this failure occurs, it will seriously affect the user experience.

[0084] Therefore, in order to ensure the normal operation of the application when the gesture navigation bar height is 0, a whitelist system can be added to ensure that the applications in the whitelist can operate normally. Specifically, between the aforementioned S204-S205, a step is added to determine whether the application that obtains the gesture navigation bar height is an application in the whitelist. If so, the gesture navigation bar height information is modified from 0dp to a non-zero value, such as 1dp, and the modified gesture navigation bar height information is returned to the third-party application. If the application package name is not in the whitelist, the gesture navigation bar height information of 0dp is directly returned to the third-party application. After adding the whitelist mechanism, the gesture navigation bar height information received by the application in the whitelist can be 1dp, so that the third-party application can successfully execute the corresponding specific business, that is, operate normally. If the gesture navigation bar height information received by the third-party application that is not in the whitelist is 0dp, the third-party application fails to operate.

[0085] The package name is the unique identifier of the application. The package name must be unique. One package name represents one application. Two applications are not allowed to have the same package name.

[0086] However, the whitelist system can only ensure that some applications can run normally when the gesture navigation bar height information value is 0dp, and it fails to achieve the goal of making all applications run normally. In addition, the whitelist requires long-term manual maintenance, and it is not possible to add all applications with operating failures in advance. Therefore, the whitelist mechanism cannot fundamentally solve the problem.

[0087] In order to solve the aforementioned problems, specifically, in order to improve the screen usage efficiency and to solve the operational failure problems that occur when the application uses the gesture navigation bar height information from the root, the present application provides a method for compatible operation of an application and a gesture navigation bar, a graphical interface and related devices. The method includes: configuring the gesture navigation bar height information to be greater than 0 and less than a first threshold in the System UI of the electronic device, the application of the electronic device receives a trigger operation, and the application successfully executes the service corresponding to the trigger operation after obtaining the non-zero gesture navigation bar height information. In addition, the application also obtains avoidance information from the window management module, and the window management module modifies the obtained avoidance information from non-0 to 0 based on the gesture navigation bar height information obtained from the System UI and returns it to the application, and the electronic device does not display a white bar in the process of successfully executing the above-mentioned service. Specifically, the avoidance information includes an avoidance area.

[0088] Among them, the gesture navigation bar height information is greater than 0 and less than a first threshold value, and it is only necessary to ensure that the user can hardly see the gesture navigation bar in the display screen. The threshold is determined by the pixel density parameter of the display screen of the electronic device. When the pixel density parameters of the display screens of different electronic devices are different, the first threshold value can be configured with different values. The following embodiments of this application only take the configuration of the gesture navigation bar height information to 1dp as an example.

[0089] Implementing the application and gesture navigation bar compatible operation method provided by this application can bring the following effects:

[0090] (1) While ensuring that the gesture navigation bar occupies almost no display space of the electronic device, the application is ensured to successfully execute its business, that is, to run normally.

[0091] (2) When the application and the gesture navigation bar are compatible, the problem of white bars displayed on electronic devices due to application layout avoidance is avoided.

[0092] (3) It can also ensure that the compatibility test requirements of the Google framework are passed.

[0093] The method for running an application compatible with the gesture navigation bar includes configuring the height information of the gesture navigation bar so that the application can adapt to the height information of the gesture navigation bar and then run normally. For details, please refer to the following Figure 2 Description of S302-S306 in.

[0094] Optionally, the method for running the application compatible with the gesture navigation bar also includes modifying the avoidance information so that the normal display of the electronic device is not affected when the application is running. For details, please refer to Figure 4 Steps S501-S509 shown.

[0095] Figure 2Another schematic diagram of the operation flow when an application obtains the height information of the gesture navigation bar is shown.

[0096] Figure 2 The process shown involves third-party applications, System UI, and system resource management modules.

[0097] The third-party applications, System UI and system resource management modules involved are described in detail later. Figure 8 Description in the software architecture of electronic devices.

[0098] Another operating process of the system application involving obtaining the height information of the gesture navigation bar is similar to another operating process of the third-party application described below involving obtaining the height information of the gesture navigation bar. Therefore, for another operating process of the system application involving obtaining the height information of the gesture navigation bar, you can refer to another operating process of the third-party application involving obtaining the height information of the gesture navigation bar, which will not be repeated here.

[0099] like Figure 2 As shown, another operation process 300 involving an application obtaining gesture navigation bar height information specifically includes the following steps:

[0100] S301, the System UI is configured with a gesture navigation bar whose height information is 1dp.

[0101] S302: The third-party application receives a user-triggered operation.

[0102] S303: The third-party application requests the system resource management module to obtain the height information of the gesture navigation bar.

[0103] S304: The system resource management module obtains the gesture navigation bar height information as 1dp.

[0104] Specifically, the 1dp height of the gesture navigation bar may be referred to as a first height.

[0105] S305: The system resource management module returns the gesture navigation bar height information to the third-party application.

[0106] The specific implementation of steps S301-S305 is the same as in the previous article. Figure 1 The specific implementation of steps S201-S205 is similar, the difference is that the height involved in steps S301-S305 is not 0dp, for example, 1dp, so for the description of steps S301-S305, please refer to the previous article Figure 1 Description of steps S201-S205.

[0107] S306: The third-party application determines that the height of the gesture navigation bar is greater than 0 based on the acquired gesture navigation bar height information, and operates normally in response to the triggering operation.

[0108] The specific implementation of step S306 is the same as the previous Figure 1 The specific implementation of step S206 is similar, except that the height involved in step S306 is not 0dp, for example, 1dp. Specifically, after obtaining the gesture navigation bar height information of 1dp, the third-party application can normally respond to the user's triggering operation and run normally.

[0109] During normal operation of application A, the electronic device may display a white bar or no white bar.

[0110] The implementation method of displaying white bars includes: some applications involve layout avoidance during operation. Specifically, the application needs to obtain the insets value for layout avoidance, and based on the insets value, it performs layout avoidance for other display contents other than the application. The insets value is obtained based on the gesture navigation bar height information. Specifically, based on the gesture navigation bar height information is not 0dp, the obtained insets value is not 0dp, then a white bar appears. The electronic device can display the following Fig. 7A and Figure 7B The interface. Fig. 7A b and Figure 7B b respectively show a display interface that operates normally but has a white bar. For the above method of obtaining the insets value, the specific implementation method can refer to the following Figure 3 The process shown.

[0111] The implementation method of not displaying the white bar includes: some applications do not involve layout avoidance during operation, or in the process of application layout avoidance, the obtained layout avoidance related parameters are modified to 0dp based on the relevant data, for example, the obtained gesture navigation bar height information is modified to make the obtained insets value 0dp. The electronic device can display the following Fig. 7A and Figure 7B The interface. Fig. 7A b and Figure 7B b respectively show a display interface of a different third-party application running normally and without a white bar. For the above method of obtaining the insets value, the specific implementation method can refer to the following Figure 4 The process shown.

[0112] Next, combine Figure 3 Hereinafter, a schematic diagram of an interface operation flow of an electronic device having a display problem provided by the present application will be introduced.

[0113] Figure 3 A schematic diagram of an operation flow when an application obtains avoidance information is shown.

[0114] Figure 3The process shown involves third-party applications, System UI, system resource management module and window management module.

[0115] The third-party applications, System UI, system resource management module and window management module involved are described in detail later. Figure 8 The description in the electronic device software architecture. The third-party application may include a first application, specifically, application A or application B.

[0116] Specifically, the operating process when the system application obtains avoidance information is similar to the operating process when the third-party application obtains avoidance information described below. Therefore, the operating process when the system application obtains avoidance information can refer to the operating process when the third-party application obtains avoidance information described below, which will not be repeated here.

[0117] like Figure 3 As shown, an interface operation process 400 of an electronic device having a display problem specifically includes the following steps:

[0118] S401, the third-party application obtains the insets value from the window management module.

[0119] Specifically, after receiving the trigger operation, the third-party application can request the management module to obtain the insets value. The trigger operation can be the above Figure 2 The operation shown in step S302 or other operations. Specifically, the electronic device performs Figure 2 The subsequent steps S303-S306 also execute the subsequent steps S402-S408.

[0120] S402, the window management module sends data related to obtaining insets values ​​to SystemUI.

[0121] After receiving the request for obtaining the insets value sent by the third-party application, the window management module sends the data related to obtaining the insets value to SystemUI. Specifically, the window management module sends the data related to obtaining the insets value to SystemUI.

[0122] S403, SystemUI sends data related to obtaining insets values ​​to the system resource management module.

[0123] The System UI sends data related to obtaining the insets value to the System Resource Management Module. Specifically, the data related to obtaining the insets value sent by the System UI to the System Resource Management Module includes the height information of the gesture navigation bar.

[0124] S404: The system resource management module adds 1dp to the acquired gesture navigation bar height information.

[0125] Specifically, the system resource management module increases the actual height value of the gesture navigation bar and the frame height value of the gesture navigation bar from 1dp to 2dp. The modification operation of the height information of the gesture navigation bar is an optional scheme, and the height information of the gesture navigation bar may be modified or not. The specific modification method of the height information of the gesture navigation bar is also an optional scheme, and the height information of the gesture navigation bar may be modified and increased by 1dp or other values. Specifically, for the above scheme of modifying the height information of the gesture navigation bar from 1dp to 2dp, when the gesture navigation bar is displayed on the display screen, since this type of gesture navigation bar takes up almost no display space, the effect of the user hardly seeing the navigation bar can be achieved. At the same time, because the processing efficiency of even-numbered parameters is higher in the framework of the Google system, the subsequent data processing execution efficiency of this modification scheme in the framework of the Google system is higher, and the calculation speed is faster, which is beneficial to subsequent data processing.

[0126] S405, the system resource management module sends the modified gesture navigation bar height information to the System UI.

[0127] Specifically, the System UI receives the gesture navigation bar height information of 2dp, and the System UI generates relevant parameters for calculating the insets value according to the received information. Specifically, the relevant parameters may be frame parameters composed of the actual height value of the gesture navigation bar and the frame height value of the gesture navigation bar.

[0128] S406, System UI sends insets related parameters to the window management module.

[0129] The insets-related parameter sent by the System UI to the window management module may be a frame, and the frame may be in a rectangular data format. Specifically, the frame may include the display distances of the four sides of the rectangle from the edges of the screen of the electronic device.

[0130] Optionally, the above steps S405-S406 can also be replaced by: the system resource management module directly sends the modified gesture navigation bar height information and insets related parameters to the window management module. That is, the transmission of the above gesture navigation bar height information and related parameters can be implemented only in the application framework layer, without passing through the SystemUI of the application layer and then passing to the window management module.

[0131] S407: The window management module returns the insets value to the third-party application.

[0132] The window management module calculates the insets value based on the received gesture navigation bar height information and related parameters. Specifically, based on the related parameter frame, the obtained insets value is 2dp. The data format constituting the frame is a rectangle with a height of 2dp. After obtaining the insets value, the window management module returns the insets value to the third-party application.

[0133] S408: The third-party application displays a white bar based on the acquired insets value.

[0134] Among them, the third-party application displays an abnormality in the electronic device in response to the request to obtain the insets value based on the obtained insets value. Specifically, the third-party application uses the obtained 2dp value to perform layout avoidance in the display interface. Since the insets value is not 0dp, a 2dp high white bar is left at the bottom of the display interface. Specifically, when the third-party application is application A, the abnormal interface displayed by application A can be as follows Fig. 6A As shown in b, when the third-party application is application B, the abnormal interface displayed by application B may be as follows Figure 6B Optionally, the bottom of the display interface in the electronic device may not display the above-mentioned 2dp white bar, but display a 2dp high black bar. Specifically, the display form of the avoidance area is not limited, that is, the avoidance area can display a white bar or a black bar.

[0135] Next, combine Figure 4 Hereinafter, a schematic diagram of the normal display interface operation flow of an electronic device provided by the present application will be introduced.

[0136] Figure 4 Another schematic diagram of the operation flow when an application obtains avoidance information is shown.

[0137] Figure 4 The process shown involves third-party applications, System UI, system resource management module and window management module.

[0138] For the third-party applications, System UI, system resource management module, and window management module involved, please refer to the following for detailed descriptions. Figure 8 Description of the software architecture of an electronic device. The third-party application can be application A or application B.

[0139] Specifically, the operating process of another method of the system application to obtain avoidance information is similar to the operating process of another method of the third-party application to obtain avoidance information described below. Therefore, the operating process of another method of the system application to obtain avoidance information can be referred to the operating process of another method of the third-party application to obtain avoidance information described below, which will not be repeated here.

[0140] like Figure 4 As shown, a normal display interface operation process 500 of an application in an electronic device specifically includes the following steps:

[0141] S501: The third-party application requests the window management module to obtain the insets value.

[0142] S502: The window management module sends data related to obtaining insets values ​​to SystemUI.

[0143] S503, SystemUI sends data related to obtaining insets values ​​to the system resource management module.

[0144] S504: The system resource management module adds 1dp to the acquired gesture navigation bar height information.

[0145] S505: The system resource management module sends the modified gesture navigation bar height information to the System UI.

[0146] S506, System UI sends insets related parameters to the window management module.

[0147] The specific implementation of steps S501-S506 is the same as above. Figure 3 The specific implementation of steps S401-S406 is similar, so for the description of steps S501-S506, please refer to the previous article Figure 3 Description of steps S401-S406.

[0148] S507, the window management module modifies relevant parameters to obtain new insets values.

[0149] The window management module modifies the relevant parameters. Specifically, the window management module modifies the received frame value, and modifies the value indicating the position of the upper border and the value indicating the position of the lower border in the frame to the same value, so as to overlap the upper and lower borders of the rectangle formed by the frame, and change a rectangle with a height of 2dp into a rectangle with a height of 0dp. Therefore, the new insets value calculated based on the modified frame is 0dp.

[0150] Specifically, frame refers to the rectangular area displayed on the display screen, including the display positions of the upper left vertex and the lower right vertex on the display screen. Usually, the ordinate of the lower right vertex is 0, and the ordinate of the upper left vertex is the height of the navigation bar. In this case, the method of obtaining the insets value modified to 0 specifically includes: setting the ordinates of the upper left vertex and the lower right vertex to the same, for example, modifying the ordinate of the upper left vertex to 0, and obtaining an insets value of 0.

[0151] When this new insets value is used for application layout avoidance, the application's display interface will not leave a 2dp high white bar.

[0152] S508: The window management module returns a new insets value to the third-party application.

[0153] Specifically, the insets value returned by the window management module to the third-party application is 0dp.

[0154] S509: The third-party application is displayed normally based on the obtained insets value.

[0155] The third-party application responds to the request to obtain the insets value based on the obtained insets value and displays normally in the electronic device. Specifically, the third-party application performs layout avoidance according to the insets value. Since it is 0dp, no avoidance is performed, and no abnormal avoidance area is displayed, that is, no white or black bar is displayed at the bottom of the electronic device screen, so that the interface is displayed correctly. When the third-party application is application A, the interface of application A can be as follows: Fig. 7A As shown in FIG. 1 , when the third-party application is application B, the interface of application B may be as follows: Figure 7B b is shown.

[0156] Based on the introduction of the method shown above, when executing the above method, the electronic device displays some user interfaces accordingly, including fault operation, normal operation but white bar and normal operation without white bar display. The specific display interface is as follows:

[0157] Figure 5A-Figure 5B A schematic diagram of a user interface when a group of applications fail to run is shown.

[0158] Figure 5A A schematic diagram of a user interface when an application fails to run is shown.

[0159] like Figure 5A FIG. a shows a user interface when application A captures an image through the rear camera. The interface includes: a front and rear camera switching icon 602 and a front camera 601 .

[0160] When application A uses the rear camera, the user needs to switch to the scene of using the front camera for shooting operation. The user clicks the front and rear camera switching icon 602 to trigger the front and rear camera switching operation. This operation can belong to Figure 1 After the user triggers the operation, if the electronic device performs the following steps: Figure 1 In the steps S203-S206, the front camera 601 cannot be started normally, and the service corresponding to the above operation cannot be successfully executed, that is, the electronic device displays the application A running fault interface, such as Figure 5Ab is shown.

[0161] Figure 5A FIG. 6 shows a fault operation interface of application A after a user operation. The interface displays an error prompt 603 to prompt the user that application A failed to successfully respond to the camera switching operation. The specific reasons for the failure of the operation may be: Figure 1 The reason is shown in step S206.

[0162] Figure 5B Another user interface schematic diagram when an application fails to run is shown.

[0163] Figure 5B FIG. a shows a user interface when application B is running, including a voice message sent by a user.

[0164] In the chat interface of application B, when the user needs to play the sent voice message, the user can touch the sent voice icon to play the voice. This operation can belong to Figure 1 After the user triggers the operation, if the electronic device executes the above Figure 1 If the steps S203-S206 in the above operation are not executed successfully, the service corresponding to the above operation cannot be successfully executed, that is, the user interface where the user fails to play the sent voice message can be as follows Figure 5B b is shown.

[0165] Figure 5B FIG. 1 shows a fault display interface of application B after a user operation. Specifically, after the user touches the voice icon, application B has no feedback and cannot play the voice message. The specific reason for the failure of the operation may be Figure 1 The reason is shown in step S206.

[0166] Figure 6A-6B A schematic diagram of a user interface showing a group of applications running normally but displaying a white bar.

[0167] Fig. 6A A schematic diagram of a user interface showing a normal running application but displaying a white bar is shown.

[0168] like Fig. 6A FIG. a shows a user interface when application A captures an image through the rear camera. The interface includes: a front and rear camera switching icon 602 and a front camera 601 .

[0169] When application A uses the rear camera, the user needs to switch to the scene where the front camera is used for shooting. The user clicks the front and rear camera switching icon 602 to trigger the front and rear camera switching operation. This operation can belong to Figure 2In step S302 of the embodiment, the user triggers the operation. After the user triggers the operation, if the electronic device executes the above Figure 2 If the front camera 601 is started normally, the service corresponding to the above operation is successfully executed. Figure 3 In the steps S401-S408 described in the above, the electronic device displays a user interface that runs application A normally but displays a white bar, such as Fig. 6A b is shown.

[0170] Fig. 6A FIG. 1 b shows a user interface of application A that runs normally after a user operation but displays a white bar. The interface correctly displays the front camera shooting picture, but a white strip 604 appears at the bottom of the interface. The specific reason for the white strip at the bottom of the interface may be Figure 3 The reason is shown in step S408.

[0171] Figure 6B Another user interface diagram showing a normal running application but displaying a white bar is shown.

[0172] Figure 6B FIG. a shows a user interface when application B is running, including a voice message sent by a user.

[0173] In the chat interface of application B, when the user needs to play the sent voice message, the user can touch the sent voice icon to play the voice. This operation can belong to Figure 2 After the user triggers the operation, if the electronic device executes the above Figure 2 At the same time, after the user triggers the operation, if the electronic device executes the above steps S303-S306, the service corresponding to the above operation is successfully executed. Figure 3 The electronic device displays a user interface that runs application B normally but displays a white bar. That is, the user plays a voice message normally but displays a white bar. Figure 6B b is shown.

[0174] Figure 6B b shows a user interface in which application B plays a voice message normally after a user operation but displays a white bar. Specifically, after the user touches the voice icon, the voice message icon of application B changes to a play icon, and a white bar 604 is displayed at the bottom of the display interface. The specific reason for the display of the white bar 604 may be Figure 3 The reason is shown in step S408.

[0175] Figure 7A-7B A schematic diagram of a user interface showing a group of applications running normally and being displayed normally is shown.

[0176] Fig. 7A A schematic diagram of a user interface in which an application is running normally and displayed normally is shown.

[0177] like Fig. 7A FIG. a shows a user interface when application A captures an image through the rear camera. The interface includes: a front and rear camera switching icon 602 and a front camera 601 .

[0178] When application A uses the rear camera, the user switches to a scene where the front camera is required for shooting. The user clicks the front and rear camera switching icon 602 to trigger the front and rear camera switching operation. This operation may belong to Figure 2 After the user triggers the operation, if the electronic device executes the above Figure 2 If the front camera 601 is started normally, the service corresponding to the above operation is successfully executed. Figure 4 The electronic device displays a user interface that runs application A normally and does not display a white bar, such as Fig. 7A b is shown.

[0179] Fig. 7A b shows a user interface of application A that runs normally after user operation and does not display a white bar, and the interface correctly displays the picture taken by the front camera.

[0180] Figure 7B Another schematic diagram of a user interface showing a normal running application and a normal display is shown.

[0181] Figure 7B FIG. a shows a user interface when application B is running, including a voice message sent by a user.

[0182] In the chat interface of application B, when the user needs to play the sent voice message, the user can touch the sent voice icon to play the voice. This operation can belong to Figure 2 After the user triggers the operation, if the electronic device executes the above Figure 4 At the same time, after the user triggers the operation, if the electronic device executes the above steps S501-S509, the service corresponding to the above operation is successfully executed. Figure 4 The electronic device displays the user interface of the normal operation of application B and does not display the white bar. That is, the user interface of the voice message played by the user is normal and does not display the white bar. Figure 7B b is shown.

[0183] Figure 7B FIG. 1 b shows a user interface in which application B plays a voice message normally and does not display a white bar after a user operation. Specifically, after the user touches the voice icon, the voice message icon of application B changes to a play icon.

[0184] In order to better understand the embodiments of the present application, the electronic device software architecture involved in the embodiments of the present application is first introduced.

[0185] Figure 8 A block diagram of the software architecture of an electronic device is exemplified.

[0186] like Figure 8 As shown, the software system of the electronic device can adopt a layered architecture, an event-driven architecture, a micro-core architecture, a micro-service architecture, or a cloud architecture. Taking the system as an example, the software structure of the electronic device is exemplarily explained.

[0187] The layered architecture divides the software into several layers, each with clear roles and division of labor. The layers communicate with each other through software interfaces. The system is divided into four layers, from top to bottom: application layer, application framework layer, Android runtime ( runtime) and system libraries, as well as the kernel layer.

[0188] The application layer can include a series of application packages.

[0189] like Figure 8 As shown, in the embodiment of the present application, the application layer includes: a system user interface (System UI) and a first application, etc.

[0190] Among them, System UI is a visual interface provided by the electronic device. For example, System UI is used to provide resources for displaying the navigation bar, status bar, notification bar, lock screen interface, etc. The information about the display resources of the navigation bar can be provided by the navigation bar resource configuration module in System UI. Specifically, the navigation bar resource configuration module pre-stores the gesture navigation bar height information.

[0191] Among them, the first application can be a third-party application or a system application. The first application can include application software with a large number of users at home and abroad. The first application can obtain the gesture navigation bar height information in SystemUI. Specifically, the first application can send a service request to the module in the application framework layer to control it to perform the corresponding task. For example, the system resource management module in the application framework layer can be controlled to obtain the gesture navigation bar height information from SystemUI. The specific introduction to the application framework layer can be shown as follows.

[0192] like Figure 8 As shown, in the embodiment of the present application, the application framework layer includes a system resource management module, a window management module, a view system module, and a notification management module.

[0193] Among them, the system resource management module can obtain the gesture navigation bar height information from SystemUI based on the business request of the application, modify the obtained gesture navigation bar height information, and then return it to the corresponding application. In addition, the system resource management module can also send the modified gesture navigation bar height information to SystemUI for subsequent business interaction between SystemUI and the window management module.

[0194] Among them, the window management module is used to manage window programs. The window management module has the functions of obtaining the size of the display screen, determining whether there is a status bar, locking the screen, and capturing the screen. In addition, based on the business request of the application, the window management module can obtain the gesture navigation bar height information from SystemUI to obtain avoidance information such as insets value, and send the insets value to the corresponding application. If the insets value obtained by the window management module is not 0dp, the insets value must be changed to 0dp, and then the modified insets value is sent to the application.

[0195] The view system module 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.

[0196] The notification management module enables applications to display notification information in the status bar, which 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 prompted in the status bar, a prompt sound is emitted, an electronic device vibrates, an indicator light flashes, etc.

[0197] like Figure 8 As shown, The runtime includes the core library and the virtual machine. The runtime is responsible for scheduling and management of the Android system.

[0198] The core library consists of two parts: one part is the function that needs to be called by the Java language, and the other part is the Android core library.

[0199] The application layer and the application framework layer run in a virtual machine. The virtual machine executes the Java files of the application layer and the application framework layer as binary files. The virtual machine is used to perform functions such as object life cycle management, stack management, thread management, security and exception management, and garbage collection.

[0200] The system library may include multiple functional modules, such as surface manager, media library, 3D graphics processing library (such as OpenGL ES), 2D graphics engine (such as SGL), etc.

[0201] The surface manager is used to manage the display subsystem and provide the fusion of two-dimensional and three-dimensional layers for multiple applications.

[0202] 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: JPG, PNG, etc.

[0203] The 3D graphics processing library is used to implement 3D graphics drawing, image rendering, synthesis and layer processing, etc.

[0204] A 2D graphics engine is a drawing engine for 2D drawings.

[0205] like Figure 8 As shown in Figure 1, the kernel layer is the layer between hardware and software. The kernel layer is used to drive the hardware to make it work. The kernel layer includes display drivers, audio drivers, camera drivers, and sensor drivers. Among them, the display driver is used to control the display screen to display the user interface, such as Figure 5A-Figure 7B The audio driver is used to drive the audio device to play audio, such as playing the following text Figure 6B and Figure 7B The camera driver is used to drive the camera to collect images, for example, Figure 5A , Fig. 6A and Fig. 7A The image in the shooting interface shown, the display driver is used to drive the display screen to display information, such as displaying Figure 5A , Fig. 6A and Fig. 7A The sensor driver is used to control the sensor module to collect corresponding parameters, such as Figure 5A-Figure 7B Displays the relevant data of the touch operation.

[0206] Electronic equipment can be equipped Or portable terminal devices with other operating systems, such as mobile phones, tablet computers, desktop computers, laptop computers, handheld computers, notebook computers, ultra-mobile personal computers (UMPC), netbooks, as well as cellular phones, personal digital assistants (PDA), augmented reality (AR) devices, virtual reality (VR) devices, artificial intelligence (AI) devices, wearable devices, vehicle-mounted devices, smart home devices and / or smart city devices, etc.

[0207] Fig. 9 A hardware architecture block diagram of an electronic device 900 is shown.

[0208] The electronic device 900 may include: a processor 910, an external memory interface 920, an internal memory 921, a universal serial bus (USB) interface 930, a charging management module 940, a power management module 941, a battery 942, an antenna 1, an antenna 2, a mobile communication module 950, a wireless communication module 960, an audio module 970, a speaker 970A, a receiver 970B, a microphone 970C, an earphone interface 970D, a sensor module 980, a camera 993, a display screen 994, and a subscriber identification module (SIM) card interface 995, etc. The sensor module 980 may include an ambient light sensor 980A, a distance sensor 980B, a touch sensor 980C, etc.

[0209] It is to be understood that the structure illustrated in the embodiment of the present application does not constitute a specific limitation on the electronic device 900. In other embodiments of the present application, the electronic device 900 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.

[0210] The processor 910 may include one or more processing units, for example, the processor 910 may include an application processor (AP), a modem processor, a graphics processor (GPU), an image signal processor (ISP), a controller, a memory, a video codec, a digital signal processor (DSP), a baseband processor, and / or a neural-network processing unit (NPU), etc. Different processing units may be independent devices or integrated into one or more processors.

[0211] The controller may be the nerve center and command center of the electronic device 900. The controller may generate an operation control signal according to the instruction operation code and the timing signal to complete the control of fetching and executing instructions.

[0212] The processor 910 may also be provided with a memory for storing instructions and data. In some embodiments, the memory in the processor 910 is a cache memory. The memory may store instructions or data that the processor 910 has just used or cyclically used. If the processor 910 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 910, and thus improves the efficiency of the system.

[0213] In some embodiments, the processor 910 may include one or more interfaces. The interface may include an inter-integrated circuit (I2C) interface, an inter-integrated circuit 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.

[0214] The USB interface 930 is an interface that complies with the USB standard specification, and specifically can be a Mini USB interface, a Micro USB interface, a USB Type C interface, etc. The USB interface 930 can be used to connect a charger to charge the electronic device 900, and can also be used to transfer data between the electronic device 900 and a peripheral device. It can also be used to connect headphones to play audio through the headphones. The interface can also be used to connect other electronic devices, such as AR devices, etc.

[0215] In the embodiment of the present application, the processor 910 is used to execute Figure 1-Figure 4 The method executed by the electronic device in the embodiment of the present invention, for the detailed introduction of the method, please refer to the above Figure 1-Figure 4 Introduction.

[0216] 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 900. In other embodiments of the present application, the electronic device 900 may also adopt different interface connection methods in the above embodiments, or a combination of multiple interface connection methods.

[0217] The charging management module 940 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 940 may receive charging input from a wired charger through the USB interface 930. In some wireless charging embodiments, the charging management module 940 may receive wireless charging input through a wireless charging coil of the electronic device 900. While the charging management module 940 is charging the battery 942, it may also power the electronic device through the power management module 941.

[0218] The power management module 941 is used to connect the battery 942, the charging management module 940 and the processor 910. The power management module 941 receives input from the battery 942 and / or the charging management module 940, and supplies power to the processor 910, the internal memory 921, the external memory, the display screen 994, the camera 993, and the wireless communication module 960. The power management module 941 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 941 can also be set in the processor 910. In other embodiments, the power management module 941 and the charging management module 940 can also be set in the same device.

[0219] The wireless communication function of the electronic device 900 can be implemented through antenna 1, antenna 2, mobile communication module 950, wireless communication module 960, modem processor and baseband processor.

[0220] Antenna 1 and antenna 2 are used to transmit and receive electromagnetic wave signals. Each antenna in electronic device 900 can be used to cover a single or multiple communication frequency bands. Different antennas can also be reused to improve the utilization of antennas. For example, antenna 1 can be reused as a diversity antenna for a wireless local area network. In some other embodiments, the antenna can be used in combination with a tuning switch.

[0221] The mobile communication module 950 can provide solutions for wireless communications including 2G / 3G / 4G / 5G, etc., applied to the electronic device 900. The mobile communication module 950 may include at least one filter, a switch, a power amplifier, a low noise amplifier (LNA), etc. The mobile communication module 950 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 950 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 950 can be set in the processor 910. In some embodiments, at least some of the functional modules of the mobile communication module 950 can be set in the same device as at least some of the modules of the processor 910.

[0222] 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 970A, a receiver 970B, etc.), or displays an image or video through a display screen 994. In some embodiments, the modem processor may be an independent device. In other embodiments, the modem processor may be independent of the processor 910 and be set in the same device as the mobile communication module 950 or other functional modules.

[0223] The wireless communication module 960 can provide wireless communication solutions including wireless local area networks (WLAN) (such as wireless fidelity (Wi-Fi) networks), bluetooth (BT), global navigation satellite system (GNSS), frequency modulation (FM), near field communication (NFC), infrared (IR), etc., which are applied to the electronic device 900. The wireless communication module 960 can be one or more devices integrating at least one communication processing module. The wireless communication module 960 receives electromagnetic waves via the antenna 2, demodulates and filters the electromagnetic wave signals, and sends the processed signals to the processor 910. The wireless communication module 960 can also receive the signal to be sent from the processor 910, modulate the frequency, amplify it, and convert it into electromagnetic waves for radiation through the antenna 2.

[0224] In some embodiments, the antenna 1 of the electronic device 900 is coupled to the mobile communication module 950, and the antenna 2 is coupled to the wireless communication module 960, so that the electronic device 900 can communicate with the network and other devices through wireless communication technology. The wireless communication technology may include global system for mobile communications (GSM), general packet radio service (GPRS), code division multiple access (CDMA), wideband code division multiple access (WCDMA), time-division code division multiple access (TD-SCDMA), long term evolution (LTE), BT, GNSS, WLAN, NFC, FM, and / or IR technology. The 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).

[0225] The electronic device 900 implements the display function through a GPU, a display screen 994, and an application processor. The GPU is a microprocessor for image processing, which connects the display screen 994 and the application processor. The GPU is used to perform mathematical and geometric calculations for graphics rendering. The processor 910 may include one or more GPUs, which execute program instructions to generate or change display information.

[0226] The display screen 994 is used to display images, videos, etc. The display screen 994 includes a display panel. The display panel can be a liquid crystal display (LCD). The display screen panel can also be made of 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, quantum dot light emitting diodes (QLED), etc. In some embodiments, the electronic device 900 may include 1 or N display screens 994, where N is a positive integer greater than 1.

[0227] In the embodiment of the present application, the display screen 994 is used to display in the electronic device, such as Figure 5A b and Figure 5B As shown in b, the display interface of the compatibility problem between the third-party application and the gesture navigation bar is as follows Fig. 6A b and Figure 6B The display interface shown in b solves the compatibility issue between third-party applications and the gesture navigation bar, but does not solve the problem of displaying a white bar, such as Fig. 7A b and Figure 7B The display interface shown in b solves the compatibility problem between third-party applications and the gesture navigation bar, and solves the problem of displaying white bars. For a detailed introduction to the above interface, please refer to the corresponding Figure 5A b to Figure 7B The introduction of b.

[0228] Furthermore, the display screen 994 is also used to display, for example Figure 5A A and Figure 5B The operation interface that triggers compatibility issues between third-party applications and the gesture navigation bar is shown in a. Fig. 6A A and Figure 6B The trigger shown in a solves the compatibility issue between third-party applications and the gesture navigation bar, but does not solve the problem of displaying a white bar. Fig. 7A A and Figure 7B The trigger shown in a solves the compatibility problem between third-party applications and the gesture navigation bar, and solves the problem of displaying white bars. For a detailed introduction to the above trigger operation interface, please refer to the corresponding method of the above method. Fig. 6A A to Figure 7B The introduction of a.

[0229] The electronic device 900 can realize the shooting function through an ISP, a camera 993, a video codec, a GPU, a display screen 994, and an application processor.

[0230] ISP is used to process the data fed back by camera 993. 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 and brightness 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 993.

[0231] The camera 993 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 to be converted 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 900 may include 1 or N cameras 993, where N is a positive integer greater than 1.

[0232] 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 900 selects a frequency point, the digital signal processor is used to perform Fourier transform on the frequency point energy.

[0233] Video codecs are used to compress or decompress digital videos. The electronic device 900 may support one or more video codecs. Thus, the electronic device 900 may play or record videos in a variety of coding formats, such as Moving Picture Experts Group (MPEG) 1, MPEG2, MPEG3, MPEG4, etc.

[0234] NPU is a neural network (NN) computing processor. By drawing on the structure of biological neural networks, such as the transmission mode between neurons in the human brain, it can quickly process input information and can also continuously self-learn. Through NPU, applications such as intelligent cognition of electronic device 900 can be realized, such as image recognition, face recognition, voice recognition, text understanding, etc.

[0235] The internal memory 921 may include one or more random access memories (RAM) and one or more non-volatile memories (NVM).

[0236] Random access memory may include static random access memory (SRAM), dynamic random access memory (DRAM), synchronous dynamic random access memory (SDRAM), double data rate synchronous dynamic random access memory (DDR SDRAM, for example, the fifth generation DDR SDRAM is generally referred to as DDR5 SDRAM), etc.;

[0237] Non-volatile memory may include disk storage devices and flash memory.

[0238] Flash memory can be divided into NOR FLASH, NAND FLASH, 3D NAND FLASH, etc. according to the operating principle; can be divided into single-level cell (SLC), multi-level cell (MLC), triple-level cell (TLC), quad-level cell (QLC), etc. according to the storage unit potential level; can be divided into universal flash storage (UFS), embedded multi media card (eMMC), etc. according to the storage specification.

[0239] The random access memory can be directly read and written by the processor 910, and can be used to store executable programs (such as machine instructions) of the operating system or other running programs, and can also be used to store user and application data, etc.

[0240] The non-volatile memory may also store executable programs and user and application data, etc., and may be loaded into the random access memory in advance for direct reading and writing by the processor 910 .

[0241] In the embodiment of the present application, the internal memory 921 is used to store Figures 1 to 4 The method executed by the electronic device in the embodiment of the present invention, for the detailed introduction of the method, please refer to the above Figures 1 to 4 The external memory interface 920 can be used to connect an external non-volatile memory to expand the storage capacity of the electronic device 900. The external non-volatile memory communicates with the processor 910 through the external memory interface 920 to implement a data storage function. For example, files such as music and videos are stored in the external non-volatile memory.

[0242] The electronic device 900 can implement audio functions such as music playing and recording through the audio module 970, the speaker 970A, the receiver 970B, the microphone 970C, the headphone jack 970D, and the application processor.

[0243] The audio module 970 is used to convert digital audio information into analog audio signal output, and is also used to convert analog audio input into digital audio signal. The audio module 970 can also be used to encode and decode audio signals. In some embodiments, the audio module 970 can be arranged in the processor 910, or some functional modules of the audio module 970 can be arranged in the processor 910.

[0244] The speaker 970A, also called a "speaker", is used to convert an audio electrical signal into a sound signal. The electronic device 900 can listen to music or listen to a hands-free call through the speaker 970A.

[0245] The receiver 970B, also called a "earpiece", is used to convert audio electrical signals into sound signals. When the electronic device 900 receives a call or voice message, the voice can be received by placing the receiver 970B close to the human ear.

[0246] Microphone 970C, 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 the microphone 970C to input the sound signal into the microphone 970C. The electronic device 900 can be provided with at least one microphone 970C. In other embodiments, the electronic device 900 can be provided with two microphones 970C, which can not only collect sound signals but also realize noise reduction function. In other embodiments, the electronic device 900 can also be provided with three, four or more microphones 970C to collect sound signals, reduce noise, identify the sound source, realize directional recording function, etc.

[0247] The earphone interface 970D is used to connect a wired earphone and can be the USB interface 930 or a 3.5 mm open mobile terminal platform (OMTP) standard interface or a cellular telecommunications industry association of the USA (CTIA) standard interface.

[0248] The ambient light sensor 980A is used to sense the brightness of the ambient light. The electronic device 900 can adaptively adjust the brightness of the display screen 994 according to the perceived brightness of the ambient light. The ambient light sensor 980A can also be used to automatically adjust the white balance when taking pictures.

[0249] The distance sensor 980B is used to measure the distance. The electronic device 900 can measure the distance by infrared or laser. In some embodiments, when shooting a scene, the electronic device 900 can use the distance sensor 980B to measure the distance to achieve fast focusing.

[0250] The touch sensor 980C is also called a "touch panel". The touch sensor 980C can be set on the display screen 994, and the touch sensor 980C and the display screen 994 form a touch screen, also called a "touch screen". The touch sensor 980C 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 display screen 994. In other embodiments, the touch sensor 980C can also be set on the surface of the electronic device 900, which is different from the position of the display screen 994.

[0251] The SIM card interface 995 is used to connect a SIM card. The SIM card can be connected to and separated from the electronic device 900 by inserting it into the SIM card interface 995 or pulling it out from the SIM card interface 995. The electronic device 900 can support 1 or N SIM card interfaces, where N is a positive integer greater than 1. The SIM card interface 995 can support Nano SIM cards, Micro SIM cards, SIM cards, and the like. Multiple cards can be inserted into the same SIM card interface 995 at the same time. The types of the multiple cards can be the same or different. The SIM card interface 995 can also be compatible with different types of SIM cards. The SIM card interface 995 can also be compatible with external memory cards. The electronic device 900 interacts with the network through the SIM card to implement functions such as calls and data communications. In some embodiments, the electronic device 900 uses an eSIM, i.e., an embedded SIM card. The eSIM card can be embedded in the electronic device 900 and cannot be separated from the electronic device 900.

[0252] The following is an example of the workflow of the software and hardware of the electronic device 900 in conjunction with capturing a photo scene.

[0253] When the touch sensor 980C receives a touch operation, the corresponding hardware interrupt is sent to the kernel layer. The kernel layer processes the touch operation into an original input event (including touch coordinates, timestamp of the touch operation, and other information). The original input event is stored in the kernel layer. The application framework layer obtains the original input event from the kernel layer and identifies the control corresponding to the input event. For example, if the touch operation is a touch single-click operation and the control corresponding to the single-click operation is the control of the camera application icon, the camera application calls the interface of the application framework layer to start the camera application, and then starts the camera driver by calling the kernel layer to capture static images or videos through the camera 993.

[0254] It should be understood that each step in the above method embodiment provided by the present application can be completed by an integrated logic circuit of hardware in a processor or by instructions in the form of software. The method steps disclosed in the embodiments of the present application can be directly embodied as being executed by a hardware processor, or by a combination of hardware and software modules in a processor.

[0255] The present application also provides an electronic device, which may include: a memory and a processor, wherein the memory may be used to store a computer program; and the processor may be used to call the computer program in the memory so that the electronic device executes the method in any one of the above embodiments.

[0256] The present application also provides a chip system, which includes at least one processor for implementing the functions involved in the method executed by the electronic device in any of the above embodiments.

[0257] In one possible design, the chip system also includes a memory, which is used to store program instructions and data, and the memory is located inside or outside the processor.

[0258] The chip system may be composed of the chip, or may include the chip and other discrete devices.

[0259] Optionally, the processor in the chip system may be one or more. The processor may be implemented by hardware or by software. When implemented by hardware, the processor may be a logic circuit, an integrated circuit, etc. When implemented by software, the processor may be a general-purpose processor implemented by obtaining software code stored in a memory.

[0260] Optionally, the memory in the chip system may also be one or more. The memory may be integrated with the processor or may be separately arranged with the processor, which is not limited in the embodiments of the present application. Exemplarily, the memory may be a non-transient processor, such as a read-only memory ROM, which may be integrated with the processor on the same chip or may be arranged on different chips respectively. The embodiments of the present application do not specifically limit the type of memory and the arrangement of the memory and the processor.

[0261] Exemplarily, the chip system can be a field programmable gate array (FPGA), an application specific integrated circuit (ASIC), a system on chip (SoC), a central processor unit (CPU), a network processor (NP), a digital signal processor (DSP), a microcontroller unit (MCU), a programmable logic device (PLD) or other integrated chips.

[0262] The present application also provides a computer program product, which includes: a computer program (also referred to as code, or instruction), which enables a computer to execute the method executed by the electronic device in any of the above embodiments when the computer program is executed.

[0263] The present application also provides a computer-readable storage medium, wherein the computer-readable storage medium stores a computer program (also referred to as code or instruction). When the computer program is executed, the computer executes the method executed by the electronic device in any of the above embodiments.

[0264] The various implementation modes of the present application can be combined arbitrarily to achieve different technical effects.

[0265] In the above embodiments, it can be implemented in whole or in part by software, hardware, firmware or any combination thereof. When implemented by software, it can be implemented in whole or in part in the form of a computer program product. The computer program product includes one or more computer instructions. When the computer program instructions are loaded and executed on a computer, the process or function described in this application is generated in whole or in part. The computer can be a general-purpose computer, a special-purpose computer, a computer network, or other programmable device. The computer instructions can 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 can be transmitted from a website site, computer, server or data center to another website site, computer, server or data center by wired (e.g., coaxial cable, optical fiber, digital subscriber line) or wireless (e.g., infrared, wireless, microwave, etc.) mode. The computer-readable storage medium can be any available medium that a computer can access or a data storage device such as a server or data center that includes one or more available media integrated. 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 SolidStateDisk), etc.

[0266] A person skilled in the art can understand that to implement all or part of the processes in the above-mentioned embodiments, the processes can be completed by a computer program to instruct the relevant hardware, and the program can be stored in a computer-accessible storage medium. When the program is executed, it can include the processes of the above-mentioned method embodiments. The aforementioned storage medium includes: ROM or random access memory RAM, magnetic disk or optical disk and other media that can store program codes.

[0267] In short, the above description is only an embodiment of the technical solution of the present invention, and is not intended to limit the protection scope of the present invention. Any modification, equivalent replacement, improvement, etc. made according to the disclosure of the present invention shall be included in the protection scope of the present invention.

Claims

1. A method for running an application compatible with a gesture navigation bar, characterized in that: The method is applied to an electronic device including a first application, the height of a gesture navigation bar of the electronic device is greater than 0, and the method includes: Displaying a first interface of the first application, where the first interface does not include prompt information, and the prompt information is used to prompt the user to perform gesture navigation; A first operation is received, and in response to the first operation, the first application obtains a height of the gesture navigation bar; Determine that the height of the gesture navigation bar is greater than 0, and execute the task corresponding to the first operation through the first application; Acquire the height of the avoidance area through the first application; The avoidance area is used for avoidance when laying out the content of the first application, 0 is the height of the avoidance area after modification, and the height of the avoidance area before modification is a value greater than or equal to the height of the gesture navigation bar generated based on the height of the gesture navigation bar; The content of the first application is displayed in a first area, where the first area is the entire display area of ​​the electronic device or the display area excluding a status bar, and the status bar is located at the top of the entire display area of ​​the electronic device.

2. The method according to claim 1, characterized in that: Obtaining the height of the avoidance area through the first application specifically includes: The first application sends a first request to the window management module, where the first request is used to obtain the height of the avoidance area; In response to the first request, the window management module obtains the height of the avoidance area before modification, and modifies the height of the avoidance area before modification to 0; The window management module returns the modified height of the avoidance area to the first application.

3. The method according to claim 1 or 2, characterized in that: The electronic device further includes a resource management module and a system user interface System UI, and the first application obtains the height of the gesture navigation bar, specifically including: The first application sends a second request to the resource management module, where the second request is used to obtain the height of the gesture navigation bar; The resource management module obtains the height of the gesture navigation bar from the System UI; The resource management module returns the height of the gesture navigation bar to the first application.

4. The method according to claim 1, characterized in that: The height of the gesture navigation bar is preset in the System UI of the electronic device.

5. The method according to claim 1, characterized in that The height of the gesture navigation bar is 1 device independent pixel dp.

6. The method according to claim 1, characterized in that The first operation includes any one of the following: an operation for switching a camera or an operation for playing a voice message.

7. An electronic device, characterized in that: The electronic device includes one or more memories and one or more processors; the memory is coupled to the one or more processors, the memory is used to store computer program code, the computer program code includes computer instructions, and the one or more processors call the computer instructions to enable the electronic device to execute the method described in any one of claims 1-6.

8. A chip, which is applied to electronic equipment, characterized in that: The chip includes one or more processors, and the processor is used to call computer instructions to enable the electronic device to execute the method as described in any one of claims 1-6.

9. A computer-readable storage medium comprising instructions, characterized in that: When the instructions are executed on an electronic device, the electronic device is caused to execute the method as claimed in any one of claims 1 to 6.