A page jump animation control method, device, electronic equipment and system
Patent Information
- Application Number
- CN202511052649.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-07-28
- Publication Date
- 2026-08-21
- Estimated Expiration
- 2045-07-28
AI Technical Summary
[0003]然而,在实际开发中,这种自定义的动画效果往往会与系统默认的页面跳转动画产生叠加,导致视觉效果混乱
[0066] This invention enables the acquisition of target transition animation parameters corresponding to a page transition command when a page transition command from a source page to a target page is detected. A transition page corresponding to the command is created, and the transition animation duration in the transition animation parameters corresponding to the default transition animation is set to 0. This allows the application to transition from the source page to the transition page with a transition animation duration of 0, achieving the effect of not displaying the default transition animation. Then, based on the target transition animation parameters, the application is controlled to transition from the transition page to the target page, thus displaying only the target transition animation corresponding to the target transition animation parameters. This allows for separate control of the default transition animation and custom page transition animations through simple operations. This eliminates the visual effect of the default transition animation when it cannot be eliminated, thereby eliminating the animation overlay effect between the custom and default transition animations and displaying only the custom animation. This improves the accuracy of page transition animation control, allowing for more precise and flexible display of page transition animations, thus improving the smoothness of page transition animation display and ultimately enhancing the user experience of the application.
Smart Images

Figure CN121166248B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of front-end development technology, and in particular to a method, apparatus, electronic device, and system for controlling page transition animations. Background Technology
[0002] Currently, in the front-end development of applications, custom shared element transition animations can be used to visually connect related elements in the preceding and following pages, achieving a smooth, seamless animation effect.
[0003] However, in actual development, these custom animation effects often overlap with the system's default page transition animations, resulting in visual clutter. To address this issue, some existing development frameworks provide APIs (Application Programming Interfaces) to disable system transition animations, but in certain cross-page development scenarios, basic transition effects are still retained. Alternatively, developers can manually synchronize the timing of the two animation effects, but this method requires cumbersome adaptation operations for different devices and makes it difficult to guarantee a smooth transition between animation effects.
[0004] Therefore, it is particularly important to propose a technical solution that can improve the control accuracy of page transition animation effects, thereby improving the smoothness of page transition animations and enhancing the user experience. Summary of the Invention
[0005] This invention provides a method, apparatus, electronic device, and system for controlling page transition animations, which can improve the accuracy of page transition animation control, thereby improving the smoothness of page transition animations and enhancing the user experience.
[0006] To address the aforementioned technical problems, the first aspect of this invention discloses a page transition animation control method. This method is applied to an electronic device, which has an application installed and is communicatively connected to a network attached storage device (LAN). The electronic device can access the LAN via the application. The application is configured with default transition animations between pages. The method includes:
[0007] When a page jump instruction triggered on the source page is detected, the target jump animation parameters corresponding to the page jump instruction are obtained; wherein, the page jump instruction is used to instruct the application to jump from the source page to the target page;
[0008] Create a transition page corresponding to the page jump instruction, and set the transition animation parameters corresponding to the default transition animation; the transition animation parameters include at least the transition animation duration, and the transition animation duration is 0;
[0009] Based on the transition animation parameters, the application is controlled to perform a first jump operation from the source page to the transition page, so as not to display the default transition animation;
[0010] Based on the target jump animation parameters, the application is controlled to perform a second jump operation from the transition page to the target page, so as to display the target jump animation corresponding to the target jump animation parameters.
[0011] As an optional implementation, in the first aspect of the present invention, the source page exists in a first stack, the target page and the transition page both exist in a second stack, and the first stack and the second stack are not the same stack;
[0012] The default transition animation is the transition animation triggered when navigating between pages across the stack.
[0013] As an optional implementation, in the first aspect of the present invention, the page transparency corresponding to the transition page is a preset transparency value;
[0014] Furthermore, the transition animation parameters also include the animation application state, and the animation application state is an unapplication state.
[0015] As an optional implementation, in the first aspect of the present invention, the source page is provided with a first shared element, the target page is provided with a second shared element, and the element identifier of the first shared element is consistent with the element identifier of the second shared element.
[0016] Furthermore, the method further includes:
[0017] When a trigger instruction is detected for the first shared element set for the source page, a preset jump instruction corresponding to the first shared element is triggered, and the preset jump instruction is determined as the page jump instruction triggered on the source page;
[0018] The target jump animation parameters corresponding to the page jump instruction include the jump animation parameters pre-set for the first shared element.
[0019] As an optional implementation, in the first aspect of the present invention, after controlling the application to perform a second jump operation from the transition page to the target page according to the target jump animation parameters, so as to display the target jump animation corresponding to the target jump animation parameters, the method further includes:
[0020] When a page exit command triggered on the target page is detected, the target exit animation parameters corresponding to the page exit command are obtained;
[0021] Based on the target exit animation parameters, the application is controlled to perform a first exit operation, which jumps from the target page to the transition page, so as to display the target exit animation corresponding to the target exit animation parameters;
[0022] Based on the transition animation parameters, the application is controlled to perform a second exit operation, jumping from the transition page to the source page, so as not to display the default transition animation.
[0023] As an optional implementation, in the first aspect of the present invention, the target exit animation parameter includes the exit animation duration;
[0024] The method further includes:
[0025] Determine whether the first exit operation meets the pre-set blocking execution conditions;
[0026] When it is determined that the first exit operation meets the blocking execution condition, a timer is set; the timer duration is the exit animation duration.
[0027] After the timer has elapsed for the specified duration, the second exit operation, which controls the application to jump from the transition page to the source page based on the transition animation parameters, is triggered to prevent the default transition animation from being displayed.
[0028] As an optional implementation, in the first aspect of the present invention, determining whether the first exit operation satisfies a pre-set blocking execution condition includes:
[0029] Determine whether a return value is generated after the first exit operation is completed, and whether the return value is used to trigger the execution of the second exit operation;
[0030] When it is determined that the return value will be generated after the first exit operation is completed and the return value is used to trigger the execution of the second exit operation, it is determined that the first exit operation meets the pre-set blocking execution condition;
[0031] If it is determined that no return value is generated after the first exit operation is completed, or the return value is not used to trigger the execution of the second exit operation, then the first exit operation does not meet the pre-set blocking execution conditions.
[0032] A second aspect of this invention discloses a page transition animation control device, which is applied in an electronic device. The electronic device has an application installed and is communicatively connected to a network attached storage device (LAN). The electronic device can access the LAN via the application. The application is configured with default transition animations between pages. The device includes:
[0033] The acquisition module is used to acquire the target jump animation parameters corresponding to the page jump instruction when a page jump instruction triggered on the source page is detected; wherein, the page jump instruction is used to instruct the application to jump from the source page to the target page;
[0034] A module is created to create the transition page corresponding to the page jump instruction;
[0035] The settings module is used to set the transition animation parameters corresponding to the default transition animation; the transition animation parameters include at least the transition animation duration, and the transition animation duration is 0;
[0036] The control module is configured to control the application to perform a first jump operation from the source page to the transition page based on the transition animation parameters, so as not to display the default transition animation;
[0037] The control module is further configured to control the application to perform a second jump operation from the transition page to the target page according to the target jump animation parameters, so as to display the target jump animation corresponding to the target jump animation parameters.
[0038] As an optional implementation, in a second aspect of the present invention, the source page exists in a first stack, the target page and the transition page both exist in a second stack, and the first stack and the second stack are not the same stack;
[0039] The default transition animation is the transition animation triggered when navigating between pages across the stack.
[0040] As an optional implementation, in the second aspect of the present invention, the page transparency corresponding to the transition page is a preset transparency value;
[0041] Furthermore, the transition animation parameters also include the animation application state, and the animation application state is an unapplication state.
[0042] As an optional implementation, in a second aspect of the present invention, the source page is provided with a first shared element, the target page is provided with a second shared element, and the element identifier of the first shared element is consistent with the element identifier of the second shared element;
[0043] The device also includes:
[0044] The instruction triggering module is used to trigger a preset jump instruction corresponding to the first shared element when a trigger instruction set for the first shared element of the source page is detected, and to determine the preset jump instruction as the page jump instruction triggered on the source page;
[0045] The target jump animation parameters corresponding to the page jump instruction include the jump animation parameters pre-set for the first shared element.
[0046] As an optional implementation, in the second aspect of the present invention, the acquisition module is further configured to acquire the target exit animation parameters corresponding to the page exit instruction when a page exit instruction triggered on the target page is detected after the control module controls the application to perform a second jump operation from the transition page to the target page according to the target jump animation parameters to display the target jump animation corresponding to the target jump animation parameters;
[0047] The control module is further configured to control the application to perform a first exit operation, which jumps from the target page to the transition page, based on the target exit animation parameters, so as to display the target exit animation corresponding to the target exit animation parameters;
[0048] The control module is further configured to control the application to perform a second exit operation, which jumps from the transition page to the source page, based on the transition animation parameters, so as not to display the default transition animation.
[0049] As an optional implementation, in a second aspect of the invention, the target exit animation parameter includes the exit animation duration;
[0050] The device further includes:
[0051] The judgment module is used to determine whether the first exit operation meets the preset blocking execution conditions;
[0052] The setting module is further configured to set a timer when the judgment module determines that the first exit operation meets the blocking execution condition; the timer duration is the exit animation duration; after the timer duration has elapsed, the control module is triggered to execute the second exit operation, which controls the application to jump from the transition page to the source page according to the transition animation parameters, so as not to display the default transition animation.
[0053] As an optional implementation, in a second aspect of the present invention, the specific method by which the determining module determines whether the first exit operation meets the preset blocking execution conditions includes:
[0054] Determine whether a return value is generated after the first exit operation is completed, and whether the return value is used to trigger the execution of the second exit operation;
[0055] When it is determined that the return value will be generated after the first exit operation is completed and the return value is used to trigger the execution of the second exit operation, it is determined that the first exit operation meets the pre-set blocking execution condition;
[0056] If it is determined that no return value is generated after the first exit operation is completed, or the return value is not used to trigger the execution of the second exit operation, then the first exit operation does not meet the pre-set blocking execution conditions.
[0057] A third aspect of the present invention discloses an electronic device, the electronic device comprising:
[0058] Memory containing executable program code;
[0059] A processor coupled to the memory;
[0060] The processor calls the executable program code stored in the memory to execute some or all of the steps of the page jump animation control method disclosed in the first aspect of the present invention.
[0061] The fourth aspect of the present invention discloses a page transition animation control system, the system comprising a page transition animation control device as disclosed in the second aspect of the present invention, and a network additional storage device communicatively connected to the page transition animation control device; wherein the page transition animation control device controls the page transition animation effect according to the page transition animation control method as disclosed in the first aspect of the present invention;
[0062] or,
[0063] The system includes an electronic device as disclosed in the third aspect of the present invention, and a network-attached storage device communicatively connected to the electronic device; wherein the electronic device controls the page transition animation effect according to the page transition animation control method disclosed in the first aspect of the present invention.
[0064] The fifth aspect of the present invention discloses a computer storage medium storing computer instructions, which, when invoked, are used to execute some or all of the steps of the page jump animation control method disclosed in the first aspect of the present invention.
[0065] Compared with the prior art, the present invention has the following beneficial effects:
[0066] This invention enables the acquisition of target transition animation parameters corresponding to a page transition command when a page transition command from a source page to a target page is detected. A transition page corresponding to the command is created, and the transition animation duration in the transition animation parameters corresponding to the default transition animation is set to 0. This allows the application to transition from the source page to the transition page with a transition animation duration of 0, achieving the effect of not displaying the default transition animation. Then, based on the target transition animation parameters, the application is controlled to transition from the transition page to the target page, thus displaying only the target transition animation corresponding to the target transition animation parameters. This allows for separate control of the default transition animation and custom page transition animations through simple operations. This eliminates the visual effect of the default transition animation when it cannot be eliminated, thereby eliminating the animation overlay effect between the custom and default transition animations and displaying only the custom animation. This improves the accuracy of page transition animation control, allowing for more precise and flexible display of page transition animations, thus improving the smoothness of page transition animation display and ultimately enhancing the user experience of the application. Attached Figure Description
[0067] To more clearly illustrate the technical solutions in the embodiments of the present invention, the accompanying drawings used in the description of the embodiments will be briefly introduced below. Obviously, the accompanying drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0068] Figure 1 This is a flowchart illustrating a page transition animation control method disclosed in an embodiment of the present invention;
[0069] Figure 2 This is a flowchart illustrating another page transition animation control method disclosed in an embodiment of the present invention;
[0070] Figure 3 This is a schematic diagram illustrating the principle of a page transition animation control method disclosed in an embodiment of the present invention;
[0071] Figure 4 This is a flowchart illustrating another page transition animation control method disclosed in an embodiment of the present invention;
[0072] Figure 5 This is a schematic diagram illustrating the effect of a prior art disclosed in an embodiment of the present invention;
[0073] Figure 6 This is a schematic diagram illustrating the effect of a page transition animation control method disclosed in an embodiment of the present invention;
[0074] Figure 7 This is a schematic diagram of the structure of a page jump animation control device disclosed in an embodiment of the present invention;
[0075] Figure 8 This is a schematic diagram of another page transition animation control device disclosed in an embodiment of the present invention;
[0076] Figure 9 This is a schematic diagram of the structure of an electronic device disclosed in an embodiment of the present invention;
[0077] Figure 10 This is a schematic diagram of the structure of a page transition animation control system disclosed in an embodiment of the present invention;
[0078] Figure 11 This is a schematic diagram of another page transition animation control system disclosed in an embodiment of the present invention. Detailed Implementation
[0079] To enable those skilled in the art to better understand the present invention, the technical solutions of the present invention will be clearly and completely described below with reference to the accompanying drawings of the embodiments of the present invention. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.
[0080] The terms "first," "second," etc., used in the specification, claims, and accompanying drawings of this invention are used to distinguish different objects, not to describe a specific order. Furthermore, the terms "comprising" and "having," and any variations thereof, are intended to cover non-exclusive inclusion. For example, a process, method, apparatus, product, or end that includes a series of steps or units is not limited to the listed steps or units, but may optionally include steps or units not listed, or may optionally include other steps or units inherent to these processes, methods, products, or ends.
[0081] In this document, the term "embodiment" means that a particular feature, structure, or characteristic described in connection with an embodiment may be included in at least one embodiment of the invention. The appearance of this phrase in various places throughout the specification does not necessarily refer to the same embodiment, nor is it a separate or alternative embodiment mutually exclusive with other embodiments. It will be explicitly and implicitly understood by those skilled in the art that the embodiments described herein can be combined with other embodiments.
[0082] This invention discloses a page transition animation control method, device, electronic device, and system. When a page transition instruction requiring a jump from a source page to a target page is detected, the system obtains the target transition animation parameters corresponding to the instruction, creates a transition page corresponding to the instruction, and sets the transition animation duration in the transition animation parameters corresponding to the default transition animation to 0. This allows the application to jump from the source page to the transition page with a 0-second transition animation duration, effectively preventing the default transition animation from being displayed. Then, based on the target transition animation parameters, the application jumps from the transition page to the target page, displaying only the target transition animation corresponding to the parameters. This allows for separate control of the default transition animation and custom page transition animations through simple operations. It eliminates the visual effect of the default transition animation when it cannot be eliminated, thereby eliminating the animation overlay effect between the custom and default transition animations and displaying only the custom animation. This improves the accuracy of page transition animation control, enabling more precise and flexible display of page transition animations, thus enhancing the smoothness of the animation display and ultimately improving the user experience. The following sections will provide detailed explanations.
[0083] Example 1
[0084] Please see Figure 1 , Figure 1 This is a flowchart illustrating a page transition animation control method disclosed in an embodiment of the present invention. Figure 1 The described page transition animation control method can be applied to a page transition animation control device, which may include one of a control device, a control terminal, a control system, and a server. The server can be a local server or a cloud server; this embodiment of the invention is not limited thereto. The method can also be applied to electronic devices, where an application is installed, and the electronic device is communicatively connected to a network attached storage device (NETS). The electronic device can access the NETS through the application. Furthermore, the application sets default transition animations between pages; more specifically, the application sets default transition animations between pages in different stacks. Furthermore, these default transition animations cannot be eliminated; this embodiment of the invention is not limited thereto. Further optionally, the application can be built using the ArkUI framework, or other frameworks; this embodiment of the invention is not limited thereto. Figure 1 As shown, the page transition animation control method can include the following operations:
[0085] 101. When a page jump instruction triggered on the source page is detected, obtain the target jump animation parameters corresponding to the page jump instruction.
[0086] In this embodiment of the invention, the page jump instruction is used to instruct the application to jump from the source page to the target page; for example, the page jump instruction can be triggered by clicking any element of the source page, or by triggering any preset listener event of the source page, and this embodiment of the invention does not limit the scope.
[0087] In this embodiment of the invention, optionally, the target jump animation parameters corresponding to the page jump instruction may include target change effect parameters for at least one page element and / or target jump animation duration. Further optionally, the target change effect parameters may include one or more combinations of size change parameters, position change parameters, transparency change parameters, color change parameters, and gradient parameters, and may also include other animation effect parameters for page elements. This embodiment of the invention does not limit these parameters. For example, the target jump animation duration may be 150 milliseconds, or it may be any other duration value. This embodiment of the invention does not limit this duration.
[0088] 102. Create a transition page corresponding to the page jump instruction, and set the transition animation parameters corresponding to the default transition animation.
[0089] In this embodiment of the invention, the transition animation parameters include at least the transition animation duration, and the transition animation duration is 0.
[0090] In this embodiment of the invention, optionally, a transition page corresponding to the page jump instruction can be created based on pre-set transition page parameters; further optionally, the transition page parameters may include one or more combinations of page transparency, page transition transparency, page size, and page display mode, and may also include other parameters used to define and create the page, which are not limited in this embodiment of the invention; wherein, for example, the page display mode of the transition page may be a pop-up display mode, which is not limited in this embodiment of the invention.
[0091] 103. Based on the transition animation parameters, control the application to perform the first jump operation from the source page to the transition page, so as not to display the default transition animation.
[0092] In this embodiment of the invention, since the duration of the transition animation corresponding to the default transition animation is 0, the animation effect of the default transition animation will not be displayed in the actual jump situation in step 103.
[0093] 104. Based on the target jump animation parameters, control the application to execute the second jump operation from the transition page to the target page, so as to display the target jump animation corresponding to the target jump animation parameters.
[0094] In this embodiment of the invention, since step 103 results in the default transition animation not being displayed, the visual effect of the default transition animation being superimposed on the target jump animation can be eliminated, that is, only the target jump animation can be displayed.
[0095] In this embodiment of the invention, step 104 may optionally be:
[0096] Obtain the routing parameters from the source page to the transition page, and define the target jump animation parameters in the transition page;
[0097] Based on the target jump animation parameters and routing parameters, the application is controlled to execute a second jump operation from the transition page to the target page, so as to display the target jump animation corresponding to the target jump animation parameters.
[0098] As can be seen, the method described in this embodiment of the invention can, when a page jump instruction requiring a jump from the source page to the target page is detected, obtain the target jump animation parameters corresponding to the page jump instruction, create a transition page corresponding to the page jump instruction, and set the transition animation duration in the transition animation parameters corresponding to the default transition animation to 0. Thus, with the transition animation duration set to 0, the application is controlled to jump from the source page to the transition page, achieving the effect of not displaying the default transition animation. Then, based on the target jump animation parameters, the application is controlled to jump from the transition page to the target page, thereby displaying only the target jump animation corresponding to the target jump animation parameters. This allows for separate control of the default transition animation and the custom page jump animation through simple operations, eliminating the visual effect of the default transition animation when it cannot be eliminated, thereby eliminating the animation overlay effect between the custom jump animation and the default transition animation, and displaying only the custom jump animation. This improves the accuracy of page jump animation control, enabling more precise and flexible display of page jump animations, thereby improving the smoothness of page jump animation display and ultimately enhancing the user experience of the application.
[0099] In an optional embodiment, the source page exists in a first stack, and the target page and the transition page both exist in a second stack, and the first stack and the second stack are not the same stack.
[0100] Optionally, the default transition animation can be the transition animation triggered when navigating between pages across the stack.
[0101] It's important to note that in mobile application or web front-end development, routing specifically refers to the management of navigation between pages, such as navigating from page A to page B, which constitutes a route. Furthermore, it involves managing and storing the state of each page through a stack. For example, when navigating between pages, a stack can be created, and the target page can be stored in a designated stack. The stack uses a Last-In-First-Out (LIFO) data structure: newly opened pages are pushed onto the top of the stack, and when a page is closed, it is popped from the top of the stack. The bottom of the stack is typically the application's main page.
[0102] Furthermore, since the page jump operation corresponding to the page jump instruction uses the same routing controller for the jump, that is, the jump from the source page to the transition page and the jump from the transition page to the target page uses the same routing controller, this will make the transition page and the target page exist in the same stack. Therefore, after jumping from the source page to the transition page, that is, after the cross-stack page jump without displaying the default cross-stack transition animation, jumping from the transition page to the target page can successfully transform the cross-stack page jump between the source page and the target page into a same-stack page jump between the transition page and the target page, and only the target jump animation is displayed.
[0103] Optionally, the application may include multiple functional modules, and each functional module may be configured with its own stack; further optionally, the functional module may be a common module that can be called by other functional modules; further optionally, the target page may be one of the pages in the common module, and other functional modules may jump to the target page; for example, assuming the target page is an image preview page in the application, the target page may be called by other functional modules such as file management and photo album, thereby jumping to the target page, and this embodiment of the invention is not limited.
[0104] As can be seen, this optional embodiment can change the jump process of displaying the target jump animation from a cross-stack page jump to a page jump within the same stack by setting the transition page in the same stack as the target page. This achieves the visual effect of eliminating the default transition animation triggered by the cross-stack while controlling the source page to jump to the transition page first to complete the cross-stack page jump. Moreover, it can display the target jump animation when jumping from the transition page to the target page, which can further improve the control accuracy of the page jump animation effect and display the target jump animation more accurately and flexibly.
[0105] In another optional embodiment, the page transparency corresponding to the transition page can be a preset transparency value.
[0106] For example, the preset transparency value can be a value that makes the transition page display a fully transparent effect, or it can be other transparency values. This embodiment of the invention does not limit the value.
[0107] Optionally, the transition animation parameters may also include the animation application state, where the animation application state is the non-application state.
[0108] As can be seen, this optional embodiment can further eliminate the visual effects of the transition page and the default transition animation by setting the transition page to a page with preset transparency and setting the animation application state corresponding to the default transition animation to an unapplication state. This can further ensure that the transition page and the default transition animation are invisible, which in turn helps to ensure that only the target jump animation is displayed and further improves the display accuracy of the page jump animation.
[0109] In another optional embodiment, the source page is provided with a first shared element, the target page is provided with a second shared element, and the element identifier of the first shared element is consistent with the element identifier of the second shared element.
[0110] Optionally, a target attribute can be set in the first shared element and the second shared element. For example, the target attribute can be the geometryTransition attribute to specify the element identifier of the shared element. Optionally, the element identifier of the shared element (such as the first shared element and the second shared element) can be the element id. This embodiment of the invention does not limit this.
[0111] The shared element can be any page element on the page; for example, the shared element can be an image component or other page elements, and this embodiment of the invention does not limit the scope.
[0112] Optionally, the method may also include the following operations:
[0113] When a trigger command is detected for the first shared element set on the source page, the preset jump command corresponding to the first shared element is triggered, and the preset jump command is determined as the page jump command triggered on the source page.
[0114] Optionally, the preset jump instruction corresponding to the first shared element can be used to control the application to jump from the source page to the target page, while displaying the jump animation effect between the first shared element and the second shared element.
[0115] Optionally, the target jump animation parameters corresponding to the page jump instruction include the jump animation parameters pre-set for the first shared element.
[0116] Among them, the pre-set jump animation parameters for the first shared element can be used to indicate the animation changes produced by the target jump animation between the first shared element and the second shared element when jumping from the source page to the target page.
[0117] As can be seen, this optional embodiment can improve the triggering flexibility and accuracy of page jump instructions by setting a first shared element on the source page, setting a second shared element with the same element identifier as the first shared element on the target page, and determining the corresponding preset jump instruction as the page jump instruction when the first shared element is triggered; and the target jump animation parameters can include preset jump animation parameters for the first shared element, so that when the page jump operation from the source page to the target page is triggered, the animation change effect between the first shared element and the second shared element can be displayed, thereby further improving the control accuracy of the page jump animation and thus displaying the animation change effect between the shared elements more accurately.
[0118] Example 2
[0119] Please see Figure 2 , Figure 2 This is a flowchart illustrating a page transition animation control method disclosed in an embodiment of the present invention. Figure 2 The described page transition animation control method can be applied to a page transition animation control device, which may include one of a control device, a control terminal, a control system, and a server. The server can be a local server or a cloud server; this embodiment of the invention is not limited thereto. The method can also be applied to electronic devices, where an application is installed, and the electronic device is communicatively connected to a network attached storage device (NETS). The electronic device can access the NETS through the application. Furthermore, the application sets default transition animations between pages; more specifically, the application sets default transition animations between pages in different stacks. Furthermore, these default transition animations cannot be eliminated; this embodiment of the invention is not limited thereto. Further optionally, the application can be built using the ArkUI framework, or other frameworks; this embodiment of the invention is not limited thereto. Figure 2 As shown, the page transition animation control method can include the following operations:
[0120] 201. When a page jump instruction triggered on the source page is detected, obtain the target jump animation parameters corresponding to the page jump instruction.
[0121] In this embodiment of the invention, the page jump instruction is used to instruct the application to jump from the source page to the target page.
[0122] 202. Create a transition page corresponding to the page jump instruction, and set the transition animation parameters corresponding to the default transition animation.
[0123] In this embodiment of the invention, the transition animation parameters include at least the transition animation duration, and the transition animation duration is 0.
[0124] 203. Based on the transition animation parameters, control the application to perform the first jump operation from the source page to the transition page, so as not to display the default transition animation.
[0125] 204. Based on the target jump animation parameters, control the application to execute the second jump operation from the transition page to the target page, so as to display the target jump animation corresponding to the target jump animation parameters.
[0126] 205. When a page exit command triggered on the target page is detected, obtain the target exit animation parameters corresponding to the page exit command.
[0127] In this embodiment of the invention, optionally, the target exit animation parameters corresponding to the page exit instruction may include target change effect parameters for at least one page element and / or target jump animation duration. Further optionally, the target change effect parameters may include one or more combinations of size change parameters, position change parameters, transparency change parameters, color change parameters, and gradient parameters, and may also include other animation effect parameters for page elements. This embodiment of the invention does not limit these parameters. Further optionally, the target exit animation parameters may be the same as or different from the target jump animation parameters. This embodiment of the invention does not limit these parameters.
[0128] In this embodiment of the invention, optionally, before step 205, the method may further include the following operations:
[0129] When a trigger command is detected for a second shared element set on the target page, the preset exit command corresponding to the second shared element is triggered, and the preset exit command is determined as the page exit command triggered on the target page.
[0130] In this embodiment of the invention, the pre-set jump animation parameters for the second shared element can be used to indicate the animation change effect between the second shared element and the first shared element when exiting from the target page to the source page.
[0131] 206. Based on the target exit animation parameters, control the application to execute the first exit operation from the target page to the transition page, so as to display the target exit animation corresponding to the target exit animation parameters.
[0132] 207. Based on the transition animation parameters, control the application to perform a second exit operation, jumping from the transition page to the source page, so as not to display the default transition animation.
[0133] In this embodiment of the invention, for other detailed descriptions of steps 201-204, please refer to the detailed description of steps 101-104 in Embodiment 1. These details will not be repeated in this embodiment of the invention.
[0134] As can be seen, the method described in this embodiment of the invention can, when a page jump instruction requiring a jump from the source page to the target page is detected, obtain the target jump animation parameters corresponding to the page jump instruction, create a transition page corresponding to the page jump instruction, and set the transition animation duration in the transition animation parameters corresponding to the default transition animation to 0. Thus, with the transition animation duration set to 0, the application is controlled to jump from the source page to the transition page, achieving the effect of not displaying the default transition animation. Then, based on the target jump animation parameters, the application is controlled to jump from the transition page to the target page, thereby displaying only the target jump animation corresponding to the target jump animation parameters. This allows for separate control of the default transition animation and the custom page jump animation through simple operations, eliminating the visual effect of the default transition animation when it cannot be eliminated, thereby eliminating the animation overlay effect between the custom jump animation and the default transition animation, and displaying only the custom jump animation. This improves the accuracy of page jump animation control, enabling more precise and flexible display of page jump animations, thereby improving the smoothness of page jump animation display and ultimately enhancing the user experience of the application. Furthermore, upon detecting a page exit command, the application can obtain the target exit animation parameters and, based on these parameters, control the application to jump from the target page to a transition page to display the target exit animation parameters. Then, based on the transition animation parameters, the application jumps from the transition page back to the source page without displaying the default transition animation. This eliminates the animation overlap between the custom exit animation and the default transition animation when the page exits, displaying only the custom exit animation. This further improves the accuracy and flexibility of controlling the page exit animation, resulting in a more precise and smoother display of the page exit animation.
[0135] In an optional embodiment, the target exit animation parameter may include the exit animation duration.
[0136] Optionally, the method may also include the following operations:
[0137] Determine whether the first exit operation meets the pre-set blocking execution conditions;
[0138] When it is determined that the first exit operation meets the blocking execution condition, a timer is set; the timer duration is the exit animation duration.
[0139] After the timer has elapsed for the specified duration, the second exit operation, which controls the application to jump from the transition page to the source page based on the transition animation parameters, is triggered to prevent the default transition animation from being displayed.
[0140] When the first exit operation meets the blocking execution condition, if no timer is set, the second exit operation will be executed immediately after the first exit operation is completed. This means that the page will immediately exit from the transition page to the source page, and the target exit animation corresponding to the target exit animation parameter will not be displayed. Therefore, a timer is set to fully display the target exit animation corresponding to the exit animation duration, so that the page will jump to the source page after the target exit animation is fully displayed.
[0141] As can be seen, this optional embodiment can set a timer with the same duration as the exit animation when it is determined that the first exit operation meets the blocking execution condition. The second exit operation, which jumps from the transition page to the source page, will only be triggered after the timer ends. This can avoid the situation where the target exit animation cannot be fully displayed because the target page exits to the transition page and then immediately exits to the source page. This further improves the accuracy of the display control of the page exit animation, and thus helps to display the page exit animation more accurately and reliably.
[0142] In this optional embodiment, determining whether the first exit operation meets the preset blocking execution conditions may include the following operations:
[0143] Determine whether a return value is generated after the first exit operation is completed, and whether the return value is used to trigger the execution of the second exit operation;
[0144] When it is determined that a return value will be generated after the first exit operation is completed and the return value is used to trigger the execution of the second exit operation, it is determined that the first exit operation meets the pre-set blocking execution conditions.
[0145] If it is determined that no return value is generated after the first exit operation is completed, or the return value is not used to trigger the execution of the second exit operation, then the first exit operation does not meet the pre-set blocking execution conditions.
[0146] For example, suppose the second exit operation is actually the operation of popping a transition page from the top of the second stack. Since this operation is a blocking operation, if the return value generated after the first exit operation is completed will immediately trigger the operation of popping a transition page from the top of the second stack (that is, immediately triggering the execution of the second exit operation), then the first exit operation is determined to meet the blocking execution condition.
[0147] Optionally, when it is determined that the first exit operation meets the blocking execution condition, the timer can be set in the stack pop function corresponding to the second exit operation to trigger the execution of the second exit operation after the timer expires.
[0148] As can be seen, this optional embodiment can also determine that the first exit operation meets the preset blocking execution conditions when a return value for triggering the execution of the second exit operation is generated after the first exit operation is completed. This can improve the accuracy of the judgment on whether the first exit operation meets the blocking execution conditions, thereby improving the accuracy of the timer setting, and further improving the accuracy of the display control of the page exit animation.
[0149] In this embodiment of the invention, the principle of the page transition animation control method can be found in [reference needed]. Figure 3 , Figure 3 This is a schematic diagram illustrating the principle of a page transition animation control method disclosed in an embodiment of the present invention; as shown below. Figure 3 As shown, the source page resides in stack A, while the transparent transition page (i.e., the aforementioned transition page) and the target page both reside in stack B. Further details regarding the flow of this page transition animation control method can be found in [reference needed]. Figure 4 , Figure 4 This is a flowchart illustrating another page transition animation control method disclosed in an embodiment of the present invention; as shown below. Figure 3 and Figure 4 As shown, the method for controlling page transition animations may include the following steps:
[0150] After creating the source page and defining the shared element, clicking the shared element will trigger a jump from the source page to the target page. At this time, the animation duration of the default transition animation corresponding to the jump between pages across stacks (that is, from a page in stack A to a page in stack B) needs to be set to 0. This will achieve the effect of jumping to the transparent transition page without displaying the default transition animation. Then, jump from the transparent transition page to the target page in the same stack. At this time, the default transition animation will not be triggered, and the animation corresponding to the shared element will be executed.
[0151] Furthermore, if it is necessary to return from the target page to the source page, then return from the source page to a transparent transition page in the same stack. At this time, the default transition animation will not be triggered, and the animation corresponding to the shared element will be executed. A timer with the same duration as the animation of the shared element will be set. After the timer ends, the user will immediately return from the transparent transition page to the source page. At this time, the animation duration of the default transition animation corresponding to the cross-stack page jump (i.e., the jump from a page in stack B to a page in stack A) needs to be set to 0, so as to achieve the effect of returning to the source page without displaying the default transition animation.
[0152] For example, if the page transition animation control method described in this embodiment of the invention is not used when a default transition animation exists, the page transition animation effect can be referred to... Figure 5 , Figure 5 This is a schematic diagram illustrating the effect of a prior art disclosed in an embodiment of the present invention; as shown. Figure 5 As shown, when clicking on the source component of the source page to jump to the target page, there is a gradient animation effect from small to large between the shared elements (that is, the source component and the target component of the target page). However, due to the existence of the default transition animation, the animation effect of the target page entering from right to left will be superimposed at the same time. Therefore, the target component enters from right to left along with the target page at the same time, and it is impossible to achieve the goal of only displaying the animation effect between the shared elements.
[0153] If the page transition animation control method described in this embodiment of the invention is used when a default transition animation exists, the page transition animation effect can be referred to [reference needed]. Figure 6 , Figure 6 This is a schematic diagram illustrating the effect of a page transition animation control method disclosed in an embodiment of the present invention; for example... Figure 6 As shown, when clicking on the source component of the source page to navigate to the target page, the default transition animation (entering from right to left) is not iterated. Instead, the target page's transparency gradually changes, and the shared element animation also gradually increases in size from the source component's position to the target page component's position. Before applying the method described in this embodiment of the invention, cross-stack page navigation, even with a set animation duration, could not cancel the default transition animation (entering from right to left).
[0154] Example 3
[0155] Please see Figure 7 , Figure 7 This is a schematic diagram of the structure of a page transition animation control device disclosed in an embodiment of the present invention. Figure 7 The described page transition animation control device may include one of a control device, a control terminal, a control system, and a server, wherein the server can be a local server or a cloud server, and this embodiment of the invention is not limited thereto. The device can be applied to an electronic device, which has an application installed and is communicatively connected to a network attached storage device (NAS). The electronic device can access the NAS through the application. Further, the application sets default transition animations between pages; more specifically, the application sets default transition animations between pages in different stacks. Furthermore, these default transition animations cannot be eliminated, and this embodiment of the invention is not limited thereto. Further optionally, the application can be built using the ArkUI framework or other frameworks, and this embodiment of the invention is not limited thereto. Figure 7 As shown, the page transition animation control device 30 may include:
[0156] The acquisition module 301 is used to acquire the target jump animation parameters corresponding to the page jump instruction when a page jump instruction triggered on the source page is detected; wherein, the page jump instruction is used to instruct the application to jump from the source page to the target page;
[0157] Create module 302 to create the transition page corresponding to the page jump instruction;
[0158] The setting module 303 is used to set the transition animation parameters corresponding to the default transition animation; the transition animation parameters include at least the transition animation duration, and the transition animation duration is 0;
[0159] The control module 304 is used to control the application to perform the first jump operation from the source page to the transition page according to the transition animation parameters, so as not to display the default transition animation;
[0160] The control module 304 is also used to control the application to perform a second jump operation from the transition page to the target page according to the target jump animation parameters, so as to display the target jump animation corresponding to the target jump animation parameters.
[0161] As can be seen, the apparatus described in the embodiments of the present invention can, when detecting a page jump instruction that requires a jump from the source page to the target page, obtain the target jump animation parameters corresponding to the page jump instruction, create a transition page corresponding to the page jump instruction, and set the transition animation duration in the transition animation parameters corresponding to the default transition animation to 0. Thus, with the transition animation duration set to 0, the application is controlled to jump from the source page to the transition page, achieving the effect of not displaying the default transition animation. Then, based on the target jump animation parameters, the application is controlled to jump from the transition page to the target page, thereby displaying only the target jump animation corresponding to the target jump animation parameters. This allows for separate control of the default transition animation and the custom page jump animation through simple operations, eliminating the visual effect of the default transition animation when it cannot be eliminated, thereby eliminating the animation overlay effect between the custom jump animation and the default transition animation, and displaying only the custom jump animation. This improves the accuracy of page jump animation control, enabling more precise and flexible display of page jump animations, thereby improving the smoothness of page jump animation display and ultimately enhancing the user experience of the application.
[0162] In an optional embodiment, the source page exists in a first stack, and the target page and the transition page both exist in a second stack, and the first stack and the second stack are not the same stack;
[0163] The default transition animation is the one triggered when navigating between pages in the stack.
[0164] As can be seen, the apparatus described in this optional embodiment can change the jump process of displaying the target jump animation from a cross-stack page jump to a page jump within the same stack by setting the transition page in the same stack as the target page. This achieves the elimination of the visual effect of the default transition animation triggered by the cross-stack while controlling the source page to jump to the transition page first to complete the cross-stack page jump. Furthermore, it can display the target jump animation when jumping from the transition page to the target page, which can further improve the control accuracy of the page jump animation effect and display the target jump animation more accurately and flexibly.
[0165] In another optional embodiment, the page transparency corresponding to the transition page is a preset transparency value;
[0166] Additionally, the transition animation parameters also include the animation application status, and the animation application status is the non-application status.
[0167] As can be seen, the apparatus described in this optional embodiment can further eliminate the visual effects of the transition page and the default transition animation by setting the transition page to a page with preset transparency and setting the animation application state corresponding to the default transition animation to an unapplication state. This further ensures that the transition page and the default transition animation are invisible, which in turn helps to further ensure that only the target jump animation is displayed and further improves the display accuracy of the page jump animation.
[0168] In another optional embodiment, the source page is provided with a first shared element, the target page is provided with a second shared element, and the element identifier of the first shared element is consistent with the element identifier of the second shared element;
[0169] And, such as Figure 8 As shown, the device may further include:
[0170] The instruction triggering module 305 is used to trigger the preset jump instruction corresponding to the first shared element when a trigger instruction set for the first shared element of the source page is detected, and to determine the preset jump instruction as the page jump instruction triggered on the source page.
[0171] The target jump animation parameters corresponding to the page jump instruction include the jump animation parameters pre-set for the first shared element.
[0172] As can be seen, the apparatus described in this optional embodiment can improve the triggering flexibility and accuracy of page jump instructions by setting a first shared element on the source page, setting a second shared element with the same element identifier as the first shared element on the target page, and determining the corresponding preset jump instruction as a page jump instruction when the first shared element is triggered; and the target jump animation parameters may include preset jump animation parameters for the first shared element, so that when a page jump operation from the source page to the target page is triggered, the animation change effect between the first shared element and the second shared element can be displayed, thereby further improving the control accuracy of the page jump animation and thus displaying the animation change effect between the shared elements more accurately.
[0173] In another optional embodiment, the acquisition module 301 is further configured to acquire the target exit animation parameters corresponding to the page exit instruction when a page exit instruction triggered on the target page is detected after the control module 304 controls the application to perform a second jump operation from the transition page to the target page according to the target jump animation parameters to display the target jump animation corresponding to the target jump animation parameters.
[0174] The control module 304 is also used to control the application to perform the first exit operation from the target page to the transition page according to the target exit animation parameters, so as to display the target exit animation corresponding to the target exit animation parameters;
[0175] The control module 304 is also used to control the application to perform a second exit operation from the transition page to the source page based on the transition animation parameters, so as not to display the default transition animation.
[0176] As can be seen, the apparatus described in this optional embodiment can obtain the target exit animation parameters when a page exit command is detected, and control the application to jump from the target page to the transition page to display the target exit animation parameters based on the target exit animation parameters. Then, it jumps from the transition page to the source page based on the transition animation parameters, without displaying the default transition animation. This eliminates the animation overlap effect between the custom exit animation and the default transition animation when the page exits, and only displays the custom exit animation, thereby further improving the control accuracy and flexibility of the page exit animation, and further displaying the page exit animation more accurately and smoothly.
[0177] In this optional embodiment, the target exit animation parameter may optionally include the exit animation duration;
[0178] Among them, such as Figure 8 As shown, the device may further include:
[0179] The judgment module 306 is used to determine whether the first exit operation meets the preset blocking execution conditions;
[0180] The setting module 302 is also used to set a timer when the judgment module 306 determines that the first exit operation meets the blocking execution condition; the timer duration is the exit animation duration; after the timer duration has elapsed, the control module 304 is triggered to execute the second exit operation, which controls the application to jump from the transition page to the source page according to the transition animation parameters, so as not to display the default transition animation.
[0181] As can be seen, the apparatus described in this optional embodiment can also set a timer with the same duration as the exit animation when it is determined that the first exit operation meets the blocking execution condition. The second exit operation, which jumps from the transition page to the source page, will only be triggered after the timer ends. This can avoid the situation where the target exit animation cannot be fully displayed because the target page exits to the transition page and then immediately exits to the source page. This further improves the accuracy of the display control of the page exit animation, and thus helps to display the page exit animation more accurately and reliably.
[0182] In this optional embodiment, the specific method by which the determining module 306 determines whether the first exit operation meets the preset blocking execution conditions may include:
[0183] Determine whether a return value is generated after the first exit operation is completed, and whether the return value is used to trigger the execution of the second exit operation;
[0184] When it is determined that a return value will be generated after the first exit operation is completed and the return value is used to trigger the execution of the second exit operation, it is determined that the first exit operation meets the pre-set blocking execution conditions.
[0185] If it is determined that no return value is generated after the first exit operation is completed, or the return value is not used to trigger the execution of the second exit operation, then the first exit operation does not meet the pre-set blocking execution conditions.
[0186] As can be seen, the apparatus described in this optional embodiment can also determine that the first exit operation meets the preset blocking execution conditions when a return value for triggering the execution of the second exit operation is generated after the first exit operation is completed. This can improve the accuracy of the judgment on whether the first exit operation meets the blocking execution conditions, thereby improving the accuracy of the timer setting and further improving the accuracy of the display control of the page exit animation.
[0187] Example 4
[0188] Please see Figure 9 , Figure 9 This is a schematic diagram of the structure of an electronic device disclosed in an embodiment of the present invention. For example... Figure 9As shown, the electronic device 40 may include:
[0189] Memory 401 storing executable program code;
[0190] Processor 402 coupled to memory 401;
[0191] The processor 402 calls the executable program code stored in the memory 401 to execute some or all of the steps in the page jump animation control method described in Embodiment 1 or Embodiment 2 of the present invention.
[0192] Example 5
[0193] This invention discloses a page transition animation control system. Please refer to [link / reference]. Figure 10 , Figure 10 This is a schematic diagram of the structure of a page transition animation control system disclosed in an embodiment of the present invention. Figure 10 As shown, the page transition animation control system includes the page transition animation control device 30 described in Embodiment 3 of the present invention, and a network additional storage device 50 communicatively connected to the page transition animation control device 30; wherein, the page transition animation control device 30 controls the animation effect of page transition according to the page transition animation control method described in Embodiment 1 or Embodiment 2 of the present invention;
[0194] or,
[0195] In this embodiment of the invention, as another optional implementation, please refer to [link / reference needed]. Figure 11 , Figure 11 This is a schematic diagram of another page transition animation control system disclosed in an embodiment of the present invention. For example... Figure 11 As shown, the page transition animation control system includes an electronic device 40 as described in Embodiment 4 of the present invention, and a network-attached storage device 50 communicatively connected to the electronic device 40; wherein, the electronic device 40 controls the page transition animation effect according to the page transition animation control method described in Embodiment 1 or Embodiment 2 of the present invention.
[0196] Example 6
[0197] This invention discloses a computer storage medium storing computer instructions. When these computer instructions are invoked, they are used to execute some or all of the steps in the page transition animation control method described in Embodiment 1 or Embodiment 2 of this invention.
[0198] Example 7
[0199] This invention discloses a computer program product, which includes a non-transitory computer-readable storage medium storing a computer program, and the computer program is operable to cause a computer to perform some or all of the steps in the page jump animation control method described in Embodiment 1 or Embodiment 2.
[0200] The device embodiments described above are merely illustrative. The modules described as separate components may or may not be physically separate. The components shown as modules may or may not be physical modules; that is, they may be located in one place or distributed across multiple network modules. Some or all of the modules can be selected to achieve the purpose of this embodiment according to actual needs. Those skilled in the art can understand and implement this without any creative effort.
[0201] Through the detailed description of the above embodiments, those skilled in the art can clearly understand that each implementation method can be implemented by means of software plus necessary general-purpose hardware platforms, and of course, it can also be implemented by hardware. Based on this understanding, the above technical solutions, in essence or the part that contributes to the prior art, can be embodied in the form of a software product. This computer software product can be stored in a computer-readable storage medium, including read-only memory (ROM), random access memory (RAM), programmable read-only memory (PROM), erasable programmable read-only memory (EPROM), one-time programmable read-only memory (OTPROM), electrically-Erasable Programmable Read-Only Memory (EEPROM), compact disc read-only memory (CD-ROM) or other optical disc storage, disk storage, magnetic tape storage, or any other computer-readable medium that can be used to carry or store data.
[0202] Finally, it should be noted that the page jump animation control method, device, electronic device and system disclosed in the embodiments of the present invention are only preferred embodiments of the present invention, and are only used to illustrate the technical solutions of the present invention, and not to limit it; although the present invention 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; and these modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the embodiments of the present invention.
Claims
1. A method for controlling page transition animation, characterized in that, The method is applied to an electronic device, which has an application installed and is communicatively connected to a network attached storage device (NETS). The electronic device can access the NETS via the application. The application includes default transition animations between pages. When a page jump instruction triggered on the source page is detected, the target jump animation parameters corresponding to the page jump instruction are obtained; wherein, the page jump instruction is used to instruct the application to jump from the source page to the target page; Create a transition page corresponding to the page jump instruction, and set the transition animation parameters corresponding to the default transition animation; the transition animation parameters include at least the transition animation duration, and the transition animation duration is 0; Based on the transition animation parameters, the application is controlled to perform a first jump operation from the source page to the transition page, so as not to display the default transition animation; Based on the target jump animation parameters, the application is controlled to perform a second jump operation from the transition page to the target page, so as to display the target jump animation corresponding to the target jump animation parameters; The source page exists in the first stack, the target page and the transition page both exist in the second stack, and the first stack and the second stack are not the same stack; The default transition animation is the transition animation triggered when navigating between pages across the stack.
2. The page transition animation control method according to claim 1, characterized in that, The page transparency of the transition page is a preset transparency value; Furthermore, the transition animation parameters also include the animation application state, and the animation application state is an unapplication state.
3. The page transition animation control method according to claim 1 or 2, characterized in that, The source page is provided with a first shared element, and the target page is provided with a second shared element, wherein the element identifier of the first shared element is consistent with the element identifier of the second shared element; Furthermore, the method further includes: When a trigger instruction is detected for the first shared element set for the source page, a preset jump instruction corresponding to the first shared element is triggered, and the preset jump instruction is determined as the page jump instruction triggered on the source page; The target jump animation parameters corresponding to the page jump instruction include the jump animation parameters pre-set for the first shared element.
4. The page transition animation control method according to claim 1 or 2, characterized in that, After controlling the application to execute a second jump operation from the transition page to the target page according to the target jump animation parameters, so as to display the target jump animation corresponding to the target jump animation parameters, the method further includes: When a page exit command triggered on the target page is detected, the target exit animation parameters corresponding to the page exit command are obtained; Based on the target exit animation parameters, the application is controlled to perform a first exit operation, which jumps from the target page to the transition page, so as to display the target exit animation corresponding to the target exit animation parameters; Based on the transition animation parameters, the application is controlled to perform a second exit operation, jumping from the transition page to the source page, so as not to display the default transition animation.
5. The page transition animation control method according to claim 4, characterized in that, The target exit animation parameters include the exit animation duration; The method further includes: Determine whether the first exit operation meets the pre-set blocking execution conditions; When it is determined that the first exit operation meets the blocking execution condition, a timer is set; the timer duration is the exit animation duration. After the timer has elapsed for the specified duration, the second exit operation, which controls the application to jump from the transition page to the source page based on the transition animation parameters, is triggered to prevent the default transition animation from being displayed.
6. The page transition animation control method according to claim 5, characterized in that, The determination of whether the first exit operation meets the preset blocking execution conditions includes: Determine whether a return value is generated after the first exit operation is completed, and whether the return value is used to trigger the execution of the second exit operation; When it is determined that the return value will be generated after the first exit operation is completed and the return value is used to trigger the execution of the second exit operation, it is determined that the first exit operation meets the pre-set blocking execution condition; If it is determined that no return value is generated after the first exit operation is completed, or the return value is not used to trigger the execution of the second exit operation, then the first exit operation does not meet the pre-set blocking execution conditions.
7. A page transition animation control device, characterized in that, The device is used in an electronic device, which has an application installed and is communicatively connected to a network attached storage device (NETS). The electronic device can access the NETS via the application. The application includes default transition animations between pages. The device comprises: The acquisition module is used to acquire the target jump animation parameters corresponding to the page jump instruction when a page jump instruction triggered on the source page is detected; wherein, the page jump instruction is used to instruct the application to jump from the source page to the target page; A module is created to create the transition page corresponding to the page jump instruction; The settings module is used to set the transition animation parameters corresponding to the default transition animation; the transition animation parameters include at least the transition animation duration, and the transition animation duration is 0; The control module is configured to control the application to perform a first jump operation from the source page to the transition page based on the transition animation parameters, so as not to display the default transition animation; The control module is further configured to control the application to perform a second jump operation from the transition page to the target page according to the target jump animation parameters, so as to display the target jump animation corresponding to the target jump animation parameters; The source page exists in the first stack, the target page and the transition page both exist in the second stack, and the first stack and the second stack are not the same stack; The default transition animation is the transition animation triggered when navigating between pages across the stack.
8. An electronic device, characterized in that, The electronic device includes: Memory containing executable program code; A processor coupled to the memory; The processor calls the executable program code stored in the memory to execute the page jump animation control method as described in any one of claims 1-6.
9. A page transition animation control system, characterized in that, The system includes the page transition animation control device as described in claim 7, and a network-attached storage device communicatively connected to the page transition animation control device; wherein the page transition animation control device controls the page transition animation effect according to the page transition animation control method as described in any one of claims 1-6; or, The system includes the electronic device as described in claim 8, and a network-attached storage device communicatively connected to the electronic device; wherein the electronic device controls the page transition animation effect according to the page transition animation control method as described in any one of claims 1-6.
10. A computer storage medium, characterized in that, The computer storage medium stores computer instructions, which, when invoked, are used to execute the page transition animation control method as described in any one of claims 1-6.
Citation Information
Patent Citations
Animation state machine creation method and device, animation control method and device, equipment and medium
CN111862272A
Animation loading implementation method, hybrid development application and storage medium
CN120104223A