WO2023202590A1 - 页面切换方法、装置以及终端设备的交互方法 - Google Patents

页面切换方法、装置以及终端设备的交互方法 Download PDF

Info

Publication number
WO2023202590A1
WO2023202590A1 PCT/CN2023/089052 CN2023089052W WO2023202590A1 WO 2023202590 A1 WO2023202590 A1 WO 2023202590A1 CN 2023089052 W CN2023089052 W CN 2023089052W WO 2023202590 A1 WO2023202590 A1 WO 2023202590A1
Authority
WO
WIPO (PCT)
Prior art keywords
page
visual element
target visual
switching
target
Prior art date
Application number
PCT/CN2023/089052
Other languages
English (en)
French (fr)
Inventor
王道裕
李星佑
王星懿
Original Assignee
北京字跳网络技术有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 北京字跳网络技术有限公司 filed Critical 北京字跳网络技术有限公司
Publication of WO2023202590A1 publication Critical patent/WO2023202590A1/zh

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/90Details of database functions independent of the retrieved data types
    • G06F16/95Retrieval from the web
    • G06F16/957Browsing optimisation, e.g. caching or content distillation
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/01Input arrangements or combined input and output arrangements for interaction between user and computer
    • G06F3/048Interaction techniques based on graphical user interfaces [GUI]
    • G06F3/0484Interaction techniques based on graphical user interfaces [GUI] for the control of specific functions or operations, e.g. selecting or manipulating an object, an image or a displayed text element, setting a parameter value or selecting a range
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/01Input arrangements or combined input and output arrangements for interaction between user and computer
    • G06F3/048Interaction techniques based on graphical user interfaces [GUI]
    • G06F3/0484Interaction techniques based on graphical user interfaces [GUI] for the control of specific functions or operations, e.g. selecting or manipulating an object, an image or a displayed text element, setting a parameter value or selecting a range
    • G06F3/0485Scrolling or panning
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/44Arrangements for executing specific programs
    • G06F9/451Execution arrangements for user interfaces

Definitions

  • the present disclosure relates to the field of information interaction technology, and in particular, to a page switching method, device, terminal device interaction method, electronic device, computer-readable storage medium, computer program product, and computer program.
  • page switching can be completed by overlaying the switched page on the pre-switched page.
  • page switching completed only by overlaying each other between pages cannot visually present the coherent displacement of visual elements, thereby reducing the user experience.
  • the present disclosure provides a page switching method, device, terminal device interaction method, electronic device, computer-readable storage medium, computer program product, and computer program.
  • an embodiment of the present disclosure provides a page switching method, including:
  • the target visual element is moved from the first position to a second position of the target visual element in the second page.
  • an embodiment of the present disclosure provides a page switching device, including:
  • An extraction module configured to extract target visual elements from the first page or the second page in response to a user-triggered page switching instruction, the page switching instruction being used to instruct switching the first page to the second page.
  • Page the target visual element is a visual element common to the first page and the second page;
  • An adding module configured to add the target visual element to the top view of the first position of the first page, where the first position is the original position of the target visual element in the first page;
  • a switching module configured to move the target visual element from the first position to a second position of the target visual element in the second page when the first page is switched to the second page.
  • inventions of the present disclosure provide an interaction method for a terminal device.
  • the method includes:
  • control the first page In response to the user's triggering operation on the first page, control the first page to perform a first deformation, the first page and trigger a page switching instruction;
  • the first deformed target visual element performs a second deformation.
  • an electronic device including:
  • Memory used to store computer programs
  • the processor is configured to implement the page switching method as described in the above first aspect and various possible designs of the first aspect by executing the computer program.
  • embodiments of the present disclosure provide a computer-readable storage medium.
  • Computer-executable instructions are stored in the computer-readable storage medium.
  • the processor executes the computer-executable instructions, the above first aspect and the first aspect are implemented. Page switching methods described in various possible designs.
  • embodiments of the present disclosure provide a computer program product, including a computer program that, when executed by a processor, implements the page switching method described in the above first aspect and various possible designs of the first aspect.
  • embodiments of the present disclosure provide a computer program that, when executed by a processor, implements the page switching method described in the above first aspect and various possible designs of the first aspect.
  • Embodiments of the present disclosure provide a page switching method, device, terminal device interaction method, electronic device, computer-readable storage medium, computer program product and computer program, in response to a page switching instruction triggered by a user, from the first page or A target visual element is extracted from the second page.
  • the page switching instruction is used to instruct switching the first page to the second page.
  • the target visual element is a common visual element between the first page and the second page. Subsequently, the target visual element is added to the top view of the first position on the first page, and the first position is the original position of the target visual element on the first page. Finally, when the first page is switched to the second page, the target visual element is moved from the first position to the second position of the target visual element on the second page.
  • Figure 1 is a schematic flowchart of a page switching method provided by an embodiment of the present disclosure.
  • FIG. 2 is a schematic diagram of page switching provided by an embodiment of the present disclosure.
  • FIG. 3 is a schematic flowchart of an interaction method for a terminal device provided by an embodiment of the present disclosure.
  • FIG. 4 is a schematic diagram of a triggering operation provided by an embodiment of the present disclosure.
  • FIG. 5 is a schematic flowchart of another page switching method provided by an embodiment of the present disclosure.
  • FIG. 6 is a schematic flowchart of yet another page switching method provided by an embodiment of the present disclosure.
  • FIG. 7 is a schematic structural diagram of a page switching device provided by an embodiment of the present disclosure.
  • FIG. 8 is a schematic structural diagram of an electronic device provided by an embodiment of the present disclosure.
  • the term “include” and its variations are open-ended, ie, “including but not limited to.”
  • the term “based on” means “based at least in part on.”
  • the term “one embodiment” means “at least one embodiment”; the term “another embodiment” means “at least one additional embodiment”; and the term “some embodiments” means “at least some embodiments”. Relevant definitions of other terms will be given in the description below.
  • page switching can be completed by overlaying the switched page on the pre-switched page.
  • page switching completed only by overlaying each other between pages cannot visually present the coherent displacement of visual elements, thereby reducing the user experience.
  • the present disclosure aims to: extract common target visual elements from the first page before switching or the second page after switching, and place the target visual elements at the top of the view of the first page. When, the target visual element is then displaced.
  • this method not only can the visual displacement continuity of the target visual element be ensured, but also the playback continuity of the internal animation of the target visual element during the page switching process can be ensured, thereby improving the user experience.
  • the page switching method provided in this embodiment can be applied in video application scenarios.
  • users can switch between different playback pages. For example, you can switch the full-screen playback page to a graphic playback page.
  • the full-screen playback page contains an image carousel component
  • the graphic playback page contains an image carousel component and a text display component.
  • the common image carousel component can be extracted from the full-screen playback page or the graphic playback page and placed on the top view of the page before the switch. Subsequently, during the switching process between the full-screen playback page and the graphic playback page, the image carousel component can be moved from the position in the page before the switch to the position in the page after the switch.
  • the page switching method provided in this embodiment can be applied in an instant messaging application scenario.
  • a user uses an instant messaging application and plays a video in the session, the user can play the video in the full-screen playback page and window. Switch between each other in the playback page.
  • the video carousel component can also be extracted from the full-screen playback page or the window playback page and placed on top of the view of the page before the switch. Subsequently, during the switching process between the full-screen play page and the window play page, the video carousel component can be moved from the position in the page before the switch to the position in the page after the switch.
  • the page switching device can be part or all of a certain device, such as a terminal device or a processor of the terminal device.
  • FIG. 1 is a schematic flowchart of a page switching method provided by an embodiment of the present disclosure. As shown in Figure 1, the page switching method provided by this embodiment includes:
  • Step 101 In response to the page switching instruction triggered by the user, extract the target visual element from the first page or the second page.
  • the page switching instruction is used to instruct switching the first page to the second page.
  • first page and the second page can be any pages in the application.
  • first page and the second page can be switched back and forth through a user-triggered switching instruction.
  • the first page may be a full-screen playback page
  • the second page may be a graphic playback page.
  • the user can trigger the page switching command to switch the full-screen playback page to the graphics and text playback page, and can also trigger the page switching command to switch the graphics and text playback page to the full-screen playback page.
  • the visual elements involved in this disclosure may be components displayed on the first page or the second page.
  • the target visual element may be a visual element common to the first page and the second page.
  • the target visual elements may include image carousel components, video carousel components, text carousel components, etc.
  • the target visual element involved in the present disclosure may include at least one piece of content to be played, and each piece of content to be played may be connected through a preset animation special effect.
  • the content to be played can be determined according to the type of the target visual element. If the target visual element is an image carousel component, then the corresponding content to be played is an image; if the target visual element is a video carousel component, then the corresponding content to be played is a video; if the target visual element is a text carousel component, Correspondingly, the content to be played is text.
  • the embodiments of the present disclosure do not limit how the user triggers the page switching instruction.
  • the user can trigger the page switching instruction by performing a triggering operation on the display interface of the terminal device.
  • the triggering operation may include clicking, sliding at a preset angle, etc.
  • the preset angle of sliding may be, for example, a downward sliding between 75° and 115° with the horizontal plane.
  • Trigger operations such as clicking or sliding at a preset angle can be performed in a specific area of the display interface, or can be performed in any area on the display interface. This is not limited in the embodiments of the present disclosure.
  • the display interface of the terminal device may perform corresponding display changes. For example, when the user's trigger operation is detected, the display interface of the terminal device can be reduced. When the user's trigger operation is detected, the page can be switched and the display interface of the terminal device can be enlarged, and then displayed in the display interface. Target visual elements.
  • FIG. 2 is a schematic diagram of page switching provided by an embodiment of the present disclosure.
  • the first page is a full-screen playback page
  • the second page is a graphic and text playback page. If the user clicks on the text area suspended on the image carousel component 21 in the full-screen playback page, the first switching instruction is triggered, and the terminal device switches from the full-screen playback page to the graphic and text playback page. If the user slides down on the display position corresponding to the image carousel component 21 in the image and text playback page, the second switching instruction is triggered, and the terminal device switches from the image and text playback page to the full-screen playback page.
  • the image carousel component 21 can be the above-mentioned target visual element.
  • the embodiments of the present disclosure do not limit how to extract the target visual element.
  • the target visual element can be extracted from the view tree of the first page or the second page.
  • the view tree contains the visual elements of each view on the page and is stored according to the view hierarchy.
  • the terminal device can compare the first page and the second page, thereby using the visual elements common to the first page and the second page as the target visual elements. Subsequently, the terminal device can extract the target visual element from the first page, and can also extract the target visual element from the second page.
  • animation playback parameters of the target visual element extracted from the first page and the target visual element extracted from the second page are different.
  • the animation playback parameters include the view state of the target visual element and the animation effect included in the target visual element.
  • the animation effect is the switching effect between the playback content in the target visual element, and the animation effects between different playback contents can be the same or different.
  • the view state is used to indicate the playback progress of the playback content in the target visual element, which can be implemented through the offset in the view state.
  • the view state may also include information such as business parameters to indicate the size of the target visual element, playback of dubbing, and other information.
  • Step 102 Add the target visual element to the top view of the first position on the first page.
  • the target visual element can be added to the top view of the first position on the first page.
  • the first position is the original position of the target visual element on the first page.
  • the terminal device can directly switch pages and move the position of the target visual element.
  • the target visual element is a visual element extracted from the second page
  • the terminal device adds the target visual element to the top view of the first position on the first page
  • the first animation playback parameter in the first page is synchronized to the second animation playback parameter of the target visual element in the second page.
  • the terminal device can first traverse and save the view state and animation effect of the target visual element on the first page. Subsequently, the view state and animation effect of the target visual element in the first page are added to the second animation playback parameter in sequence.
  • the view state and animation effect of the target visual element extracted from the second page and the target visual element in the first page can be completely consistent. , thus making the user unable to perceive the switching between target visual elements during the page switching process.
  • extracting the target visual elements from the second page can also avoid the problem of frequent moving of the target visual elements, ensuring stability during page switching.
  • the target visual element when the target visual element is added to the top level of the view at the first position of the first page, the target visual element can also be kept for animation playback according to the playback progress corresponding to the view state.
  • the playback progress can be determined by the playback content indicated by the offset in the view state.
  • Step 103 When the first page is switched to the second page, move the target visual element from the first position to the second position of the target visual element on the second page.
  • the first page can be switched to the second page, and during the switching process, the target visual element can be moved from the first position to the target visual element on the second page. second position in.
  • the terminal device may first obtain the relative position between the target visual element and the reference visual element in the second page, and then set the target visual element to the second position. The relative position between the element and the reference visual element in the second page is converted to the second position.
  • the reference visual element can be any visual element in the terminal device.
  • the second position of the target visual element can be determined through the relative position between the target visual element and the reference visual element, and the relative position between the reference visual element and the display interface.
  • special effects can also be added to the target visual element, thereby optimizing the user's visual experience.
  • the target visual element when the terminal device switches the first page to the second page and completes the displacement of the target visual element, the target visual element can be placed back into the corresponding layer of the second page, thereby completing the page switch.
  • the virtual resource acquisition method extracts the target visual element from the first page or the second page in response to a page switching instruction triggered by the user.
  • the page switching instruction is used to indicate switching the first page to the second page.
  • Page the target visual element is a visual element common to the first page and the second page.
  • the target visual element is added to the top view of the first position on the first page, and the first position is the original position of the target visual element on the first page.
  • the target visual element is moved from the first position to the second position of the target visual element on the second page.
  • the common visual elements are first placed on top and then displaced when the page is switched, it can not only ensure the visual continuity of the displacement of the target visual element, but also ensure the internal animation of the target visual element during the page switching process. Playback continuity, thereby improving user experience.
  • FIG. 3 is a schematic flowchart of an interaction method for a terminal device provided by an embodiment of the present disclosure. As shown in Figure 3, the interaction method of the terminal device provided by this embodiment includes:
  • Step S201 Display the first page.
  • Step S202 In response to the user's triggering operation on the first page of animation playback parameters, control the first page to perform a first deformation and trigger a page switching instruction.
  • the first page is reduced and the page switching instruction is triggered.
  • the embodiments of the present disclosure do not limit the triggering operation.
  • the triggering operation may include sliding at a preset angle on the screen of the animation playback parameter terminal device.
  • the preset angle of sliding may be, for example, a downward sliding between 75° and 115° with the horizontal plane.
  • the embodiments of the present disclosure do not limit the triggering area on the screen of the terminal device for triggering the operation.
  • the area where the target visual element is located may be the triggering area on the screen of the terminal device for triggering the operation. .
  • the embodiments of the present disclosure do not limit the reduction ratio of the display interface.
  • the display interface can be reduced to 80%, 70%, etc. before the trigger operation is performed.
  • Figure 4 is a schematic diagram of a triggering operation provided by an embodiment of the present disclosure.
  • the page switching command can be triggered.
  • the display interface can be reduced as shown in Figure 4, and remains in the reduced state during the user's triggering operation.
  • Step S203 After detecting that the trigger operation is completed, switch the first page to the second page.
  • the embodiments of the present disclosure do not limit how to detect the end of the triggering operation.
  • the end of the triggering operation may be determined when it is detected that the user ends the sliding on the terminal device. In other embodiments, it may be determined that the triggering operation ends when it is detected that the triggering part such as the user's finger leaves the screen of the terminal device.
  • Step S204 Display the target visual element in the second interface, wherein during the process of switching from the first page to the second page, the first deformed target visual element performs the second deformation.
  • the second deformation may be a deformation operation opposite to the first deformation.
  • the first page performs the first deformation
  • the first page performs a zoom-out operation
  • the target visual element performs the second deformation to perform a zoom-in operation on the target visual element.
  • the target visual elements can achieve continuous changing states.
  • the page switching instruction is triggered by sliding at a preset angle on the screen of the terminal device, and during the page switching process, the display interface is reduced and enlarged. In this way, the interactivity with the user during the page switching process can be improved, thereby improving the user experience.
  • FIG. 5 is a schematic flowchart of another page switching method provided by an embodiment of the present disclosure.
  • Figure 5 relates to the processing flow of target visual elements extracted from the first page.
  • the page switching method provided by this embodiment includes:
  • Step S301 In response to the page switching instruction triggered by the user, extract the target visual element from the view tree of the first page.
  • the page switching instruction is used to instruct switching the first page to the second page, and the target visual element is a visual element common to the first page and the second page.
  • view tree contains visual elements of each layer of views in the page, and is stored according to the view hierarchy.
  • Step S302 Add the target visual element to the top view of the first page at a first position, where the first position is the original position of the target visual element in the first page.
  • Step S303 Obtain the relative position between the target visual element and the reference visual element in the second page.
  • Step S304 Convert the relative position between the target visual element and the reference visual element in the second page to a second position.
  • the terminal device may first obtain the relative position between the target visual element and the reference visual element in the second page, and then set the target visual element to the second position. The relative position between the element and the reference visual element in the second page is converted to the second position.
  • the reference visual element can be any visual element in the terminal device.
  • the second position of the target visual element can be determined through the relative position between the template visual element and the reference visual element, and the relative position between the reference visual element and the display interface.
  • Step S305 When the first page is switched to the second page, move the target visual element from the first position to the second position of the target visual element on the second page.
  • special effects can also be added to the target visual element, thereby optimizing the user's visual experience.
  • Step S306 Put the target visual element into the view layer corresponding to the second page.
  • the view layer corresponding to the second page is the view layer where the target visual element was originally located in the second page.
  • steps S301-S306 can be understood with reference to S101-S103 shown in Figure 1.
  • the repeated content will not be repeated here.
  • FIG. 6 is a schematic flowchart of yet another page switching method provided by an embodiment of the present disclosure.
  • Figure 6 relates to the processing flow of target visual elements extracted from the second page.
  • the page switching method provided by this embodiment includes:
  • Step S401 In response to the page switching instruction triggered by the user, extract the target visual element from the view tree of the second page.
  • the page switching instruction is used to instruct switching the first page to the second page, and the target visual element is a visual element common to the first page and the second page.
  • Step S402 Add the target visual element to the top view of the first page at a first position, where the first position is the original position of the target visual element in the first page.
  • Step S403 Traverse and save the view state and animation effect of the target visual element in the first page.
  • the view state can include offsets and business parameters.
  • Step S404 Add the view status and animation effect of the target visual element in the first page to the second animation playback parameters in sequence.
  • the second animation playback parameter by assigning the view state of the target visual element in the first page to the second animation playback parameter, it can be ensured that the target visual element added at the top level of the view is synchronized with the view state of the original target visual element in the first page.
  • the animation effect of the target visual element in the first page by adding the animation effect of the target visual element in the first page to the second animation playback parameter, it can be ensured that the animation effect of the target visual element added at the top level of the view is synchronized with the animation effect of the original target visual element in the first page.
  • Step S405 Obtain the relative position between the target visual element and the reference visual element in the second page.
  • Step S406 Convert the relative position between the target visual element and the reference visual element in the second page to a second position.
  • Step S407 When the first page is switched to the second page, move the target visual element from the first position to the second position of the target visual element on the second page.
  • Step S408 Put the target visual element into the view layer corresponding to the second page.
  • steps S401-S408 can be understood with reference to S101-S103 shown in Figure 1.
  • the repeated content will not be repeated here.
  • the virtual resource acquisition method extracts the target visual element from the first page or the second page in response to a page switching instruction triggered by the user.
  • the page switching instruction is used to indicate switching the first page to the second page.
  • Page the target visual element is a visual element common to the first page and the second page.
  • the target visual element is added to the top view of the first position on the first page, and the first position is the original position of the target visual element on the first page.
  • the target visual element is moved from the first position to the second position of the target visual element on the second page.
  • the common visual elements are first placed on top and then displaced when the page is switched, it can not only ensure the visual continuity of the displacement of the target visual element, but also ensure the internal animation of the target visual element during the page switching process. Playback continuity, thereby improving user experience.
  • FIG. 7 is a schematic structural diagram of a page switching device provided by an embodiment of the present disclosure.
  • the page switching device 500 provided in this embodiment includes: an extraction module 501, an adding module 502, a switching module 503 and a synchronization module 504.
  • the extraction module 501 is configured to extract the target visual element from the first page or the second page in response to a page switching instruction triggered by the user.
  • the page switching instruction is used to instruct the first page to be switched to the second page, and the target visual element is the third page. Visual elements common to the first page and the second page.
  • the adding module 502 is used to add the target visual element to the top view of the first page at a first position, where the first position is the original position of the target visual element in the first page.
  • the switching module 503 is configured to move the target visual element from the first position to the second position of the target visual element on the second page when the first page is switched to the second page.
  • the target visual element extracted from the first page has different animation playback parameters from the target visual element extracted from the second page.
  • the animation playback parameters include a view state of the target visual element and an animation effect included in the target visual element
  • the view state is used to indicate the playback progress of the playback content in the target visual element
  • the animation effect is the switching effect between the playback content in the target visual element
  • the page switching device 500 further includes:
  • the synchronization module 504 is used to synchronize the first animation playback parameter of the target visual element in the first page to the second animation playback parameter of the target visual element in the second page.
  • the synchronization module 504 is specifically configured to traverse and save the view state and animation effect of the target visual element in the first page; The effects are added to the second animation playback parameters in turn.
  • the switching module 503 is also used to maintain the target visual element for animation playback according to the playback progress corresponding to the view state.
  • the first position and the second position are relative positions of the target visual element on the display interface.
  • the switching module 503 is also used to obtain the relative position between the target visual element and the reference visual element in the second page; and combine the target visual element and the reference visual element in the second page. The relative position between is converted to the second position.
  • the target visual elements include image carousel components, video carousel components, and text carousel components.
  • page switching device provided by the embodiment shown in Figure 7 can be used to perform the method provided by any of the above embodiments.
  • the specific implementation methods and technical effects are similar, and will not be described again here.
  • FIG. 8 is a schematic structural diagram of an electronic device provided by an embodiment of the present disclosure. As shown in FIG. 8 , it shows a schematic structural diagram of an electronic device 900 suitable for implementing embodiments of the present disclosure.
  • Terminal devices in the embodiments of the present disclosure may include, but are not limited to, mobile phones, notebook computers, digital broadcast receivers, personal digital assistants (Personal Digital Assistant, PDA), tablet computers (Portable Android Device, PAD), portable multimedia players (Portable Media Player, PMP), vehicle-mounted terminals (such as vehicle-mounted navigation terminals), wearable electronic devices and other mobile terminals with image acquisition functions, as well as external devices with image acquisition devices such as digital TVs, desktop computers, smart home devices, etc.
  • Fixed terminal The electronic device shown in FIG. 8 is only an example and should not impose any limitations on the functions and scope of use of the embodiments of the present disclosure.
  • the electronic device 900 may include a processing device (such as a central processing unit, a graphics processor, etc.) 601 , which may be loaded according to a program stored in a read-only memory (Read Only Memory, ROM) 602 or loaded from a memory 607 to the program in the random access memory (Random Access Memory, RAM) 603 to execute various appropriate actions and processes.
  • a processing device such as a central processing unit, a graphics processor, etc.
  • ROM read-only memory
  • RAM random access memory
  • various programs and data required for the operation of the electronic device 600 are also stored.
  • the processing device 601, ROM 602 and RAM 603 are connected to each other via a bus 604. Input/Output (I/O) interface 605 also Connected to bus 604.
  • the memory is used to store programs for executing the methods of each of the above method embodiments; the processor is configured to execute the programs stored in the memory to implement the functions of the above embodiments of the present disclosure and/or other desired functions.
  • the following devices can be connected to the I/O interface 605: input devices 609 including, for example, a touch screen, touch pad, keyboard, mouse, camera, microphone, accelerometer, gyroscope, etc.; including, for example, a Liquid Crystal Display (LCD) , an output device 608 such as a speaker, a vibrator, etc.; a storage device 607 including a magnetic tape, a hard disk, etc.; and a communication device 606.
  • Communication device 606 may allow electronic device 900 to communicate wirelessly or wiredly with other devices to exchange data.
  • FIG. 8 illustrates electronic device 900 with various means, it should be understood that implementation or availability of all illustrated means is not required. More or fewer means may alternatively be implemented or provided.
  • embodiments of the present disclosure include a computer program product including a computer program carried on a non-transitory computer-readable medium, the computer program including a program for performing the method illustrated in the flowchart of the embodiment of the present disclosure. code.
  • the computer program may be downloaded and installed from the network via communication device 606, or from storage device 607, or from ROM 602.
  • the processing device 601 When the computer program is executed by the processing device 601, the above functions defined in the method of the embodiment of the present disclosure are performed.
  • Embodiments of the present disclosure also include a computer program that, when executed by a processor, implements the above functions defined in the method of the embodiment of the present disclosure.
  • the computer-readable medium mentioned above in the present disclosure may be a computer-readable signal medium or a computer-readable storage medium, or any combination of the above two.
  • the computer-readable storage medium may be, for example, but is not limited to, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus or device, or any combination thereof.
  • Computer readable storage media may include, but are not limited to: an electrical connection having one or more wires, a portable computer disk, a hard drive, random access memory (RAM), read only memory (ROM), removable Programmable read-only memory (Electrical Programmable ROM, EPROM or flash memory), optical fiber, portable compact disk read-only memory (Compact Disc ROM, CD-ROM), optical storage device, magnetic storage device, or any suitable combination of the above.
  • a computer-readable storage medium may be any tangible medium that contains or stores a program for use by or in connection with an instruction execution system, apparatus, or device.
  • a computer-readable signal medium may include a data signal propagated in baseband or as part of a carrier wave, carrying computer-readable program code therein. Such propagated data signals may take many forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination of the above.
  • a computer-readable signal medium may also be any computer-readable medium other than a computer-readable storage medium that can send, propagate, or transmit a program for use by or in connection with an instruction execution system, apparatus, or device .
  • Program code contained on a computer-readable medium can be transmitted using any appropriate medium, including but not limited to: wires, optical cables, radio frequency (Radio Frequency, RF), etc., or any suitable combination of the above.
  • the above-mentioned computer-readable medium may be included in the above-mentioned electronic device; it may also exist independently without being assembled into the electronic device.
  • the computer-readable medium carries one or more programs.
  • the electronic device displays the first shooting interface in response to the first instruction triggered by the user, wherein the first A shooting interface includes multiple target shooting modes; in response to the user's trigger operation on the first shooting interface, the first virtual resource is acquired, and an icon corresponding to the first virtual resource is displayed on the first shooting interface; wherein, the multiple targets
  • the shooting modes include at least one variable shooting mode configured to change over time.
  • Computer program code for performing the operations of the present disclosure may be written in one or more programming languages, including but not limited to object-oriented programming languages—such as Java, Smalltalk, C++, or a combination thereof, Also included are conventional procedural programming languages—such as the "C" language or similar programming languages.
  • the program code may execute entirely on the user's computer, partly on the user's computer, as a stand-alone software package, partly on the user's computer and partly on a remote computer or entirely on the remote computer or server.
  • the remote computer can be connected to the user's computer through any kind of network, including a Local Area Network (LAN) or a Wide Area Network (WAN), or it can be connected to an external computer ( For example, using an Internet service provider to connect via the Internet).
  • LAN Local Area Network
  • WAN Wide Area Network
  • the client and server can communicate using any currently known or future developed network protocol such as HTTP (HyperText Transfer Protocol), and can communicate with digital data in any form or medium.
  • Communications e.g., communications network
  • communications networks include local area networks (“LAN”), wide area networks (“WAN”), the Internet (e.g., the Internet), and end-to-end networks (e.g., ad hoc end-to-end networks), as well as any currently known or developed in the future network of.
  • each block in the flowchart or block diagram may represent a module, segment, or portion of code that contains one or more logic functions that implement the specified executable instructions.
  • the functions noted in the block may occur out of the order noted in the figures. For example, two blocks shown one after another may actually execute substantially in parallel, or they may sometimes execute in the reverse order, depending on the functionality involved.
  • each block of the block diagram and/or flowchart illustration, and combinations of blocks in the block diagram and/or flowchart illustration can be implemented by special purpose hardware-based systems that perform the specified functions or operations. , or can be implemented using a combination of specialized hardware and computer instructions.
  • the modules involved in the embodiments of the present disclosure can be implemented in software or hardware. Among them, the name of the module does not constitute a limitation on the unit itself under certain circumstances.
  • exemplary types of hardware logic components include: field programmable gate array (Field Programmable Gate Array, FPGA), application specific integrated circuit (Application Specific Integrated Circuit, ASIC), application specific standard product (Application Specific Standard Product (ASSP), System on Chip (SOC), Complex Programmable Logic Device (CPLD), etc.
  • computer-readable media may be tangible media that may contain or store a program for use by or in connection with an instruction execution system, apparatus, or device.
  • the computer-readable medium may be a computer-readable signal medium or a computer-readable storage medium.
  • Computer-readable media may include, but are not limited to, electronic, magnetic, optical, electromagnetic, infrared, or semiconductor systems, devices or devices, or any suitable combination of the foregoing.
  • Computer readable storage media may include one or more wire-based electrical connections, portable computer disks, hard drives, random access memory (RAM), read only memory (ROM), erasable programmable read only memory (EPROM or flash memory), optical fiber, portable compact disk read-only memory (CD-ROM), optical storage device, magnetic storage device, or any suitable combination of the above.
  • RAM random access memory
  • ROM read only memory
  • EPROM or flash memory erasable programmable read only memory
  • CD-ROM compact disk read-only memory
  • magnetic storage device or any suitable combination of the above.
  • a page switching method including:
  • the target visual element is moved from the first position to a second position of the target visual element in the second page.
  • the target visual element extracted from the first page has different animation playback parameters from the target visual element extracted from the second page.
  • the animation playback parameters include a view state of the target visual element and an animation effect included in the target visual element
  • the view state is used to indicate the playback progress of the playback content in the target visual element
  • the animation effect is a switching effect between the playback content in the target visual element
  • the method also includes:
  • the first animation playback parameter of the target visual element in the first page is synchronized to the second animation of the target visual element in the second page.
  • Play parameters including:
  • the view state and animation effect of the target visual element in the first page are sequentially added to the second animation playback parameter.
  • the method further includes:
  • the target visual element is maintained for animation playback.
  • the first position and the second position are relative positions of the target visual element on the display interface.
  • the method before moving the target visual element from the first position to a second position of the target visual element in the second page, the method further include:
  • the target visual elements include an image carousel component, a video carousel component, and a text carousel component.
  • a page switching device including:
  • An extraction module configured to extract target visual elements from the first page or the second page in response to a user-triggered page switching instruction, the page switching instruction being used to instruct switching the first page to the second page.
  • Page the target visual element is a visual element common to the first page and the second page;
  • An adding module configured to add the target visual element to the top view of the first position of the first page, where the first position is the original position of the target visual element in the first page;
  • a switching module configured to move the target visual element from the first position to a second position of the target visual element in the second page when the first page is switched to the second page.
  • the target visual element extracted from the first page has different animation playback parameters from the target visual element extracted from the second page.
  • the animation playback parameters include a view state of the target visual element and an animation effect included in the target visual element
  • the view state is used to indicate the playback progress of the playback content in the target visual element
  • the animation effect is a switching effect between the playback content in the target visual element
  • the page switching device further includes:
  • a synchronization module configured to synchronize the first animation playback parameter of the target visual element in the first page to the second animation playback parameter of the target visual element in the second page.
  • the synchronization module is specifically configured to traverse and save the view status and animation effect of the target visual element in the first page;
  • the view state and animation effects in the first page are sequentially added to the second animation playback parameters.
  • the switching module is further configured to maintain the target visual element for animation playback according to the playback progress corresponding to the view state.
  • the first position and the second position are relative positions of the target visual element on the display interface.
  • the switching module is further configured to obtain the relative position between the target visual element and the reference visual element in the second page; and combine the target visual element with the reference visual element.
  • the relative positions between the reference visual elements in the second page are converted to the second position.
  • the target visual elements include an image carousel component, a video carousel component, and a text carousel component.
  • embodiments of the present disclosure provide an interaction method for a terminal device, including
  • control the first page In response to the user's triggering operation on the first page, control the first page to perform a first deformation and trigger a page switching instruction;
  • the first deformed target visual element performs a second deformation.
  • the triggering operation includes sliding at a preset angle on the screen of the terminal device.
  • an electronic device including:
  • Memory used to store computer programs
  • the processor is configured to implement the page switching method as described in the above-mentioned first aspect and various possible designs of the first aspect by executing the computer program.
  • embodiments of the present disclosure provide a computer-readable storage medium.
  • Computer-executable instructions are stored in the computer-readable storage medium.
  • the processor executes the computer-executable instructions, the above first aspect and the first aspect are implemented. Page switching methods described in various possible designs.
  • embodiments of the present disclosure provide a computer program product, including a computer program that, when executed by a processor, implements the page switching method described in the above first aspect and various possible designs of the first aspect.
  • embodiments of the present disclosure provide a computer program that, when executed by a processor, implements the page switching method described in the above first aspect and various possible designs of the first aspect.

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • General Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Human Computer Interaction (AREA)
  • Software Systems (AREA)
  • Databases & Information Systems (AREA)
  • Data Mining & Analysis (AREA)
  • User Interface Of Digital Computer (AREA)

Abstract

本公开提供一种页面切换方法、装置、终端设备的交互方法、电子设备、计算机可读存储介质、计算机程序产品及计算机程序。本公开提供的页面切换方法,响应于用户触发的页面切换指令,从第一页面或第二页面中提取目标视觉元素,页面切换指令用于指示将第一页面切换为第二页面,目标视觉元素为第一页面和第二页面共有的视觉元素;将目标视觉元素添加到第一页面的第一位置的视图顶层,第一位置为目标视觉元素在第一页面中的原位置;在第一页面切换为第二页面时,将目标视觉元素从第一位置移动至目标视觉元素在第二页面中的第二位置。通过该方式,由于在页面切换时,将共有的视觉元素先置顶再进行位移,从而保证了视觉元素的位移连贯性。

Description

页面切换方法、装置以及终端设备的交互方法
相关申请的交叉引用
本申请要求于2022年4月20日提交中国专利局、申请号202210418796.7、发明名称为“页面切换方法、装置以及终端设备的交互方法”的中国专利申请的优先权,其全部内容通过引用结合在本文中。
技术领域
本公开涉及信息交互技术领域,尤其涉及一种页面切换方法、装置、终端设备的交互方法、电子设备、计算机可读存储介质、计算机程序产品及计算机程序。
背景技术
随着网络技术的发展,各种类型的视频应用正不断深入到人们的生活中。用户在使用视频应用时,可以基于不同的观看需求,进行不同类型的页面之间的相互切换。
相关技术中,可以通过将切换后的页面覆盖在切换前的页面上,从而完成页面切换。然而,仅仅通过页面之间的相互覆盖完成的页面切换,在视觉上无法呈现视觉元素的连贯位移,从而降低用户体验。
发明内容
本公开提供一种页面切换方法、装置、终端设备的交互方法、电子设备、计算机可读存储介质、计算机程序产品及计算机程序。
第一方面,本公开实施例提供一种页面切换方法,包括:
响应于用户触发的页面切换指令,从第一页面或第二页面中提取目标视觉元素,所述页面切换指令用于指示将所述第一页面切换为所述第二页面,所述目标视觉元素为所述第一页面和所述第二页面共有的视觉元素;
将所述目标视觉元素添加到所述第一页面的第一位置的视图顶层,所述第一位置为所述目标视觉元素在所述第一页面中的原位置;
在所述第一页面切换为所述第二页面时,将所述目标视觉元素从所述第一位置移动至所述目标视觉元素在所述第二页面中的第二位置。
第二方面,本公开实施例提供一种页面切换装置,包括:
提取模块,用于响应于用户触发的页面切换指令,从所述第一页面或第二页面中提取目标视觉元素,所述页面切换指令用于指示将所述第一页面切换为所述第二页面,所述目标视觉元素为所述第一页面和所述第二页面共有的视觉元素;
添加模块,用于将所述目标视觉元素添加到所述第一页面的第一位置的视图顶层,所述第一位置为所述目标视觉元素在所述第一页面中的原位置;
切换模块,用于在所述第一页面切换为所述第二页面时,将所述目标视觉元素从所述第一位置移动至所述目标视觉元素在所述第二页面中的第二位置。
第三方面,本公开实施例提供一种终端设备的交互方法,所述方法包括:
显示第一页面;
响应于用户对所述第一页面的触发操作,控制所述第一页面执行第一形变,第一页面并触发页面切换指令;
当检测到所述触发操作结束后,执行如前所述的页面切换方法;
显示第二界面中的目标视觉元素;
其中,所述第一页面切换至第二页面的过程中,所述第一形变后的目标视觉元素执行第二形变。
第四方面,本公开实施例提供一种电子设备,包括:
处理器;以及
存储器,用于存储计算机程序;
其中,所述处理器被配置为通过执行所述计算机程序来实现如上第一方面以及第一方面各种可能的设计中所述的页面切换方法。
第五方面,本公开实施例提供一种计算机可读存储介质,所述计算机可读存储介质中存储有计算机执行指令,当处理器执行所述计算机执行指令时,实现如上第一方面以及第一方面各种可能的设计中所述的页面切换方法。
第六方面,本公开实施例提供一种计算机程序产品,包括计算机程序,该计算机程序被处理器执行时实现如上第一方面以及第一方面各种可能的设计中所述的页面切换方法。
第七方面,本公开实施例提供一种计算机程序,该计算机程序被处理器执行时实现如上第一方面以及第一方面各种可能的设计中所述的页面切换方法。
本公开实施例提供的一种页面切换方法、装置、终端设备的交互方法、电子设备、计算机可读存储介质、计算机程序产品及计算机程序,响应于用户触发的页面切换指令,从第一页面或第二页面中提取目标视觉元素,该页面切换指令用于指示将第一页面切换为第二页面,该目标视觉元素为第一页面和第二页面共有的视觉元素。随后,将目标视觉元素添加到第一页面的第一位置的视图顶层,第一位置为目标视觉元素在第一页面中的原位置。最后,在第一页面切换为第二页面时,将目标视觉元素从第一位置移动至目标视觉元素在第二页面中的第二位置。
附图说明
为了更清楚地说明本公开实施例或相关技术中的技术方案,下面将对实施例或相关技术描述中所需要使用的附图作一简单地介绍,显而易见地,下面描述中的附图是本公开的一些实施例,对于本领域普通技术人员来讲,在不付出创造性劳动性的前提下,还可以根据这些附图获得其他的附图。
图1为本公开实施例提供的一种页面切换方法的流程示意图。
图2为本公开实施例提供的一种页面切换的示意图。
图3为本公开实施例提供的一种终端设备的交互方法的流程示意图。
图4为本公开实施例提供的一种触发操作的示意图。
图5为本公开实施例提供的另一种页面切换方法的流程示意图。
图6为本公开实施例提供的再一种页面切换方法的流程示意图。
图7为本公开实施例提供的一种页面切换装置的结构示意图。
图8为本公开实施例提供的一种电子设备的结构示意图。
具体实施方式
下面将参照附图更详细地描述本公开的实施例。虽然附图中显示了本公开的某些实施例,然而应当理解的是,本公开可以通过各种形式来实现,而且不应该被解释为限于这里阐述的实施例,相反提供这些实施例是为了更加透彻和完整地理解本公开。应当理解的是,本公开的附图及实施例仅用于示例性作用,并非用于限制本公开的保护范围。
应当理解,本公开的方法实施方式中记载的各个步骤可以按照不同的顺序执行,和/或并行执行。此外,方法实施方式可以包括附加的步骤和/或省略执行示出的步骤。本公开的范围在此方面不受限制。
本文使用的术语“包括”及其变形是开放性包括,即“包括但不限于”。术语“基于”是“至少部分地基于”。术语“一个实施例”表示“至少一个实施例”;术语“另一实施例”表示“至少一个另外的实施例”;术语“一些实施例”表示“至少一些实施例”。其他术语的相关定义将在下文描述中给出。
需要注意,本公开中提及的“一个”、“多个”的修饰是示意性而非限制性的,本领域技术人员应当理解,除非在上下文另有明确指出,否则应该理解为“一个或多个”。
相关技术中,可以通过将切换后的页面覆盖在切换前的页面上,从而完成页面切换。然而,仅仅通过页面之间的相互覆盖完成的页面切换,在视觉上无法呈现视觉元素的连贯位移,从而降低用户体验。
此外,还可以通过对视觉元素进行截图所生成的假元素,并通过对假元素进行位移来伪装视觉元素的位移。然而,通过假元素的伪装无法实现在页面切换过程中视觉元素的内部动画的连贯播放。
针对上述技术问题,本公开旨在:从切换前的第一页面或切换后的第二页面中提取共有的目标视觉元素,并将该目标视觉元素置于第一页面的视图顶层,在页面切换时,再将目标视觉元素进行位移。通过该方式,不但可以保证目标视觉元素在视觉上的位移连贯性,还可以保证在页面切换过程中目标视觉元素的内部动画的播放连贯性,从而提高了用户体验。
下面对于本公开提供的页面切换方法的应用场景进行说明。
在一种页面切换方法中,本实施例提供的页面切换方法,可以应用在视频应用的场景。用户在使用视频应用时,可以进行不同的播放页面之间的切换。例如,可以将全屏播放页面切换为图文播放页面。全屏播放页面包含有图像轮播组件,图文播放页面中包含有图像轮播组件和文字显示组件。在接收到用户触发的切换指令后,可以从全屏播放页面或图文播放页面中提取共有的图像轮播组件,并将其置于切换前的页面的视图顶层。随后,在全屏播放页面和图文播放页面的切换过程中,可以将图像轮播组件从切换前的页面中的位置位移到在切换后的页面中的位置。
在另一种页面切换方法中,本实施例提供的页面切换方法,可以应用在即时通信应用的场景。用户在使用即时通信应用时,若在会话中进行视频播放,则可以在全屏播放页面和窗 口播放页面中相互切换。在切换过程中,同样可以从全屏播放页面或窗口播放页面中提取视频轮播组件,并置于切换前的页面的视图顶层。随后,在全屏播放页面和窗口播放页面的切换过程中,可以将视频轮播组件从切换前的页面中的位置位移到在切换后的页面中的位置。
需要说明的是,上述两种应用场景并不构成对本公开的限制,本公开提供的页面切换方法可以应用于任何页面切换的场景中。
可以理解,上述页面切换方法可以通过本公开实施例提供的页面切换装置实现,页面切换装置可以是某个设备的部分或全部,例如为终端设备或终端设备的处理器。
下面以具体地实施例对本公开实施例的技术方案进行详细说明。下面这几个具体的实施例可以相互结合,对于相同或相似的概念或过程可能在某些实施例不再赘述。
图1为本公开实施例提供的一种页面切换方法的流程示意图。如图1所示,本实施例提供的页面切换方法,包括:
步骤101、响应于用户触发的页面切换指令,从第一页面或第二页面中提取目标视觉元素。
其中,页面切换指令用于指示将第一页面切换为第二页面。
应理解,第一页面和第二页面可以为应用中的任意页面,在一些实施例中,通过用户触发的切换指令,第一页面和第二页面之间可以进行来回切换。
示例性的,若应用为视频播放应用,则第一页面可以为全屏播放页面,第二页面可以为图文播放页面。用户可以触发页面切换指令将全屏播放页面切换为图文播放页面,也可以触发页面切换指令将图文播放页面切换为全屏播放页面。
应理解,本公开涉及的视觉元素,可以为第一页面或第二页面中显示的组件。相应的,目标视觉元素可以为第一页面和第二页面共有的视觉元素。示例性的,目标视觉元素可以包括图像轮播组件、视频轮播组件、文字轮播组件等。
在一些实施例中,本公开涉及的目标视觉元素可以包括至少一个待播放内容,各个待播放内容之间可以通过预设的动画特效连接。
其中,待播放内容可以根据目标视觉元素的类型确定。若目标视觉元素为图像轮播组件,则相应的,待播放内容为图像;若目标视觉元素为视频轮播组件,则相应的,待播放内容为视频;若目标视觉元素为文字轮播组件,则相应的,待播放内容为文字。
需要说明的,本公开实施例对于用户如何触发页面切换指令不作限制,在一些实施例中,用户可以通过在终端设备的显示界面上进行触发操作来触发页面切换指令。
示例性的,触发操作可以包括点击、预设角度的滑动等。示例性的,预设角度的滑动可以例如与水平面成75°到115°之间的向下滑动。
其中,点击或预设角度的滑动等触发操作可以在显示界面中的特定的区域进行,也可以在显示界面上的任意区域进行,本公开实施例对此不作限制。
在另一些实施例中,当检测到用户的触发操作时,终端设备的显示界面可以进行相应的显示变化。示例性的,当检测到用户的触发操作时,可以缩小终端设备的显示界面,当检测到用户的触发操作结束后,可以进行页面切换并放大终端设备的显示界面,随后,在显示界面中显示目标视觉元素。
示例性的,图2为本公开实施例提供的一种页面切换的示意图。如图2所示,第一页面为全屏播放页面,第二页面为图文播放页面。若用户点击全屏播放页面中悬浮在图像轮播组件21上的文字区域,则触发第一切换指令,终端设备由全屏播放页面切换为图文播放页面。 若用户在图文播放页面中的图像轮播组件21对应的显示位置上向下滑动,则触发第二切换指令,终端设备由图文播放页面切换为全屏播放页面。其中,图像轮播组件21可以为上述目标视觉元素。
应理解,本公开实施例对于如何提取目标视觉元素也不作限制,在一些实施例中,在一些实施例中,可以通过第一页面或第二页面的视图树中提取目标视觉元素。该视图树包含有页面中每层视图的视觉元素,并按照视图层级进行存放。
示例性的,终端设备可以对比第一页面和第二页面,从而将第一页面和第二页面共有的视觉元素作为目标视觉元素。随后,终端设备可以从第一页面中提取目标视觉元素,也可以从第二页面中提取目标视觉元素。
需要说明的是,从第一页面中提取到的目标视觉元素与从第二页面中提取到的目标视觉元素的动画播放参数不同。
其中,动画播放参数包括目标视觉元素的视图状态和目标视觉元素包括的动画效果。
应理解,动画效果为目标视觉元素中的播放内容之间的切换效果,不同播放内容之间的动画效果可以相同,也可以不同。
应理解,视图状态用于指示目标视觉元素中的播放内容的播放进度,可以通过视图状态中的偏移量来实现。在另一些实施例中,视图状态还可以包括业务参数等信息,来指示目标视觉元素的大小、播放配音等信息。
步骤102、将目标视觉元素添加到第一页面的第一位置的视图顶层。
在本步骤中,当终端设备提取到目标视觉元素后,可以将目标视觉元素添加到第一页面的第一位置的视图顶层。
其中,第一位置为目标视觉元素在第一页面中的原位置。
在一些实施例中,若目标视觉元素为从第一页面中提取到的视觉元素,则终端设备可以直接进行页面切换,并移动目标视觉元素的位置。
在另一些实施例中,若目标视觉元素为从第二页面中提取到的视觉元素,终端设备在将目标视觉元素添加到第一页面的第一位置的视图顶层后,还需要将目标视觉元素在第一页面中的第一动画播放参数同步给目标视觉元素在第二页面中的第二动画播放参数。
示例性的,终端设备可以先遍历并保存目标视觉元素在第一页面中的视图状态和动画效果。随后,将目标视觉元素在第一页面中的视图状态和动画效果依次添加到第二动画播放参数中。
在本公开中,通过将第一动画播放参数同步给第二动画播放参数,可以使从第二页面中提取出的目标视觉元素和第一页面中的目标视觉元素的视图状态和动画效果完全一致,从而在页面切换过程中,使用户无法感知目标视觉元素之间的切换。此外,从第二页面中提取目标视觉元素,还可以避免目标视觉元素被频繁搬移的问题,保证了页面切换过程中的稳定性。
在一些实施例中,在将目标视觉元素添加到第一页面的第一位置的视图顶层,还可以根据视图状态对应的播放进度,保持目标视觉元素进行动画播放。
其中,播放进度可以通过视图状态中的偏移量所指示的播放内容确定。
步骤103、在第一页面切换为第二页面时,将目标视觉元素从第一位置移动至目标视觉元素在第二页面中的第二位置。
在本步骤中,在终端设备获取并处理完目标视觉元素后,可以将第一页面切换为第二页面,并在切换过程中将目标视觉元素从第一位置移动至目标视觉元素在第二页面中的第二位置。
应理解,本公开实施例对于如何确定第二位置不作限制,在一些实施例中,终端设备可以先获取目标视觉元素与第二页面中的参照视觉元素之间的相对位置,随后,将目标视觉元素与第二页面中的参照视觉元素之间的相对位置转换为第二位置。
其中,参照视觉元素可以为终端设备中的任意视觉元素,通过目标视觉元素和参照视觉元素之间的相对位置,以及参照视觉元素与显示界面的相对位置,可以确定目标视觉元素的第二位置。
在一些实施例中,在目标视觉元素的移动过程中,还可以为目标视觉元素添加特效,从而优化用户的视觉体验。
应理解,本公开实施例对于目标视觉元素在移动中添加的特效类型不作限制,示例性的,可以为渐变特效、留影特效等。
在另一些实施例中,当终端设备将第一页面切换为第二页面并完成目标视觉元素的位移后,可以将目标视觉元素放回第二页面的对应图层中,从而完成页面的切换。
本公开实施例提供的虚拟资源的获取方法,响应于用户触发的页面切换指令,从第一页面或第二页面中提取目标视觉元素,该页面切换指令用于指示将第一页面切换为第二页面,该目标视觉元素为第一页面和第二页面共有的视觉元素。随后,将目标视觉元素添加到第一页面的第一位置的视图顶层,第一位置为目标视觉元素在第一页面中的原位置。最后,在第一页面切换为第二页面时,将目标视觉元素从第一位置移动至目标视觉元素在第二页面中的第二位置。通过该方式,由于在页面切换时,将共有的视觉元素先置顶再进行位移,不但可以保证目标视觉元素在视觉上的位移连贯性,还可以保证在页面切换过程中目标视觉元素的内部动画的播放连贯性,从而提高了用户体验。
在上述实施例的基础上,下面对于在页面切换过程中与用户的交互过程进行说明。图3为本公开实施例提供的一种终端设备的交互方法的流程示意图。如图3所示,本实施例提供的终端设备的交互方法,包括:
步骤S201、显示第一页面。
步骤S202、响应于用户对动画播放参数第一页面的触发操作,控制第一页面执行第一形变,第一页面并触发页面切换指令。
示例性地,响应于用户对动画播放参数第一页面的触发操作,缩小第一页面并触发页面切换指令。
应理解,本公开实施例对于触发操作不作限制,在一些实施例中,触发操作可以包括在动画播放参数终端设备的屏幕上进行预设角度的滑动。
示例性的,预设角度的滑动可以例如与水平面成75°到115°之间的向下滑动。
应理解,本公开实施例对于触发操作在终端设备上的屏幕上的触发区域也不作限制,在一些实施例中,目标视觉元素所在的区域可以为触发操作在终端设备上的屏幕上的触发区域。
此外,本公开实施例对于显示界面的缩小比例也不做限制,示例性的,显示界面可以缩小为进行触发操作前的百分之八十、百分之七十等。
图4为本公开实施例提供的一种触发操作的示意图,如图4所示,当用户需要将图文播放页面切换为全屏播放页面时,若检测到用户在全屏播放页面的图像轮播组件的区域进行与水平面成75°到115°之间的向下滑动,则可以触发页面切换指令。同时显示界面可以如图4所示进行缩小,并在用户进行触发操作的过程中,维持缩小状态。
步骤S203、当检测到触发操作结束后,将第一页面切换为第二页面。
应理解,本公开实施例对于如何检测到触发操作结束不作限制。在一些实施例中,当检测到用户在终端设备上结束滑动时可以确定触发操作结束。在另一些实施例中,当检测到用户手指等触发部位离开终端设备的屏幕时可以确定触发操作结束。
步骤S204、显示第二界面中的目标视觉元素,其中,第一页面切换至第二页面的过程中,第一形变后的目标视觉元素执行第二形变。
示例性地,第二形变可以为与第一形变相反的形变操作,例如第一页面执行第一形变为第一页面执行缩小操作,则目标视觉元素执行第二形变为目标视觉元素执行放大操作。由此,目标视觉元素可以实现连续的变化状态。
在本公开实施例中,通过在终端设备的屏幕上进行预设角度的滑动来触发页面切换指令,并在页面切换的过程中,缩小和放大显示界面。通过该方式,可以提高在页面切换过程中与用户的交互性,从而提高用户体验。
在上述实施例的基础上,下面对于两种提取目标视觉元素的方式进行说明。图5为本公开实施例提供的另一种页面切换方法的流程示意图。图5涉及的是从第一页面中提取出的目标视觉元素的处理流程,如图5所示,本实施例提供的页面切换方法,包括:
步骤S301、响应于用户触发的页面切换指令,从第一页面的视图树中提取目标视觉元素。
其中,页面切换指令用于指示将第一页面切换为第二页面,目标视觉元素为第一页面和第二页面共有的视觉元素。
应理解,该视图树包含有页面中每层视图的视觉元素,并按照视图层级进行存放。
步骤S302、将目标视觉元素添加到第一页面的第一位置的视图顶层,第一位置为目标视觉元素在第一页面中的原位置。
步骤S303、获取目标视觉元素与第二页面中的参照视觉元素之间的相对位置。
步骤S304、将目标视觉元素与第二页面中的参照视觉元素之间的相对位置转换为第二位置。
应理解,本公开实施例对于如何确定第二位置不作限制,在一些实施例中,终端设备可以先获取目标视觉元素与第二页面中的参照视觉元素之间的相对位置,随后,将目标视觉元素与第二页面中的参照视觉元素之间的相对位置转换为第二位置。
其中,参照视觉元素可以为终端设备中的任意视觉元素,通过模板视觉元素和参照视觉元素之间的相对位置,以及参照视觉元素与显示界面的相对位置,可以确定目标视觉元素的第二位置。
步骤S305、在第一页面切换为第二页面时,将目标视觉元素从第一位置移动至目标视觉元素在第二页面中的第二位置。
在一些实施例中,在目标视觉元素的移动过程中,还可以为目标视觉元素添加特效,从而优化用户的视觉体验。
步骤S306、将目标视觉元素放入第二页面对应的视图层中。
其中,第二页面对应的视图层为目标视觉元素在第二页面中原先所处的视图层。
步骤S301-S306的技术名词、技术效果、技术特征,以及可选实施方式,可参照图1所示的S101-S103理解,对于重复的内容,在此不再累述。
图6为本公开实施例提供的再一种页面切换方法的流程示意图。图6涉及的是从第二页面中提取出的目标视觉元素的处理流程,如图6所示,本实施例提供的页面切换方法,包括:
步骤S401、响应于用户触发的页面切换指令,从第二页面的视图树中提取目标视觉元素。
其中,页面切换指令用于指示将第一页面切换为第二页面,目标视觉元素为第一页面和第二页面共有的视觉元素。
步骤S402、将目标视觉元素添加到第一页面的第一位置的视图顶层,第一位置为目标视觉元素在第一页面中的原位置。
步骤S403、遍历并保存目标视觉元素在第一页面中的视图状态和动画效果。
其中,视图状态可以包括偏移量和业务参数。
步骤S404、将目标视觉元素在第一页面中的视图状态和动画效果依次添加到第二动画播放参数中。
在本公开中,通过将目标视觉元素在第一页面中的视图状态赋予给第二动画播放参数,可以保证添加在视图顶层的目标视觉元素与第一页面中原有的目标视觉元素的视图状态同步。相应的,通过将目标视觉元素在第一页面中的动画效果添加到第二动画播放参数中,可以保证添加在视图顶层的目标视觉元素与第一页面中原有的目标视觉元素的动画效果同步。
步骤S405、获取目标视觉元素与第二页面中的参照视觉元素之间的相对位置。
步骤S406、将目标视觉元素与第二页面中的参照视觉元素之间的相对位置转换为第二位置。
步骤S407、在第一页面切换为第二页面时,将目标视觉元素从第一位置移动至目标视觉元素在第二页面中的第二位置。
步骤S408、将目标视觉元素放入第二页面对应的视图层中。
步骤S401-S408的技术名词、技术效果、技术特征,以及可选实施方式,可参照图1所示的S101-S103理解,对于重复的内容,在此不再累述。
本公开实施例提供的虚拟资源的获取方法,响应于用户触发的页面切换指令,从第一页面或第二页面中提取目标视觉元素,该页面切换指令用于指示将第一页面切换为第二页面,该目标视觉元素为第一页面和第二页面共有的视觉元素。随后,将目标视觉元素添加到第一页面的第一位置的视图顶层,第一位置为目标视觉元素在第一页面中的原位置。最后,在第一页面切换为第二页面时,将目标视觉元素从第一位置移动至目标视觉元素在第二页面中的第二位置。通过该方式,由于在页面切换时,将共有的视觉元素先置顶再进行位移,不但可以保证目标视觉元素在视觉上的位移连贯性,还可以保证在页面切换过程中目标视觉元素的内部动画的播放连贯性,从而提高了用户体验。
图7为本公开实施例提供的一种页面切换装置的结构示意图。如图7所示,本实施例提供的页面切换装置500,包括:提取模块501、添加模块502、切换模块503和同步模块504。
提取模块501,用于响应于用户触发的页面切换指令,从第一页面或第二页面中提取目标视觉元素,页面切换指令用于指示将第一页面切换为第二页面,目标视觉元素为第一页面和第二页面共有的视觉元素。
添加模块502,用于将目标视觉元素添加到第一页面的第一位置的视图顶层,第一位置为目标视觉元素在第一页面中的原位置。
切换模块503,用于在第一页面切换为第二页面时,将目标视觉元素从第一位置移动至目标视觉元素在第二页面中的第二位置。
根据本公开的一个或多个实施例,从第一页面中提取到的目标视觉元素与从第二页面中提取到的目标视觉元素的动画播放参数不同。
根据本公开的一个或多个实施例,动画播放参数包括目标视觉元素的视图状态和目标视觉元素包括的动画效果;
其中,视图状态用于指示目标视觉元素中的播放内容的播放进度,动画效果为目标视觉元素中的播放内容之间的切换效果。
根据本公开的一个或多个实施例,页面切换装置500还包括:
同步模块504,用于将目标视觉元素在第一页面中的第一动画播放参数同步给目标视觉元素在第二页面中的第二动画播放参数。
根据本公开的一个或多个实施例,同步模块504,具体用于遍历并保存目标视觉元素在第一页面中的视图状态和动画效果;将目标视觉元素在第一页面中的视图状态和动画效果依次添加到第二动画播放参数中。
根据本公开的一个或多个实施例,切换模块503,还用于根据视图状态对应的播放进度,保持目标视觉元素进行动画播放。
根据本公开的一个或多个实施例,第一位置和第二位置为目标视觉元素在显示界面上的相对位置。
根据本公开的一个或多个实施例,切换模块503,还用于获取目标视觉元素与第二页面中的参照视觉元素之间的相对位置;将目标视觉元素与第二页面中的参照视觉元素之间的相对位置转换为第二位置。
根据本公开的一个或多个实施例,目标视觉元素包括图像轮播组件、视频轮播组件、文字轮播组件。
值得说明的,图7所示实施例提供的页面切换装置,可用于执行上述任一实施例提供的方法,具体实现方式和技术效果类似,这里不再赘述。
图8为本公开实施例提供的一种电子设备的结构示意图。如图8所示,其示出了适于用来实现本公开实施例的电子设备900的结构示意图。本公开实施例中的终端设备可以包括但不限于诸如移动电话、笔记本电脑、数字广播接收器、个人数字助理(Personal Digital Assistant,PDA)、平板电脑(Portable Android Device,PAD)、便携式多媒体播放器(Portable Media Player,PMP)、车载终端(例如车载导航终端)、可穿戴电子设备等等具有图像获取功能的移动终端以及诸如数字TV、台式计算机、智能家居设备等等外接有具有图像获取设备的固定终端。图8示出的电子设备仅仅是一个示例,不应对本公开实施例的功能和使用范围带来任何限制。
如图8所示,电子设备900可以包括处理装置(例如中央处理器、图形处理器等)601,其可以根据存储在只读存储器(Read Only Memory,ROM)602中的程序或者从存储器607加载到随机访问存储器(Random Access Memory,RAM)603中的程序而执行各种适当的动作和处理。在RAM 603中,还存储有电子设备600操作所需的各种程序和数据。处理装置601、ROM 602以及RAM 603通过总线604彼此相连。输入/输出(Input/Output,I/O)接口605也 连接至总线604。存储器用于存储执行上述各个方法实施例方法的程序;处理器被配置为执行存储器中存储的程序,以实现上文的本公开的实施例的功能以及/或者其它期望的功能。
通常,以下装置可以连接至I/O接口605:包括例如触摸屏、触摸板、键盘、鼠标、摄像头、麦克风、加速度计、陀螺仪等的输入装置609;包括例如液晶显示器(Liquid Crystal Display,LCD)、扬声器、振动器等的输出装置608;包括例如磁带、硬盘等的存储装置607;以及通信装置606。通信装置606可以允许电子设备900与其他设备进行无线或有线通信以交换数据。虽然图8示出了具有各种装置的电子设备900,但是应理解的是,并不要求实施或具备所有示出的装置。可以替代地实施或具备更多或更少的装置。
特别地,根据本公开的实施例,上文参考流程图描述的过程可以被实现为计算机软件程序。例如,本公开的实施例包括一种计算机程序产品,其包括承载在非暂态计算机可读介质上的计算机程序,该计算机程序包含用于执行本公开实施例的流程图所示的方法的程序代码。在这样的实施例中,该计算机程序可以通过通信装置606从网络上被下载和安装,或者从存储装置607被安装,或者从ROM 602被安装。在该计算机程序被处理装置601执行时,执行本公开实施例的方法中限定的上述功能。本公开的实施例还包括一种计算机程序,该计算机程序在被处理器执行时实现本公开实施例的方法中限定的上述功能。
需要说明的是,本公开上述的计算机可读介质可以是计算机可读信号介质或者计算机可读存储介质或者是上述两者的任意组合。计算机可读存储介质例如可以是——但不限于——电、磁、光、电磁、红外线、或半导体的系统、装置或器件,或者任意以上的组合。计算机可读存储介质的更具体的例子可以包括但不限于:具有一个或多个导线的电连接、便携式计算机磁盘、硬盘、随机访问存储器(RAM)、只读存储器(ROM)、可擦式可编程只读存储器(Electrical Programmable ROM,EPROM或闪存)、光纤、便携式紧凑磁盘只读存储器(Compact Disc ROM,CD-ROM)、光存储器件、磁存储器件、或者上述的任意合适的组合。在本公开中,计算机可读存储介质可以是任何包含或存储程序的有形介质,该程序可以被指令执行系统、装置或者器件使用或者与其结合使用。而在本公开中,计算机可读信号介质可以包括在基带中或者作为载波一部分传播的数据信号,其中承载了计算机可读的程序代码。这种传播的数据信号可以采用多种形式,包括但不限于电磁信号、光信号或上述的任意合适的组合。计算机可读信号介质还可以是计算机可读存储介质以外的任何计算机可读介质,该计算机可读信号介质可以发送、传播或者传输用于由指令执行系统、装置或者器件使用或者与其结合使用的程序。计算机可读介质上包含的程序代码可以用任何适当的介质传输,包括但不限于:电线、光缆、射频(Radio Frequency,RF)等等,或者上述的任意合适的组合。
上述计算机可读介质可以是上述电子设备中所包含的;也可以是单独存在,而未装配入该电子设备中。
上述计算机可读介质承载有一个或者多个程序,当上述一个或者多个程序被该电子设备执行时,使得该电子设备:响应于用户触发的第一指令,显示第一拍摄界面,其中,第一拍摄界面包括多个目标拍摄模式;响应于用户在第一拍摄界面上的触发操作,获取第一虚拟资源,并在第一拍摄界面上显示第一虚拟资源对应的图标;其中,多个目标拍摄模式包括至少一个可变拍摄模式,可变拍摄模式被配置为随时间变化。
可以以一种或多种程序设计语言或其组合来编写用于执行本公开的操作的计算机程序代码,上述程序设计语言包括但不限于面向对象的程序设计语言—诸如Java、Smalltalk、C++, 还包括常规的过程式程序设计语言—诸如“C”语言或类似的程序设计语言。程序代码可以完全地在用户计算机上执行、部分地在用户计算机上执行、作为一个独立的软件包执行、部分在用户计算机上部分在远程计算机上执行、或者完全在远程计算机或服务器上执行。在涉及远程计算机的情形中,远程计算机可以通过任意种类的网络——包括局域网(Local Area Network,LAN)或广域网(Wide Area Network,WAN)—连接到用户计算机,或者,可以连接到外部计算机(例如利用因特网服务提供商来通过因特网连接)。
在一些实施方式中,客户端、服务器可以利用诸如HTTP(HyperText Transfer Protocol,超文本传输协议)之类的任何当前已知或未来研发的网络协议进行通信,并且可以与任意形式或介质的数字数据通信(例如,通信网络)互连。通信网络的示例包括局域网(“LAN”),广域网(“WAN”),网际网(例如,互联网)以及端对端网络(例如,ad hoc端对端网络),以及任何当前已知或未来研发的网络。
附图中的流程图和框图,图示了按照本公开各种实施例的系统、方法和计算机程序产品的可能实现的体系架构、功能和操作。在这点上,流程图或框图中的每个方框可以代表一个模块、程序段、或代码的一部分,该模块、程序段、或代码的一部分包含一个或多个用于实现规定的逻辑功能的可执行指令。也应当注意,在有些作为替换的实现中,方框中所标注的功能也可以以不同于附图中所标注的顺序发生。例如,两个接连地表示的方框实际上可以基本并行地执行,它们有时也可以按相反的顺序执行,这依所涉及的功能而定。也要注意的是,框图和/或流程图中的每个方框、以及框图和/或流程图中的方框的组合,可以用执行规定的功能或操作的专用的基于硬件的系统来实现,或者可以用专用硬件与计算机指令的组合来实现。
描述于本公开实施例中所涉及到的模块可以通过软件的方式实现,也可以通过硬件的方式来实现。其中,模块的名称在某种情况下并不构成对该单元本身的限定。
本文中以上描述的功能可以至少部分地由一个或多个硬件逻辑部件来执行。例如,非限制性地,可以使用的示范类型的硬件逻辑部件包括:现场可编程门阵列(Field Programmable Gate Array,FPGA)、专用集成电路(Application Specific Integrated Circuit,ASIC)、专用标准产品(Application Specific Standard Product,ASSP)、片上系统(System on Chip,SOC)、复杂可编程逻辑设备(Complex Programmable Logic Device,CPLD)等等。
在本公开的上下文中,计算机可读介质可以是有形的介质,其可以包含或存储以供指令执行系统、装置或设备使用或与指令执行系统、装置或设备结合地使用的程序。计算机可读介质可以是计算机可读信号介质或计算机可读储存介质。计算机可读介质可以包括但不限于电子的、磁性的、光学的、电磁的、红外的、或半导体系统、装置或设备,或者上述内容的任何合适组合。计算机可读存储介质的更具体示例可以包括基于一个或多个线的电气连接、便携式计算机盘、硬盘、随机存取存储器(RAM)、只读存储器(ROM)、可擦除可编程只读存储器(EPROM或快闪存储器)、光纤、便捷式紧凑盘只读存储器(CD-ROM)、光学储存设备、磁储存设备、或上述内容的任何合适组合。
第一方面,根据本公开的一个或多个实施例,提供了一种页面切换方法,包括:
响应于用户触发的页面切换指令,从第一页面或第二页面中提取目标视觉元素,所述页面切换指令用于指示将所述第一页面切换为所述第二页面,所述目标视觉元素为所述第一页面和所述第二页面共有的视觉元素;
将所述目标视觉元素添加到所述第一页面的第一位置的视图顶层,所述第一位置为所述目标视觉元素在所述第一页面中的原位置;
在所述第一页面切换为所述第二页面时,将所述目标视觉元素从所述第一位置移动至所述目标视觉元素在所述第二页面中的第二位置。
根据本公开的一个或多个实施例,从所述第一页面中提取到的目标视觉元素与从所述第二页面中提取到的目标视觉元素的动画播放参数不同。
根据本公开的一个或多个实施例,所述动画播放参数包括所述目标视觉元素的视图状态和所述目标视觉元素包括的动画效果;
其中,所述视图状态用于指示所述目标视觉元素中的播放内容的播放进度,所述动画效果为所述目标视觉元素中的播放内容之间的切换效果。
根据本公开的一个或多个实施例,若所述目标视觉元素为从所述第二页面中提取到的视觉元素,则在所述将所述目标视觉元素添加到所述第一页面的第一位置的视图顶层之后,所述方法还包括:
将所述目标视觉元素在所述第一页面中的第一动画播放参数同步给所述目标视觉元素在所述第二页面中的第二动画播放参数。
根据本公开的一个或多个实施例,所述将所述目标视觉元素在所述第一页面中的第一动画播放参数同步给所述目标视觉元素在所述第二页面中的第二动画播放参数,包括:
遍历并保存所述目标视觉元素在所述第一页面中的视图状态和动画效果;
将所述目标视觉元素在所述第一页面中的视图状态和动画效果依次添加到所述第二动画播放参数中。
根据本公开的一个或多个实施例,在所述将所述目标视觉元素添加到所述第一页面的第一位置的视图顶层之后,所述方法还包括:
根据所述视图状态对应的播放进度,保持所述目标视觉元素进行动画播放。
根据本公开的一个或多个实施例,所述第一位置和所述第二位置为所述目标视觉元素在显示界面上的相对位置。
根据本公开的一个或多个实施例,在所述将所述目标视觉元素从所述第一位置移动至所述目标视觉元素在所述第二页面中的第二位置之前,所述方法还包括:
获取所述目标视觉元素与所述第二页面中的参照视觉元素之间的相对位置;
将所述目标视觉元素与所述第二页面中的参照视觉元素之间的相对位置转换为所述第二位置。
根据本公开的一个或多个实施例,所述目标视觉元素包括图像轮播组件、视频轮播组件、文字轮播组件。
第二方面,根据本公开的一个或多个实施例,提供了一种页面切换装置,包括:
提取模块,用于响应于用户触发的页面切换指令,从所述第一页面或第二页面中提取目标视觉元素,所述页面切换指令用于指示将所述第一页面切换为所述第二页面,所述目标视觉元素为所述第一页面和所述第二页面共有的视觉元素;
添加模块,用于将所述目标视觉元素添加到所述第一页面的第一位置的视图顶层,所述第一位置为所述目标视觉元素在所述第一页面中的原位置;
切换模块,用于在所述第一页面切换为所述第二页面时,将所述目标视觉元素从所述第一位置移动至所述目标视觉元素在所述第二页面中的第二位置。
根据本公开的一个或多个实施例,从所述第一页面中提取到的目标视觉元素与从所述第二页面中提取到的目标视觉元素的动画播放参数不同。
根据本公开的一个或多个实施例,所述动画播放参数包括所述目标视觉元素的视图状态和所述目标视觉元素包括的动画效果;
其中,所述视图状态用于指示所述目标视觉元素中的播放内容的播放进度,所述动画效果为所述目标视觉元素中的播放内容之间的切换效果。
根据本公开的一个或多个实施例,所述页面切换装置还包括:
同步模块,用于将所述目标视觉元素在所述第一页面中的第一动画播放参数同步给所述目标视觉元素在所述第二页面中的第二动画播放参数。
根据本公开的一个或多个实施例,所述同步模块,具体用于遍历并保存所述目标视觉元素在所述第一页面中的视图状态和动画效果;将所述目标视觉元素在所述第一页面中的视图状态和动画效果依次添加到所述第二动画播放参数中。
根据本公开的一个或多个实施例,所述切换模块,还用于根据所述视图状态对应的播放进度,保持所述目标视觉元素进行动画播放。
根据本公开的一个或多个实施例,所述第一位置和所述第二位置为所述目标视觉元素在显示界面上的相对位置。
根据本公开的一个或多个实施例,所述切换模块,还用于获取所述目标视觉元素与所述第二页面中的参照视觉元素之间的相对位置;将所述目标视觉元素与所述第二页面中的参照视觉元素之间的相对位置转换为所述第二位置。
根据本公开的一个或多个实施例,所述目标视觉元素包括图像轮播组件、视频轮播组件、文字轮播组件。
第三方面,本公开实施例提供一种终端设备的交互方法,包括
显示第一页面;
响应于用户对所述第一页面的触发操作,控制所述第一页面执行第一形变,并触发页面切换指令;
当检测到所述触发操作结束后,执行如第一方面所述的页面切换方法;
显示第二界面中的目标视觉元素;
其中,所述第一页面切换至第二页面的过程中,所述第一形变后的目标视觉元素执行第二形变。
根据本公开的一个或多个实施例,所述触发操作包括在所述终端设备的屏幕上进行预设角度的滑动。
第一页面第四方面,本公开实施例提供一种电子设备,包括:
处理器;以及
存储器,用于存储计算机程序;
其中,所述处理器被配置为通过执行所述计算机程序来实现如上述第一方面以及第一方面各种可能的设计中所述的页面切换方法。
第五方面,本公开实施例提供一种计算机可读存储介质,所述计算机可读存储介质中存储有计算机执行指令,当处理器执行所述计算机执行指令时,实现如上第一方面以及第一方面各种可能的设计中所述的页面切换方法。
第六方面,本公开实施例提供一种计算机程序产品,包括计算机程序,该计算机程序被处理器执行时实现如上第一方面以及第一方面各种可能的设计中所述的页面切换方法。
第七方面,本公开实施例提供一种计算机程序,该计算机程序被处理器执行时实现如上第一方面以及第一方面各种可能的设计中所述的页面切换方法。
以上描述仅为本公开的较佳实施例以及对所运用技术原理的说明。本领域技术人员应当理解,本公开中所涉及的公开范围,并不限于上述技术特征的特定组合而成的技术方案,同时也应涵盖在不脱离上述公开构思的情况下,由上述技术特征或其等同特征进行任意组合而形成的其它技术方案。例如上述特征与本公开中公开的(但不限于)具有类似功能的技术特征进行互相替换而形成的技术方案。
此外,虽然采用特定次序描绘了各操作,但是这不应当理解为要求这些操作以所示出的特定次序或以顺序次序执行来执行。在一定环境下,多任务和并行处理可能是有利的。同样地,虽然在上面论述中包含了若干具体实现细节,但是这些不应当被解释为对本公开的范围的限制。在单独的实施例的上下文中描述的某些特征还可以组合地实现在单个实施例中。相反地,在单个实施例的上下文中描述的各种特征也可以单独地或以任何合适的子组合的方式实现在多个实施例中。
尽管已经采用特定于结构特征和/或方法逻辑动作的语言描述了本主题,但是应当理解所附权利要求书中所限定的主题未必局限于上面描述的特定特征或动作。相反,上面所描述的特定特征和动作仅仅是实现权利要求书的示例形式。

Claims (16)

  1. 一种页面切换方法,包括:
    响应于用户触发的页面切换指令,从第一页面或第二页面中提取目标视觉元素,所述页面切换指令用于指示将所述第一页面切换为所述第二页面,所述目标视觉元素为所述第一页面和所述第二页面共有的视觉元素;
    将所述目标视觉元素添加到所述第一页面的第一位置的视图顶层,所述第一位置为所述目标视觉元素在所述第一页面中的原位置;
    在所述第一页面切换为所述第二页面时,将所述目标视觉元素从所述第一位置移动至所述目标视觉元素在所述第二页面中的第二位置。
  2. 根据权利要求1所述的方法,其中,从所述第一页面中提取到的目标视觉元素与从所述第二页面中提取到的目标视觉元素的动画播放参数不同。
  3. 根据权利要求2所述的方法,其中,所述动画播放参数包括所述目标视觉元素的视图状态和所述目标视觉元素包括的动画效果;
    其中,所述视图状态用于指示所述目标视觉元素中的播放内容的播放进度,所述动画效果为所述目标视觉元素中的播放内容之间的切换效果。
  4. 根据权利要求1至3任一项所述的方法,其中,若所述目标视觉元素为从所述第二页面中提取到的视觉元素,则在所述将所述目标视觉元素添加到所述第一页面的第一位置的视图顶层之后,所述方法还包括:
    将所述目标视觉元素在所述第一页面中的第一动画播放参数同步给所述目标视觉元素在所述第二页面中的第二动画播放参数。
  5. 根据权利要求4所述的方法,其中,所述将所述目标视觉元素在所述第一页面中的第一动画播放参数同步给所述目标视觉元素在所述第二页面中的第二动画播放参数,包括:
    遍历并保存所述目标视觉元素在所述第一页面中的视图状态和动画效果;
    将所述目标视觉元素在所述第一页面中的视图状态和动画效果依次添加到所述第二动画播放参数中。
  6. 根据权利要求1至3任一项所述的方法,其中,在所述将所述目标视觉元素添加到所述第一页面的第一位置的视图顶层之后,所述方法还包括:
    根据视图状态对应的播放进度,保持所述目标视觉元素进行动画播放。
  7. 根据权利要求1至6任一项所述的方法,其中,所述第一位置和所述第二位置为所述目标视觉元素在显示界面上的相对位置。
  8. 根据权利要求1至7任一项所述的方法,其中,在所述将所述目标视觉元素从所述第一位置移动至所述目标视觉元素在所述第二页面中的第二位置之前,所述方法还包括:
    获取所述目标视觉元素与所述第二页面中的参照视觉元素之间的相对位置;
    将所述目标视觉元素与所述第二页面中的参照视觉元素之间的相对位置转换为所述第二位置。
  9. 根据权利要求1至8任一项所述的方法,其中,所述目标视觉元素包括图像轮播组件、视频轮播组件、文字轮播组件。
  10. 一种页面切换装置,包括:
    提取模块,用于响应于用户触发的页面切换指令,从第一页面或第二页面中提取目标视 觉元素,所述页面切换指令用于指示将所述第一页面切换为所述第二页面,所述目标视觉元素为所述第一页面和所述第二页面共有的视觉元素;
    添加模块,用于将所述目标视觉元素添加到所述第一页面的第一位置的视图顶层,所述第一位置为所述目标视觉元素在所述第一页面中的原位置;
    切换模块,用于在所述第一页面切换为所述第二页面时,将所述目标视觉元素从所述第一位置移动至所述目标视觉元素在所述第二页面中的第二位置。
  11. 一种终端设备的交互方法,包括:
    显示第一页面;
    响应于用户对所述第一页面的触发操作,控制所述第一页面执行第一形变,并触发页面切换指令;
    当检测到所述触发操作结束后,执行如权利要求1至9任一项所述的页面切换方法;
    显示第二界面中的目标视觉元素;
    其中,所述第一页面切换至第二页面的过程中,所述第一形变后的目标视觉元素执行第二形变。
  12. 根据权利要求11所述的方法,其特征在于,所述触发操作包括在所述终端设备的屏幕上进行预设角度的滑动。
  13. 一种电子设备,包括:
    处理器;以及
    存储器,用于存储计算机程序;
    其中,所述处理器被配置为通过执行所述计算机程序来实现权利要求1至9任一项所述的页面切换方法。
  14. 一种计算机可读存储介质,所述计算机可读存储介质中存储有计算机执行指令,当处理器执行所述计算机执行指令时,实现如权利要求1至9任一项所述的页面切换方法。
  15. 一种计算机程序产品,包括计算机程序,所述计算机程序被处理器执行时实现权利要求1至9任一项所述的页面切换方法。
  16. 一种计算机程序,所述计算机程序被处理器执行时实现权利要求1至9任一项所述的页面切换方法。
PCT/CN2023/089052 2022-04-20 2023-04-18 页面切换方法、装置以及终端设备的交互方法 WO2023202590A1 (zh)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN202210418796.7 2022-04-20
CN202210418796.7A CN114722320A (zh) 2022-04-20 2022-04-20 页面切换方法、装置以及终端设备的交互方法

Publications (1)

Publication Number Publication Date
WO2023202590A1 true WO2023202590A1 (zh) 2023-10-26

Family

ID=82246183

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2023/089052 WO2023202590A1 (zh) 2022-04-20 2023-04-18 页面切换方法、装置以及终端设备的交互方法

Country Status (2)

Country Link
CN (1) CN114722320A (zh)
WO (1) WO2023202590A1 (zh)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114722320A (zh) * 2022-04-20 2022-07-08 北京字跳网络技术有限公司 页面切换方法、装置以及终端设备的交互方法
CN116991528B (zh) * 2023-08-14 2024-03-19 腾讯科技(深圳)有限公司 一种页面切换方法、装置、存储介质和电子设备

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20150135048A1 (en) * 2011-04-20 2015-05-14 Panafold Methods, apparatus, and systems for visually representing a relative relevance of content elements to an attractor
CN109710348A (zh) * 2018-11-14 2019-05-03 深圳壹账通智能科技有限公司 页面跳转的方法及装置、计算机设备、存储介质
CN112596845A (zh) * 2020-12-29 2021-04-02 百果园技术(新加坡)有限公司 一种页面切换的方法、装置、服务器和存储介质
CN114327698A (zh) * 2020-09-30 2022-04-12 深圳市万普拉斯科技有限公司 一种页面切换的方法、系统、电子装置及存储介质
CN114722320A (zh) * 2022-04-20 2022-07-08 北京字跳网络技术有限公司 页面切换方法、装置以及终端设备的交互方法

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20150135048A1 (en) * 2011-04-20 2015-05-14 Panafold Methods, apparatus, and systems for visually representing a relative relevance of content elements to an attractor
CN109710348A (zh) * 2018-11-14 2019-05-03 深圳壹账通智能科技有限公司 页面跳转的方法及装置、计算机设备、存储介质
CN114327698A (zh) * 2020-09-30 2022-04-12 深圳市万普拉斯科技有限公司 一种页面切换的方法、系统、电子装置及存储介质
CN112596845A (zh) * 2020-12-29 2021-04-02 百果园技术(新加坡)有限公司 一种页面切换的方法、装置、服务器和存储介质
CN114722320A (zh) * 2022-04-20 2022-07-08 北京字跳网络技术有限公司 页面切换方法、装置以及终端设备的交互方法

Also Published As

Publication number Publication date
CN114722320A (zh) 2022-07-08

Similar Documents

Publication Publication Date Title
WO2023202590A1 (zh) 页面切换方法、装置以及终端设备的交互方法
CN112261459B (zh) 一种视频处理方法、装置、电子设备和存储介质
US20230007065A1 (en) Video sharing method, apparatus, device and medium
JP7407289B2 (ja) ビデオを表示するための方法、装置、電子機器及び媒体
EP3754476A1 (en) Information display method, graphical user interface and terminal
WO2022007724A1 (zh) 视频处理方法、装置、设备及存储介质
WO2022007722A1 (zh) 显示方法、装置、设备及存储介质
EP4343544A1 (en) Interaction method and apparatus, electronic device, and storage medium
WO2023024921A1 (zh) 视频交互方法、装置、设备及介质
WO2022199426A1 (zh) 视频的展示方法、装置、电子设备和存储介质
EP4124052A1 (en) Video production method and apparatus, and device and storage medium
CN112965780B (zh) 图像显示方法、装置、设备及介质
EP4175307A1 (en) Interaction method and apparatus, and electronic device
CN112051961A (zh) 虚拟交互方法、装置、电子设备及计算机可读存储介质
WO2023216936A1 (zh) 视频播放方法、装置、电子设备、存储介质和程序产品
WO2023179362A1 (zh) 控件的显示方法、装置、电子设备、存储介质和程序产品
WO2022183887A1 (zh) 视频编辑及播放方法、装置、设备、介质
EP4343512A1 (en) Control display method and apparatus, device, and medium
WO2023185647A1 (zh) 媒体内容的显示方法、装置、设备、存储介质和程序产品
WO2023125164A1 (zh) 页面显示方法、装置、电子设备和存储介质
WO2023169305A1 (zh) 特效视频生成方法、装置、电子设备及存储介质
WO2021027596A1 (zh) 图像特效处理方法、装置、电子设备和计算机可读存储介质
JP2023502610A (ja) 目標対象表示方法、装置、電子機器、及びコンピュータ読み取り可能な媒体
JP2023515607A (ja) 画像特殊効果の処理方法及び装置
EP4086732A1 (en) Method and apparatus for controlling target object, and electronic device and storage medium

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 23791245

Country of ref document: EP

Kind code of ref document: A1