Display method and device for multiple windows in application, electronic equipment and storage medium
By declaring an in-app multi-window solution to access the operating system in the application configuration file, obtaining application configuration information and displaying the window controller, the problem of high cost of in-app multi-window development in the prior art is solved, and low-cost in-app multi-window and floating window display is realized.
Patent Information
- Application Number
- CN202411404643.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-10-09
- Publication Date
- 2025-02-28
AI Technical Summary
The existing multi-window solution in applications requires the API capabilities provided by electronic device manufacturers, resulting in high development costs and does not support in-app floating window technology.
By declaring an in-app multi-window solution to access the operating system for the application page that wants to perform in-app multi-window in the application configuration file, obtain the application configuration information of the application, and display the window controller of the operating system in the application page, display the menu bar and perform multi-window operations in response to touch operations.
It realizes the application to realize multi-window display in-app at low cost, reducing development complexity and cost, and supporting in-app floating window technology.
Smart Images

Figure CN119536590A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the technical field of electronic devices, and more specifically, to a method, device, electronic device and storage medium for displaying multiple windows within an application. Background Art
[0002] Among them, in-app multi-window refers to allowing users to open multiple task windows in the same application to improve work efficiency and convenience. However, the current in-app multi-window solution requires the application to access the application programming interface (Application Programming Interface, API) capabilities provided by electronic device manufacturers, resulting in high development costs for applications that need to implement in-app multi-window. Summary of the invention
[0003] In view of the above problems, the present application proposes a method, device, electronic device and storage medium for displaying multiple windows within an application to solve the above problems.
[0004] In a first aspect, an embodiment of the present application provides a method for displaying multiple windows within an application, the method comprising: when displaying an application page of an application, obtaining application configuration information corresponding to the application, wherein the application configuration information is obtained by parsing an application configuration file of the application by an operating system of an electronic device; if it is determined based on the application configuration information that the application configuration file declares multiple windows within the application accessing the operating system under a node corresponding to the application page, then displaying a window controller of the operating system in the application page; in response to a touch operation on the window controller, displaying a first menu bar of the window controller, wherein the first menu bar includes an in-application multi-window button; in response to a touch operation on the in-application multi-window button, performing an in-application multi-window operation on the application page.
[0005] In a second aspect, an embodiment of the present application provides a display device for multiple windows within an application, the device comprising: an application configuration information acquisition module, for acquiring application configuration information corresponding to the application when displaying an application page of the application, wherein the application configuration information is obtained by parsing an application configuration file of the application by an operating system of the electronic device; a window controller display module, for displaying the window controller of the operating system in the application page if it is determined based on the application configuration information that multiple windows within the application accessing the operating system are declared in the application configuration file under a node corresponding to the application page; a first menu bar display module, for displaying a first menu bar of the window controller in response to a touch operation on the window controller, wherein the first menu bar includes an in-application multiple window button; and an in-application multiple window execution module, for executing the in-application multiple window operation for the application page in response to a touch operation on the in-application multiple window button.
[0006] In a third aspect, an embodiment of the present application provides an electronic device, comprising a memory and a processor, wherein the memory is coupled to the processor, the memory stores instructions, and when the instructions are executed by the processor, the processor executes the above method.
[0007] In a fourth aspect, an embodiment of the present application provides a computer-readable storage medium, in which a program code is stored, and the program code can be called by a processor to execute the above method.
[0008] The embodiments of the present application provide a method, device, electronic device, and storage medium for displaying multiple windows within an application. When displaying an application page of an application, application configuration information corresponding to the application is obtained, wherein the application configuration information is obtained by parsing an application configuration file of the application by the operating system of the electronic device. If it is determined based on the application configuration information that the application configuration file of the application declares multiple windows within the application of the operating system under a node corresponding to the application page, then the window controller of the operating system is displayed in the application page, and in response to a touch operation on the window controller, a first menu bar of the window controller is displayed, wherein the first menu bar includes an in-application multiple window button, and in response to a touch operation on the in-application multiple window button, an in-application multiple window operation is performed on the application page, thereby declaring the in-application multiple window solution for access to the operating system for the application page that wants to perform in-application multiple windows in the application configuration file, so that the application can achieve in-application multiple window display at a low cost. BRIEF DESCRIPTION OF THE DRAWINGS
[0009] In order to more clearly illustrate the technical solutions in the embodiments of the present application, the drawings required for use in the description of the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present application. For those skilled in the art, other drawings can be obtained based on these drawings without paying any creative work.
[0010] Figure 1 A schematic diagram showing a flow chart of a method for displaying multiple windows within an application provided by an embodiment of the present application;
[0011] Figure 2 A first page schematic diagram of an electronic device provided in an embodiment of the present application is shown;
[0012] Figure 3 A second page schematic diagram of an electronic device provided in an embodiment of the present application is shown;
[0013] Figure 4 A schematic diagram showing a flow chart of a method for displaying multiple windows within an application provided by an embodiment of the present application is shown;
[0014] Figure 5 A third page schematic diagram of an electronic device provided in an embodiment of the present application is shown;
[0015] Figure 6 A fourth page schematic diagram of an electronic device provided in an embodiment of the present application is shown;
[0016] Figure 7 A fifth page schematic diagram of the electronic device provided in the embodiment of the present application is shown;
[0017] Figure 8 A schematic diagram of the process of splitting the screen within an application provided in an embodiment of the present application is shown;
[0018] Fig. 9 A schematic diagram showing a flow chart of a method for displaying multiple windows within an application provided by an embodiment of the present application is shown;
[0019] Fig.10 A sixth page schematic diagram of the electronic device provided in the embodiment of the present application is shown;
[0020] Fig.11 A seventh page schematic diagram of the electronic device provided in the embodiment of the present application is shown;
[0021] Fig.12 An eighth page schematic diagram of the electronic device provided in the embodiment of the present application is shown;
[0022] Fig.13 A schematic diagram of the process of a floating window in an application provided in an embodiment of the present application is shown;
[0023] Fig.14 A module block diagram of a display device for multiple windows within an application provided by an embodiment of the present application is shown;
[0024] Fig.15 A block diagram of an electronic device for executing a method for displaying multiple windows within an application according to an embodiment of the present application is shown;
[0025] Fig.16 A storage unit for storing or carrying program codes for implementing a method for displaying multiple windows within an application according to an embodiment of the present application is shown. DETAILED DESCRIPTION
[0026] In order to enable those skilled in the art to better understand the solution of the present application, the technical solution in the embodiments of the present application will be clearly and completely described below in conjunction with the drawings in the embodiments of the present application.
[0027] At present, the in-app multi-window solutions provided by major electronic device manufacturers (such as smartphones and tablets) generally only support in-app split-screen technology, which uses a Java archive file (JAR package) to provide an API for application integration. The application displays a split-screen button and a full-screen button on the full-screen page and split-screen page respectively, for switching between split-screen and full-screen. This type of in-app split-screen solution that accesses the API interface capabilities provided by electronic device manufacturers has at least the following disadvantages:
[0028] First, the application needs to access the software development kit (SDK) of the electronic device manufacturer. The API interfaces provided by different electronic device manufacturers are different. The application needs to determine whether different electronic device manufacturers support this capability at runtime, and call different system API interfaces according to different electronic device manufacturers, which makes the application access complicated;
[0029] Second, the application needs to modify the page layout within the application page and provide users with an entry to switch between split screen and full screen, which makes the implementation logic complex;
[0030] Third, the application needs to monitor the status of the current page and dynamically refresh the entry switch items, which increases the logic complexity and development cost of the application page;
[0031] Fourth, the application cannot be accessed in display modes such as parallel windows / ActivityEmbedding, because existing scene applications consider display modes such as parallel windows / ActivityEmbedding to be a special split-screen system, so the split-screen entrance will no longer be displayed;
[0032] Fifth, currently electronic device manufacturers on the market only support in-app split-screen technology, but not in-app floating window technology. If you need to support in-app floating window format, you need to reintegrate the SDK into the application and add an in-app floating window button on the application page. The cost of application access is relatively high.
[0033] In view of the above problems, the inventors have discovered after long-term research and proposed the method, device, electronic device and storage medium for displaying multiple windows in an application provided in the embodiments of the present application. By declaring the multiple windows in an application page that wants to display multiple windows in an application in an application configuration file, the application program can realize multiple windows display in an application at a low cost. The specific method for displaying multiple windows in an application is described in detail in the subsequent embodiments.
[0034] The following is an explanation of the technical terms involved in the embodiments of the present application:
[0035] In-app split screen: pages and split screen technology implemented within the same app;
[0036] In-app floating window: page-level floating window technology implemented within the same application;
[0037] Activity page: application page;
[0038] Task: application task stack, consisting of several Activity pages;
[0039] AndroidManifest: Android application configuration file.
[0040] See also Figure 1 , Figure 1 The flowchart of a method for displaying multiple windows in an application is shown in an embodiment of the present application. The method is used to declare an application page that wants to display multiple windows in an application configuration file to access the application's multiple windows scheme of the operating system, so that the application can realize the multiple windows display in the application at a low cost. In a specific embodiment, the method for displaying multiple windows in an application is applied to Fig.14 The display device 200 with multiple windows in an application and the electronic device 100 equipped with the display device 200 with multiple windows in an application are shown. Fig.15 ). The following will take an electronic device as an example to illustrate the specific process of this embodiment. Of course, it can be understood that the electronic device used in this embodiment may include a smart phone, a tablet computer, a wearable electronic device, etc., which is not limited here. Figure 1 The process shown is described in detail, and the method for displaying multiple windows in an application may specifically include the following steps:
[0041] Step S110: when an application page of an application is displayed, application configuration information corresponding to the application is obtained, wherein the application configuration information is obtained by parsing an application configuration file of the application by an operating system of the electronic device.
[0042] Among them, an embodiment of the present application provides an in-application multi-window technical solution that supports applications declaring access to the operating system of an electronic device. As a system-level solution, an application that wants to access the in-application multi-window of the operating system of an electronic device only needs to declare the in-application multi-window technical solution for access to the operating system of the electronic device in the application configuration file of the application (such as the AndroidManifest configuration file) for the Activity page that wants to perform in-application multi-window. The application does not need to integrate any SDK, nor does it need to add any entry on the application page to change the display logic of the application page. All logic is implemented by the electronic device manufacturer, and the access cost of the application is extremely low.
[0043] In some implementations, the application program may declare a metadata meta-data under the Activity node in the application configuration file to indicate that the in-application multi-window technical solution of the operating system of the electronic device needs to be accessed. The specific access content examples are as follows:
[0044]
[0045] By using meta-data to access, the compilation of the application does not depend on the electronic device manufacturer. Even if the electronic device manufacturer does not support this feature, it will not affect the operation of the application. The key value of androidx.window.ACTIVITY_MULTI_WINDOW, if the configured value is true, indicates the in-application multi-window technology solution of the operating system of the electronic device is accessed; if the configured value is false or the key-value pair is not configured, it indicates the in-application multi-window technology solution of the operating system of the electronic device is not accessed.
[0046] The embodiment of the present application will dynamically add an in-application multi-window entry (including in-application split screen and in-application floating window) in the menu bar of the top window controller of the full-screen application page (the window controller is also added and controlled by the operating system of the electronic device) according to the meta-data parameters configured in the application page. The user can trigger the system's in-application multi-window capability by clicking the controller button added by the operating system. When the application window becomes an in-application multi-window form, the menu in the controller will also be updated accordingly. There is no need for the application to monitor and maintain the window status and menu button form.
[0047] It is understandable that the solution provided in the embodiment of the present application has at least the following advantages:
[0048] (1) The application does not need to modify any code. It only needs to configure the application page that wants to support multiple windows in the application configuration file of the application.
[0049] (2) The application does not need to pay attention to the page menu entry, which is all completed by the operating system of the electronic device, completely avoiding the need to modify the page view, greatly reducing development costs;
[0050] (3) Even on an electronic device that does not support this capability, the support flag for multiple windows within an application declared in the application configuration file will not be used. The application does not need to make any judgment on electronic devices of different manufacturers or different versions. The operating system of the electronic device is responsible for identifying whether this capability needs to be supported.
[0051] (4) Applications do not need to make judgments on large screen forms such as foldable screens and isolate services. Scenarios that do not need to support this capability, such as candy-bar phones, are handled uniformly by the operating system of the electronic device.
[0052] (5) When the operating system of subsequent electronic devices adds new multi-window capabilities, there is no need for the application to undergo secondary development and access;
[0053] (6) Access without SDK integration, no need to increase the size of the application;
[0054] (7) This capability is effective regardless of whether the application is in full screen or parallel window mode.
[0055] Therefore, for an application, it can declare access to the operating system's in-application multi-window under the node corresponding to the application page in the application configuration file for the application page that wants to perform in-application multi-window; for an application page that does not want to perform in-application multi-window, it does not declare access to the operating system's in-application multi-window under the node corresponding to the application page in the application configuration file. Accordingly, for an electronic device, it can parse the application configuration file of the application to determine whether each application page of the application needs to access the in-application multi-window of its operating system, so as to display different menu bars in the window controller, for example, for an application page that declares access to the in-application multi-window of its operating system, a menu bar including an in-application multi-window button (in-application multi-window entrance) is displayed, and for an application page that does not declare access to the in-application multi-window of its operating system, a menu bar that does not include the in-application multi-window button is displayed.
[0056] In this embodiment, the electronic device can display the application page of the application, and obtain application configuration information corresponding to the application when displaying the application page of the application, wherein the application configuration information is obtained by parsing the application configuration file of the application by the operating system of the electronic device.
[0057] Optionally, the application page may be any page of the application, for example, it may be the homepage of the application, or it may be a page at a lower level of the homepage, etc., which is not limited here.
[0058] As an implementable manner, when installing an application, the electronic device can obtain an application configuration file of the application, parse the application configuration file through the operating system of the electronic device to obtain application configuration information of the application, and store the application configuration information of the application locally on the electronic device. Accordingly, when displaying the application page of the application, the application configuration information corresponding to the application can be obtained from the local of the electronic device.
[0059] As another practicable manner, when the electronic device first starts the application program, it obtains the application configuration file of the application program, parses the application configuration file through the operating system of the electronic device to obtain the application configuration information of the application program, and stores the application configuration information of the application program locally in the electronic device. Accordingly, when the application page of the application program is displayed, the application configuration information corresponding to the application program can be obtained from the local of the electronic device.
[0060] As another feasible manner, when displaying an application page of an application, the electronic device may obtain an application configuration file of the application, and obtain application configuration information of the application by parsing the application configuration file through the operating system of the electronic device.
[0061] Step S120: If it is determined based on the application configuration information that the application configuration file declares access to multiple windows within the application of the operating system under the node corresponding to the application page, then a window controller of the operating system is displayed in the application page.
[0062] In this embodiment, when the application configuration information of the application is obtained, it can be determined based on the application configuration information whether the application configuration file declares the multiple windows in the application accessing the operating system under the node corresponding to the application page. If it is determined based on the application configuration information that the application configuration file declares the multiple windows in the application accessing the operating system under the node corresponding to the application page, it can be determined that the application expects to perform the multiple windows in the application for the application page, and the window controller of the operating system can be displayed in the application page, and an entry to the multiple windows in the application can be added in the menu bar of the window controller; if it is determined based on the application configuration information that the application configuration file does not declare the multiple windows in the application accessing the operating system under the node corresponding to the application page, it can be determined that the application does not expect to perform the multiple windows in the application for the application page, and the window controller of the operating system can be displayed in the application page, and the entry to the multiple windows in the application is not added in the menu bar of the window controller.
[0063] Among them, the window controller of the operating system of the electronic device can be completed by the collaboration of multiple components, mainly including ActivityManagerService (AMS), WindowManagerService (WMS) and SurfaceFlinger (SF), etc., which are not limited here.
[0064] In some implementations, the metadata meta-data parameter under the node corresponding to the application page in the application configuration file can be determined based on the application configuration information, and based on the meta-data parameter, it can be determined whether the application configuration file declares multiple windows within the application connected to the operating system under the node corresponding to the application page. As an implementable method, if it is determined based on the application configuration information that target metadata is added under the node corresponding to the application page in the application configuration file, the window controller of the operating system is displayed in the application page, wherein the target metadata is used to characterize the multiple windows within the application connected to the operating system, that is, the meta-data parameter of the target metadata is name=androidx.window.ACTIVITY_MULTI_WINDOW
[0065] , vaLue=true.
[0066] In some embodiments, displaying the window controller of the operating system in the application page may include: displaying the window controller of the operating system at a target position in the application page, wherein the target position has little obstruction or interference with the application page. For example, the target position may be located at the top of the application page, at the bottom of the application page, at the side edge of the application page, etc., which is not limited here.
[0067] See also Figure 2 , Figure 2 A first page schematic diagram of an electronic device provided in an embodiment of the present application is shown. Figure 2 As shown, the electronic device may display an application page of an application, and a window controller A may be displayed on the application page.
[0068] Step S130: In response to a touch operation on the window controller, a first menu bar of the window controller is displayed, wherein the first menu bar includes a multi-window button within an application.
[0069] In this embodiment, the electronic device can detect a touch operation on the window controller during the process of displaying the window controller on the application page. If a touch operation on the window controller is detected, the first menu bar of the window controller can be triggered to display, wherein the first menu bar can include an in-application multi-window button. It can be understood that the in-application multi-window button is the entrance to the in-application multi-window.
[0070] In some embodiments, during the process of displaying a window controller on an application page, the electronic device can detect touch operations acting on the window controller in real time, can detect touch operations acting on the window controller at preset time intervals, can detect touch operations acting on the window controller at preset time points, can detect touch operations acting on the window controller according to other preset rules, etc., which are not limited here.
[0071] Optionally, the touch operation acting on the window controller may include: a click operation acting on the window controller, a press operation acting on the window controller, a slide operation acting on the window controller, etc., which are not limited here. In addition, the click operation acting on the window controller may include a single click operation, multiple click operations, etc., the press operation acting on the window controller may include a press duration, a press area, a press force, etc., and the slide operation acting on the window controller may include a slide direction, a slide distance, a slide track, etc., which are not limited here.
[0072] In some implementations, displaying the first menu bar of the window controller may include: floatingly displaying the first menu bar on the application page.
[0073] Optionally, in addition to the multi-window button within the application, the first menu bar may also include other buttons, for example, a split screen button, a floating window button, a close button, etc., which are not limited here.
[0074] See also Figure 3 , Figure 3 A second page schematic diagram of an electronic device provided in an embodiment of the present application is shown. Figure 3As shown, the electronic device may display an application page of an application program, and the first menu bar B1 of the window controller A may be displayed on the application page.
[0075] Step S140: In response to a touch operation on the in-application multi-window button, executing an in-application multi-window operation on the application page.
[0076] In this embodiment, the electronic device can detect a touch operation on the multi-window button in the application page while displaying the multi-window button in the application page. If a touch operation on the multi-window button in the application is detected, the multi-window operation in the application page can be triggered to implement multi-window in the application, for example, to implement split screen in the application or floating window in the application.
[0077] In some embodiments, when the electronic device displays a multi-window button within an application on an application page, it can detect touch operations on the multi-window button within the application in real time, can detect touch operations on the multi-window button within the application at preset time intervals, can detect touch operations on the multi-window button within the application at preset time points, can detect touch operations on the multi-window button within the application according to other preset rules, etc., which are not limited here.
[0078] Optionally, the touch operation acting on the multi-window button in the application may include: a click operation acting on the multi-window button in the application, a press operation acting on the multi-window button in the application, a slide operation acting on the multi-window button in the application, etc., which are not limited here. In addition, the click operation acting on the multi-window button in the application may include a single click operation, multiple click operations, etc., the press operation acting on the multi-window button in the application may include press duration, press area, press force, etc., and the slide operation acting on the multi-window button in the application may include slide direction, slide distance, slide track, etc., which are not limited here.
[0079] In some embodiments, the electronic device may pre-set and store an execution method for multiple windows within an application. When a touch operation acting on a multi-window button within an application is detected, the electronic device may respond to the touch operation acting on the multi-window button within the application and perform the in-application multi-window operation on the application page according to the set execution method.
[0080] An embodiment of the present application provides a method for displaying multiple windows within an application. When an application page of an application is displayed, application configuration information corresponding to the application is obtained by parsing an application configuration file of the application by the operating system of the electronic device. If it is determined based on the application configuration information that the application configuration file of the application declares access to multiple windows within the application of the operating system under a node corresponding to the application page, a window controller of the operating system is displayed in the application page, and a first menu bar of the window controller is displayed in response to a touch operation on the window controller, wherein the first menu bar includes an in-application multi-window button, and in-application multi-window operation is performed on the application page in response to a touch operation on the in-application multi-window button, thereby declaring access to the in-application multi-window scheme of the operating system for the application page for which in-application multi-window is desired in the application configuration file, so that the application can achieve in-application multi-window display at a low cost.
[0081] See also Figure 4 , Figure 4 The flowchart of the method for displaying multiple windows in an application provided by an embodiment of the present application is shown in FIG. Figure 4 The process shown is described in detail, and the method for displaying multiple windows in an application may specifically include the following steps:
[0082] Step S210: when an application page of an application is displayed, application configuration information corresponding to the application is obtained, wherein the application configuration information is obtained by parsing an application configuration file of the application by an operating system of the electronic device.
[0083] Step S220: If it is determined based on the application configuration information that multiple windows in the application of the operating system are declared to be connected under the node corresponding to the application page in the application configuration file, the window controller of the operating system is displayed in the application page.
[0084] Step S230: In response to a touch operation on the window controller, a first menu bar of the window controller is displayed, wherein the first menu bar includes an in-application split-screen button.
[0085] For the detailed description of step S210 to step S230 , please refer to step S110 to step S130 , which will not be repeated here.
[0086] Step S240: In response to a touch operation on the in-application split-screen button, perform an in-application split-screen operation on the application page.
[0087] Optionally, the in-app multi-window may include an in-app split screen. Accordingly, the in-app multi-window button may include an in-app split screen button, that is, the in-app split screen button may be used as an entry for executing the in-app split screen, and the in-app split screen button may be used to indicate the execution of the in-app split screen operation.
[0088] In this embodiment, the electronic device can detect a touch operation on the in-application split-screen button when the in-application split-screen button is displayed on the application page. If a touch operation on the in-application split-screen button is detected, the in-application split-screen operation on the application page can be triggered to implement the in-application split-screen.
[0089] In some embodiments, the electronic device can respond to the touch operation on the split-screen button within the application to determine whether it is a cross-stack scenario (i.e., determine whether the current task stack where the application page is located only includes the application page (one application page)). Among them, if it is determined that it is not a cross-stack scenario (i.e., it is determined that the current task stack where the application page is located does not only include the application page), the current application page can be split from the current task stack and paired for split-screen to perform in-application stack splitting and split-screen operation. If it is determined that it is a cross-stack scenario (i.e., it is determined that the current task stack where the application page is located only includes the application page), it can be detected whether there is another same-package stack below the current task stack, wherein, if it is detected that there is no same-package stack below the current task stack, no operation is performed, that is, no in-application split-screen is performed; if it is detected that there is a same-package stack below the current task stack, the current task stack can be paired with the same-package stack for split-screen to perform in-application cross-stack split-screen and achieve in-application split-screen operation.
[0090] See also Figure 5 , Figure 5 FIG. 3 shows a third page schematic diagram of an electronic device provided in an embodiment of the present application. Figure 5 As shown, the electronic device may display an application page of an application program, and the application page may display a first menu bar B1 of a window controller A, wherein the first menu bar B1 includes an “in-application split-screen button”.
[0091] Step S250: Displaying the split-screen page within the application, wherein the split-screen page within the application includes at least two sub-pages, and each of the at least two sub-pages displays the window controller.
[0092] In this embodiment, after performing an in-application split-screen operation on an application page, the in-application split-screen page can be displayed, wherein the in-application split-screen page includes at least two sub-pages, and each of the at least two sub-pages displays a window controller.
[0093] Optionally, in the split-screen page within the application, the at least two sub-pages can be displayed in a horizontal arrangement or in a vertical arrangement, and the positional relationship between the at least two sub-pages can be fixed or dynamically changed as needed, which is not limited here.
[0094] Optionally, in the application split-screen page, the display sizes of the at least two sub-pages may be consistent or inconsistent, and the display sizes of the at least two sub-pages may be fixed or dynamically change according to demand, which is not limited here.
[0095] In some embodiments, displaying a window controller on each of the at least two sub-pages may include: displaying the window controller of the operating system at a target position on each of the at least two sub-pages, wherein the target position has little obstruction or interference with the sub-page. For example, the target position may be located at the top of the sub-page, at the bottom of the sub-page, at the side edge of the sub-page, etc., which is not limited here.
[0096] See also Figure 6 , Figure 6 FIG. 4 shows a fourth page schematic diagram of an electronic device provided in an embodiment of the present application. Figure 6 As shown, the electronic device may display an in-application split-screen page, which may include a first sub-page C1 and a second sub-page C2, wherein a window controller A is displayed on the first sub-page C1, and a window controller A is displayed on the second sub-page C2.
[0097] Step S260: In response to a touch operation on the window controller displayed on a target subpage, a second menu bar of the window controller is displayed on the target subpage, wherein the second menu bar includes a first full screen button, and the target subpage is any one of the at least two subpages.
[0098] Wherein, when the electronic device is displaying the split-screen page within the application, if the user wants to exit the split-screen within the application, the user can trigger the exit through the window controller displayed by any of the at least two sub-pages. In this embodiment, any of the at least two sub-pages can be determined as a target sub-page, and accordingly, the user can trigger the exit of the split-screen within the application through the window controller displayed by the target sub-page.
[0099] In some embodiments, the electronic device may detect a touch operation on a window controller displayed by a target sub-page during the process of displaying a split-screen page in an application. If a touch operation on a window controller displayed by a target sub-page is detected, a second menu bar for displaying the window controller may be triggered, wherein the second menu bar may include a first full-screen button, and it is understood that the first full-screen button is the entrance to exit the split-screen in the application.
[0100] In some embodiments, during the process of displaying a window controller on a target sub-page, the electronic device can detect touch operations on the window controller displayed on the target sub-page in real time, can detect touch operations on the window controller displayed on the target sub-page at preset time intervals, can detect touch operations on the window controller displayed on the target sub-page at preset time points, can detect touch operations on the window controller displayed on the target sub-page according to other preset rules, etc., without limitation herein.
[0101] Optionally, the touch operation acting on the window controller displayed on the target subpage may include: a click operation acting on the window controller displayed on the target subpage, a press operation acting on the window controller displayed on the target subpage, a slide operation acting on the window controller displayed on the target subpage, etc., which are not limited here. In addition, the click operation acting on the window controller displayed on the target subpage may include a single click operation, multiple click operations, etc., the press operation acting on the window controller displayed on the target subpage may include a press duration, a press area, a press force, etc., and the slide operation acting on the window controller displayed on the target subpage may include a slide direction, a slide distance, a slide track, etc., which are not limited here.
[0102] In some implementations, displaying the second menu bar of the window controller may include: floatingly displaying the second menu bar on the target sub-page.
[0103] Optionally, the second menu bar may also include a replace application button, a zoom window button, a close application button, etc., which are not limited here.
[0104] See also Figure 7 , Figure 7 FIG. 5 shows a fifth page schematic diagram of an electronic device provided in an embodiment of the present application. Figure 7 As shown, the electronic device can display an in-application split-screen page, and the in-application split-screen page can include a first sub-page C1 and a second sub-page C2. Assuming that the second sub-page C2 is the target sub-page, a window controller A is displayed on the first sub-page C1, and a second menu bar B2 of the window controller A is displayed on the second sub-page C2.
[0105] Step S270: In response to the touch operation on the first full-screen button, exit the split-screen mode within the application.
[0106] In this embodiment, the electronic device can detect a touch operation on the first full-screen button when the target sub-page displays the first full-screen button. If a touch operation on the first full-screen button is detected, exiting the split screen in the application can be triggered to return to the full-screen display mode.
[0107] As a method, if a touch operation on the first full-screen button is detected, the split-screen in the application can be exited by displaying the incoming split-screen task stack in full screen to return to the full-screen display mode.
[0108] In some embodiments, when the electronic device displays the first full-screen button on the target sub-page, it can detect the touch operation on the first full-screen button in real time, can detect the touch operation on the first full-screen button at preset time intervals, can detect the touch operation on the first full-screen button at preset time points, can detect the touch operation on the first full-screen button according to other preset rules, etc., which are not limited here.
[0109] Optionally, the touch operation acting on the first full-screen button may include: a click operation acting on the first full-screen button, a press operation acting on the first full-screen button, a slide operation acting on the first full-screen button, etc., which are not limited here. In addition, the click operation acting on the first full-screen button may include a single click operation, multiple click operations, etc., the press operation acting on the first full-screen button may include a press duration, a press area, a press force, etc., and the slide operation acting on the first full-screen button may include a slide direction, a slide distance, a slide track, etc., which are not limited here.
[0110] In some embodiments, when the second menu bar further includes a replacement application button, a touch operation on the replacement application button may be detected during the display of the second menu bar. If a touch operation on the replacement application button is detected, the target subpage may be replaced in response to the touch operation on the replacement application button. Optionally, replacing the target subpage may include: replacing the target subpage with another page of the same application, or replacing the target subpage with another page of a different application, etc., which is not limited here.
[0111] In some embodiments, when the second menu bar further includes a magnifying window button, a touch operation on the magnifying window button may be detected during the display of the second menu bar. If a touch operation on the magnifying window button is detected, the display size corresponding to the target subpage may be magnified in response to the touch operation on the magnifying window button, and accordingly, the display sizes of the other subpages except the target subpage among the at least two subpages may be reduced.
[0112] In some embodiments, when the second menu bar further includes a close application button, a touch operation on the close application button may be detected during the display of the second menu bar. If a touch operation on the close application button is detected, the application may be closed in response to the touch operation on the close application button.
[0113] A method for displaying multiple windows within an application provided by an embodiment of the present application obtains application configuration information corresponding to the application when displaying an application page of the application, wherein the application configuration information is obtained by parsing an application configuration file of the application by the operating system of the electronic device; if it is determined based on the application configuration information that multiple windows within the application accessing the operating system is declared under a node corresponding to the application page in the application configuration file, then a window controller of the operating system is displayed in the application page, and in response to a touch operation on the window controller, a first menu bar of the window controller is displayed, wherein the first menu bar includes an in-application split-screen button, and in response to a touch operation on the in-application split-screen button, an in-application split-screen operation is performed on the application page, thereby declaring the in-application multi-window scheme of accessing the operating system for the application page that wants to perform in-application multi-window in the application configuration file, so that the application can achieve in-application split-screen display at a low cost. In addition, the present embodiment also displays an in-application split-screen page, wherein the in-application split-screen page includes at least two sub-pages, and at least the two sub-pages each display a window controller. In response to a touch operation on the window controller displayed on a target sub-page, a second menu bar of the window controller is displayed on the target sub-page, wherein the second menu bar includes a first full-screen button, and the target sub-page is any sub-page of the at least two sub-pages. In response to a touch operation on the first full-screen button, the in-application split-screen is exited, so that the in-application split-screen can be quickly exited through the window controller, thereby improving the user experience.
[0114] See also Figure 8 , Figure 8 The schematic diagram of the process of splitting the screen within the application provided by the embodiment of the present application is shown. Figure 8As shown, the operating system of the electronic device can parse the application configuration file of the application to determine whether the application page of the application declares multiple windows in the application of the operating system of the electronic device. Among them, if it is determined that the application page of the application does not declare multiple windows in the application of the operating system of the electronic device, the window controller of the operating system does not display the application split screen entrance; if it is determined that the application page of the application declares multiple windows in the application of the operating system of the electronic device, the window controller of the operating system displays the application split screen entrance. At this time, the user can click the application split screen button in the window controller, and the operating system determines whether it is a stack collapse scenario (whether there is only one page in the current task stack). If it is determined that it is not a stack collapse scenario, the operating system can split the current application page from the task stack where it is located and pair the split screen, so that the application stack split screen is successful; if it is determined that it is a stack collapse scenario, the operating system can detect whether there is another same package stack below the current task stack, wherein, if it is determined that there is no same package stack below the current task stack, the operating system does not perform task operations and returns directly; if it is determined that there is a same package stack below the current task stack, the operating system pairs the current task stack with the same package stack below to split the screen, so that the application stack collapses successfully. Afterwards, the operating system updates the split-screen switching entrance within the application to a full-screen button form, and the window controller of the operating system displays the full-screen button. In the split-screen state, clicking the full-screen button in the window controller can exit the split-screen. The operating system displays the passed split-screen task stack in full screen, so that the split-screen exit within the application is successful.
[0115] See also Fig. 9 , Fig. 9 The flowchart of the method for displaying multiple windows in an application provided by an embodiment of the present application is shown in FIG. Fig. 9 The process shown is described in detail, and the method for displaying multiple windows in an application may specifically include the following steps:
[0116] Step S310: when an application page of an application is displayed, application configuration information corresponding to the application is obtained, wherein the application configuration information is obtained by parsing an application configuration file of the application by an operating system of the electronic device.
[0117] Step S320: If it is determined based on the application configuration information that multiple windows in the application of the operating system are declared to be connected under the node corresponding to the application page in the application configuration file, the window controller of the operating system is displayed in the application page.
[0118] Step S330: In response to a touch operation on the window controller, a first menu bar of the window controller is displayed, wherein the first menu bar includes a floating window button within an application.
[0119] For the detailed description of step S310 to step S330 , please refer to step S110 to step S130 , which will not be repeated here.
[0120] Step S340: In response to the touch operation on the in-application floating window button, perform an in-application floating window operation on the application page.
[0121] Optionally, the in-app multi-window may include an in-app floating window. Accordingly, the in-app multi-window button may include an in-app floating window button, that is, the in-app floating window button may be used as an entry for executing the in-app floating window, and the in-app floating window button may be used to indicate the execution of the in-app floating window operation.
[0122] In this embodiment, the electronic device can detect a touch operation on the in-application floating window button during the process of displaying the in-application floating window button on the application page. If a touch operation on the in-application floating window button is detected, the in-application floating window operation on the application page can be triggered to implement the in-application floating window.
[0123] In some embodiments, the electronic device can respond to a touch operation on a floating window button within an application to determine whether it is a cross-stack scenario (i.e., determine whether the current task stack where the application page is located only includes the application page (one application page)). If it is determined that it is not a cross-stack scenario (i.e., it is determined that the current task stack where the application page is located does not only include the application page), the current application page can be split from the current task stack and switched to a floating window to implement a floating window operation within the application. If it is determined that it is a cross-stack scenario (i.e., it is determined that the current task stack where the application page is located only includes the application page), the current task stack can be switched to a floating window to implement a floating window operation within the application.
[0124] See also Fig.10 , Fig.10 FIG. 6 shows a sixth page schematic diagram of an electronic device provided in an embodiment of the present application. Fig.10 As shown, the electronic device may display an application page of an application program, and the application page may display a first menu bar B1 of a window controller A, wherein the first menu bar B1 includes an “in-application floating window button”.
[0125] Step S350: displaying a floating window page within the application, wherein the floating window page within the application displays the window controller.
[0126] In this embodiment, after performing the in-application floating window operation on the application page, the in-application floating window page may be displayed, wherein the in-application floating window page may display a window controller.
[0127] In some implementations, the electronic device may pre-set and store a floating window size, and after performing an in-application floating window operation on an application page, the in-application floating window page may be displayed with the floating window size.
[0128] In some embodiments, after performing an in-application floating window operation on an application page, the electronic device may determine a floating window size based on the displayed content of the application page, and display the in-application floating window page with the floating window size. As an example, if the displayed content of the application page is video content, a first floating window size may be determined, and if the displayed content of the application page is non-video content, such as chat content, search content, etc., a second floating window size may be determined, wherein the first floating window size is larger than the second floating window size.
[0129] Optionally, when the electronic device is displaying a floating page within an application, the display position of the floating page within the application can be fixed or dynamically changed based on user needs; the display size of the floating page within the application can be fixed or dynamically changed based on user needs, etc., which are not limited here.
[0130] See also Fig.11 , Fig.11 FIG. 7 shows a seventh page schematic diagram of an electronic device provided in an embodiment of the present application. Fig.11 As shown, the electronic device may display a floating window page D within an application, and a window controller A is displayed on the floating window page D within the application.
[0131] Step S360: In response to the touch operation on the window controller, display a third menu bar of the window controller, wherein the third menu bar includes a second full screen button.
[0132] Among them, when the electronic device is displaying the floating window page within the application, if the user wants to exit the floating window within the application, the exit can be triggered by the window controller displayed by the floating window page within the application.
[0133] In some embodiments, the electronic device may detect a touch operation on a window controller displayed by the floating window page in the application during the process of displaying the floating window page in the application. If a touch operation on the window controller displayed by the floating window page in the application is detected, a third menu bar for displaying the window controller may be triggered, wherein the third menu bar may include a second full screen button, and it is understood that the second full screen button is the entrance to exit the floating window in the application.
[0134] In some embodiments, during the process of displaying a window controller on a floating window page within an application, the electronic device can detect touch operations on the window controller displayed on the floating window page within the application in real time, can detect touch operations on the window controller displayed on the floating window page within the application at preset time intervals, can detect touch operations on the window controller displayed on the floating window page within the application at preset time points, can detect touch operations on the window controller displayed on the floating window page within the application according to other preset rules, etc., which are not limited here.
[0135] Optionally, the touch operation acting on the window controller displayed on the floating window page in the application may include: a click operation on the window controller displayed on the floating window page in the application, a press operation on the window controller displayed on the floating window page in the application, a slide operation on the window controller displayed on the floating window page in the application, etc., which are not limited here. In addition, the click operation on the window controller displayed on the floating window page in the application may include a single click operation, multiple click operations, etc., the press operation on the window controller displayed on the floating window page in the application may include press duration, press area, press force, etc., and the slide operation on the window controller displayed on the floating window page in the application may include slide direction, slide distance, slide track, etc., which are not limited here.
[0136] In some implementations, displaying the third menu bar of the window controller may include: floatingly displaying the third menu bar on a floating window page within the application.
[0137] Optionally, the third menu bar may also include a minimize button, a close button, etc., which are not limited here.
[0138] See also Fig.12 , Fig.12 FIG. 8 is a schematic diagram showing an eighth page of an electronic device provided in an embodiment of the present application. Fig.12 As shown, the electronic device may display a floating window page D within the application, and the third menu bar B3 of the window controller A is displayed on the floating window page D within the application.
[0139] Step S370: In response to the touch operation on the second full-screen button, exit the floating window within the application.
[0140] In this embodiment, the electronic device can detect a touch operation on the second full-screen button when the second full-screen button is displayed on the floating window page in the application. If a touch operation on the second full-screen button is detected, the floating window in the application can be triggered to exit and return to the full-screen display mode.
[0141] As a method, if a touch operation on the second full-screen button is detected, the floating window in the application can be exited by displaying the incoming floating window task stack in full screen to return to the full-screen display mode.
[0142] In some embodiments, when the electronic device displays the second full-screen button on a floating window page within an application, the electronic device can detect touch operations on the second full-screen button in real time, can detect touch operations on the second full-screen button at preset time intervals, can detect touch operations on the second full-screen button at preset time points, can detect touch operations on the second full-screen button according to other preset rules, etc., which are not limited here.
[0143] Optionally, the touch operation acting on the second full-screen button may include: a click operation acting on the second full-screen button, a press operation acting on the second full-screen button, a slide operation acting on the second full-screen button, etc., which are not limited here. In addition, the click operation acting on the second full-screen button may include a single click operation, multiple click operations, etc., the press operation acting on the second full-screen button may include a press duration, a press area, a press force, etc., and the slide operation acting on the second full-screen button may include a slide direction, a slide distance, a slide track, etc., which are not limited here.
[0144] In some embodiments, when the third menu bar further includes a minimize button, a touch operation on the minimize button may be detected during the display of the third menu bar. If a touch operation on the minimize button is detected, the floating window page in the application may be minimized in response to the touch operation on the minimize button.
[0145] In some embodiments, when the third menu bar further includes a close button, a touch operation on the close button may be detected during the display of the third menu bar. If a touch operation on the close button is detected, the application may be closed in response to the touch operation on the close button.
[0146] A method for displaying multiple windows within an application provided by an embodiment of the present application obtains application configuration information corresponding to the application when displaying an application page of the application, wherein the application configuration information is obtained by parsing an application configuration file of the application by the operating system of the electronic device; if it is determined based on the application configuration information that multiple windows within the application accessing the operating system is declared under a node corresponding to the application page in the application configuration file, then a window controller of the operating system is displayed in the application page, and in response to a touch operation on the window controller, a first menu bar of the window controller is displayed, wherein the first menu bar includes an in-application floating window button, and in response to a touch operation on the in-application floating window button, an in-application floating window operation is performed on the application page, thereby declaring the in-application multi-window solution of accessing the operating system for the application page that wants to perform in-application multi-window in the application configuration file, so that the application can realize the in-application floating window display at a low cost. In addition, this embodiment also displays a floating window page within the application, wherein the floating window page within the application displays a window controller, and in response to a touch operation on the window controller, a third menu bar of the window controller is displayed, wherein the third menu bar includes a second full-screen button, and in response to a touch operation on the second full-screen button, the floating window within the application is exited, so that the floating window within the application can be quickly exited through the window controller, thereby improving the user experience.
[0147] See also Fig.13 , Fig.13 FIG. 1 shows a schematic diagram of the process of the floating window in the application provided by the embodiment of the present application. Fig.13 As shown, the operating system of the electronic device can parse the application configuration file of the application to determine whether the application page of the application declares multiple windows in the application of the operating system of the electronic device. Among them, if it is determined that the application page of the application does not declare multiple windows in the application of the operating system of the electronic device, the window controller of the operating system does not display the floating window entrance in the application; if it is determined that the application page of the application declares multiple windows in the application of the operating system of the electronic device, the window controller of the operating system displays the floating window entrance in the application. At this time, the user can click the floating window button in the application in the window controller, and the operating system determines whether it is a stack collapse scenario (whether there is only one page in the current task stack). If it is determined that it is not a stack collapse scenario, the operating system can split the current application page from the task stack where it is located and switch it to a floating window, so that the floating window in the application enters successfully; if it is determined that it is a stack collapse scenario, the operating system switches the task stack where the application page is located to a floating window, so that the floating window in the application enters successfully. Afterwards, the operating system updates the floating window switch entrance in the application to a full-screen button form, and the window controller of the operating system displays the full-screen button. Clicking the full-screen button in the window controller in the floating window state can exit the floating window, and the operating system displays the incoming floating window task stack in full screen, so that the floating window in the application exits successfully.
[0148] See also Fig.14 , Fig.14 The module block diagram of the display device of multiple windows in an application provided by an embodiment of the present application is shown. Fig.14 As shown in the block diagram, the in-application multi-window display device 200 may include: an application configuration information acquisition module 210, a window controller display module 220, a first menu bar display module 230 and an in-application multi-window execution module 240, wherein:
[0149] The application configuration information acquisition module 210 is used to acquire application configuration information corresponding to the application when the application page of the application is displayed, wherein the application configuration information is obtained by parsing the application configuration file of the application by the operating system of the electronic device.
[0150] The window controller display module 220 is used to display the window controller of the operating system in the application page if it is determined based on the application configuration information that the application configuration file declares multiple windows in the application accessing the operating system under the node corresponding to the application page.
[0151] Furthermore, the window controller display module 220 includes: a window controller display submodule, wherein:
[0152] A window controller display submodule is used to display the window controller of the operating system in the application page if it is determined based on the application configuration information that target metadata is added in the application configuration file under the node corresponding to the application page, wherein the target metadata is used to characterize multiple windows in an application connected to the operating system.
[0153] The first menu bar display module 230 is used to respond to the touch operation on the window controller and display the first menu bar of the window controller, wherein the first menu bar includes a multi-window button within the application.
[0154] The in-application multi-window execution module 240 is used to respond to a touch operation on the in-application multi-window button and execute an in-application multi-window operation on the application page.
[0155] Further, the in-application multi-window button includes an in-application split-screen button, and the in-application multi-window execution module 240 includes: an in-application split-screen execution submodule, wherein:
[0156] The in-application split-screen execution submodule is used to respond to a touch operation on the in-application split-screen button and execute an in-application split-screen operation on the application page.
[0157] Furthermore, the in-application split-screen execution submodule includes: a first in-application split-screen execution unit and a second in-application split-screen execution unit, wherein:
[0158] The first in-application split-screen execution unit is used to pair the current task stack with the same package stack for split-screen if the current task stack where the application page is located only includes the application page and there is a same package stack below the current task stack.
[0159] The second in-application split-screen execution unit is configured to split the application page from the current task stack into paired split screens if the current task stack where the application page is located includes not only the application page.
[0160] Furthermore, the in-application multi-window button includes an in-application floating window button, and the in-application multi-window execution module 240 includes: an in-application floating window execution submodule, wherein:
[0161] The in-application floating window execution submodule is used to respond to a touch operation on the in-application floating window button and execute an in-application floating window operation on the application page.
[0162] Furthermore, the in-application floating window execution submodule includes: a first in-application floating window execution unit and a second in-application floating window execution unit, wherein:
[0163] The first in-application floating window execution unit is configured to switch the current task stack to a floating window if the current task stack where the application page is located only includes the application page.
[0164] The second in-application floating window execution unit is configured to split and switch the application page from the current task stack into a floating window if the current task stack where the application page is located includes not only the application page.
[0165] Furthermore, the multi-window display device 200 in the application further includes: a split-screen page display module, a second menu bar display module and a split-screen exit module, wherein:
[0166] The split-screen page display module is used to display a split-screen page within an application, wherein the split-screen page within the application includes at least two sub-pages, and each of the at least two sub-pages displays the window controller.
[0167] A second menu bar display module is used to respond to the touch operation of the window controller acting on the target sub-page display, and display the second menu bar of the window controller on the target sub-page, wherein the second menu bar includes a first full-screen button, and the target sub-page is any sub-page of the at least two sub-pages.
[0168] The split-screen exit module is used to respond to the touch operation on the first full-screen button and exit the split-screen within the application.
[0169] Furthermore, the second menu bar further includes a replacement application button, and the multi-window display device 200 within the application further includes: an application replacement module, wherein:
[0170] The application replacement module is used to replace the target sub-page in response to a touch operation on the application replacement button.
[0171] Furthermore, the in-application multi-window display device 200 further includes: an in-application floating window page display module, a third menu bar display module, and an in-application floating window exit module, wherein:
[0172] The in-application floating window page display module is used to display the in-application floating window page, wherein the in-application floating window page displays the window controller.
[0173] The third menu bar display module is used to respond to the touch operation on the window controller and display the third menu bar of the window controller, wherein the third menu bar includes a second full screen button.
[0174] The in-application floating window exit module is used to respond to a touch operation on the second full-screen button to exit the in-application floating window.
[0175] Furthermore, the third menu bar further includes a minimize button, and the multi-window display device 200 in the application further includes: a minimize display module, wherein:
[0176] The minimization display module is used to respond to a touch operation on the minimize button to minimize the floating window page in the application.
[0177] Those skilled in the art can clearly understand that, for the convenience and brevity of description, the specific working processes of the above-described devices and modules can refer to the corresponding processes in the aforementioned method embodiments, and will not be repeated here.
[0178] In several embodiments provided in the present application, the coupling between modules may be electrical, mechanical or other forms of coupling.
[0179] In addition, each functional module in each embodiment of the present application can be integrated into a processing module, or each module can exist physically separately, or two or more modules can be integrated into one module. The above integrated modules can be implemented in the form of hardware or software functional modules.
[0180] See also Fig.15, which shows a structural block diagram of an electronic device 100 provided in an embodiment of the present application. The electronic device 100 may be an electronic device capable of running applications, such as a smart phone, a tablet computer, an e-book, etc. The electronic device 100 in the present application may include one or more of the following components: a processor 110, a memory 120, and one or more applications, wherein the one or more applications may be stored in the memory 120 and configured to be executed by one or more processors 110, and the one or more programs are configured to execute the method described in the aforementioned method embodiment.
[0181] Among them, the processor 110 may include one or more processing cores. The processor 110 uses various interfaces and lines to connect various parts of the entire electronic device 100, and executes various functions and processes data of the electronic device 100 by running or executing instructions, programs, code sets or instruction sets stored in the memory 120, and calling data stored in the memory 120. Optionally, the processor 110 can be implemented in at least one hardware form of digital signal processing (Digital Signal Processing, DSP), field programmable gate array (Field-Programmable Gate Array, FPGA), and programmable logic array (Programmable Logic Array, PLA). The processor 110 can integrate one or a combination of a central processing unit (Central Processing Unit, CPU), a graphics processing unit (Graphics Processing Unit, GPU) and a modem. Among them, the CPU mainly processes the operating system, user pages and applications, etc.; the GPU is responsible for rendering and drawing the content to be displayed; and the modem is used to process wireless communications. It can be understood that the above-mentioned modem may not be integrated into the processor 110, but may be implemented separately through a communication chip.
[0182] The memory 120 may include a random access memory (RAM) or a read-only memory (ROM). The memory 120 may be used to store instructions, programs, codes, code sets or instruction sets. The memory 120 may include a program storage area and a data storage area, wherein the program storage area may store instructions for implementing an operating system, instructions for implementing functions (such as a touch function, a sound playback function, an image playback function, etc.), instructions for implementing the following various method embodiments, etc. The data storage area may also store data (such as a phone book, audio and video data, chat record data) created by the electronic device 100 during use.
[0183] See also Fig.16, which shows a structural block diagram of a computer-readable storage medium provided in an embodiment of the present application. The computer-readable medium 300 stores program codes, which can be called by a processor to execute the method described in the above method embodiment.
[0184] The computer readable storage medium 300 may be an electronic memory such as a flash memory, an EEPROM (electrically erasable programmable read-only memory), an EPROM, a hard disk, or a ROM. Optionally, the computer readable storage medium 300 includes a non-transitory computer-readable storage medium. The computer readable storage medium 300 has storage space for program code 310 that performs any method steps in the above method. These program codes can be read from or written to one or more computer program products. The program code 310 can be compressed, for example, in an appropriate form.
[0185] In summary, the method, device, electronic device and storage medium for displaying multiple windows within an application provided by the embodiments of the present application obtain application configuration information corresponding to the application when displaying the application page of the application, wherein the application configuration information is obtained by parsing the application configuration file of the application by the operating system of the electronic device. If it is determined based on the application configuration information that the application configuration file of the application declares access to the multiple windows within the application of the operating system under the node corresponding to the application page, then the window controller of the operating system is displayed in the application page, and in response to a touch operation on the window controller, the first menu bar of the window controller is displayed, wherein the first menu bar includes an in-application multiple window button, and in response to a touch operation on the in-application multiple window button, the in-application multiple window operation is performed on the application page, thereby declaring the in-application multiple window scheme for access to the operating system for the application page that wants to perform in-application multiple windows in the application configuration file, so that the application can achieve in-application multiple window display at a low cost.
[0186] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present application, rather than to limit it. Although the present application has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or make equivalent replacements for some of the technical features therein. However, these modifications or replacements do not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the embodiments of the present application.
Claims
1. A method for displaying multiple windows within an application, characterized in that: The method comprises: In the case of displaying an application page of the application, obtaining application configuration information corresponding to the application, wherein the application configuration information is obtained by parsing an application configuration file of the application by an operating system of the electronic device; If it is determined based on the application configuration information that the application configuration file declares access to multiple windows in the application of the operating system under the node corresponding to the application page, then displaying the window controller of the operating system in the application page; In response to a touch operation on the window controller, displaying a first menu bar of the window controller, wherein the first menu bar includes a multi-window button within the application; In response to a touch operation on the in-application multi-window button, an in-application multi-window operation on the application page is performed.
2. The method according to claim 1, characterized in that The in-application multi-window button includes an in-application split-screen button, and the in-application multi-window operation for the application page is performed in response to a touch operation on the in-application multi-window button, including: In response to a touch operation on the in-application split-screen button, an in-application split-screen operation is performed on the application page.
3. The method according to claim 2, characterized in that After the in-application split-screen operation on the application page is performed in response to the touch operation on the in-application split-screen button, the method further includes: Displaying a split-screen page within the application, wherein the split-screen page within the application includes at least two sub-pages, and each of the at least two sub-pages displays the window controller; In response to a touch operation of the window controller on a target subpage, displaying a second menu bar of the window controller on the target subpage, wherein the second menu bar includes a first full screen button, and the target subpage is any one of the at least two subpages; In response to the touch operation on the first full-screen button, the in-application split-screen is exited.
4. The method according to claim 3, characterized in that The second menu bar further includes a replacement application button, and after the target sub-page displays the second menu bar of the window controller, further includes: In response to a touch operation on the replacement application button, the target sub-page is replaced.
5. The method according to any one of claims 2 to 4, characterized in that: The performing the in-application split-screen operation on the application page includes: If the current task stack where the application page is located only includes the application page and there is a stack in the same package below the current task stack, pair the current task stack with the stack in the same package and split the screen; or If the current task stack where the application page is located includes not only the application page, the application page is split from the current task stack into a paired split screen.
6. The method according to claim 1, characterized in that The in-application multi-window button includes an in-application floating window button, and the in-application multi-window operation for the application page is performed in response to a touch operation on the in-application multi-window button, including: In response to a touch operation on the in-application floating window button, an in-application floating window operation on the application page is performed.
7. The method according to claim 6, characterized in that After the in-application floating window operation on the application page is performed in response to the touch operation on the in-application floating window button, the method further includes: Displaying a floating window page within the application, wherein the floating window page within the application displays the window controller; In response to a touch operation on the window controller, displaying a third menu bar of the window controller, wherein the third menu bar includes a second full screen button; In response to the touch operation on the second full-screen button, exit the floating window within the application.
8. The method according to claim 7, characterized in that The third menu bar further includes a minimize button, and after the third menu bar displaying the window controller, further includes: In response to a touch operation on the minimize button, the floating window page within the application is minimized.
9. The method according to any one of claims 6 to 8, characterized in that: The performing the in-application floating window operation on the application page includes: If the current task stack where the application page is located only includes the application page, switching the current task stack to a floating window; or If the current task stack where the application page is located includes not only the application page, the application page is split from the current task stack and switched into a floating window.
10. The method according to claim 1, characterized in that If it is determined based on the application configuration information that multiple windows in the application of the operating system are declared to be connected under the node corresponding to the application page in the application configuration file, then the window controller of the operating system is displayed in the application page, including: If it is determined based on the application configuration information that target metadata is added in the application configuration file under the node corresponding to the application page, the window controller of the operating system is displayed in the application page, wherein the target metadata is used to characterize multiple windows in an application connected to the operating system.
11. A display device with multiple windows in an application, characterized in that: The device comprises: An application configuration information acquisition module, used to acquire application configuration information corresponding to the application when the application page of the application is displayed, wherein the application configuration information is obtained by parsing the application configuration file of the application by the operating system of the electronic device; a window controller display module, configured to display a window controller of the operating system in the application page if it is determined based on the application configuration information that multiple windows in the application of the operating system are declared to be connected under the node corresponding to the application page in the application configuration file; A first menu bar display module, configured to display a first menu bar of the window controller in response to a touch operation on the window controller, wherein the first menu bar includes a multi-window button within the application; The in-application multi-window execution module is used to respond to a touch operation on the in-application multi-window button and execute an in-application multi-window operation on the application page.
12. An electronic device, characterized in that: The method comprises a memory and a processor, wherein the memory is coupled to the processor, the memory stores instructions, and when the instructions are executed by the processor, the processor executes the method according to any one of claims 1 to 10.
13. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores program codes, which can be called by a processor to execute the method according to any one of claims 1 to 10.