Communication terminal and display method in multi-window mode

By configuring the processor in the communication terminal to adapt to the user interface layout of non-full-screen windows, the problem of improper display of interface elements in multi-window mode was solved, thus improving the user experience.

CN111367456BActive Publication Date: 2025-11-07QINGDAO HISENSE MOBILE COMM TECH CO LTD
View PDF 5 Cites 0 Cited by

Patent Information

Application Number
CN202010128710.8
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2020-02-28
Publication Date
2025-11-07
Estimated Expiration
2040-02-28

AI Technical Summary

Technical Problem

In multi-window mode, existing technologies struggle to display the application's user interface correctly, especially in non-full-screen windows where interface elements often extend beyond the window's boundaries, impacting the user experience.

Method used

By configuring a processor in the communication terminal, it is possible to adapt the layout of user interface elements in non-full-screen windows, including responding to user operations, switching between portrait and landscape modes, and obtaining window sizes, ensuring that interface elements are adapted to window sizes.

Benefits of technology

It achieves correct alignment of user interface elements with non-fullscreen windows in multi-window mode, improving user experience and avoiding the problem of interface elements being displayed outside the window area.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN111367456B_ABST
    Figure CN111367456B_ABST
Patent Text Reader

Abstract

The application discloses a communication terminal and a display method in a multi-window mode. The communication terminal comprises a touch screen configured to receive a touch operation from a user; a display screen configured to display a user interface; and a processor coupled with the touch screen and the display screen respectively; the display screen displays at least two windows, a first window in the at least two windows being a non-full-screen window; the processor is configured to: in response to a user operation of starting an application in the first window or starting an application running in the background to the first window, display a user interface of the application in the first window, and make an interface element layout of the user interface adapt to a size of the first window.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application relates to the field of communication, and in particular to a communication terminal and a display method in a multi-window mode. BACKGROUND

[0002] With the popularization of intelligent communication terminals, the communication terminals support more and more functions. In order to provide users with better user experience, more and more communication terminals support a multi-window mode. In the multi-window mode, two or more windows can be displayed on the screen of the communication terminal, and different windows can display user interfaces of different applications.

[0003] One typical type of the multi-window mode is a picture-in-picture mode, which means that one or more sub-windows are displayed in a main window, and the main window and the sub-windows can display different contents so that the user can simultaneously watch the contents in the main window and the contents in the sub-windows. The sub-windows can also be located outside the main window. Another typical type of the multi-window mode is a split-screen mode, which means that two or more non-overlapping windows are simultaneously displayed on the same screen. In addition, the multi-window mode can also include other types, such as a screen displaying a full-screen window and one or more small windows (a small window is a non-full-screen window, and the window size of the small window is smaller than that of the full-screen window).

[0004] How to correctly display the user interface of an application in the multi-window mode is a problem to be solved at present. SUMMARY

[0005] In the exemplary embodiments of the present application, a communication terminal and a display method in a multi-window mode are provided to correctly display the user interface of an application in the multi-window mode.

[0006] According to an aspect of the exemplary embodiments, a communication terminal is provided, comprising:

[0007] a touch screen configured to receive a touch operation from a user;

[0008] a display screen configured to display a user interface;

[0009] a processor coupled with the touch screen and the display screen respectively;

[0010] the display screen displays at least two windows, and a first window of the at least two windows is a non-full-screen window;

[0011] the processor is configured to:

[0012] In response to a user operation of starting an application in the first window or starting a background running application into the first window, displaying a user interface of the application in the first window, and causing an interface element layout of the user interface to adapt to a size of the first window.

[0013] Based on the above embodiments, since the application can obtain the size of the non-full screen window when starting into the non-full screen window, the application can perform layout design according to the size of the non-full screen window when performing interface element layout design of the user interface, so that the interface element layout of the user interface adapts to the size of the non-full screen window.

[0014] In the above embodiments, the processor is further configured to, in response to a user operation of starting a background running application into the first window, notify the application to perform a landscape / portrait screen switching, so that the application obtains the size of the first window and performs layout setting of interface elements of the user interface according to the size of the first window.

[0015] Based on the above embodiments, since the application can obtain the size of the non-full screen window when starting into the non-full screen window, the application can perform layout design according to the size of the non-full screen window when performing interface element layout design of the user interface, so that the interface element layout of the user interface adapts to the size of the non-full screen window.

[0016] In the above embodiments, the processor is further configured to, after displaying the user interface of the application in the first window, in response to a user operation of landscape / portrait screen switching, adjust a layout of the at least two windows, redraw the user interface in the first window, and cause an interface element layout of the user interface in the first window to adapt to a size of the first window.

[0017] Based on the above embodiments, when landscape / portrait screen switching is performed, the application currently displayed in the non-full screen window can obtain the size of the non-full screen window, so that the application can perform layout design according to the size of the non-full screen window when performing interface element layout design of the user interface, so that the interface element layout of the user interface adapts to the size of the non-full screen window.

[0018] In the above embodiment, the processor is further configured to: determine whether the application needs to be displayed in a non-full screen window according to the request of the application for obtaining a default display window size; if it is determined that the application needs to be displayed in a non-full screen window, obtain the size of the first window, the first window being a target window for displaying the application, otherwise obtain a default display window size; and notify the application of the obtained window size.

[0019] Based on the above embodiment, when an application requests an application framework layer to obtain a default display window size, the application framework layer needs to determine whether the application needs to be displayed in a non-full screen window, and if it is determined that the application needs to be displayed in a non-full screen window, the size of the non-full screen window is returned instead of the size of a full screen window (the size of the default display window is usually the size of a full screen window), so that the application can perform layout design of interface elements of a user interface according to the size of the non-full screen window when performing the layout design, thereby making the layout of the interface elements of the user interface adapt to the size of the non-full screen window.

[0020] In the above embodiment, the processor is further configured to: when determining whether the application needs to be displayed in a non-full screen window according to the request of the application for obtaining a default display window size, determine whether the application needs to be displayed in a non-full screen window according to first attribute information; wherein the first attribute information is used to indicate the package name of the application started into the first window, and the first attribute information is created when the first window is created.

[0021] In the above embodiment, the processor is further configured to: when obtaining the size of the first window, obtain the size of the first window according to second attribute information; wherein the second attribute information is used to indicate the size of the first window, and the second attribute information is created when the first window is created.

[0022] According to an aspect of an exemplary embodiment, a display method in a multi-window mode is provided, including: in response to a user operation of starting an application in a first window or starting a background running application into the first window, displaying a user interface of the application in the first window, and making the layout of interface elements of the user interface adapt to the size of the first window.

[0023] In the above embodiment, it further includes: in response to the user operation of starting the background running application into the first window, notifying the application to perform landscape / portrait screen switching, so that the application obtains the size of the first window and performs layout setting of interface elements of the user interface according to the size of the first window.

[0024] In the above embodiments, before displaying the user interface of the application in the first window, the method further comprises: judging whether the application needs to be displayed in a non-full screen window according to a request of the application for a default display window size; if it is judged that the application needs to be displayed in a non-full screen window, obtaining the size of the first window, the first window being a target window for displaying the application, otherwise obtaining the size of a default display window; and notifying the application of the obtained size of the window.

[0025] According to an aspect of some embodiments, a computer storage medium is provided, having computer program instructions stored therein, which when executed on a computer, cause the computer to perform the above method.

[0026] On the basis of common general knowledge in the art, the above preferred conditions can be combined in any manner to obtain various preferred embodiments of the present application. BRIEF DESCRIPTION OF DRAWINGS

[0027] In order to more clearly illustrate the technical solutions in the embodiments of the present application or the prior art, a brief introduction will be given below to the drawings needed in the embodiments or the prior art description. Obviously, the drawings described below are some embodiments of the present application, and those skilled in the art can obtain other drawings according to these drawings without any creative effort.

[0028] Figure 1 An exemplary structure schematic diagram of a communication terminal provided by an embodiment of the present application is shown;

[0029] Figure 2 An exemplary software architecture schematic diagram of a communication terminal provided by an embodiment of the present application is shown;

[0030] Figure 3 An exemplary user interface schematic diagram of a communication terminal provided by an embodiment of the present application is shown;

[0031] Figure 4a 、 Figure 4b An exemplary comparison diagram of displaying a user interface in a full screen window and in a multi-window mode in a scenario is shown;

[0032] Figure 5a 、 Figure 5b An exemplary comparison diagram of displaying a user interface in a full screen window and in a multi-window mode in another scenario is shown;

[0033] Figure 6 An exemplary flowchart of starting an application in a small window in an embodiment of the present application is shown;

[0034] Figure 7 、 Figure 8 、Figure 9 The following are exemplary user interface diagrams in the multi-window mode of the embodiments of this application. Detailed Implementation

[0035] The technical solutions in the embodiments of this application will now be described clearly and in detail with reference to the accompanying drawings. In the description of the embodiments of this application, unless otherwise stated, " / " means "or," for example, A / B can mean A or B; the word "and / or" in the text is merely a description of the relationship between related objects, indicating that three relationships can exist. For example, A and / or B can represent: A alone, A and B simultaneously, and B alone. Furthermore, in the description of the embodiments of this application, "multiple" refers to two or more than two.

[0036] Hereinafter, the terms "first" and "second" are used for descriptive purposes only and should not be construed as implying or suggesting relative importance or implicitly indicating the number of indicated technical features. Thus, a feature defined as "first" or "second" may explicitly or implicitly include one or more of that feature, and in the description of the embodiments of this application, unless otherwise stated, "multiple" means two or more.

[0037] Figure 1 A schematic diagram of the communication terminal 100 is shown.

[0038] The communication terminal 100 in this embodiment supports a multi-window mode. For example, the communication terminal can be a smartphone, wearable device, tablet computer, etc. that supports a multi-window mode.

[0039] The following description uses communication terminal 100 as an example to illustrate the embodiment. It should be understood that... Figure 1 The communication terminal 100 shown is merely an example, and the communication terminal 100 may have more than Figure 1 The more or fewer components shown can be combined into two or more components, or they can have different component configurations. The various components shown in the figure can be implemented in hardware, software, or a combination of hardware and software, including one or more signal processing and / or application-specific integrated circuits.

[0040] Figure 1 The diagram illustrates a hardware configuration block diagram of a communication terminal 100 according to an exemplary embodiment. Figure 1 As shown, the communication terminal 100 includes components such as a radio frequency (RF) circuit 110, a memory 120, a display unit 130, a camera 140, a sensor 150, an audio circuit 160, a wireless Fidelity (Wi-Fi) module 170, a processor 180, a Bluetooth module 181, and a power supply 190.

[0041] The RF circuit 110 can be used for receiving and sending signals in the process of receiving information or talking, and can receive downlink data of a base station and hand over the downlink data to the processor 180 for processing; and can send uplink data to the base station. Generally, the RF circuit includes, but is not limited to, an antenna, at least one amplifier, a transceiver, a coupler, a low-noise amplifier, a duplexer, and the like.

[0042] The memory 120 can be used to store software programs and data. The processor 180 executes various functions of the communication terminal 100 and data processing by running the software programs or data stored in the memory 120. The memory 120 can include a high-speed random access memory, and can further include a non-volatile memory, such as at least one magnetic disk storage device, a flash memory device, or other volatile solid-state memory device. The memory 120 stores an operating system that enables the communication terminal 100 to operate. In the embodiment of the present application, the memory 120 can store an operating system and various application programs, and can further store codes for executing the method described in the embodiment of the present application.

[0043] The display unit 130 can be used to receive input digital or character information, and generate signal input related to user settings and function control of the communication terminal 100. Specifically, the display unit 130 can include a touch screen 131 arranged on the front of the communication terminal 100, and can collect touch operations of the user thereon or therearound, such as clicking buttons, dragging scroll boxes, and the like.

[0044] The display unit 130 can also be used to display information input by the user or information provided to the user, and a graphical user interface (GUI) of various menus of the terminal 100. Specifically, the display unit 130 can include a display screen 132 arranged on the front of the communication terminal 100. The display screen 132 can be configured in the form of a liquid crystal display screen, a light-emitting diode, or the like. The display unit 130 can be used to display various graphical user interfaces described in the embodiment of the present application.

[0045] The touch screen 131 can be overlaid on the display screen 132, or the touch screen 131 can be integrated with the display screen 132 to realize the input and output functions of the communication terminal 100. After integration, it can be simply referred to as a touch display screen. The display unit 130 in the embodiment of the present application can display application programs and corresponding operation steps.

[0046] The camera 140 can be used to capture still images or videos. An object projects an optical image through a lens to a photosensitive element. The photosensitive element can be a charge coupled device (CCD) or a complementary metal-oxide-semiconductor (CMOS) phototransistor. The photosensitive element converts the optical signal into an electrical signal, which is then passed to the processor 180 for conversion into a digital image signal.

[0047] The communication terminal 100 can also include at least one sensor 150, such as an acceleration sensor 151, a distance sensor 152, a fingerprint sensor 153, a temperature sensor 154. The communication terminal 100 can also be configured with a gyroscope, a barometer, a hygrometer, a thermometer, an infrared sensor, a light sensor, a motion sensor, and other sensors.

[0048] The audio circuit 160, the speaker 161, and the microphone 162 can provide an audio interface between the user and the communication terminal 100. The audio circuit 160 can convert the received audio data into an electrical signal and transmit it to the speaker 161, which converts the electrical signal into an audible signal for output. The communication terminal 100 can also be configured with a volume button for adjusting the volume of the audible signal. On the other hand, the microphone 162 converts the collected sound signal into an electrical signal, which is received by the audio circuit 160 and converted into audio data, which is then output to the RF circuit 110 for transmission to another terminal, for example, or to the memory 120 for further processing. In the embodiments of the present application, the microphone 162 can obtain the user's voice.

[0049] Wi-Fi is a short-range wireless transmission technology. The communication terminal 100 can help users send and receive emails, browse web pages, and access streaming media through the Wi-Fi module 170, which provides users with wireless broadband Internet access.

[0050] The processor 180 is the control center of the communication terminal 100, connects various parts of the entire terminal through various interfaces and lines, and performs various functions of the communication terminal 100 and processes data by running or executing software programs stored in the memory 120 and calling data stored in the memory 120. In some embodiments, the processor 180 can include one or more processing units; the processor 180 can also integrate an application processor and a baseband processor, wherein the application processor mainly processes the operating system, user interface, and application programs, etc., and the baseband processor mainly processes wireless communication. It can be understood that the above-mentioned baseband processor can also not be integrated into the processor 180. The processor 180 in the embodiments of the present application can run the operating system, application programs, user interface display and touch response, and the processing method described in the embodiments of the present application. In addition, the processor 180 is coupled with the display unit 130 and the camera 140.

[0051] The Bluetooth module 181 is used to interact with other Bluetooth devices with Bluetooth modules through Bluetooth protocol. For example, the communication terminal 100 can establish a Bluetooth connection with a wearable electronic device (such as a smart watch) also having a Bluetooth module through the Bluetooth module 181, so as to interact data.

[0052] The communication terminal 100 further includes a power supply 190 (such as a battery) for supplying power to various components. The power supply can be logically connected to the processor 180 through a power management system, so as to realize the functions of managing charging, discharging, and power consumption through the power management system. The communication terminal 100 can also be configured with a power button for the functions of turning on and off the terminal, and locking the screen.

[0053] Figure 2 is a software structure block diagram of the communication terminal 100 of the embodiments of the present application.

[0054] The layered architecture divides the software into several layers, each layer has a clear role and division of labor. Layers communicate with each other through software interfaces. In some embodiments, the Android system is divided into four layers, from top to bottom, the application layer, the application framework layer, the Android runtime and the system library, and the kernel layer.

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

[0056] As shown in Figure 2 , the application package can include camera, gallery, calendar, call, map, navigation, WLAN, Bluetooth, music, video, short message, etc.

[0057] The application framework layer provides application programming interfaces (APIs) and programming frameworks for applications in the application layer. The application framework layer includes some pre-defined functions.

[0058] As shown in Figure 2 the application framework layer can include a window manager, a content provider, a view system, a phone manager, a resource manager, a notification manager, etc.

[0059] The window manager is used to manage window programs. The window manager can acquire the size of a display screen, determine whether there is a status bar, lock a screen, and capture a screen, etc.

[0060] The content provider is used to store and acquire data, and make the data accessible to applications. The data can include videos, images, audios, dialed and received calls, browsing history and bookmarks, a phone book, etc.

[0061] The view system includes visual controls, such as a control for displaying text, a control for displaying pictures, etc. The view system can be used to build an application. A display interface can be composed of one or more views. For example, a display interface including a short message notification icon can include a view for displaying text and a view for displaying pictures.

[0062] The phone manager is used to provide communication functions of the communication terminal 100. For example, management of a call state (including call connection, call hang-up, etc.).

[0063] The resource manager provides various resources for applications, such as localized strings, icons, pictures, layout files, video files, etc.

[0064] The notification manager enables an application to display notification information in a status bar. The notification manager can be used to convey a message of the notification type, which can automatically disappear after a short stay without user interaction. For example, the notification manager is used to notify a download completion, a message reminder, etc. The notification manager can also be a notification appearing in a system top status bar in a form of a graph or a scrolling bar text, for example, a notification of an application running in the background, or a notification appearing on a screen in a form of a dialog window. For example, a text information is prompted in a status bar, a prompt sound is emitted, the communication terminal vibrates, an indicator light flashes, etc.

[0065] The Android runtime includes a core library and a virtual machine. The Android runtime is responsible for scheduling and management of the Android system.

[0066] The core library includes two parts: one part is a function function called by the java language, and the other part is the core library of the Android.

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

[0068] The system library can include a plurality of functional modules. For example, a surface manager, media libraries, a three-dimensional graphics processing library (e.g., OpenGL ES), a 2D graphics engine (e.g., SGL), etc.

[0069] The surface manager is used to manage the display subsystem and provides fusion of 2D and 3D layers for a plurality of applications.

[0070] The media libraries support playback and recording of a plurality of commonly used audio, video formats, and still image files. The media libraries can support a plurality of audio and video encoding formats, such as MPEG4, H.264, MP3, AAC, AMR, JPG, PNG, etc.

[0071] The three-dimensional graphics processing library is used to implement three-dimensional graphics drawing, image rendering, composition, and layer processing, etc.

[0072] The 2D graphics engine is a drawing engine for 2D drawing.

[0073] The kernel layer is a layer between hardware and software. The kernel layer includes at least display drivers, camera drivers, audio drivers, and sensor drivers.

[0074] The following illustrates the workflow of the software and hardware of the communication terminal 100 in the context of capturing a photograph.

[0075] When the touchscreen 131 receives a touch operation, a corresponding hardware interrupt is sent to the kernel layer. The kernel layer processes the touch operation into a raw input event (including touch coordinates, a timestamp of the touch operation, etc.). The raw input event is stored in the kernel layer. The application framework layer obtains the raw input event from the kernel layer and identifies the control corresponding to the input event. Taking the case where the touch operation is a touch click operation and the control corresponding to the click operation is the control of the camera application icon as an example, the camera application calls an interface of the application framework layer, starts the camera application, and then starts the camera driver through the kernel layer to capture a still image or video through the camera 140.

[0076] Figure 3 is used to illustrate a communication terminal (e.g. Figure 1Fig. 1 is a schematic diagram of a user interface on a communication terminal 100. In some embodiments, a user can open a corresponding application by touching an application icon on the user interface, or open a corresponding folder by touching a folder icon on the user interface.

[0077] The communication terminal in the embodiments of the present application supports a multi-window mode. A user can enable or disable the multi-window mode as needed. Taking a picture-in-picture mode as an example, a user can enable or exit the picture-in-picture mode by setting a picture-in-picture mode setting option in a setting interface.

[0078] In the multi-window mode, the user interface of an application that needs to be displayed in a small window can not be normally displayed. In the embodiments of the present application, a "small window" is distinguished from a full-screen size window, and the small window is a non-full-screen window, which has a size smaller than that of the full-screen window. For example, the "small window" can be a split-screen window in a split-screen mode, or a sub-window in a picture-in-picture mode.

[0079] The "application" described in the embodiments of the present application can be a third-party application or a system application, or other types of applications, which are not limited in the embodiments of the present application.

[0080] Figure 4a and Figure 4b An example is shown to illustrate a comparison between the user interface display in a full-screen window and in a multi-window mode when the existing solution is used to handle a scenario.

[0081] As shown in Figure 4a , in this scenario, the first application is a shopping application. When the user requests to register after the application is started in the full-screen window, the application displays a pop-up window 400 in a pop-up manner, and the user usage declaration content is displayed in the pop-up window 400.

[0082] As shown in Figure 4b , also taking the first application as an example, in this scenario, the communication terminal enables the picture-in-picture mode, and the first window 410 and the second window 420 are displayed on the screen of the communication terminal. The first window 410 is a small window, and the second window 420 is a full-screen window. The first application is a shopping application, which is started in the first window 410, and the second application is a game application, which is started in the second window 420. The interface of the game is displayed in full screen, and the user usage declaration in the user interface of the shopping application is displayed in a pop-up manner. The width of the pop-up box 411 exceeds the width of the first window 410, so that the content of the user usage declaration cannot be fully displayed in the first window 410, which affects the user experience.

[0083] Figure 5a and Figure 5bExemplarily, another scenario is shown, in which the user interface display in full screen window and multi-window mode is compared when the existing solution is used to process.

[0084] As shown in Figure 5a , in this scenario, the first application is a social application. When the application is started in full screen window and uses video call, the video call window 500 of the application is as shown in Figure 5a .

[0085] When the user opens the split screen mode, the first split screen window 510 and the second split screen window 520 are displayed on the screen of the communication terminal, as shown in Figure 5b . The first application (the social application) is displayed in the first split screen window 510. The desktop (home screen interface) of the communication terminal is displayed in the second split screen window 520. The length and width of the video call window in the user interface of the social application exceed the range of the first split screen window 510, so that the video picture in the video call window cannot be fully displayed in the first split screen window 510, affecting the user experience.

[0086] Embodiments of the present application provide a display method in multi-window mode. When an application is started in a small window or a background running application is started in a small window, the layout of interface elements of the user interface can be adapted to the size of the small window, thereby improving the user experience.

[0087] The display process in multi-window mode provided by the embodiments of the present application will be described in detail below with reference to the accompanying drawings.

[0088] Figure 6 Exemplarily, a flowchart of starting an application in a small window in the embodiments of the present application is shown.

[0089] In this embodiment, the communication terminal is currently in multi-window mode, and the display screen displays at least two windows, including a first window, which is a small window. The following flow is described by taking starting an application A in a small window as an example to describe the starting process of the application A. As shown in the figure, the flow can include:

[0090] In S601, after the application A is started, the window size is requested from the application framework layer.

[0091] In this step, in some scenarios, the user can start the application A in the first window by clicking the icon of the application A in the home page displayed in the first window.

[0092] The application A can call an interface for obtaining the window size, so that the application framework layer obtains the window size and returns it to the application A. For example, the application A can obtain the window size by calling the following interface:

[0093] Interface for obtaining the width of the default display window:

[0094] getWindowManager().getDefaultDisplay().getWidth();

[0095] Interface for obtaining the height of the default display window:

[0096] getWindowManager().getDefaultDisplay().getHeigh()

[0097] Interface for obtaining the area in the default display window that the application can actually display (for example, if the default display window contains an icon area, the area that the application can actually display needs to deduct the icon area):

[0098] WindowManager().getDefaultDisplay().getRealMetrics()

[0099] At S602, after the application framework layer receives the request of the application A to obtain the window size, it is judged whether the target window of the application A is a small window, and the attribute container is recorded in priority, so as to distinguish the drawing of the full-screen and non-full-screen application interface switching in the subsequent. If it is a small window, it is transferred to S603, otherwise it is transferred to S604.

[0100] At S603, the application framework layer obtains the size of the small window (i.e. the first window) for displaying the application A, and returns the size of the first window to the application A.

[0101] Among them, the size of the small window returned to the application A is the actual size of the small window. For example, the size of the first window (small window) is 1080x1170 (the full-screen size is 1080x2340).

[0102] At S604, the application framework layer obtains the size of the default display window, and returns the size of the default display window to the application A.

[0103] Among them, the size of the default display window is also the size of the default home screen, which is usually the full-screen size, such as 1080x2340. According to the differences of the models of the communication terminals, the screen sizes of different models of communication terminals may be different. Of course, it can also be other default window sizes.

[0104] At S605-S606, the application A lays out interface elements in the user interface according to the size of the window returned by the application framework layer, obtains display parameters of the user interface, and provides the display parameters of the user interface to the application framework layer, and the application framework layer renders and displays the user interface according to the display parameters of the user interface.

[0105] In this step, if the window size obtained by the application A is a small window size, the interface elements in the user interface are laid out according to the small window size to avoid the display range of the interface elements in the user interface exceeding the range of the small window, such as avoiding the pop-up window or video window in the user interface exceeding the range of the small window. If the window size obtained by the application A is a full-screen window size, the interface elements in the user interface are laid out according to the full-screen window size.

[0106] Thereafter, without performing the horizontal-vertical screen switching or the window mode switching, the application A lays out the interface elements in the user interface of the application according to the window size obtained at the start.

[0107] For an application, the layout display of each user interface thereof can include the following two ways:

[0108] The first way is to display the interface according to the relative layout design, which includes but is not limited to top alignment, both-end alignment, full-screen centering, left alignment, right alignment, etc.

[0109] The second way is to display the interface according to the fixed layout design, which includes but is not limited to fixing the width of the interface display element, fixing the height of the interface display element, fixing the distance between the display interface element and the edge of the display window, fixing the distance between the display interface element and the notch area, etc.

[0110] In the above process, after the application framework layer receives the request sent by the application A through calling the interface for obtaining the default display window size, instead of directly returning the size of the default display window (the size of the default display window is the size of the default main screen, which is usually the full-screen size), the size of the small window is returned to the application A in the case that the application A is started in the small window (i.e., the application A needs to be displayed in the small window). That is, when the application A is started in the first window (small window), the application framework layer returns the size of the first window (small window) to the application A instead of the size of the default main screen window (such as the size of the full-screen window), so that the application A lays out the interface elements in the user interface according to the size of the small window, so that the layout of the interface elements in the user interface matches the size of the small window, to avoid the display of the interface elements exceeding the range of the small window due to the mismatch between the layout of the interface elements and the size of the small window.

[0111] Figure 7 An exemplary schematic diagram of a user interface in a multi-window mode according to an embodiment of this application is shown. The scenario depicted in this schematic diagram is similar to... Figure 4b The scenarios are the same. For example... Figure 7 As shown, taking the first application as an example, in this scenario, the communication terminal uses picture-in-picture mode, displaying a first window 710 and a second window 720 on the terminal screen. The first window 710 is a small window, and the second window 720 is a full-screen window. The first application is a shopping application, launched in the first window 710, and the second application is a game application, launched in the second window 720. The game interface is displayed in full screen, and the user interface of the shopping application displays a user declaration in a pop-up. Because the method provided in this embodiment matches the width of the pop-up 711 with the width of the first window 710, the content of the user declaration can be proportionally scaled down and displayed normally in the first window 710, providing complete user operation buttons and improving the user experience.

[0112] Figure 8 An exemplary schematic diagram of a user interface in a multi-window mode according to an embodiment of this application is shown. The scenario depicted in this schematic diagram is similar to... Figure 5b The scenarios are the same. For example... Figure 8 As shown, when the user activates split-screen mode, a first split-screen window 810 and a second split-screen window 820 are displayed on the communication terminal screen. The first application (the social application) is displayed in the first split-screen window 810. The desktop (main screen interface) of the communication terminal is displayed in the second split-screen window 820. Because the method provided in this embodiment is used, the dimensions of the video call window in the user interface of the social application are adapted to the range of the first split-screen window 810, allowing the video image in the video call window to be proportionally reduced and displayed normally in the first split-screen window 810, thus improving the user experience.

[0113] Optionally, in some embodiments of this application, when the communication terminal enables multi-window mode, the application framework layer can obtain and record the package name of the application that needs to be launched into the small window and the display size of the small window. In this way, when the application is launched, the application framework layer can determine whether the currently launched application needs to be launched into the small window based on the recorded package name of the application that needs to be launched into the small window, and return the window size to the application that needs to be launched into the small window based on the recorded size of the small window.

[0114] Specifically, in some embodiments, when the communication terminal enters the multi-window mode, the application framework layer can obtain the package name of the application that needs to be started into the small window. In the embodiments of the present application, the multi-window related control such as opening and closing is implemented by the application framework layer, and the user can select which application to start in the form of a small window or in the form of a full-screen window by providing a menu of small window starting modes. Taking the split screen as an example, the application can be displayed in a split screen by providing a certain starting mode, for example, the currently started application can be displayed in a split screen by long pressing the recent task key, and a UI (User Interface) menu can also be provided on the desktop to directly start an application in the form of a small window. In this way, the application framework layer can obtain the package name of the application that needs to be started into the small window.

[0115] Optionally, the package name of the application that needs to be started into the small window can be recorded in the form of an attribute, for example, the attribute can be defined as: property_AppName. When the application is started, the application framework layer can determine whether the application needs to be started into the small window by the recorded property_AppName attribute.

[0116] In some other embodiments, when the communication terminal enters the multi-window mode (for example, the split screen mode or the picture-in-picture mode), the application framework layer can record the size of the small window for the small window. Optionally, the display size of the small window can be recorded in the form of an attribute, for example, the attribute can be defined as: property_displaySize. When the application requests the application framework layer to obtain the window size by calling a corresponding interface, the application framework layer obtains the size of the small window by the recorded property_displaySize attribute of the small window and returns the size to the application in the case that the application needs to be started into the small window.

[0117] In some embodiments of the present application, when the communication terminal performs a landscape / portrait screen switching in the multi-window mode, the interface elements in the user interface in the small window can still adapt to the size of the small window after the landscape / portrait screen switching.

[0118] Specifically, when the communication terminal opens the multi-window mode, the user interface of the application A is displayed in the small window (the process of starting the application A to the small window can be referred to the above embodiment). At this time, the horizontal-vertical screen switching occurs, in response to which the communication terminal adjusts the window layout (for example, when switching from vertical screen to horizontal screen, the layout of arranging two windows vertically is adjusted to the layout of arranging two windows horizontally, and vice versa), the application A requests the application framework layer to obtain the window size, and the application framework layer receives the request of the application A to obtain the window size, judges that the target window of the application A is the small window, and thus obtains the size of the small window for displaying the application A, and returns the size of the small window to the application A. The application A performs layout design on the interface elements in the user interface according to the size of the window returned by the application framework layer, obtains the display parameters of the user interface, and provides the display parameters of the user interface to the application framework layer. The application framework layer performs user interface rendering and display according to the display parameters of the user interface. The processing process is similar to the flow shown in Figure 6 and will not be repeated here.

[0119] For example, taking the user interface shown in Figure 8 as an example, after the horizontal-vertical screen switching occurs, as shown in Figure 9 , the first split screen window 910 and the second split screen window 920 are displayed on the screen of the communication terminal, and the two windows are adjusted from vertical arrangement before the horizontal-vertical screen switching to horizontal arrangement after the horizontal-vertical screen switching. The first application (the social application) is displayed in the first split screen window 910. The desktop (home screen interface) of the communication terminal is displayed in the second split screen window 920. Due to the method provided in the embodiments of the present application, the length-width of the video call window in the user interface of the social application is adapted to the range of the first split screen window 910, so that the video picture in the video call window can be normally displayed in the first split screen window 910, and the user experience is improved.

[0120] In some scenarios, an application has been started and displayed as full screen, and when the application is started into the small window in the foreground after running in the background, according to the conventional process, the application will not obtain the window size again, but perform layout setting of the interface elements in the user interface according to the size of the full screen window obtained when the application is started before, and thus the interface elements in the user interface may not match the size of the small window.

[0121] To this end, in some embodiments of the present application, when a currently running in the background full-screen launched application is launched into a small window, the application framework layer can send a notification to the application for switching between landscape and portrait screens after detecting the event, and the application can request the application framework layer for obtaining the window size after receiving the notification, the application framework layer can send the size of the target small window of the application to the application, so that the application designs the layout of the interface elements in the user interface according to the size of the window returned by the application framework layer, obtains the display parameters of the user interface, and provides the display parameters of the user interface to the application framework layer, and the application framework layer performs user interface rendering and display according to the display parameters of the user interface. The processing process is similar to the flow shown in Figure 6 The flow is not repeated here.

[0122] Optionally, when a currently running in the background full-screen launched application is launched into a full-screen window, it can be processed in a conventional manner, that is, the application framework layer does not need to send a notification to the application for switching between landscape and portrait screens, and thus the application does not send a request for obtaining the window size, and the application uses the default window size obtained when starting (i.e. the default full-screen window size) to design the layout of the interface elements in the user interface.

[0123] In the above flow, taking the Android system as an example, the third-party application running in the background can be launched by calling the startActivity interface, that is, when the application framework layer receives the relevant events or messages of the startActivity interface, it is determined that the application running in the background needs to be called to the foreground. For example, a certain application currently running in the background can be launched into a first window (small window) through a UI menu, a gesture, voice control, etc. These launch operations need to call the launch interface of the small window provided by the system window module of the application framework layer, so as to directly change the window display of the application to a small window form.

[0124] In the above flow, taking the Android system as an example, the application framework layer can trigger the interface for obtaining the window size of the application by sending a configchange notification for triggering the switching between landscape and portrait screens, so that the application framework layer obtains the window size and returns it to the application.

[0125] According to still another aspect of the exemplary embodiments, a computer storage medium is provided, in which computer program instructions are stored, and when the instructions run on a computer, the computer executes the processing method as described above.

[0126] Since the communication terminal and the computer storage medium in the embodiments of the present application can be applied to the above processing method, the technical effects they can obtain can also be referred to the above method embodiments, and the embodiments of the present application will not be repeated here.

[0127] Those skilled in the art can understand that all or part of the steps of the above-mentioned method embodiments can be completed by program instruction related hardware. The foregoing program can be stored in a computer readable storage medium. The program executes to perform the steps of the above-mentioned method embodiments; and the foregoing storage medium includes various storage media that can store program codes, such as ROM, RAM, magnetic disk or optical disk.

[0128] Although the specific embodiments of the present application are described above, those skilled in the art should understand that these are only illustrative, and the protection scope of the present application is defined by the appended claims. Those skilled in the art can make various changes or modifications to these embodiments without departing from the principles and essence of the present application, and these changes and modifications all fall within the protection scope of the present application.

Claims

1. A communication terminal, characterized by comprising: The application comprises: a touch screen configured to receive a touch operation from a user; a display screen configured to display a user interface; a processor coupled with the touch screen and the display screen respectively; the display screen displays at least two windows, and a first window of the at least two windows is a non-full screen window; the processor is configured to: in response to a user operation of starting an application in the first window or starting a background running application into the first window, display a user interface of the application in the first window, and make an interface element layout of the user interface adapt to a size of the first window; wherein, according to a request of the application for obtaining a default display window size, it is determined whether the application needs to be displayed in a non-full screen window; if it is determined that the application needs to be displayed in a non-full screen window, the size of the first window is obtained, the first window being a target window for displaying the application, otherwise the size of a default display window is obtained; wherein, when the application calls an interface for obtaining a window size, the application framework layer obtains the size of the window for displaying the application; the obtained window size is notified to the application, so that the application designs the layout of interface elements in the user interface according to the window size to obtain display parameters of the user interface; wherein, the processor is further configured to: when a user operation of starting a background running application into the first window is received, the application is notified to switch between a horizontal screen and a vertical screen, so that the application obtains the size of the first window and sets the layout of interface elements in the user interface according to the size of the first window; wherein, when the application framework layer receives a related event or message of a startActivity interface, it is determined that the application currently needs to be started from the background into the first window in the foreground.

2. The communication terminal of claim 1, wherein, the processor is further configured to: after displaying the user interface of the application in the first window, in response to a user operation of switching between a horizontal screen and a vertical screen, the layout of the at least two windows is adjusted, the user interface in the first window is redrawn, and the layout of interface elements in the user interface in the first window is adapted to the size of the first window.

3. The communication terminal of claim 1, wherein, the processor is further configured to: when determining whether the application needs to be displayed in a non-full screen window according to a request of the application for obtaining a default display window size, it is determined whether the application needs to be displayed in a non-full screen window according to first attribute information; wherein, the first attribute information is used to indicate the package name of the application started into the first window, and the first attribute information is created when the first window is created.

4. The communication terminal of claim 3, wherein, the processor is further configured to: when obtaining the size of the first window, the size of the first window is obtained according to second attribute information; wherein, the second attribute information is used to indicate the size of the first window, and the second attribute information is created when the first window is created.

5. A display method in a multi-window mode, characterized by, The application comprises: In response to a user operation of starting an application in a first window or starting a background running application into the first window, displaying a user interface of the application in the first window, and causing an interface element layout of the user interface to be adapted to a size of the first window; Before displaying the user interface of the application in the first window, further comprising: According to a request of the application for obtaining a default display window size, determining whether the application needs to be displayed in a non-full screen window; if it is determined that the application needs to be displayed in a non-full screen window, obtaining the size of the first window, the first window being a target window for displaying the application, otherwise obtaining a default display window size; wherein, when the application calls an interface for obtaining a window size, causing an application framework layer to obtain the size of a window for displaying the application; notifying the application of the obtained window size, and causing the application to design a layout of interface elements in a user interface according to the window size, to obtain display parameters of the user interface; Further comprising: In response to a user operation of starting a background running application into the first window, notifying the application to switch between a landscape mode and a portrait mode, causing the application to obtain the size of the first window, and setting a layout of interface elements in a user interface according to the size of the first window; wherein, when an application framework layer receives a related event or message of a start activity interface, it is determined that the application currently needs to be started into the first window in a foreground.

6. A computer storage medium, characterized in that The computer storage medium stores computer program instructions, and when the instructions run on a computer, the computer executes the method in claim 5.

Citation Information

Patent Citations

  • Split screen display method and device of terminal screen, and terminal

    CN106126027A

  • Picture-in-picture display method and display equipment

    CN110659010A

  • Portable information terminal

    JP1999345042A

  • Keyboard processing method and terminal

    CN106227458A

  • Interface drawing method, mobile terminal and readable storage medium of computer

    CN107168712A