A window interaction method and related device
Patent Information
- Application Number
- CN202510580367.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-04-30
- Publication Date
- 2026-10-30
AI Technical Summary
[0003]现有的位移、缩放、透明度组合虽然经典,但已在各类设备中广泛使用,缺少特殊亮眼点,难以给用户带来新鲜感
Smart Images

Figure CN123011386A_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of terminal technology, and in particular to a window interaction method and related apparatus. Background Technology
[0002] In modern graphical user interfaces, electronic devices typically display browser content or application elements in the form of windows. Therefore, minimizing and restoring windows are extremely frequent scenarios in user interaction and are an important part of the user experience. Currently, the animation effects for minimizing or restoring windows are usually achieved through a combination of techniques including window displacement, scaling, and transparency adjustment.
[0003] While the existing combination of displacement, scaling, and transparency is classic, it has been widely used in various devices and lacks any special highlights, making it difficult to bring users a sense of novelty.
[0004] Therefore, for the two extremely frequent scenarios of minimizing and restoring windows in the system, it is worthwhile to consider how to create key feature animations to increase playability and window interactivity, thereby enhancing product competitiveness. Summary of the Invention
[0005] This application provides a window interaction method and related apparatus. In this method, an electronic device can display a novel window minimization animation. This animation allows the electronic device to set the window's minimization path to a curve. During minimization, the window can undergo non-linear deformation and a blur effect can be superimposed to create a sense of movement. During window restoration, the electronic device can reverse the minimization animation and redisplay the window. Based on this window interaction method, the playability and interactivity of electronic device windows can be increased, improving the user experience.
[0006] In a first aspect, this application provides a window interaction method applied to an electronic device. The method includes: displaying a first window at a first position on the screen of the electronic device; detecting an operation to minimize the first window; responding to the operation to minimize the first window, performing a minimization of the first window, and playing a first animation effect during the minimization process; wherein the first animation effect is used to present the process of the first window gradually moving from the first position to a second position, and the first window gradually shrinking until it disappears; the path of the first window's movement is a first curved path; the change in the movement speed of each position on the first window is non-linear, and during this process, the first window undergoes a first deformation, the bending direction of the first window being close to or the same as the bending direction of the first curve; during this process, part or all of the first window is blurred.
[0007] In this way, the electronic device can move the window along a curved path when it is minimized, and perform non-linear deformation on the window during the movement to give the window a falling motion effect. At the same time, a blur effect is superimposed on the window to enhance the window's motion characteristics, increase the window's interactivity and playability, reflect the unique design concept of the electronic device, improve the user experience, and thus enhance the competitiveness of the electronic device.
[0008] In conjunction with the first aspect, during this process, the movement speed of the first window gradually increases and then gradually decreases.
[0009] Electronic devices can enhance the motion characteristics of the first window by controlling its speed, making it accelerate first and then slow down, thereby improving the user's viewing experience.
[0010] In conjunction with the first aspect, during this process, part or all of the first window is blurred, specifically including: the area in the first window that is farther away from the second position is more blurred than the area that is closer to the second position.
[0011] The blurring effect of the first window superimposed on the electronic device can be gradual, with the blurring degree of the part farther away from the moving target position being less than that of the part closer to the moving target position. This can increase the visual realism and sense of motion during the movement of the first window, thereby improving the user's interactive experience.
[0012] In conjunction with the first aspect, after minimizing the first window and playing the first animation during the minimization process, the method further includes: restoring the first window and reversing the first animation during the restoration process.
[0013] After a window is minimized, the electronic device can reverse the window minimization process to restore the window. This allows the window restoration process to also have a curved path and deformation, and can also increase the logic of the window interaction process, thereby improving the user experience.
[0014] In conjunction with the first aspect, the method further includes: displaying a first control at the second location, the first control being a desktop icon of the first window; the second location being located at the edge of the screen of the electronic device.
[0015] Electronic devices can display the icon control corresponding to the window, and the second position is located near the corresponding icon control. This allows the overall animation of the window moving towards the icon control during the minimization process, enabling users to visually perceive which icon control corresponds to the minimized window, so as to restore or perform subsequent operations, thus optimizing the user experience.
[0016] In conjunction with the first aspect, the first window includes the following deformation points: the four vertices of the first window, and N equally divided points on each edge of the first window; the first curve path includes the curve path of each deformation point; the method further includes:
[0017] For the first time, the progress of each deformation point on its respective curve path is calculated. Based on the progress, the position of each deformation point on its respective curve path is calculated. Based on the position of each deformation point at the first time, the first deformation of the first window at the first time is determined.
[0018] Wherein, the progress is the ordinate of the first position point on the second Bézier curve, and the abscissa of the first position point on the second Bézier curve is the first time; the second Bézier curve is drawn with (0,0) as the starting point, (1,1) as the ending point, and (X,1) and (X,0) as control points; X is greater than 0 and less than 1; 1 on the abscissa of the second Bézier curve is used to represent the entire movement time of the deformation point; 1 on the ordinate is used to represent the entire movement distance of the deformation point on its respective curve path.
[0019] Electronic devices can move and deform windows by setting deformation points on the window and calculating the movement path and speed of these points based on Bézier curves. This allows electronic devices to set curved paths and perform non-linear deformations on windows, adding new animation effects to the window minimization process and thus improving the user experience.
[0020] In conjunction with the first aspect, the control points of the Bézier curve corresponding to the curve path of the N equally divided points are obtained by interpolation of the control points of the Bézier curve corresponding to the curve path of the vertex.
[0021] In this way, electronic devices can obtain the paths of other deformation points through the paths of the window vertices, making the overall movement path of the window more coordinated and ensuring the user's visual experience.
[0022] In conjunction with the first aspect, the control points of the Bézier curve corresponding to the curve path of the vertex are determined based on the position of the vertex on the screen and the size of the first window.
[0023] For different locations and window sizes, electronic devices can set different movement paths for windows, making the minimize animation more match the window size and position, making the minimize animation more visually reasonable, and improving the user experience.
[0024] In conjunction with the first aspect, the second position is located in the first half of the screen of the electronic device, and the protrusion of the first curved path faces the first half of the screen.
[0025] Based on the different endpoints of the minimize animation, electronic devices can be configured with different minimize paths. For example, if the second position is located in the left half of the screen, the minimize curve path can curve to the left; if the second position is located in the right half of the screen, the minimize curve path can curve to the right. This allows the minimize animation to have a symmetrical effect, enhancing the user's perception of the minimize animation and improving the user experience.
[0026] In conjunction with the first aspect, the starting point of the curve path of each deformation point is the position of each deformation point, and the ending point of the curve path of each deformation point is the second position.
[0027] In conjunction with the first aspect, the endpoints of the curve paths of each deformation point are distributed near the second position. "Near" means that any endpoint of the curve path of each deformation point is no more than the first distance from the second position.
[0028] When an electronic device minimizes a window, the endpoint of the window's movement can be a point or an area. For example, at the end of the first window minimization process, the first window can disappear after being squeezed into a point, or it can disappear after transforming into a smaller rectangle. This can enrich the types of window minimization animations on electronic devices and enhance the user experience.
[0029] In a second aspect, this application provides an electronic device comprising: a processor and a memory coupled to the processor, the memory being used to store computer program code including computer instructions, wherein when the processor reads the computer instructions from the memory, the electronic device causes the electronic device to perform the method described in the first aspect.
[0030] Thirdly, this application provides a chip system applied to an electronic device, the chip system including one or more processors, the processors being used to invoke computer instructions to cause the execution of the methods described in the first aspect.
[0031] Fourthly, this application provides a computer-readable storage medium including a computer program that, when run on an electronic device, causes the electronic device to perform the method described in the first aspect.
[0032] Fifthly, this application provides a computer program product that, when run on a computer, causes the electronic device to perform the method described in the first aspect. Attached Figure Description
[0033] Figure 1This is a schematic diagram illustrating a scenario where an electronic device minimizes its window, as provided in an embodiment of this application.
[0034] Figure 2 This is a schematic diagram of the software architecture of an electronic device 100 provided in an embodiment of this application;
[0035] Figure 3 This is a schematic diagram of the software architecture of another electronic device 100 provided in an embodiment of this application;
[0036] Figure 4 This is a flowchart illustrating the window interaction method provided in an embodiment of this application;
[0037] Figure 5 This is a schematic diagram of a window minimization animation provided in an embodiment of this application;
[0038] Figure 6 This is a schematic diagram of a window blur effect provided in an embodiment of this application;
[0039] Figure 7 This is a schematic diagram of a scenario where an electronic device 100 minimizes a window, as provided in an embodiment of this application.
[0040] Figure 8 This is a schematic diagram of a scenario where another electronic device 100, according to an embodiment of this application, minimizes a window;
[0041] Figure 9A This is another schematic diagram of a window minimization animation provided in an embodiment of this application;
[0042] Figure 9B This is another schematic diagram of a window minimization animation provided in an embodiment of this application;
[0043] Figure 10 This is a schematic diagram illustrating the steps of drawing window interactive animation effects in the electronic device 100 provided in this application embodiment;
[0044] Figure 11 This is a schematic diagram of setting window deformation points in an electronic device 100 according to an embodiment of this application;
[0045] Figure 12A This is a schematic diagram of a Bézier curve provided in an embodiment of this application;
[0046] Figure 12B This is a schematic diagram illustrating the variation of a Bézier curve provided in an embodiment of this application;
[0047] Figure 13A This is a schematic diagram illustrating how an electronic device 100 calculates the movement path of a deformation point according to an embodiment of this application.
[0048] Figure 13BThis is a schematic diagram of a deformation point movement path provided in an embodiment of this application;
[0049] Figure 14 This is a schematic diagram illustrating the movement progress of a deformation point according to an embodiment of this application;
[0050] Figure 15A This is a schematic diagram of the time progress curve relationship of a deformation point provided in an embodiment of this application;
[0051] Figure 15B This is a schematic diagram of the time progress curve relationship of another deformation point provided in an embodiment of this application;
[0052] Figure 16 This is a schematic diagram of the hardware structure of the electronic device 100 provided in the embodiments of this application. Detailed Implementation
[0053] The technical solutions of the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of this application, not all embodiments. Based on the embodiments of this application, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of this application.
[0054] The terminology used in the following embodiments of this application is for the purpose of describing particular embodiments only and is not intended to be limiting of this application. As used in the specification and appended claims of this application, the singular expressions “a,” “an,” “the,” “the,” “the,” and “this” are intended to include the plural expressions as well, unless the context clearly indicates otherwise. The terms “first” and “second” are used for descriptive purposes only and should not be construed as implying 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. “First” and “second,” etc., are used to distinguish different objects, not to describe a particular order of objects. For example, a first object and a second object are used to distinguish different objects, not to describe a particular order of objects.
[0055] In the description of the embodiments in this application, unless otherwise stated, "multiple" means two or more. For example, multiple processing units refer to two or more processing units; multiple systems refer to two or more systems.
[0056] In the embodiments of this application, the terms "exemplary" or "for example" are used to indicate that something is an example, illustration, or description. Any embodiment or related scheme described as "exemplary" or "for example" in the embodiments of this application should not be construed as being more preferred or advantageous than other embodiments or design schemes. Specifically, the use of the terms "exemplary" or "for example" is intended to present the relevant concepts in a specific manner.
[0057] The term "and / or" in this application is merely a description of the relationship between related objects, indicating that three relationships can exist. For example, A and / or B can represent three cases: A existing alone, A and B existing simultaneously, and B existing alone.
[0058] In this application embodiment, the electronic device 100 may include, but is not limited to, devices such as computers, mobile phones, tablet computers, and smartwatches. This application embodiment does not limit the specific form or type of the electronic device 100.
[0059] The term "user interface (UI)" used in the following embodiments of this application refers to the medium interface through which an application or operating system interacts and exchanges information with the user. It realizes the conversion between the internal form of information and the form that the user can accept. The user interface is source code written in a specific computer language such as Java or Extensible Markup Language (XML). The interface source code is parsed and rendered on the electronic device, ultimately presenting content that the user can recognize. A common form of user interface is the graphical user interface (GUI), which refers to a user interface related to computer operation displayed graphically. It can be visible interface elements such as text, icons, buttons, menus, tabs, text boxes, dialog boxes, status bars, navigation bars, and widgets displayed on the screen of an electronic device.
[0060] In some embodiments, the minimize or restore animation of a window on an electronic device can be achieved through window displacement, scaling, and transparency adjustment. When a user triggers a minimize operation, the electronic device can control the window to smoothly move along a preset path to a corner of the taskbar or screen, giving the user the visual experience of the window "disappearing." During the displacement, the window can gradually shrink, simulating the visual effect of the window "shrinking" to the taskbar icon, enhancing the intuitiveness of minimizing. As the window is moved and scaled, the electronic device can also control the window's transparency to gradually decrease until it is completely invisible, further strengthening the "disappearing" animation effect. For example, taking a personal computer (PC) as an example, the electronic device can display a browser window, which can be referred to... Figure 1 , Figure 1 An illustrative diagram of an electronic device minimizing a window is shown.
[0061] like Figure 1 As shown, the electronic device can display a user interface 100A, which can be referred to as the desktop of the electronic device. The user interface 100A can include a window 101, which can be a browser window. The window 101 can include a control 101a, which can be used to trigger the electronic device to minimize the window 101. During the process of minimizing the window 101, intermediate windows 102 and 103 can be displayed sequentially according to the minimization progress.
[0062] Intermediate windows 102 and 103 can be used to characterize the window state at a certain moment during the process of minimizing window 101 in an electronic device.
[0063] Depend on Figure 1 It can be seen that the overall position of the window gradually shifts downwards from window 101 to the middle window 102, and then to the middle window 103. Furthermore, the size of the middle window 102 is smaller than that of window 101, and the transparency of the middle window 102 is greater than that of window 101. The size of the middle window 103 is smaller than that of the middle window 102, and the transparency of the middle window is greater than that of the middle window 102. Therefore, when the electronic device minimizes a window, it can move the window, reduce its size, and increase its transparency, ultimately causing the window to disappear near the program icon 104, which could be the icon corresponding to a browser. When the electronic device is running a browser program, it can display the program icon 104 in the taskbar 105. After the electronic device minimizes window 101, in response to a click on the program icon 104, it can restore window 101. During the process of restoring window 101, the middle window 103, the middle window 102, and window 101 can be displayed sequentially. That is, the electronic device can gradually move the window from the vicinity of the program icon 104 to the position of window 101, and in this process, increase the size of the window and decrease its transparency. It is understandable that the process of minimizing window 101 and the process of restoring window 101 of the electronic device can be considered as "reverse" processes.
[0064] This combination of displacement, scaling, and transparency techniques improves the user interface's friendliness and interactive experience to some extent, allowing users to intuitively feel the interaction with the window, but overall it still seems rather conventional and lacks innovation.
[0065] To enhance the playability and window interactivity of electronic devices and embody unique design concepts, this application provides a window interaction method by using key feature animations to improve product competitiveness. This method can be applied to the electronic device 100 provided in this application. For the two high-frequency interaction scenarios of window minimization and window restoration in the electronic device 100 system, special animation effects are set for the interaction process. Non-linear scaling animations of windows or window-like elements are implemented, and dynamic foreground overlay effects are added during the animation process. This makes the window minimization or restoration process in the electronic device 100 unique and visually appealing, improving the user experience.
[0066] The software structure of the electronic device 100 provided in the embodiments of this application will be introduced first below.
[0067] The electronic device 100 provided in this application embodiment can run an operating system (OS). This operating system can be various operating systems used in industry, such as an operating system based on OpenHarmony, like HarmonyOS; or other operating systems such as Android. TM An operating system can refer to the iOS mobile operating system; it can also refer to various open-source operating systems or their derivatives, such as Linux OS and other embedded operating systems; or it can refer to future new operating systems, such as AI operating systems based on artificial intelligence. An operating system is a set of interconnected system software programs that manage and control the operation of electronic devices, utilize and run hardware and software resources, and provide public services to organize user interactions. In electronic devices, the operating system connects downwards to the physical devices at the hardware layer and upwards to provide a runtime environment for application software.
[0068] An operating system typically includes a kernel layer, a middleware layer, and an application layer. The application layer includes applications, which can include system applications and third-party applications. The middleware layer includes a suite of software providing various services to application developers, or frameworks providing services such as databases, multimedia, and graphics, or capabilities such as distributed scheduling and system scaling. For example, the middleware layer may include a framework layer and / or a system service layer. The framework layer provides application programming interfaces (APIs) and programming frameworks for applications in the application layer. The system service layer includes the system's core capabilities, providing services to applications through the framework layer. The kernel layer is the layer between hardware and software. The kernel layer may include hardware drivers and the operating system kernel. In addition to providing hardware drivers, the kernel layer also supports functions such as memory management and system process management.
[0069] The electronic devices we use in our daily lives come in various types and forms, and are applied in a wide range of scenarios. Therefore, based on the different forms and functions of electronic devices, different application scenarios, and different user needs, the operating systems used in these devices may also differ. The basic functions implemented by the electronic device provided in this application can be implemented using a general-purpose operating system or a dedicated operating system. To more clearly illustrate the implementation of the embodiments of this application under a specific operating system, the architecture of HarmonyOS is shown below. Those skilled in the art can deduce the implementation of the embodiments of this application under other specific operating systems, such as Android™.
[0070] like Figure 2 As shown, in some embodiments, the software architecture of the electronic device 100, from bottom to top, consists of: a kernel layer, a system service layer, a framework layer, and an application layer. The layers communicate with each other through software interfaces. System functions can be tailored, added, or combined at the subsystem granularity in different device deployment scenarios, and each subsystem can also be tailored, added, or combined at the functional granularity.
[0071] kernel layer
[0072] The Kernel Abstraction Layer (KAL) provides basic kernel capabilities to upper layers by shielding the differences between multiple kernels, including but not limited to process / thread management, memory management, file system, network management, and peripheral device management.
[0073] Kernel Subsystem: Supports the selection of a suitable OS kernel for different resource-constrained devices, including but not limited to Linux kernel, HarmonyOS kernel, LiteOS (Lite Operating System), etc.
[0074] Driver Subsystem: The driver framework is the foundation for the open system hardware ecosystem, providing unified peripheral access capabilities and a framework for driver development and management. The driver framework includes: display drivers, camera drivers, audio drivers, Bluetooth drivers, sensor drivers, etc.
[0075] Optionally, such as Figure 3 As shown, the kernel layer of the electronic device 100 may also include a hardware display module, which can be used to call relevant hardware resources to display the window and the elements within the window when the electronic device 100 displays a window.
[0076] System service layer
[0077] The system service layer comprises the core capabilities of the system, providing services to applications through the framework layer. This layer includes, but is not limited to, the following subsystems:
[0078] The system's basic capability subsystem set provides fundamental capabilities for the operation, scheduling, and migration of distributed applications across multiple devices. This set may include distributed soft bus, distributed data management, distributed task scheduling, and Ark multi-language runtime; it may also include multi-modal input subsystem, graphics subsystem, security subsystem, and AI subsystem.
[0079] Basic software service subsystem set: provides public and general software services; the basic software service subsystem set may include event notification subsystem, telephone service subsystem, multimedia subsystem, etc.
[0080] Enhanced software service subsystem suite: Provides differentiated enhanced software services for different devices; the enhanced software service subsystem suite may include smart screen proprietary business subsystem, wearable proprietary business subsystem, IoT proprietary business subsystem, etc.
[0081] Hardware service subsystem set: Provides hardware services; the hardware service subsystem set may include location service subsystem, user IAM (Identity and Access Management) subsystem, wearable proprietary hardware service subsystem, biometric identification, IoT proprietary hardware service subsystem, etc.
[0082] Distributed task scheduling enables distributed service management (discovery, synchronization, registration, and invocation), supporting remote startup, remote invocation, remote connection, and migration of applications across devices.
[0083] Distributed data management enables data synchronization, data storage, data sharing, and data access across all scenarios and devices.
[0084] The distributed soft bus provides communication-related capabilities for seamless interconnection between multiple devices, including: WLAN service capabilities, Bluetooth service capabilities, soft bus, inter-process communication RPC (Remote Procedure Call), and StarFlash communication capabilities.
[0085] Ark Multilingual Runtime is a unified compilation runtime platform designed to support the joint compilation and execution of multiple programming languages and multiple chip platforms.
[0086] Optionally, such as Figure 3As shown, the system service layer of electronic device 100 may include modules such as a window management module, an activity management module, a window feature animation control module, and a graphics drawing library. The window management module can be used to control and manage window behavior. When electronic device 100 creates a new window, it can set the window's initial position, size, and display attributes. It can also ensure the correct rendering of the content within the window, such as text, images, and videos. Furthermore, it can respond to user actions by scaling or minimizing the window, and save the window's state before minimization, including its position, size, and content, to be restored when the window is reopened.
[0087] The activity management module can be used to monitor, schedule, and manage various activities and tasks on the electronic device 100. It can allocate necessary system resources such as memory, processor time, and input / output ports to activities. The activity manager can also provide a user interface, allowing users to view current activities, adjust activity settings, process user input, and perform activities such as minimizing or restoring windows.
[0088] The window feature animation control module can be used to manage the animation effects of windows. When the electronic device 100 performs activities such as minimizing or restoring a window, the corresponding feature animation effects of the window are displayed.
[0089] The graphics drawing library can be used to render the visual elements of a window onto the screen when the electronic device 100 displays a window. The electronic device 100 uses the graphics drawing library to process pixel drawing, ensuring that the window content is displayed correctly and clearly. During window minimization or restoration, the graphics drawing library can be used to draw smooth animation effects, such as scaling, gradation, and changes in transparency, making the window movement smooth.
[0090] In some embodiments, the graphics drawing library can also be used to draw effects that can be overlaid on a window, such as a frosted glass effect.
[0091] Framework layer
[0092] The framework layer provides application programming interfaces (APIs) and programming frameworks for applications in the application layer. The framework layer includes: the ArkUI framework (which provides a complete infrastructure for UI development of system applications, including UI functions such as components, layouts, animations, and interactive events, as well as a real-time interface preview tool), the user application framework, and the Ability framework (an Ability is a lightweight application; the Ability framework schedules and manages the operation and lifecycle of Abilities). Different devices may have different operating systems, and the APIs they support may also differ.
[0093] The HarmonyOS API is a series of open capabilities provided to support HarmonyOS application development. The HarmonyOS API can be set at the framework layer or independently of the framework layer. The HarmonyOS API includes the Audio API (audio service), Push API (push service), and Account API (account service), among others.
[0094] Application layer
[0095] Applications can include system apps and extended / third-party apps. System apps can include the desktop, control bar, settings, contacts, phone, camera, etc., while extended / third-party apps can include social apps, travel apps, etc.
[0096] Optionally, such as Figure 3 As shown, the application layer of electronic device 100 may include multiple applications such as Application 1 and Application 2. These applications can call various modules in the above-described software structure to implement the window display and window scaling animation effects for the application. In some embodiments, electronic device 100 can configure different animation effects for different applications. This application embodiment does not limit this.
[0097] Based on the software modules mentioned above, such as window management, activity management, window feature animation control, and graphics drawing library, the electronic device 100 can manage windows and window animations, and can call relevant hardware resources to apply the window interaction method provided in this application embodiment. The window interaction method provided in this application will now be described in conjunction with the accompanying drawings.
[0098] For reference Figure 4 , Figure 4 An exemplary flowchart of the window interaction method provided in an embodiment of this application is shown.
[0099] like Figure 4 As shown, the window interaction method may include the following steps.
[0100] S401. Electronic device 100 responds to user interaction with a window by displaying window animation.
[0101] In some embodiments, the electronic device 100 may display a window in the user interface. The window may be a program window, an application window, a window element within an application, or another small application window invoked within an application. The specific form of the window is not limited in the embodiments of this application.
[0102] For example, this interactive operation could be a window minimization operation, and the electronic device 100 could display a window minimization animation. For instance... Figure 5As shown, taking an electronic device 100 as a PC and a browser program window as an example, the electronic device 100 can display a user interface 100A, within which a window 101 is displayed. In response to a click on control 101a, the electronic device 100 begins to display a minimize animation of window 101. Figure 1 Unlike the basic minimization animations such as displacement, scaling, and transparency changes described in the previous article, the electronic device 100 can set special animations for the minimization process of window 101 based on the window interaction method of this application embodiment.
[0103] For reference Figure 5 In some embodiments, the electronic device 100 can configure non-linear animation effects for the minimization process of window 101. During the minimization process, the electronic device 100 can sequentially display intermediate windows such as intermediate window 501 and intermediate window 502, and finally make the window disappear at the endpoint 503, which can be a point above the program icon 104. The entire process can exhibit an animation effect of window 101 falling into or being sucked into the endpoint 503.
[0104] Depend on Figure 4 It can be seen that both intermediate windows 501 and 502 are obtained by nonlinearly deforming window 101. As the minimization process increases, the degree of deformation of the window outline also increases. That is, the degree of outline deformation of intermediate window 502 relative to window 101 can be higher than that of intermediate window 501 relative to window 101. The elements in intermediate windows 501 and 502 are the same as the elements in window 101, but both undergo corresponding degrees of deformation.
[0105] Understandable Figure 5 The minimization process shown is a continuous animation. Window 101 undergoes non-linear deformation and eventually minimizes and disappears at the endpoint 503. Intermediate windows 501 and 502 can be used to represent the window state at a certain moment in this minimization process. During this minimization process, the window outline deformation, the deformation of elements within the window, and the window's motion path can all be non-linear, thus demonstrating a more characteristic minimization animation.
[0106] Optionally, the interactive operation can also be a window restoration operation, in which case the window animation can be the window restoration animation of the electronic device 100.
[0107] S402. Electronic device 100 draws special effects superimposed on the window.
[0108] In some embodiments, during the window minimization process, the electronic device 100 may also overlay some special effects on the deformed window, thereby making the window minimization process more visually realistic and dynamic.
[0109] For example, the electronic device 100 can draw a blur effect during the window minimization process and overlay the blur effect on the window. This blur effect can accompany the window minimization process, and the electronic device 100 can adaptively adjust the coverage area of the effect according to the degree of window deformation. Figure 5 Taking the electronic device 100 displaying the middle window 502 as an example, at this moment, the electronic device 100 can overlay a blur layer 601 on the middle window 502. The blur layer 601 can cover the display area of the middle window 502. The blur layer 601 can give the middle window 502 an effect such as frosted glass, making the middle window 502 more dynamic and showing a dynamic effect of falling.
[0110] Optionally, the blur layer 601 may also have a gradient feature. In the blur layer 601, the area farther away from the endpoint 503 has a stronger blur effect, which can make the falling effect of the window more vivid and improve the user's interactive experience.
[0111] Optionally, the window interaction method provided in this application embodiment can also be applied to other scenarios, such as scenarios where tablets or mobile phones display application windows.
[0112] For example, such as Figure 7 As shown, Figure 7 The electronic device 100 shown can be a tablet computer, and it can display a window 701 and an application icon 702 on its desktop. Window 701 is the window of the application corresponding to the application icon 702. In some embodiments, in response to a click on the application icon 702, the electronic device 100 can display the application interface in window mode, i.e., display window 701. After receiving an operation to minimize window 701, the electronic device 100 can display a minimize animation effect for window 701, the specific effect of which can be referred to the above. Figure 5 and Figure 6 The description will not be repeated here. Finally, window 701 will disappear at endpoint 703 with a "falling" animation, which can be a point directly above the application icon 702. The approximate movement path of window 701 during minimization can be seen in path 704.
[0113] For example, such as Figure 8 As shown, Figure 8 The electronic device 100 shown can be a mobile phone. Figure 8In this device, electronic device 100 can display a user interface 801 and a window 802. The user interface 801 can be the user interface of application 1 within electronic device 100. While electronic device 100 displays user interface 801, it can respond to an operation of opening application 2 by displaying elements of application 2 in window 802. This operation of opening application 2 can include, but is not limited to: activating application 2 via a sidebar, clicking a link to application 2 within application 1, etc. Window 802 can include a control 803. In response to an operation on control 803, electronic device 100 can display a floating ball 804 and minimize window 802, eventually disappearing from the floating ball 804. The animation of the window 802 minimization process can also refer to the above description. Figure 5 and Figure 6 The description is as follows, but the direction of movement of window 802 can be slightly different. The minimization path of window 802 can be referenced as shown in path 805.
[0114] In the above process, regardless of the type of electronic device 100 or the type of window displayed, the electronic device 100 can make the window move along a non-linear path during the minimization process, highlighting the sense of movement and improving the user experience. In some embodiments, before minimizing the window, the electronic device 100 can first determine the endpoint of the window minimization process and then determine the minimization path. Different positions of the window minimization endpoint will affect the window minimization path. For example... Figure 5 The endpoint 503 and Figure 7 The endpoints 703 and 704 are both located in the bottom edge region of the electronic device 100. Therefore, the minimized path of window 101 and the minimized path of window 701 are similar, both being curved paths as shown in path 704. And as... Figure 8 As shown, the minimized endpoint of window 802 is located near the floating ball 804. When the floating ball 804 is located in the side area of electronic device 100, the minimized path of window 802 is different from path 704. It is a curved path pointing to the side, as shown in path 805.
[0115] Optionally, when the minimize endpoint is located on one side of the electronic device 100, the electronic device 100 can also set different minimize paths for the window depending on the half-area where the minimize endpoint is located on that side. For example, when the minimize endpoint is located in the bottom edge area of the electronic device 100, it can be compared... Figure 5 and Figure 9A For window 101, if program icon 104 is located in the bottom left half of the interface, the falling animation of window 101 will be applied to the left side of the interface. If program icon 104 is located in the bottom right half of the interface, the falling animation of window 101 will be applied to the right side of the interface. When the animation is applied to the right side, the minimized path of window 101 can be roughly referred to as path 901.
[0116] When the minimized endpoint is located in the side area of the electronic device 100, a comparison can be made. Figure 8 and Figure 9B The floating ball 804 serves as the minimized endpoint of window 802. If the floating ball 804 is located in the upper half of the side area, such as... Figure 8 As shown, the approximate path for minimizing window 802 is path 805. If the floating ball 804 is located in the lower half of the side area, as... Figure 9B As shown, the approximate path for minimizing window 802 is path 902.
[0117] It should be understood that when the electronic device 100 restores a window, it can be regarded as reversing the corresponding window minimization process. The path curve and path area of the window restoration process are the same as its corresponding minimization process, but the direction of movement is opposite.
[0118] The following section details the drawing process of window interaction animations in the window interaction method provided in this application. (See also...) Figure 10 , Figure 10 This is an exemplary schematic diagram illustrating the steps of drawing window interactive animation effects on an electronic device 100.
[0119] like Figure 10 As shown, drawing the interactive animation effects of this window can include the following steps.
[0120] S1001. Upon receiving the user's minimized window operation, determine the deformation point of the window.
[0121] During the process of minimizing a window, the electronic device 100 moves and deforms the window. The window movement path can be a curve, and the window deformation can be a non-linear deformation. In some embodiments, the electronic device 100 can determine the window movement path and the window deformation method by identifying the deformation points of the window and moving the deformation points.
[0122] For example, such as Figure 11 As shown, Figure 11 A schematic diagram of window deformation points is illustrated. Taking window 101 as an example, electronic device 100 can set deformation points on the vertices and edges of window 101. For example, electronic device 100 can use the four vertices of window 101 as deformation points, such as deformation point 1101, deformation point 1102, deformation point 1103, and deformation point 1104. Electronic device 100 can also use two trisection points on each edge of window 101 as deformation points, such as deformation point 1105, deformation point 1106, deformation point 1107, deformation point 1108, deformation point 1109, deformation point 1110, deformation point 1111, and deformation point 1112.
[0123] Before the window is minimized, the electronic device 100 can determine the overall movement path of the window 101 by setting the movement path of these deformation points.
[0124] In some embodiments, after receiving a minimize window operation, the electronic device 100 can also determine the endpoint of the window minimization, i.e., the endpoint of the movement of window 101. For example, the electronic device 100 can use endpoint 503 as the endpoint of minimizing window 101. When the window is minimized, the electronic device 100 can display an animation of moving the window to endpoint 503.
[0125] S1002. Determine the movement path of the deformation point at the vertex of the window.
[0126] After determining the deformation point of window 101, electronic device 100 can calculate the movement path of the deformation point, move the deformation point along a curved path, and thus realize the movement of the overall outline of the window. For Figure 11 As shown in the diagram, since the four vertices provide the most comprehensive coverage of window 101, the electronic device 100 can first determine the movement path of the deformation points at the four vertices of window 101.
[0127] In some embodiments, the electronic device 100 can calculate the movement path of the deformation point using a Bézier curve. A Bézier curve is a smooth curve that can be drawn based on the coordinates of multiple arbitrary points. Taking a third-order Bézier curve as an example, the points used to determine the shape of the third-order Bézier curve can include four. Figure 12A As shown, for Bézier curve 1201, the points that determine its shape can include a start point, an end point, control point 1, and control point 2. These points are used to control the direction of Bézier curve 1201 from the start point towards control point 1, and from control point 2 towards the end point. Bézier curves generally do not pass through control points 1 or 2; these two control points only provide information about the curve's direction at their respective locations, used to determine the curve's curvature. The distance between the start point and control point 1 determines how long the curve travels towards control point 2 before turning towards the end point.
[0128] For the same starting and ending points, changing the positions of control points 1 and 2 will affect the shape of the curve. For example... Figure 12BAs shown, after the positions of control points 1 and 2 change, the shape of Bézier curve 1201 changes to Bézier curve 1202. The mathematical expression for a cubic Bézier curve is as follows: B(t) = (1-t)³ * P0 + 3t(1-t)² * P1 + 3t²(1-t) * P2 + t³ * P3. Here, P0 can represent the starting point, P1 represents control point 1, P2 represents control point 2, and P3 represents the ending point. After the electronic device 100 determines the positions of the four points, it can determine the Bézier curve B(t) represented by these four points, where t is a parameter ranging from 0 to 1. This t can be used to represent the progress, that is, the ratio of the distance traveled by a point from the starting point to the ending point on the Bézier curve to the length of the Bézier curve. For any point at any progress, the position of the point can be determined by the starting point, the ending point, control point 1, and control point 2, thus forming a Bézier curve from the points at each progress.
[0129] Based on this, when determining the movement path of the vertex deformation points, the electronic device 100 considers each vertex deformation point—namely, deformation points 1101, 1102, 1103, and 1104—as its own starting point for its respective Bézier curve, while the ending point 503 can serve as the ending point for all Bézier curves. Therefore, the electronic device 100 also needs to determine two control points for each deformation point to define the Bézier curve path for each vertex.
[0130] For the Bézier curve at the vertex of window 101, electronic device 100 can determine the position of the control point of the curve by combining the position of the vertex and the size of window 101, thereby determining the shape of the curve.
[0131] For example, taking the top left vertex of window 101: deformation point 1101 as an example, the process of electronic device 100 determining control points is described.
[0132] like Figure 13AAs shown, the electronic device 100 can first determine the size of the window 101, denoted as W for width and H for height. Then, the electronic device 100 can determine the positional relationship between the deformation point 1101 and the center point of the bottom edge. The center point of the bottom edge can be the endpoint of the horizontal line where the endpoint 503 is located, or it can be the center point of the edge of the screen of the electronic device 100; this embodiment does not limit the determination. Taking the center point 1301 on the same horizontal line as the endpoint 503 as an example, the electronic device 100 can determine the distance between the deformation point 1101 and the center point 1301 on the horizontal and vertical coordinates. In some examples, the electronic device 100 can establish a rectangular coordinate system with the center point 1301 as the origin, with the vertical axis 1302 passing through the center point 1301 as the y-axis and the horizontal axis 1303 passing through the center point 1301 as the x-axis. Then, the electronic device 100 can determine the distance Δx of the deformation point 1101 with respect to the vertical axis 1302 and the distance Δy with respect to the horizontal axis 1303.
[0133] After determining the above data, the electronic device 100 can calculate the two control points corresponding to the movement path of the deformation point 1101 based on the first type of parameter relationship. For example, the electronic device 100 can use (-0.4W-Δx, 0.4H+0.4+Δy) as the coordinates of the first control point and (-0.3W, -0.4Δy) as the coordinates of the second control point. Thus, based on these two control points, as well as the deformation point 1101 and the endpoint 503, the electronic device 100 can draw a Bézier curve corresponding to the deformation point 1101. This curve represents the movement path of the deformation point 1101 in the minimized animation of window 101. The parameters for calculating the curve control points of the deformation point 1101 can be stored in the electronic device 100 by the developer. The calculation parameters for the curve control points of each vertex can be shown in the table below.
[0134] Deformation point Control Point 1 Control Point 2 1101 (Point A) (-0.4W-Δx, 0.4H+0.4+Δy) (-0.3W, -0.4Δy) 1102 (Point B) (-0.3W-Δx, 0.4Δy) (-0.15W, -0.4Δy) 1103 (Point C) (-0.7W-Δx, 0.3H) (-0.45W-Δx, -0.6Δy) 1104 (Point D) (-0.8W-Δx, -0.1H) (-0.3W, -0.4Δy)
[0135] Based on the parameter relationships shown in the table above, electronic device 100 can calculate the control point coordinates of each vertex, and then determine the movement curve of each vertex using the corresponding control points. These parameters can all be called first-class parameters, which can be pre-stored in electronic device 100 by the developers.
[0136] like Figure 13B As shown, for each vertex of window 101, electronic device 100 can use the above-described... Figure 13A The calculation is performed as shown, resulting in curve 1304 for deformation point 1101, curve 1305 for deformation point 1102, curve 1306 for deformation point 1103, and curve 1307 for deformation point 1104. In the minimized motion effect, each vertex deformation point can move along its respective curve.
[0137] S1003. Based on the movement path of the deformation point at the vertex, determine the movement path of the remaining deformation points.
[0138] After calculating the curve control points of the vertex deformation points, the electronic device 100 can perform interpolation calculations based on the control points of each vertex deformation point to obtain the curve control points corresponding to each trisection point. It should be understood that, for the convenience of subsequent description, in the table above, deformation point 1101 is referred to as point A, deformation point 1102 as point B, deformation point 1103 as point C, and deformation point 1104 as point D.
[0139] The calculation parameters for the curve control points of the remaining deformation points can be found in the table below.
[0140] Deformation point Control Point 1 Control Point 2 1103 0.67A + 0.33B 0.67A + 0.33B 1104 0.33A + 0.67B 0.33A + 0.67B 1105 0.67C + 0.33D 0.67C + 0.33D 1106 0.33C + 0.67D 0.33C + 0.67D 1107 0.67A + 0.33C 0.67A + 0.33C 1108 0.33A + 0.67C 0.33A + 0.67C 1109 0.67B + 0.33D 0.67B + 0.33D 1110 0.33B + 0.67D 0.33B + 0.67D
[0141] Taking control point 1 corresponding to deformation point 1103 as an example, 0.67A+0.33B means that the coordinates of the control point are obtained by adding the coordinates of point A * 0.67 and the coordinates of point B * 0.33.
[0142] In this way, the electronic device 100 calculates the control points of all deformation points set in step S1001, and can obtain the Bézier curve movement path of all deformation points.
[0143] S1004. Calculate the movement progress of the deformation point on the movement path, and move the deformation point according to the progress.
[0144] After determining the movement path of the deformation point, the electronic device 100 can move the deformation point, and the movement speed of the deformation point on the path can be calculated by the electronic device 100 using the second type of parameters.
[0145] For example, the electronic device 100 can first calculate the change in the moving speed of the two vertex deformation points of the window 101, and then determine the change in the moving speed of the remaining deformation points through interpolation calculation.
[0146] In some embodiments, the electronic device 100 can calculate the relationship between the movement time of the deformation point and the progress of the deformation point's movement to determine the speed of the deformation point at each position on the movement path. For example... Figure 14 As shown, taking deformation point 1103 as an example, the movement progress of deformation point 1103 can be understood as the ratio between the path L1 that deformation point 1103 has traveled on curve 1306 and the total path length L2 of curve 1306. That is, for the parametric B(t) of Bézier curve 1306, t can be understood as L1 / L2.
[0147] Based on this, in some examples, the electronic device 100 can calculate the relationship between the progress and time of each deformation point, determine the position of the deformation point on its corresponding movement curve at each moment during the motion time, and thus determine the speed change law of the deformation point during the movement.
[0148] First, the electronic device 100 can determine the progress / time relationship between the two vertex deformation points.
[0149] like Figure 15A As shown, for deformation point 1103, electronic device 100 can establish a coordinate system in which (0, 0) is the starting point, (1, 1) is the ending point, and (0.5, 0) and (0.5, 1) are the control points to draw a Bézier curve 1501. The horizontal axis of this coordinate system can be regarded as the time of movement of deformation point 1103, and the 1 on the horizontal axis can represent the total time of movement of deformation point 1103 on curve 1306. The vertical axis of this coordinate system can be regarded as the progress of movement of deformation point 1103, and the 1 on the vertical axis can be used to represent the progress of deformation point 1103 in moving to the end point of curve 1306. Based on this, electronic device 100 can determine that the relationship between the progress of movement of deformation point 1103 on curve 1306 and time satisfies the relationship shown in curve 1501. Electronic device 100 can then proceed according to... Figure 15A The progress / time relationship shown is shifted at point 1103.
[0150] The electronic device 100 can also select the vertex diagonally opposite the deformation point 1103, deformation point 1102, and calculate the progress / time relationship during the movement of deformation point 1102. For example... Figure 15B As shown, the electronic device 100 can determine the shape of the Bézier curve 1502 in the coordinate system with (0,0), (0.2,0), (0.2,1) and (1,1), and set the progress / time curve of the deformation point 1102 during the movement process as shown by the Bézier curve 1502, thereby determining the rules for moving the deformation point 1102.
[0151] After obtaining Bézier curves 1501 and 1502, which characterize the progress / time relationship between deformation points 1102 and 1103, the electronic device 100 can perform interpolation calculations based on the control points of Bézier curves 1501 and 1502, using the second type of parameters, to determine the control points of the Bézier curves corresponding to the progress / time relationship of other deformation points. The calculation method is shown in the table below.
[0152] Deformation point Bézier curve control points for progress / time relationship 1103 (Point C) (0.5,0,)、(0.5,1) 1102 (Point B) (0.2,0)、(0.2,1) 1101 0.5B+0.5C 1104 0.5B+0.5C 1105 0.67B + 0.33C 1106 0.83B + 0.17C 1107 0.17B + 0.83C 1108 0.33B + 0.67C 1109 0.33B + 0.67C 1110 0.17B + 0.83C 1111 0.83B + 0.17C 1112 0.67B + 0.33C
[0153] Taking deformation point 1101 as an example, 0.5B+0.5C represents the positions of the two control points of the movement progress / time relationship curve of deformation point 1101, which are (0.5,0)*0.5+(0.2,0)*0.5 and (0.5,1)*0.5+(0.2,1)*0.5, respectively, i.e., (0.35,0) and (0.35,1). The movement progress / time relationship curve of deformation point 1101 satisfies the Bézier curve determined by (0,0), (0.35,0), (0.35,1), and (1,1). The calculation method for other deformation points is similar and will not be repeated here.
[0154] Based on this, the electronic device 100 determines the movement curves and movement progress / time relationships of all deformation points. The electronic device 100 can move the deformation points from their respective positions to the endpoint 503 in this manner.
[0155] Optionally, for each deformation point, the electronic device 100 may set the time it takes to move from its own position to the endpoint 503 to be the same, for example, 800ms.
[0156] S1005. Connect the deformation points during the movement and draw the deformation window during the movement.
[0157] In some examples, during the movement of deformation points, at any given moment, the electronic device 100 can perform curve fitting based on the current positions of the four deformation points that originally belonged to the same edge of the window 101, thereby obtaining a closed figure composed of four curves. Based on the shape relationship between this closed figure and the window 101, the electronic device 100 adaptively stretches the internal elements of the window 101 and fills them into the closed figure, thus obtaining the window that has deformed at each moment during the minimization process.
[0158] In other embodiments, the electronic device 100 may also draw a Bézier curve based on the four deformation points that originally belonged to the same edge of the window 101 after the movement, using two of the vertices as the start and end points and two of the trisection points as control points. The drawn Bézier curve is used as the outline of the window that has deformed during the minimization process to obtain a closed shape. Then, the internal elements of the window 101 are adaptively stretched and filled into the closed shape to obtain the window that has deformed during the minimization process.
[0159] The electronic device 100 can calculate the window's outline deformation at each moment during the minimization process using the method described above, and adaptively stretch the elements within the window to obtain a complete window minimization animation. This animation is then displayed when the window is minimized.
[0160] S1006. After minimizing the window, in response to the window restore operation, the minimization process is played in reverse.
[0161] After the window is minimized, the electronic device 100 no longer displays the window, but it can still display the corresponding icon controls, such as the program icon 104, application icon 702, and floating ball 804. In response to a click on an icon control, the electronic device 100 can restore the window. During the restoration process, the electronic device 100 can reverse the minimize animation; after the reversal, the window will be displayed in its state before minimization.
[0162] Based on the aforementioned window interaction method, electronic devices can display a novel window minimization animation. In this animation, the minimization path can be set to a curve, and the window can undergo non-linear deformation during minimization, with a blur effect superimposed to create a sense of motion. Conversely, during window restoration, the animation can be reversed and the window redisplayed. This increases the playability and interactivity of the electronic device's windows, enhancing the user experience.
[0163] Finally, the hardware structure of the exemplary electronic device 100 provided in the embodiments of this application is described. Figure 16 An exemplary schematic diagram of the hardware structure of the electronic device 100 provided in an embodiment of this application is shown.
[0164] It should be understood that the electronic device 100 may have more or fewer components than shown in the figure, may combine two or more components, or may have different component configurations. The various components shown in the figure may be implemented in hardware, software, or a combination of hardware and software, including one or more signal processing and / or application-specific integrated circuits.
[0165] Electronic device 100 may include: processor 110, external memory interface 120, internal memory 121, universal serial bus (USB) interface 130, charging management module 140, power management module 141, battery 142, antenna 1, antenna 2, mobile communication module 150, wireless communication module 160, audio module 170, speaker 170A, receiver 170B, microphone 170C, headphone jack 170D, sensor module 180, button 190, motor 191, indicator 192, camera 193, display screen 194, and subscriber identification module (SIM) card interface 195, etc. The sensor module 180 may include a pressure sensor 180A, a gyroscope sensor 180B, a barometric pressure sensor 180C, a magnetic sensor 180D, an accelerometer sensor 180E, a distance sensor 180F, a proximity sensor 180G, a fingerprint sensor 180H, a temperature sensor 180J, a touch sensor 180K, an ambient light sensor 180L, a bone conduction sensor 180M, etc.
[0166] Processor 110 may include one or more processing units, such as: application processor (AP), modem processor, graphics processing unit (GPU), image signal processor (ISP), controller, memory, video codec, digital signal processor (DSP), baseband processor, and / or neural network processing unit (NPU), etc. Different processing units may be independent devices or integrated into one or more processors.
[0167] The controller can be the nerve center and command center of the electronic device 100. The controller can generate operation control signals according to the instruction opcode and timing signals to complete the control of fetching and executing instructions.
[0168] The processor 110 may also include a memory for storing instructions and data. In some embodiments, the memory in the processor 110 is a cache memory. This memory can store instructions or data that the processor 110 has just used or that are used repeatedly. If the processor 110 needs to use the instruction or data again, it can retrieve it directly from the memory. This avoids repeated accesses, reduces the waiting time of the processor 110, and thus improves the efficiency of the system.
[0169] In some embodiments, the processor 110 may include one or more interfaces. Interfaces may include an inter-integrated circuit (I2C) interface, an inter-integrated circuit sound (I2S) interface, a pulse code modulation (PCM) interface, a universal asynchronous receiver / transmitter (UART) interface, a mobile industry processor interface (MIPI), a general-purpose input / output (GPIO) interface, a subscriber identity module (SIM) interface, and / or a universal serial bus (USB) interface, etc.
[0170] The I2C interface is a bidirectional synchronous serial bus, including a serial data line (SDA) and a serial clock line (SCL). In some embodiments, the processor 110 may include multiple I2C buses. The processor 110 can couple to the touch sensor 180K, charger, flash, camera 193, etc., through different I2C bus interfaces. For example, the processor 110 can couple to the touch sensor 180K through the I2C interface, enabling the processor 110 and the touch sensor 180K to communicate through the I2C bus interface, thereby realizing the touch function of the electronic device 100.
[0171] The I2S interface can be used for audio communication. In some embodiments, the processor 110 may include multiple I2S buses. The processor 110 can be coupled to the audio module 170 via the I2S bus to enable communication between the processor 110 and the audio module 170. In some embodiments, the audio module 170 can transmit audio signals to the wireless communication module 160 via the I2S interface to enable the function of answering phone calls through a Bluetooth headset.
[0172] The PCM interface can also be used for audio communication, sampling, quantizing, and encoding analog signals. In some embodiments, the audio module 170 and the wireless communication module 160 can be coupled via the PCM bus interface. In some embodiments, the audio module 170 can also transmit audio signals to the wireless communication module 160 via the PCM interface, enabling the function of answering phone calls through a Bluetooth headset. Both the I2S interface and the PCM interface can be used for audio communication.
[0173] The UART interface is a universal serial data bus used for asynchronous communication. This bus can be a bidirectional communication bus. It converts the data to be transmitted between serial and parallel communication. In some embodiments, the UART interface is typically used to connect the processor 110 and the wireless communication module 160. For example, the processor 110 communicates with the Bluetooth module in the wireless communication module 160 via the UART interface to implement Bluetooth functionality. In some embodiments, the audio module 170 can transmit audio signals to the wireless communication module 160 via the UART interface to enable music playback through Bluetooth headphones.
[0174] The MIPI interface can be used to connect the processor 110 to peripheral devices such as the display screen 194 and the camera 193. The MIPI interface includes a camera serial interface (CSI) and a display serial interface (DSI). In some embodiments, the processor 110 and the camera 193 communicate via the CSI interface to enable the electronic device 100 to capture images. The processor 110 and the display screen 194 communicate via the DSI interface to enable the electronic device 100 to display images.
[0175] The GPIO interface can be configured via software. It can be configured as a control signal or a data signal. In some embodiments, the GPIO interface can be used to connect the processor 110 to a camera 193, a display screen 194, a wireless communication module 160, an audio module 170, a sensor module 180, etc. The GPIO interface can also be configured as an I2C interface, an I2S interface, a UART interface, a MIPI interface, etc.
[0176] The SIM interface can be used to communicate with the SIM card interface 195 to transmit data to or read data from the SIM card.
[0177] USB port 130 is a USB standard compliant interface, specifically a Mini USB port, Micro USB port, USB Type-C port, etc. USB port 130 can be used to connect a charger to charge electronic device 100, and can also be used for data transfer between electronic device 100 and peripheral devices. It can also be used to connect headphones for audio playback. This interface can also be used to connect other electronic devices, such as AR devices.
[0178] It is understood that the interface connection relationships between the modules illustrated in the embodiments of this application are merely illustrative and do not constitute a structural limitation on the electronic device 100. In other embodiments of this application, the electronic device 100 may also employ different interface connection methods or combinations of multiple interface connection methods as described in the above embodiments.
[0179] The charging management module 140 is used to receive charging input from the charger. The charger can be a wireless charger or a wired charger.
[0180] The power management module 141 is used to connect the battery 142, the charging management module 140, and the processor 110. The power management module 141 receives input from the battery 142 and / or the charging management module 140 to power the processor 110, internal memory 121, external memory, display 194, camera 193, and wireless communication module 160, etc.
[0181] The wireless communication function of electronic device 100 can be realized through antenna 1, antenna 2, mobile communication module 150, wireless communication module 160, modem processor and baseband processor, etc.
[0182] Antenna 1 and antenna 2 are used to transmit and receive electromagnetic wave signals. Each antenna in electronic device 100 can be used to cover one or more communication frequency bands. Different antennas can also be multiplexed to improve antenna utilization. For example, antenna 1 can be multiplexed as a diversity antenna for a wireless local area network. In some other embodiments, the antennas can be used in conjunction with tuning switches.
[0183] The mobile communication module 150 can provide solutions for wireless communication, including 2G / 3G / 4G / 5G, applied to the electronic device 100. The mobile communication module 150 may include at least one filter, switch, power amplifier, low noise amplifier (LNA), etc. The mobile communication module 150 can receive electromagnetic waves via antenna 1, and perform filtering, amplification, and other processing on the received electromagnetic waves before transmitting them to a modem processor for demodulation. The mobile communication module 150 can also amplify the signal modulated by the modem processor and convert it into electromagnetic waves for radiation via antenna 1. In some embodiments, at least some functional modules of the mobile communication module 150 may be housed in the processor 110. In some embodiments, at least some functional modules of the mobile communication module 150 and at least some modules of the processor 110 may be housed in the same device.
[0184] The modem processor may include a modulator and a demodulator. The modulator modulates the low-frequency baseband signal to be transmitted into a mid-to-high frequency signal. The demodulator demodulates the received electromagnetic wave signal into a low-frequency baseband signal. The demodulator then transmits the demodulated low-frequency baseband signal to the baseband processor for processing. After processing by the baseband processor, the low-frequency baseband signal is transmitted to the application processor. The application processor outputs sound signals through an audio device (not limited to speaker 170A, receiver 170B, etc.) or displays images or videos through the display screen 194. In some embodiments, the modem processor may be a separate device. In other embodiments, the modem processor may be independent of the processor 110 and may be housed in the same device as the mobile communication module 150 or other functional modules.
[0185] The wireless communication module 160 can provide solutions for wireless communication applications on the electronic device 100, including wireless local area networks (WLANs) (such as wireless fidelity (Wi-Fi) networks), Bluetooth (BT), global navigation satellite system (GNSS), frequency modulation (FM), near field communication (NFC), and infrared (IR) technologies. The wireless communication module 160 can be one or more devices integrating at least one communication processing module. The wireless communication module 160 receives electromagnetic waves via antenna 2, performs frequency modulation and filtering of the electromagnetic wave signals, and sends the processed signal to processor 110. The wireless communication module 160 can also receive signals to be transmitted from processor 110, perform frequency modulation and amplification, and convert them into electromagnetic waves for radiation via antenna 2.
[0186] In some embodiments, antenna 1 of electronic device 100 is coupled to mobile communication module 150, and antenna 2 is coupled to wireless communication module 160, enabling electronic device 100 to communicate with networks and other devices via wireless communication technology. The wireless communication technology may include Global System for Mobile Communications (GSM), General Packet Radio Service (GPRS), Code Division Multiple Access (CDMA), Wideband Code Division Multiple Access (WCDMA), Time Division Code Division Multiple Access (TD-SCDMA), Long Term Evolution (LTE), BT, GNSS, WLAN, NFC, FM, and / or IR technologies, etc. The GNSS may include the Global Positioning System (GPS), the Global Navigation Satellite System (GLONASS), the BeiDou Navigation Satellite System (BDS), the Quasi-Zenith Satellite System (QZSS), and / or satellite-based augmentation systems (SBAS).
[0187] Electronic device 100 implements display functions through a GPU, a display screen 194, and an application processor. The GPU is a microprocessor for image processing, connected to the display screen 194 and the application processor. The GPU is used to perform mathematical and geometric calculations and for graphics rendering. Processor 110 may include one or more GPUs, which execute program instructions to generate or modify display information.
[0188] Display screen 194 is used to display images, videos, etc. Display screen 194 includes a display panel. The display panel may be a liquid crystal display (LCD), an organic light-emitting diode (OLED), an active-matrix organic light-emitting diode (AMOLED), a flexible light-emitting diode (FLED), a Mini LED, a MicroLED, a Micro-OLED, a quantum dot light-emitting diode (QLED), etc. In some embodiments, electronic device 100 may include one or N displays 194, where N is a positive integer greater than 1.
[0189] Electronic device 100 can perform shooting functions through ISP, camera 193, video codec, GPU, display 194 and application processor.
[0190] The ISP (Image Signal Processor) is used to process data fed back from the camera 193. For example, when taking a picture, the shutter is opened, and light is transmitted through the lens to the camera's photosensitive element. The light signal is converted into an electrical signal, and the camera's photosensitive element transmits the electrical signal to the ISP for processing, transforming it into an image visible to the naked eye. The ISP can also perform algorithmic optimization of image noise, brightness, and color. The ISP can also optimize parameters such as exposure and color temperature of the shooting scene. In some embodiments, the ISP can be set in the camera 193.
[0191] Camera 193 is used to capture still images or videos. An object is projected onto a photosensitive element by generating an optical image through the lens. The photosensitive element can be a charge-coupled device (CCD) or a complementary metal-oxide-semiconductor (CMOS) phototransistor. The photosensitive element converts the light signal into an electrical signal, which is then passed to an ISP for conversion into a digital image signal. The ISP outputs the digital image signal to a DSP for processing. The DSP converts the digital image signal into image signals in standard RGB, YUV, or other formats. In some embodiments, the electronic device 100 may include one or N cameras 193, where N is a positive integer greater than 1.
[0192] Digital signal processors (DSPs) are used to process digital signals. Besides digital image signals, they can also process other digital signals. For example, when electronic device 100 selects a frequency, the DSP can perform Fourier transforms on the frequency energy.
[0193] Video codecs are used to compress or decompress digital video. Electronic device 100 may support one or more video codecs. Thus, electronic device 100 can play or record videos in various encoding formats, such as Moving Picture Experts Group (MPEG) 1, MPEG2, MPEG3, MPEG4, etc.
[0194] An NPU (Neural Processing Unit) is a computational processor for neural networks (NNs). By borrowing the structure of biological neural networks, such as the transmission patterns between neurons in the human brain, it can rapidly process input information and continuously learn on its own. NPUs enable intelligent cognitive applications in electronic devices, such as image recognition, facial recognition, speech recognition, and text understanding.
[0195] The external storage interface 120 can be used to connect an external memory card, such as a Micro SD card, to expand the storage capacity of the electronic device 100. The external memory card communicates with the processor 110 through the external storage interface 120 to perform data storage functions. For example, music, video, and other files can be saved on the external memory card.
[0196] Internal memory 121 can be used to store computer executable program code, which includes instructions. Processor 110 executes various functional applications and data processing of electronic device 100 by running the instructions stored in internal memory 121. Internal memory 121 may include a program storage area and a data storage area. The program storage area may store the operating system, at least one application required for a function (such as facial recognition, fingerprint recognition, mobile payment, etc.). The data storage area may store data created during the use of electronic device 100 (such as facial information template data, fingerprint information templates, etc.). Furthermore, internal memory 121 may include high-speed random access memory and non-volatile memory, such as at least one disk storage device, flash memory device, universal flash storage (UFS), etc.
[0197] Electronic device 100 can implement audio functions, such as music playback and recording, through audio module 170, speaker 170A, receiver 170B, microphone 170C, headphone jack 170D, and application processor.
[0198] The audio module 170 is used to convert digital audio information into analog audio signals for output, and also to convert analog audio input into digital audio signals. The audio module 170 can also be used for encoding and decoding audio signals. In some embodiments, the audio module 170 may be located in the processor 110, or some functional modules of the audio module 170 may be located in the processor 110.
[0199] The speaker 170A, also known as a "loudspeaker," is used to convert audio electrical signals into sound signals. The electronic device 100 can listen to music or make hands-free calls through the speaker 170A.
[0200] The receiver 170B, also known as the "earpiece," is used to convert audio electrical signals into sound signals. When the electronic device 100 answers a telephone call or voice message, the receiver 170B can be brought close to the ear to listen to the voice.
[0201] Microphone 170C, also known as a "microphone" or "voice transducer," is used to convert sound signals into electrical signals. When making a phone call or sending a voice message, the user can speak by bringing their mouth close to microphone 170C, inputting the sound signal into microphone 170C. Electronic device 100 may have at least one microphone 170C. In some embodiments, electronic device 100 may have two microphones 170C, which, in addition to collecting sound signals, can also perform noise reduction. In other embodiments, electronic device 100 may also have three, four, or more microphones 170C, which can collect sound signals, reduce noise, identify the sound source, and perform directional recording, etc.
[0202] The 170D headphone jack is used to connect wired headphones. The 170D headphone jack can be a USB 130 interface or a 3.5mm Open Mobile Terminal Platform (OMTP) standard interface, a CTIA (Cellular Telecommunications Industry Association of the USA) standard interface.
[0203] Pressure sensor 180A is used to sense pressure signals and convert them into electrical signals. In some embodiments, pressure sensor 180A can be disposed on display screen 194. There are many types of pressure sensors 180A, such as resistive pressure sensors, inductive pressure sensors, and capacitive pressure sensors. A capacitive pressure sensor may include at least two parallel plates with conductive material. When force is applied to pressure sensor 180A, the capacitance between the electrodes changes. Electronic device 100 determines the pressure intensity based on the change in capacitance. When a touch operation is applied to display screen 194, electronic device 100 detects the intensity of the touch operation based on pressure sensor 180A. Electronic device 100 can also calculate the touch position based on the detection signal from pressure sensor 180A. In some embodiments, touch operations applied to the same touch position but with different touch operation intensities can correspond to different operation commands. For example, when a touch operation with an intensity less than a first pressure threshold is applied to the SMS application icon, a command to view an SMS is executed. When a touch operation with an intensity greater than or equal to the first pressure threshold is applied to the SMS application icon, a command to create a new SMS is executed.
[0204] The gyroscope sensor 180B can be used to determine the motion attitude of the electronic device 100. In some embodiments, the gyroscope sensor 180B can determine the angular velocity of the electronic device 100 about three axes (i.e., the x, y, and z axes). The gyroscope sensor 180B can be used for image stabilization. For example, when the shutter is pressed, the gyroscope sensor 180B detects the angle of the shake of the electronic device 100, calculates the distance that the lens module needs to compensate based on the angle, and allows the lens to counteract the shake of the electronic device 100 by moving in the opposite direction, thus achieving image stabilization. The gyroscope sensor 180B can also be used in navigation and motion-sensing game scenarios.
[0205] The barometric pressure sensor 180C is used to measure air pressure. In some embodiments, the electronic device 100 calculates altitude using the air pressure value measured by the barometric pressure sensor 180C to assist in positioning and navigation.
[0206] The magnetic sensor 180D includes a Hall sensor. The electronic device 100 can use the magnetic sensor 180D to detect the opening and closing of the flip cover. In some embodiments, when the electronic device 100 is a flip phone, the electronic device 100 can detect the opening and closing of the flip cover using the magnetic sensor 180D. Then, based on the detected opening and closing state of the cover or the flip cover, features such as automatic flip unlocking can be set.
[0207] The 180E accelerometer can detect the magnitude of acceleration of electronic device 100 in various directions (typically three axes). When electronic device 100 is stationary, it can detect the magnitude and direction of gravity. It can also be used to identify the posture of electronic devices and applied to applications such as screen orientation switching and pedometers.
[0208] A distance sensor 180F is used to measure distance. Electronic device 100 can measure distance via infrared or laser. In some embodiments, during a shooting scene, electronic device 100 can utilize the distance sensor 180F to measure distance for rapid focusing.
[0209] The proximity sensor 180G may include, for example, a light-emitting diode (LED) and a light detector, such as a photodiode. The LED may be an infrared LED. The electronic device 100 emits infrared light outward through the LED. The electronic device 100 uses the photodiode to detect infrared reflected light from nearby objects. When sufficient reflected light is detected, it can be determined that there is an object near the electronic device 100. When insufficient reflected light is detected, the electronic device 100 can determine that there is no object near the electronic device 100. The electronic device 100 may use the proximity sensor 180G to detect when a user holds the electronic device 100 close to their ear for a call, so as to automatically turn off the screen to save power. The proximity sensor 180G can also be used in holster mode and pocket mode for automatic unlocking and locking of the screen.
[0210] The ambient light sensor 180L is used to sense the brightness of ambient light. The electronic device 100 can adaptively adjust the brightness of the display screen 194 based on the sensed ambient light brightness. The ambient light sensor 180L can also be used to automatically adjust the white balance when taking pictures. The ambient light sensor 180L can also work with the proximity sensor 180G to detect whether the electronic device 100 is in a pocket to prevent accidental touches.
[0211] The fingerprint sensor 180H is used to collect fingerprints. The electronic device 100 can utilize the characteristics of the collected fingerprints to achieve fingerprint unlocking, accessing application locks, taking photos with fingerprints, answering calls with fingerprints, etc.
[0212] Temperature sensor 180J is used to detect temperature. In some embodiments, electronic device 100 uses the temperature detected by temperature sensor 180J to execute a temperature handling strategy. For example, when the temperature reported by temperature sensor 180J exceeds a threshold, electronic device 100 performs thermal protection by reducing the performance of a processor located near temperature sensor 180J to reduce power consumption. In other embodiments, when the temperature is below another threshold, electronic device 100 heats battery 142 to prevent abnormal shutdown of electronic device 100 due to low temperature. In still other embodiments, when the temperature is below yet another threshold, electronic device 100 boosts the output voltage of battery 142 to prevent abnormal shutdown due to low temperature.
[0213] Touch sensor 180K, also known as a "touch panel," can be located on display screen 194. The touch sensor 180K and display screen 194 together form a touchscreen, also known as a "touch screen." Touch sensor 180K detects touch operations applied to or near it. The touch sensor can transmit the detected touch operation to the application processor to determine the type of touch event. Visual output related to the touch operation can be provided through display screen 194. In other embodiments, touch sensor 180K may also be located on the surface of electronic device 100, in a different position than display screen 194.
[0214] Buttons 190 include a power button, volume buttons, etc. Buttons 190 can be mechanical buttons or touch-sensitive buttons. Electronic device 100 can receive button input and generate key signal inputs related to user settings and function control of electronic device 100.
[0215] Motor 191 can generate vibration alerts. Motor 191 can be used for incoming call vibration alerts or for touch vibration feedback. For example, different vibration feedback effects can correspond to touch operations performed on different applications (such as taking photos, playing audio, etc.). Motor 191 can also correspond to different vibration feedback effects for touch operations performed on different areas of the display screen 194. Different application scenarios (such as time reminders, receiving messages, alarm clocks, games, etc.) can also correspond to different vibration feedback effects. The touch vibration feedback effect can also be customized.
[0216] Indicator 192 can be an indicator light, used to indicate charging status, power changes, or to indicate messages, missed calls, notifications, etc.
[0217] The SIM card interface 195 is used to connect a SIM card. The SIM card can be inserted into or removed from the SIM card interface 195 to make contact with and detach from the electronic device 100. The electronic device 100 can support one or N SIM card interfaces, where N is a positive integer greater than 1. The SIM card interface 195 can support Nano SIM cards, Micro SIM cards, and other SIM cards. Multiple cards can be inserted into the same SIM card interface 195 simultaneously. The multiple cards can be of the same or different types. The SIM card interface 195 is also compatible with different types of SIM cards. The SIM card interface 195 is also compatible with external memory cards. The electronic device 100 interacts with the network through the SIM card to realize functions such as calls and data communication.
[0218] The above-described embodiments are only used to illustrate the technical solutions of this application, and are not intended to limit it. Although this application has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some of the technical features. Such modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the scope of the technical solutions of the embodiments of this application.
[0219] As used in the above embodiments, depending on the context, the term "when..." can be interpreted as meaning "if...", "after...", "in response to determining...", or "in response to detecting...". Similarly, depending on the context, the phrase "when determining..." or "if (the stated condition or event) is interpreted as meaning "if determining...", "in response to determining...", "when (the stated condition or event) is detected", or "in response to detecting (the stated condition or event)".
[0220] In the above embodiments, implementation can be achieved entirely or partially through software, hardware, firmware, or any combination thereof. When implemented using software, it can be implemented entirely or partially in the form of a computer program product. The computer program product includes one or more computer instructions. When the computer program instructions are loaded and executed on a computer, all or part of the processes or functions described in the embodiments of this application are generated. The computer can be a general-purpose computer, a special-purpose computer, a computer network, or other programmable device. The computer instructions can be stored in a computer-readable storage medium or transmitted from one computer-readable storage medium to another. For example, the computer instructions can be transmitted from one website, computer, server, or data center to another website, computer, server, or data center via wired (e.g., coaxial cable, fiber optic, digital subscriber line) or wireless (e.g., infrared, wireless, microwave, etc.) means. The computer-readable storage medium can be any available medium that a computer can access or a data storage device such as a server or data center that integrates one or more available media. The available medium can be a magnetic medium (e.g., floppy disk, hard disk, magnetic tape), an optical medium (e.g., DVD), or a semiconductor medium (e.g., solid-state drive), etc.
[0221] Those skilled in the art will understand that all or part of the processes in the methods of the above embodiments can be implemented by a computer program instructing related hardware. This program can be stored in a computer-readable storage medium, and when executed, it can include the processes described in the above method embodiments. The aforementioned storage medium includes various media capable of storing program code, such as ROM or random access memory (RAM), magnetic disks, or optical disks.
Claims
1. A window interaction method, characterized in that, The method is applied to an electronic device, and the method includes: A first window is displayed at a first position on the screen of the electronic device; An operation to minimize the first window was detected; In response to the operation of minimizing the first window, the first window is minimized, and a first animation effect is played during the minimization process; The first animation effect is used to present the process of the first window gradually moving from the first position to the second position and the first window gradually shrinking until it disappears; the path of the first window is a first curved path; the change in the movement speed of each position on the first window is non-linear; during the process, the first window produces a first deformation; the bending direction of the first window is close to or the same as the bending direction of the first curve. During the process, part or all of the first window is blurred.
2. The method according to claim 1, characterized in that, During the process, the movement speed of the first window gradually increases and then gradually decreases.
3. The method according to claims 1 and 2, characterized in that, During the process, part or all of the first window is blurred, specifically including: In the first window, the areas farther away from the second position are more blurred than the areas closer to the second position.
4. The method according to any one of claims 1-3, characterized in that, After minimizing the first window and playing a first animation during the minimization process, the method further includes: Restore the first window, and in the process of restoring, reverse the first animation effect.
5. The method according to any one of claims 1-4, characterized in that, The method further includes: A first control is displayed at the second position, the first control being the desktop icon of the first window; the second position is located at the edge of the screen of the electronic device.
6. The method according to claims 1-5, characterized in that, The first window includes the following deformation points: the four vertices of the first window, and N equally divided points on each edge of the first window; the first curve path includes the curve path of each deformation point; the method further includes: For the first time, the progress of each deformation point on its respective curve path is calculated, and based on the progress, the position of each deformation point on its respective curve path is calculated. Based on the position of each deformation point at the first time, the first deformation of the first window at the first time is determined. Wherein, the progress is the ordinate of the first position point on the second Bézier curve, and the abscissa of the first position point on the second Bézier curve is the first time; the second Bézier curve is drawn with (0,0) as the starting point, (1,1) as the ending point, and (X,1) and (X,0) as control points; X is greater than 0 and less than 1; 1 on the abscissa of the second Bézier curve is used to represent the entire movement time of the deformation point; 1 on the ordinate is used to represent the entire movement distance of the deformation point on its respective curve path.
7. The method according to claim 6, characterized in that, The control points of the Bézier curve corresponding to the curve path of the N equally divided points are obtained by interpolating the control points of the Bézier curve corresponding to the curve path of the vertex.
8. The method according to claim 7, characterized in that, The control points of the Bézier curve corresponding to the curve path of the vertex are determined based on the position of the vertex on the screen and the size of the first window.
9. The method according to any one of claims 1-8, characterized in that, The second position is located in the first half of the screen of the electronic device, and the protrusion of the first curved path faces the first half of the screen.
10. The method according to any one of claims 6-9, characterized in that, The starting point of the curve path of each deformation point is the position of each deformation point, and the ending point of the curve path of each deformation point is the second position.
11. The method according to claim 10, characterized in that, The endpoints of the curve paths of each deformation point are distributed near the second position. "Near" means that any endpoint of the curve path of each deformation point is no more than a first distance from the second position.
12. An electronic device, characterized in that, include: A processor and a memory, the memory being coupled to the processor, the memory being used to store computer program code, the computer program code including computer instructions, which, when the processor reads the computer instructions from the memory, cause the electronic device to perform the method as described in any one of claims 1-11.
13. A chip system applied to an electronic device, the chip system comprising one or more processors, characterized in that, The processor is used to invoke computer instructions to cause the execution of the method as described in any one of claims 1-11.
14. A computer-readable storage medium, characterized in that, The computer-readable storage medium includes a computer program that, when run on an electronic device, causes the electronic device to perform the method as described in any one of claims 1-11.
15. A computer program product, characterized in that, When the computer program product is run on a computer, it causes the electronic device to perform the method as described in any one of claims 1-11.
