WO2019137217A1 - 应用程序中的页面跳转方法、终端及存储介质 - Google Patents

应用程序中的页面跳转方法、终端及存储介质 Download PDF

Info

Publication number
WO2019137217A1
WO2019137217A1 PCT/CN2018/124008 CN2018124008W WO2019137217A1 WO 2019137217 A1 WO2019137217 A1 WO 2019137217A1 CN 2018124008 W CN2018124008 W CN 2018124008W WO 2019137217 A1 WO2019137217 A1 WO 2019137217A1
Authority
WO
WIPO (PCT)
Prior art keywords
page
application
jump
transaction
restored
Prior art date
Application number
PCT/CN2018/124008
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 WO2019137217A1 publication Critical patent/WO2019137217A1/zh

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/07Responding to the occurrence of a fault, e.g. fault tolerance
    • G06F11/14Error detection or correction of the data by redundancy in operation
    • G06F11/1402Saving, restoring, recovering or retrying

Definitions

  • the present application relates to the field of page jump technologies, and in particular, to a page jump method, a terminal, and a storage medium in an application.
  • the main purpose of the present application is to provide a page jump method in an application, which aims to solve the problem of jumping from the current page to another page of the application, and returning to the current page, the edited data not saved before the current page will be Empty, users can only repeat editing, resulting in technical problems with poor user experience.
  • the present application provides a page jump method in an application, and the page jump method in the application includes:
  • the transaction to be restored is restored to the target page, and the target page after the recovery in the application is jumped.
  • the page jump method in the application further includes:
  • the transaction to be restored is stored in association with the current page.
  • determining, according to the jump instruction, the target page to be switched in the application includes:
  • the current page of the last page jump activity is the target page.
  • determining, according to the jump instruction, the target page to be switched in the application includes:
  • the first page corresponding to the original function of the original control is the target page
  • the current page of the last page jump activity is the target page.
  • the determining whether the current page in the application has a transaction to be restored includes:
  • the edit data input by the user is the current page corresponding to the transaction to be restored, and the current page has a transaction to be resumed.
  • the step of storing the to-be-recovered transaction in association with the current page includes:
  • the storage duration of the to-be-recovered transaction stored in association with the current page is counted, and it is determined whether the storage duration is greater than a second preset duration
  • determining, according to the jump instruction, the target page to be switched in the application includes:
  • the main page is the target page.
  • the method includes:
  • the first page corresponding to the original function of the original control is the target page
  • the present application further provides a terminal, the terminal comprising: a memory, a processor, and computer readable instructions stored on the memory and executable on the processor, the computer readable instructions
  • the steps described in the page jump method in the application described above are implemented when executed by the processor.
  • the present application further provides a storage medium, where the computer readable instructions are stored, and when the computer readable instructions are executed by the processor, the page jump method in the application program is implemented. The steps described.
  • the page jump method in the application program proposed by the embodiment of the present application determines the target page corresponding to the jump instruction after the terminal detects the jump instruction, and initially determines the next page and the address that the user needs; Whether there is a transaction to be restored associated with the target page, such as a browsing record or editing data of the user on the target page; if there is a transaction to be restored associated with the target page, when jumping to the target page, Restoring the to-be-recovered transaction to the target page, and outputting the target page that restores the transaction to be restored, so that the user can continue the transaction on the target page, such as browsing the article, watching the video, and continuing to edit from the previous location. Text, images, etc., improve the user-friendliness of the application and enhance the user experience.
  • FIG. 1 is a schematic structural diagram of a terminal in a hardware operating environment involved in a solution according to an embodiment of the present application
  • FIG. 2 is a schematic flowchart of a first embodiment of a page jump method in an application of the present application
  • FIG. 3 is a schematic diagram of an application program page according to an embodiment of the present application.
  • FIG. 4 is a schematic diagram of a previous page jump activity in a second embodiment of a page jump method in an application of the present application
  • FIG. 5 is a schematic flowchart of a third embodiment of a page jump method in an application of the present application.
  • FIG. 6 is a schematic diagram of a page jump of a third embodiment of a page jump method in an application of the present application.
  • FIG. 7 is a schematic diagram of a page of a new jump control of the fifth embodiment of the page jump method in the application of the present application.
  • module means merely illustrative of the application and are not intended to be limiting.
  • suffixes such as “module,” “component,” or “unit” used to denote an element are merely illustrative for the benefit of the present application, and have no particular meaning per se. Therefore, “module”, “component” or “unit” can be used in combination.
  • FIG. 1 is a schematic structural diagram of a terminal in a hardware operating environment involved in an embodiment of the present application.
  • the terminal can be implemented in various forms.
  • the terminal described in this application may include, for example, a mobile phone, a tablet, a laptop, a palmtop, a personal digital assistant (Personal) Digital Assistant, PDA), Portable Media Player (Portable Media) Players, PMPs, mobile terminals such as wearable devices (such as AR/VR devices with networking capabilities), and fixed terminals such as digital TVs and desktop computers.
  • PDA Personal digital assistant
  • PMPs Portable Media Player (Portable Media) Players
  • PMPs Portable Media Player (Portable Media) Players
  • mobile terminals such as wearable devices (such as AR/VR devices with networking capabilities)
  • fixed terminals such as digital TVs and desktop computers.
  • FIG. 1 is a schematic diagram of a hardware structure of a mobile terminal that implements various embodiments of the present application.
  • the terminal may include a processor 1001 , such as a CPU, a network interface 1004 , a user interface 1003 , a memory 1005 , and a communication bus 1002 .
  • the communication bus 1002 is used to implement connection communication between these components.
  • the user interface 1003 can include a display, an input unit such as a keyboard, a touch screen, a camera (including an AR/VR device), and the optional user interface 1003 can also include a standard wired interface, a wireless interface.
  • the network interface 1004 can optionally include a standard wired interface, a wireless interface (such as a WI-FI interface, a Bluetooth interface, a probe interface, a 3G/4G/5G network communication interface, etc.).
  • the memory 1005 can be used to store software programs as well as various data.
  • the memory 1005 may mainly include a storage program area and a storage data area, wherein the storage program area may store an operating system, an application required for at least one function (such as a sound playing function, an image playing function, etc.), and the like; the storage data area may be stored according to Data created by the use of the mobile phone (such as audio data, phone book, etc.).
  • the memory 1005 may include a high speed random access memory, and may also include a nonvolatile memory such as at least one magnetic disk storage device, flash memory device, or other volatile solid state storage device.
  • the processor 1001 is a control center of the mobile terminal that connects various portions of the entire mobile terminal using various interfaces and lines, by running or executing software programs and/or modules stored in the memory 1005, and invoking data stored in the memory 1005.
  • the mobile terminal performs various functions and processing data to perform overall monitoring on the mobile terminal.
  • the processor 1001 can call computer readable instructions in the memory 1005 to perform the following steps:
  • the transaction to be restored is restored to the target page, and the target page after the recovery in the application is jumped.
  • the page jump method in the application further includes:
  • the transaction to be restored is stored in association with the current page.
  • determining, according to the jump instruction, the target page to be switched in the application includes:
  • the current page of the last page jump activity is the target page.
  • determining, according to the jump instruction, the target page to be switched in the application includes:
  • the first page corresponding to the original function of the original control is the target page
  • the current page of the last page jump activity is the target page.
  • the determining whether the current page in the application has a transaction to be restored includes:
  • the edit data input by the user is the current page corresponding to the transaction to be restored, and the current page has a transaction to be resumed.
  • the step of associating the to-be-recovered transaction with the current page includes:
  • the storage duration of the to-be-recovered transaction stored in association with the current page is counted, and it is determined whether the storage duration is greater than a second preset duration
  • determining, according to the jump instruction, the target page to be switched in the application includes:
  • the main page is the target page.
  • the method After the step of detecting, by the terminal at the main page of the application, the second jump instruction input by the user based on the original control, the method includes:
  • the first page corresponding to the original function of the original control is the target page
  • the page jump in each embodiment of the present application refers to a page jump inside the application.
  • the page jump method in the application program includes:
  • Step S10 when a jump instruction is detected, determining, according to the jump instruction, a target page to be switched in the application;
  • the terminal may open multiple applications at the same time, and the solution of the present application implements page jumps in the same application.
  • the user controls the application on the terminal to perform a page jump according to the user's needs.
  • the input method of the jump instruction can be touch input, gesture recognition input (such as "next page” from left to right), or voice input, terminal posture or motion input (such as the terminal from left to right) For the "next page"), keyboard or remote control input, this embodiment does not limit the input mode of the jump instruction.
  • the target page is the page that the terminal will jump to after receiving the jump instruction.
  • the target page can be determined immediately according to the jump instruction, and the target page is obviously a page in the application.
  • Different jump instructions correspond to different target pages, and the jump instruction includes the class name or page address of the target page, and the page jump can be directly performed according to the class name or page address of the target page included in the jump instruction. For example, in WeChat app, click any clickable control to jump to the corresponding target page.
  • the “ ⁇ ” and “ ⁇ ” in the upper left corner are commonly used return controls. Click “ ⁇ ” or “ ⁇ ” to release. The jump instruction returned.
  • Step S11 determining whether the target page is associated with a transaction to be resumed
  • a transaction to be restored refers to data or a transaction that needs to be restored to the target page when jumping to the target page stored in association with the target page.
  • the transaction to be restored may be cached or stored in a dedicated storage area, and the data closely related to the end user may be a browsing record or edited data left by the user on the target page, and if the target page is associated with a transaction to be restored, The user browses or edits the target page.
  • the browsing history or editing data of the user browsing the target page is restored to the target page, and the user may browse or Editing the continuous experience, without the need for users to manually restore some data, can improve the user-friendliness of the application.
  • the page jump method in the application program further includes:
  • Step S111 when a jump instruction is detected, determining whether there is a pending transaction in the current page in the application;
  • Step S112 If there is a transaction to be restored on the current page of the application, the transaction to be restored is stored in association with the current page.
  • a jump activity involves two pages, one is: the current interface, that is, the current page; the second is: the target page.
  • the user browses, watches the video, edits the data and other activities on the current page. After jumping to the target page, the user may wish to return to the activity before the current page continues. To meet the user's needs, the user needs to be on the current page.
  • the progress of the activity is stored.
  • the activity performed by the user on the current page may be stored and updated in real time or periodically, so as to ensure that the user can leave the current page at any time and return to the current page, but the memory is consumed. The problem of large resources and running resources and excessive power consumption.
  • step S111 the step of determining whether the current page in the application has a transaction to be restored includes:
  • Step S113 detecting whether the current page of the application has edit data input by the user
  • step S114 if the edit data input by the user exists in the current page of the application, the edit data input by the user is the current page corresponding to the transaction to be restored, and the current page has a transaction to be resumed.
  • Detecting whether the current page of the application has user-entered edit data can be the text of the current page. Whether there is content in the view, you can also identify this type of page that needs user editing, and identify the page as the page with the transaction to be restored. If the text of the current page If there is content in the view, the current page has edit data input by the user, and vice versa. If the current page has an identifier identifying the transaction to be restored, the current page has edit data input by the user, and vice versa.
  • the terminal may automatically store the edit data input by the user for the user to When you access the current page, you can continue the last data editing activity, avoiding repeated editing by the user, so that the user can leave the current page at any time without worrying that the edited data will disappear, ensuring a good user experience.
  • a transaction to be restored refers to data or a transaction that needs to be restored to the target page when jumping to the target page stored in association with the target page. Before determining whether the target page stores the transaction to be restored, there is a judgment on whether the current page has a transaction to be restored. After determining that the current page has a pending transaction, the transaction to be restored is associated with the current page. If there is no pending transaction on the current page, no storage is required.
  • the jump instruction when the jump instruction is detected, it is determined whether the current page in the application has a pending transaction, rather than real-time or timing, thereby saving memory and running resources, reducing power consumption speed, and improving running speed. If there is a transaction to be restored, the transaction to be restored is stored in association with the current page, so that when the user returns to the current page, the transaction to be restored stored in association with the current page is restored to the current page, so that the user can continue to be in the previous time. The activities performed on the current page to enhance the user experience.
  • Step S12 If the target page is associated with a transaction to be restored, the transaction to be restored is restored to the target page, and the target page after the recovery in the application is jumped.
  • the corresponding pending transaction may be restored to the target page while jumping to the target page, so that the user can continue the browsing or editing activity on the target page last time. If the target page is not associated with any pending transaction, jump directly to the start state of the target page for the user to start browsing or editing.
  • the terminal detects the jump instruction, determining the target page corresponding to the jump instruction, initially determining the next page and the address that the user needs; and determining whether there is a transaction to be restored associated with the target page, such as a user. Browsing records or editing data and the like on the target page; if there is a transaction to be restored associated with the target page, the transaction to be restored is restored to the target page, and the output is restored while jumping to the target page
  • the target page of the transaction to be resumed so that the user can continue the last transaction on the target page, such as browsing articles, watching videos, and continuing to edit texts and pictures from the previous position, thereby improving user friendliness of the application and improving User experience.
  • the step S10 includes:
  • Step S20 when the terminal at the application main page detects the first jump instruction, determining the current page of the last page jump activity of the application;
  • Step S21 the current page of the last page jump activity is a target page.
  • a page jump activity involves two pages: one, the current page; two, the target page.
  • the first jump instruction refers to a jump instruction that has a special jump function or a special target page.
  • the first jump instruction in this embodiment refers to the current page that jumps from the main page to the last page jump activity.
  • the last page jump activity in this embodiment refers to an activity of jumping from another page to the main page, which is the current page of the last page jump activity (see FIG. 4).
  • the current page can also be returned to the main page layer by layer.
  • the "back" in the upper left corner can be clicked to return to the main page, or the current interface can be directly closed.
  • go directly to the main page such as clicking the "x" in the upper left corner of the WeChat app to return to the main page.
  • the problem with the above two page jumps is that the return from the main page to the current page needs to be re-layered, the user may be impatient and cumbersome, and after returning, the previously edited information will no longer exist, the user It needs to be re-edited to further deepen the user's dissatisfaction with the application or the services it provides. It is also likely to abandon the input of editing data on the current page, causing damage to the service provider in the application. This is extremely disadvantageous for both users and application service providers.
  • a function control that can directly return the “current page” from the main page is set, and the user inputs the first jump instruction based on the function control, and the terminal detects When the first jump instruction is reached, the current page of the last page jump activity of the application is determined.
  • the first jump instruction is received only when the terminal is in the main page of the application, and it can be determined that the target page of the last page jump activity of the application is the main page.
  • the last page jump activity record can be found, and then the current page in the page jump activity is determined.
  • the current page of the last page jump activity may also be associated with the first jump instruction, as long as the user Click the function control to release the first jump instruction, and then immediately determine the current page of the application's last page jump activity, without having to find the last page jump activity record, which can increase the jump speed and reduce unnecessary operations. Improve operational efficiency.
  • the embodiment determines the target page (ie, the application last page) while setting the function control directly returning from the main page to the “current page”. Whether the current page of the jump activity is associated with the transaction to be restored, and if the target page is associated with the transaction to be restored, the transaction to be restored is restored to the target page, and then the target of the transaction to be restored is restored.
  • the page realizes the back-and-forth jump between the current interface and the main interface, and can also temporarily store the edited information.
  • the "to-be-recovered transaction" has been detailed above, and will not be described again.
  • the terminal at the application main page detects the first hop input by the user based on the function control
  • the current page of the last page jump activity is determined as the target page, and the main page of the application jumps to the current page of the previous page jump activity, and the previous page jump is omitted.
  • the layer-by-layer operation between the current pages of the activity saves the user's operating procedures and improves the user experience.
  • step S30 is split into: step S301, The terminal of the main page of the application detects the second jump instruction input by the user based on the original control; in step S302, it is determined whether the time duration of the last page jump activity of the application is greater than the first preset duration, and the step S12 is split into steps.
  • step S121 if the target page is associated with a transaction to be restored, the transaction to be restored is restored to the target page; in step S122, the target page after the recovery in the application is returned.
  • the step S10 includes:
  • Step S30 when the terminal in the main page of the application detects the second jump instruction input by the user based on the original control, it is determined whether the time duration of the last page jump activity of the application is greater than the first preset duration;
  • Step S31 if the last page jump activity of the application is longer than the first preset duration, the first page corresponding to the original function of the original control is the target page;
  • step S32 if the last page jump activity of the application is less than the first preset duration, the current page of the last page jump activity is the target page.
  • the new function on the original control may cause the new function to conflict with the original function.
  • the time interval of the last page jump activity of the application and the first preset duration are introduced.
  • the last page jump activity of the application is longer than the current time.
  • the first preset duration refers to a time threshold, which can be set by the user. Or application/terminal system default settings.
  • the jump from the main page to the target page can be realized. Otherwise, the first page corresponding to the original function of the original control is the target page (as shown in Fig. 6), where the first page is the original of the original control. There is a function corresponding page, such as " ⁇ " corresponding to the next page.
  • the purpose of this setting is to reduce unnecessary jumps. Specifically, first of all, from the user's needs, the user jumps from the current page to the main page, and then the request to jump from the main page to the current page is in a certain time.
  • the segment is relatively large, but when the time period is larger, it can be judged that the demand is smaller.
  • the time period is large enough, the user may not want to jump from the main page to the current page. At this time, the user clicks on the original control, it is very likely that the original function of the original control needs to be used.
  • the application last page jump activity is longer than a certain threshold or returns to the previous time
  • the current page of the page jump activity it is certain that the current page of the last page jump activity is always stored, but at this time the user demand is not so large, so storing the current page all the time will waste memory. Resources.
  • the function of the original control is determined by determining whether the time of the last page jump activity of the application is greater than the first preset duration.
  • the original control is in a special period, and the new function is implemented.
  • the current page of the last page jump activity is the target page, when the application last page When the jump activity is longer than the first preset duration, the original control returns to the normal state, and the first page corresponding to the original function of the original control is the target page, preventing unnecessary page jumps and wasted memory resources.
  • the method includes:
  • Step S33 determining whether the user inputs a second jump instruction twice or more times within the third preset duration
  • Step S34 if the user inputs the second jump instruction twice or more in the third preset duration, the first page corresponding to the original function of the original control is the target page;
  • step S35 if the user inputs only the second jump instruction within the third preset duration, it is determined whether the time interval of the last page jump activity of the application is greater than the first preset duration.
  • the terminal under the main page of the application detects the second jump instruction input by the user based on the original control, because the original control has two functions, respectively pointing to different target pages, in order to more accurately determine the target of the user's intention to jump.
  • the page further determines whether a second jump instruction is input twice or more in the third preset duration, and the third preset duration is a short period of time, which may be within 1 s or 1.5 s. Even shorter, this embodiment does not limit, this preset duration is the system setting.
  • the meaning of this judgment step is: whether the user clicks on the original control in a short time or whether the user continuously clicks.
  • step S30 it is further determined whether the time interval of the last page jump activity of the application is greater than the first preset duration, that is, step S30 is performed.
  • step S31 the time interval of the last page jump activity of the application is greater than the first preset duration
  • the judgment of whether the time span of the last page jump activity by the application is greater than the first preset duration may substantially distinguish the user's intention, but a short time after the application last page jump activity Inside, the user may also jump to the target page corresponding to the original function of the original control. Therefore, in the present embodiment, a small operation similar to a double-click of a mouse is designed, that is, before the user's intention is determined by the application's last page jump activity, the user's intention is roughly determined by such a double-click operation, and the pair is reduced.
  • the error that the user intends to recognize in order to prevent the new function from hindering the realization of the original function of the original control, and having an adverse effect on the user experience, so that the dual function design of the original control is more rationalized.
  • the step S112 includes:
  • step S40 the storage duration of the to-be-recovered transaction stored in association with the current page is counted, and it is determined whether the storage duration is greater than a second preset duration
  • Step S41 if the storage duration is greater than the second preset duration, the transaction to be resumed is cleared.
  • the stored transaction to be restored needs to be cleared when a certain condition is met, and may be manually cleared by the user, or may be automatically cleared by the terminal when the to-be-recovered transaction satisfies certain conditions.
  • the storage duration is counted.
  • the storage duration of the transaction to be restored is greater than the second preset duration, the storage duration of the transaction to be restored reaches a certain threshold, and the user
  • the requirement for the to-be-recovered transaction is so small that it does not need to be stored, so it can be cleared to save memory resources and speed up the operation.
  • the second preset duration may be preset by the user or preset by the terminal/application. If the storage duration is less than the second preset duration, the to-be-recovered transaction has a large recovery requirement, and a certain memory resource may be consumed to meet the requirement of the user to recover the to-be-recovered transaction at any time.
  • the storage duration of the transaction to be restored stored in association with the current page is counted, and when the storage duration of the transaction to be restored is greater than the second preset duration, the transaction to be restored is cleared, and the usage possibility is cleared in time. Small data, saving memory resources.
  • the step S10 includes:
  • Step S50 When the terminal in the application non-main page detects the third jump instruction input by the user based on the newly added jump control, the main page is the target page.
  • jumping from the non-main page to the main page adds a function to the original control, for example, "x in the WeChat app” "(close) control to save the pending transaction of the current non-primary page while returning to the main page.
  • a jump control may be added, and the newly added jump function may save the pending transaction of the current non-main page while ensuring the jump back to the main page, and distinguish from the original return control. Open, as shown in Figure 7.
  • the jump control can be set at the second page after the main page, and the first page of the main page can directly return to the main page, so the first page can be left unset.
  • a direct jump from a non-main page to a main page can be realized.
  • a direct and fast jump between the main page and the non-main page can be realized.
  • it can temporarily store the transaction being processed by the interface, enrich the page jump function of the terminal/application, greatly facilitate the user, save time, reduce the repeated editing process, and improve the user experience.
  • the embodiment of the present application further provides a storage medium, which may be a non-volatile readable storage medium, where the computer readable instructions are stored, and the computer readable instructions are implemented by a processor.
  • a storage medium which may be a non-volatile readable storage medium, where the computer readable instructions are stored, and the computer readable instructions are implemented by a processor.
  • a terminal device can be a fixed terminal, such as IoT smart devices, including smart air conditioners, smart lights, smart power supplies, smart routers, etc.; or mobile
  • the terminal including a smartphone, a wearable networked AR/VR device, a smart speaker, a self-driving car, and the like, performs a method as described in various embodiments of the present application.

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Quality & Reliability (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • User Interface Of Digital Computer (AREA)

Abstract

本申请公开了一种应用程序中的页面跳转方法,所述方法包括:当检测到跳转指令时,根据所述跳转指令确定应用程序中待切换的目标页面;判断所述目标页面是否关联有待恢复事务;若所述目标页面关联有待恢复事务,则将该待恢复事务恢复至所述目标页面,跳转至应用程序中恢复后的所述目标页面。本申请还公开了一种终端和存储介质。

Description

应用程序中的页面跳转方法、终端及存储介质
技术领域
本申请涉及页面跳转技术领域,尤其涉及一种应用程序中的页面跳转方法、终端及存储介质。
背景技术
在使用类似微信的应用程序时,存在一种情形,即当前页面正在编辑信息内容,由于还未完成或者其他原因而没有保存,此时需要立即跳转到别的页面。产生的问题是:当从所述别的页面返回当前页面时,此前在当前页面编辑的内容都将不复存在,这样就只能重新编辑一次。使得用户从别的页面返回当前页面后只能重复编辑,给用户造成一定的麻烦,影响用户的使用体验。
发明内容
本申请的主要目的在于提供一种应用程序中的页面跳转方法,旨在解决从当前页面跳转到应用程序别的页面,再返回当前页面时,当前页面之前未保存的已编辑数据都将清空,用户只能重复编辑,造成不良用户体验的技术问题。
为实现上述目的,本申请提供一种应用程序中的页面跳转方法,所述应用程序中的页面跳转方法包括:
当检测到跳转指令时,根据所述跳转指令确定应用程序中待切换的目标页面;
判断所述目标页面是否关联有待恢复事务;
若所述目标页面关联有待恢复事务,则将该待恢复事务恢复至所述目标页面,跳转至应用程序中恢复后的所述目标页面。
在一种可选的实施方式中,所述应用程序中的页面跳转方法还包括:
当检测到跳转指令时,判断应用程序中的当前页面是否存在待恢复事务;
若所述当前页面存在待恢复事务,则将该待恢复事务与当前页面关联存储。
在一种可选的实施方式中,所述当检测到跳转指令时,根据所述跳转指令确定应用程序中待切换的目标页面的步骤包括:
当处于应用程序主页面的终端检测到第一跳转指令时,确定应用程序上一次页面跳转活动的当前页面;
所述上一次页面跳转活动的当前页面为目标页面。
在一种可选的实施方式中,所述当检测到跳转指令时,根据所述跳转指令确定应用程序中待切换的目标页面的步骤包括:
当处于应用程序主页面的终端检测到用户基于原有控件输入的第二跳转指令时,判断应用程序上一次页面跳转活动距今时长是否大于第一预设时长;
若应用程序上一次页面跳转活动距今时长大于第一预设时长,则原有控件的原有功能对应的第一页面为目标页面;
若应用程序上一次页面跳转活动距今时长小于第一预设时长,则上一次页面跳转活动的当前页面为目标页面。
在一种可选的实施方式中,所述判断应用程序中的当前页面是否存在待恢复事务包括:
检测应用程序的当前页面是否存在用户输入的编辑数据;
若应用程序的当前页面存在用户输入的编辑数据,则该用户输入的编辑数据为当前页面对应待恢复事务,当前页面存在待恢复事务。
在一种可选的实施方式中,所述若所述当前页面存在待恢复事务,则将该待恢复事务与当前页面关联存储的步骤之后包括:
统计与当前页面关联存储的所述待恢复事务的存储时长,判断所述存储时长是否大于第二预设时长;
若所述存储时长大于第二预设时长,则清除所述待恢复事务。
在一种可选的实施方式中,所述当检测到跳转指令时,根据所述跳转指令确定应用程序中待切换的目标页面的步骤包括:
当处于应用程序非主页面的终端检测到用户基于新增的跳转控件输入的第三跳转指令时,主页面为目标页面。
在一种可选的实施方式中,所述当处于应用程序主页面的终端检测到用户基于原有控件输入的第二跳转指令的步骤之后包括:
判断用户在第三预设时长内是否输入两次或两次以上的第二跳转指令;
若用户在第三预设时长内输入两次或两次以上的第二跳转指令,则原有控件的原有功能对应的第一页面为目标页面;
若用户在第三预设时长内仅输入一次第二跳转指令,则判断应用程序上一次页面跳转活动距今时长是否大于第一预设时长。
为实现上述目的,本申请还提供一种终端,所述终端包括:存储器、处理器及存储在所述存储器上并可在所述处理器上运行的计算机可读指令,所述计算机可读指令被所述处理器执行时实现如上述应用程序中的页面跳转方法所述的步骤。
此外,为实现上述目的,本申请还提供一种存储介质,所述存储介质上存储有计算机可读指令,所述计算机可读指令被处理器执行时实现如上述应用程序中的页面跳转方法所述的步骤。
本申请实施例提出的一种应用程序中的页面跳转方法,通过在终端检测到跳转指令后,确定跳转指令对应的目标页面,初步确定用户需要的下一个页面及其地址;再判断是否存在与该目标页面关联的待恢复事务,如用户在所述目标页面的浏览记录或者编辑数据等;如果存在与所述目标页面关联的待恢复事务,则在跳转到目标页面的同时,将所述待恢复事务恢复到目标页面,输出显示恢复了待恢复事务的目标页面,使得用户可以继续上一次在目标页面进行的事务,如浏览文章、观看视频,继续从上一次的位置开始编辑文字、图片等,提升应用程序的用户友好度,提升用户的使用体验。
附图说明
图1是本申请实施例方案涉及的硬件运行环境的终端结构示意图;
图2为本申请应用程序中的页面跳转方法第一实施例的流程示意图;
图3为本申请实施例方案涉及的应用程序页面示意图;
图4为本申请应用程序中的页面跳转方法第二实施例中上一次页面跳转活动的示意图;
图5为本申请应用程序中的页面跳转方法第三实施例的流程示意图;
图6为本申请应用程序中的页面跳转方法第三实施例的页面跳转示意图;
图7本申请应用程序中的页面跳转方法第五实施例的新增跳转控件的页面示意图。
本申请目的的实现、功能特点及优点将结合实施例,参照附图做进一步说明。
具体实施方式
应当理解,此处所描述的具体实施例仅仅用以解释本申请,并不用于限定本申请。在后续的描述中,使用用于表示元件的诸如“模块”、“部件”或“单元”的后缀仅为了有利于本申请的说明,其本身没有特定的意义。因此,“模块”、“部件”或“单元”可以混合地使用。
如图1所示,图1是本申请实施例方案涉及的硬件运行环境的终端结构示意图。
终端可以以各种形式来实施。例如,本申请中描述的终端可以包括诸如手机、平板电脑、笔记本电脑、掌上电脑、个人数字助理(Personal Digital Assistant,PDA)、便捷式媒体播放器(Portable Media Player,PMP)、可穿戴设备(如带联网功能的AR/VR设备)等移动终端,以及诸如数字TV、台式计算机等固定终端。
后续描述中将以移动终端为例进行说明,本领域技术人员将理解的是,除了特别用于移动目的的元件之外,根据本申请的实施方式的构造也能够应用于固定类型的终端。
请参阅图1,其为实现本申请各个实施例的一种移动终端的硬件结构示意图,该终端可以包括:处理器1001,例如CPU,网络接口1004,用户接口1003,存储器1005,通信总线1002。其中,通信总线1002用于实现这些组件之间的连接通信。用户接口1003可以包括显示屏(Display)、输入单元比如键盘(Keyboard)、触摸屏、摄像头(包括AR/VR设备),可选用户接口1003还可以包括标准的有线接口、无线接口。网络接口1004可选的可以包括标准的有线接口、无线接口(如WI-FI接口、蓝牙接口、探针接口、3G/4G/5G联网通信接口等)。
存储器1005可用于存储软件程序以及各种数据。存储器1005可主要包括存储程序区和存储数据区,其中,存储程序区可存储操作系统、至少一个功能所需的应用程序(比如声音播放功能、图像播放功能等)等;存储数据区可存储根据手机的使用所创建的数据(比如音频数据、电话本等)等。此外,存储器1005可以包括高速随机存取存储器,还可以包括非易失性存储器,例如至少一个磁盘存储器件、闪存器件、或其他易失性固态存储器件。
处理器1001是移动终端的控制中心,利用各种接口和线路连接整个移动终端的各个部分,通过运行或执行存储在存储器1005内的软件程序和/或模块,以及调用存储在存储器1005内的数据,执行移动终端的各种功能和处理数据,从而对移动终端进行整体监控。本申请中,处理器1001可调用存储器1005内的计算机可读指令,执行下述步骤:
当检测到跳转指令时,根据所述跳转指令确定应用程序中待切换的目标页面;
判断所述目标页面是否关联有待恢复事务;
若所述目标页面关联有待恢复事务,则将该待恢复事务恢复至所述目标页面,跳转至应用程序中恢复后的所述目标页面。
所述应用程序中的页面跳转方法还包括:
当检测到跳转指令时,判断应用程序中的当前页面是否存在待恢复事务;
若所述当前页面存在待恢复事务,则将该待恢复事务与当前页面关联存储。
所述当检测到跳转指令时,根据所述跳转指令确定应用程序中待切换的目标页面的步骤包括:
当处于应用程序主页面的终端检测到第一跳转指令时,确定应用程序上一次页面跳转活动的当前页面;
所述上一次页面跳转活动的当前页面为目标页面。
所述当检测到跳转指令时,根据所述跳转指令确定应用程序中待切换的目标页面的步骤包括:
当处于应用程序主页面的终端检测到用户基于原有控件输入的第二跳转指令时,判断应用程序上一次页面跳转活动距今时长是否大于第一预设时长;
若应用程序上一次页面跳转活动距今时长大于第一预设时长,则原有控件的原有功能对应的第一页面为目标页面;
若应用程序上一次页面跳转活动距今时长小于第一预设时长,则上一次页面跳转活动的当前页面为目标页面。
所述判断应用程序中的当前页面是否存在待恢复事务包括:
检测应用程序的当前页面是否存在用户输入的编辑数据;
若应用程序的当前页面存在用户输入的编辑数据,则该用户输入的编辑数据为当前页面对应待恢复事务,当前页面存在待恢复事务。
所述若所述当前页面存在待恢复事务,则将该待恢复事务与当前页面关联存储的步骤之后包括:
统计与当前页面关联存储的所述待恢复事务的存储时长,判断所述存储时长是否大于第二预设时长;
若所述存储时长大于第二预设时长,则清除所述待恢复事务。
所述当检测到跳转指令时,根据所述跳转指令确定应用程序中待切换的目标页面的步骤包括:
当处于应用程序非主页面的终端检测到用户基于新增的跳转控件输入的第三跳转指令时,主页面为目标页面。
所述当处于应用程序主页面的终端检测到用户基于原有控件输入的第二跳转指令的步骤之后包括:
判断用户在第三预设时长内是否输入两次或两次以上的第二跳转指令;
若用户在第三预设时长内输入两次或两次以上的第二跳转指令,则原有控件的原有功能对应的第一页面为目标页面;
若用户在第三预设时长内仅输入一次第二跳转指令,则判断应用程序上一次页面跳转活动距今时长是否大于第一预设时长。
基于上述移动终端硬件结构,提出本申请方法各个实施例。本申请各实施例中的页面跳转指应用程序内部的页面跳转。
参照图2,在本申请应用程序中的页面跳转方法第一实施例中,所述应用程序中的页面跳转方法包括:
步骤S10,当检测到跳转指令时,根据所述跳转指令确定应用程序中待切换的目标页面;
终端可能同时打开多个应用程序,本申请方案实现的是同一应用程序内的页面跳转。用户通过输入跳转指令,控制终端上的应用程序依照用户需求进行页面跳转。跳转指令的输入方式可以为触控输入、手势识别输入(如从左往右一划为“下一页”),也可以为语音输入、终端姿势或者动作输入(如终端从左往右一晃为“下一页”)、键盘或遥控器输入,本实施例对跳转指令的输入方式不做限定。
目标页面为终端接收到跳转指令后,将要跳转的页面。当终端处理器接收到跳转指令时,可以立即根据该跳转指令确定目标页面,该目标页面显然是应用程序中的页面。不同跳转指令对应不同的目标页面,跳转指令包含目标页面的类名或者页面地址,可直接根据跳转指令包含的目标页面的类名或者页面地址等信息进行页面跳转。例如,在微信app中,点击任一可点击控件均可跳转到对应的目标页面,左上角的“×”和“←”为常用的返回控件,点击“×”或“←”均可下达返回的跳转指令。
步骤S11,判断所述目标页面是否关联有待恢复事务;
待恢复事务指与所述目标页面关联存储的、跳转到目标页面时需要恢复到所述目标页面的数据或者事务。待恢复事务可为缓存或者存储于专用的存储区,为与终端用户密切相关的数据,可以为用户在目标页面留下的浏览记录或者编辑的数据,若所述目标页面关联有待恢复事务,说明用户浏览过或者编辑过所述目标页面,当用户再次浏览或者编辑所述目标页面时,将用户上一次浏览目标页面的浏览记录或者编辑数据恢复到所述目标页面,可以给用户一种浏览或者编辑的持续性体验,无需用户手动恢复一些数据,可以提升应用程序的用户友好度。
用户常常会遇到一种情形:当用户在应用程序的当前页面编辑信息时,应用程序的其他页面来了信息需要处理,此时,用户面临一个两难选择,若是跳转到其他页面再返回当前页面,则当前页面已编辑好的内容(未编辑完,无法保存)将不复存在,若是不跳转到其他页面,则当前页面无法继续编辑或者其他页面事情紧急而必须跳转。本申请实施例即可解决这一问题,使得用户使用应用程序时无需为难。
有关所述待恢复事务的存储,进一步地,本申请实施例中,所述应用程序中的页面跳转方法还包括:
步骤S111,当检测到跳转指令时,判断应用程序中的当前页面是否存在待恢复事务;
步骤S112,若应用程序的当前页面存在待恢复事务,则将该待恢复事务与当前页面关联存储。
一次跳转活动涉及两个页面,一为:当前所在界面,即当前页面;二为:目标页面。将要跳转时,用户在当前页面进行浏览、看视频、编辑数据等活动,跳转至目标页面后,用户可能希望返回当前页面继续之前进行的活动,要满足用户需求需要对用户在当前页面的活动进度进行存储。在一种实施方式中,可以实时或者定时对用户在当前页面进行的活动进行存储及更新存储,这样可以保证用户随时可离开当前页面且返回当前页面时继续之前进行的活动,但会存在耗费内存资源、运行资源较大,耗电速度过快的问题。因而,为避免前一实施方式造成的“耗费内存资源、运行资源较大,耗电速度过快”等问题,在另一种实施方式中,在检测到跳转指令、即将要进行跳转时,才将用户在当前页面正在进行的活动进度(包括浏览记录、已编辑数据)进行存储。但是用户在当前页面进行的活动并不全是需要进行存储的,即,并非所有用户在当前页面进行的活动进度数据都是待恢复事务,在判断是否存在待恢复事务时,需要明确其判断标准,或者明确待恢复事务的判断标准。待恢复事务的判断标准可以由用户参与设置,也可以全由应用程序或者终端系统默认设置。
在一种实施方式中,所述步骤S111中,判断应用程序中的当前页面是否存在待恢复事务这一步骤包括:
步骤S113,检测应用程序的当前页面是否存在用户输入的编辑数据;
步骤S114,若应用程序的当前页面存在用户输入的编辑数据,则该用户输入的编辑数据为当前页面对应待恢复事务,当前页面存在待恢复事务。
检测应用程序的当前页面是否存在用户输入的编辑数据可以是判断在当前页面的text view中是否有内容,也可以对这一类需要用户编辑的页面做标识,标识该页面为存在待恢复事务的页面。若当前页面的text view中有内容,则当前页面存在用户输入的编辑数据,反之则无。若当前页面有标识待恢复事务的标识,则当前页面存在用户输入的编辑数据,反之则无。
若是存在用户输入的编辑数据,在大多数情况下,都是需要保存的。例如,在微信里的滴滴打车软件中开具发票时,需要填写相关信息,如下图3所示,但现在有些信息内容不知怎么填写,需要咨询微信朋友。此时编辑了一半的信息,还不能提交,若跳转到好友界面,这些编辑的信息就会丢失。还比如用户阅读时做的标记、批注,或者某些需用户填写信息的页面,如调查问卷、保险单等。若是当前页面不存在用户输入的编辑数据,则需要看当前页面是否存在其他数据显示存在待恢复事务或者也可以直接判定当前页面不存在待恢复事务。
本实施例通过检测应用程序的当前页面是否存在用户输入的编辑数据,使得当用户在当前页面输入了数据或者进行了其他编辑活动时,终端可以自动将用户输入的编辑数据存储,以供用户再次访问当前页面时可以继续上一次的数据编辑活动,避免用户重复编辑,使得用户可以随时离开当前页面而不用担心已编辑的数据会消失,保证用户良好的使用体验。
待恢复事务指与所述目标页面关联存储的、跳转到目标页面时需要恢复到所述目标页面的数据或者事务。在判断目标页面是否存储有待恢复事务之前,就有对当前页面是否存在待恢复事务的判断,在确定当前页面存在待恢复事务后,再将该待恢复事务与当前页面关联存储。若当前页面不存在待恢复事务,则无需存储。
本实施例通过在检测到跳转指令时,判断应用程序中的当前页面是否存在待恢复事务,而非实时或者定时进行所述判断,节约了内存及运行资源,降低电量消耗速度,提高运行速度,如果存在待恢复事务,则将该待恢复事务与当前页面关联存储,以供用户再返回当前页面时,将与当前页面关联存储的待恢复事务恢复至当前页面,使得用户可继续上一次在当前页面进行的活动,进而提升用户的使用体验。
步骤S12,若所述目标页面关联有待恢复事务,则将该待恢复事务恢复至所述目标页面,跳转至应用程序中恢复后的所述目标页面。
当所述目标页面关联有待恢复事务时,可在跳转至目标页面的同时,将对应的待恢复事务恢复至目标页面,使得用户可继续上一次在所述目标页面的浏览或者编辑活动。若所述目标页面没有关联任何待恢复事务,则直接跳转至目标页面的起始状态,供用户开始浏览或者编辑。
本实施例通过在终端检测到跳转指令后,确定跳转指令对应的目标页面,初步确定用户需要的下一个页面及其地址;再判断是否存在与该目标页面关联的待恢复事务,如用户在所述目标页面的浏览记录或者编辑数据等;如果存在与所述目标页面关联的待恢复事务,则在跳转到目标页面的同时,将所述待恢复事务恢复到目标页面,输出显示恢复了待恢复事务的目标页面,使得用户可以继续上一次在目标页面进行的事务,如浏览文章、观看视频,继续从上一次的位置开始编辑文字、图片等,提升应用程序的用户友好度,提升用户的使用体验。
进一步地,基于上一实施例,在本申请应用程序中的页面跳转方法的第二实施例中,所述步骤S10包括:
步骤S20,当处于应用程序主页面的终端检测到第一跳转指令时,确定应用程序上一次页面跳转活动的当前页面;
步骤S21,所述上一次页面跳转活动的当前页面为目标页面。
一次页面跳转活动涉及两个页面:一、当前页面;二、目标页面。
第一跳转指令指拥有特殊跳转功能的或者特殊目标页面的跳转指令,本实施例中的第一跳转指令指从主页面跳转到上一次页面跳转活动的当前页面。本实施例中的上一次页面跳转活动指从其他页面跳转到主页面的活动,该其他页面即上一次页面跳转活动的当前页面(如图4)。
现有的应用程序的页面跳转中,可从当前页面也层层返回到主页面,如在微信app中,一直点击左上角的“返回”可层层返回主页面,也可直接关闭当前界面与中间界面,直接回到主页面,如点击微信app中左上角的“x”可回到主页面。上述两种页面跳转均存在的问题是:从主页面再返回到当前页面需要重新层层递进,用户可能不耐烦繁琐的操作,且返回后,先前编辑的信息将全部不复存在,用户需重新编辑,进一步加深用户对应用程序或其提供的服务的不满,也很可能放弃继续在当前页面输入编辑数据,对应用程序中的服务提供商造成损失。这不论对于用户还是应用程序服务提供商都是极其不利的。
为解决现有应用程序页面跳转中存在的上述问题,本实施例中,设置一个可以从主页面直接返回“当前页面”的功能控件,用户基于该功能控件输入第一跳转指令,终端检测到该第一跳转指令时,确定应用程序上一次页面跳转活动的当前页面。所述第一跳转指令只有在终端处于应用程序的主页面时才会收到,可以确定的是,应用程序的上一次页面跳转活动的目标页面为主页面。
在一种实施方式中,可以查找上一次页面跳转活动记录,再确定该次页面跳转活动中的当前页面。为尽快确定应用程序上一次页面跳转活动的当前页面,在另一种实施方式中,也可以将该上一次页面跳转活动的当前页面与所述第一跳转指令进行关联存储,只要用户点击所述功能控件下达第一跳转指令,就可立即确定应用程序上一次页面跳转活动的当前页面,无需查找上一次页面跳转活动记录,可增快跳转速度,减少不必要的操作,提升运行效率。
为解决现有应用程序页面跳转中存在的上述问题,本实施例在设置所述从主页面直接返回“当前页面”的功能控件的同时,还判断所述目标页面(即应用程序上一次页面跳转活动的当前页面)是否关联有待恢复事务,若所述目标页面关联有待恢复事务,则将该待恢复事务恢复至所述目标页面后,跳转至恢复了该待恢复事务的所述目标页面,进而实现当前界面与主界面的来回跳转,还能暂存编辑的信息,有关“待恢复事务”已在上文详述,不再赘述。
本实施例通过在应用程序主页面设置一个从主页面返回到上一次页面跳转活动的当前页面的功能控件,当处于应用程序主页面的终端检测到用户基于所述功能控件输入的第一跳转指令时,确定上一次页面跳转活动的当前页面为目标页面,实现应用程序中主页面一键跳转至上一次页面跳转活动的当前页面,省去了从主页面到上一次页面跳转活动的当前页面间的一层层操作,节约了用户操作程序,提升了用户体验。
进一步地,基于上述实施例,在本申请应用程序中的页面跳转方法的第三实施例中,如图5,(为便于在附图中标识,将步骤S30拆分为:步骤S301,处于应用程序主页面的终端检测用户基于原有控件输入的第二跳转指令;步骤S302,判断应用程序上一次页面跳转活动距今时长是否大于第一预设时长,将步骤S12拆分为步骤S121,若所述目标页面关联有待恢复事务,则将该待恢复事务恢复至所述目标页面;步骤步骤S122,跳转至应用程序中恢复后的所述目标页面)所述步骤S10包括:
步骤S30,当处于应用程序主页面的终端检测到用户基于原有控件输入的第二跳转指令时,判断应用程序上一次页面跳转活动距今时长是否大于第一预设时长;
步骤S31,若应用程序上一次页面跳转活动距今时长大于第一预设时长,则原有控件的原有功能对应的第一页面为目标页面;
步骤S32,若应用程序上一次页面跳转活动距今时长小于第一预设时长,则上一次页面跳转活动的当前页面为目标页面。
本实施例中,也有可能通过第二跳转指令从主页面返回到上一次页面跳转活动的当前页面,与第二实施例不同的是:本实施例并未增加一个专门用于从主页面返回到上一次页面跳转活动当前页面的功能控件,而是利用原有的功能控件实现不同的功能。
以手机浏览器为例,通常手机浏览器都有“→”“←”或者“下一页”“上一页”指向上一页面和下一页面,这是“→”“←”控件的常用功能,本实施例即利用这些常见控件实现从主页面返回到上一次页面跳转活动当前页面这一功能,因为用户对于一个应用程序页面上的功能控件都比较熟悉,对其布局也已经习惯,突然增加一个控件对用户的观感有一定不良影响,且增加一个功能控件会占据更多内存。而在原有控件上新增一个功能在可以实现新增功能的同时,还可避免上述问题。
在原有控件上新增功能可能导致新增功能与原有功能的冲突,为解决这一问题,本实施例中,引入应用程序上一次页面跳转活动距今时长和第一预设时长。应用程序上一次页面跳转活动距今时长,顾名思义,为跳转到主页面多久了,或者主页面本次持续时长,第一预设时长指一个时间阈值,这一时间阈值可以由用户自主设置或者应用程序/终端系统默认设置。
判断应用程序上一次页面跳转活动距今时长是否大于第一预设时长,只有当应用程序上一次页面跳转活动距今时长小于第一预设时长,上一次页面跳转活动的当前页面才为目标页面,才能实现从主页面跳转到目标页面,反之,则原有控件的原有功能对应的第一页面为目标页面(如图6),这里的第一页面即原有控件的原有功能对应的页面,如“→”对应下一个页面。这种设置的目的是为了减少不必要的跳转,具体而言,首先,从用户需求考虑,用户从当前页面跳转到主页面,其再从主页面跳转到当前页面的需求在一定时间段内是比较大的,但当这一时间段越大,可判断出这种需求越小,当这一时间段足够大时,用户可能根本想不起来要再从主页面跳转到当前页面了,此时,用户点击原有控件极可能是需要使用该原有控件的原有功能,其次,从内存资源考虑,若是应用程序上一次页面跳转活动距今时长大于一定阈值还是返回上一次页面跳转活动的当前页面,则可以肯定的是,上一次页面跳转活动的当前页面是一直需要存储的,但此时用户需求已经不是那么大了,因而一直存储所述当前页面会浪费内存资源。
本实施例通过在一个原有控件中集成两个功能,节约了内存资源,通过应用程序上一次页面跳转活动距今时长是否大于第一预设时长的判断,确定该原有控件的功能,当应用程序上一次页面跳转活动距今时长小于第一预设时长时,原有控件处于特殊时期,实现新功能,上一次页面跳转活动的当前页面为目标页面,当应用程序上一次页面跳转活动距今时长大于第一预设时长时,原有控件返回正常状态,原有控件的原有功能对应的第一页面为目标页面,防止不必要的页面跳转和内存资源浪费。
进一步地,所述步骤S30中,所述当处于应用程序主页面的终端检测到用户基于原有控件输入的第二跳转指令的步骤之后包括:
步骤S33,判断用户在第三预设时长内是否输入两次或两次以上的第二跳转指令;
步骤S34,若用户在第三预设时长内输入两次或两次以上的第二跳转指令,则原有控件的原有功能对应的第一页面为目标页面;
步骤S35,若用户在第三预设时长内仅输入一次第二跳转指令,则判断应用程序上一次页面跳转活动距今时长是否大于第一预设时长。
在应用程序主页面下的终端检测到用户基于原有控件输入的第二跳转指令,因为原有控件有两个功能,分别指向不同的目标页面,为更加精确地确定用户意图跳转的目标页面,进一步判断在第三预设时长内是否输入两次或两次以上的第二跳转指令,第三预设时长是一个很短的时间段,可以为1s内,也可以为1.5s,甚至更短,本实施例不做限制,这一预设时长为系统设置。这一判断步骤的含义为:用户是否在短时间内或者用户是否连续点击了原有控件。
若用户在第三预设时长内输入两次或两次以上的第二跳转指令,即用户在短时间内点击了两次以上的原有控件,则用户希望实现原有控件的原有功能,反之,若用户在第三预设时长内仅仅输入一次第二跳转指令,则还需进一步判断应用程序上一次页面跳转活动距今时长是否大于第一预设时长,即执行步骤S30中的判断步骤,后续步骤如步骤S31、步骤S32及上文对各实施方式的详细描述,不再赘述。
虽然在上面的实施方式中,通过应用程序上一次页面跳转活动距今时长是否大于第一预设时长这一判断可以大致区分用户意图,但是在应用程序上一次页面跳转活动之后的短时间内,用户也有可能跳转到原有控件的原有功能对应的目标页面。因而,本实施方式中,设计一个类似于鼠标双击的小操作,即,在通过应用程序上一次页面跳转活动距今时长判断用户意图之前,通过这样的双击操作先大致判断用户意图,减少对用户意图识别的误差,以防新增功能阻碍了原有控件原有功能的实现,对用户体验造成反效果,使得原有控件的双功能设计更加合理化。
进一步地,基于上述实施例,在本申请应用程序中的页面跳转方法的第四实施例中,所述步骤S112之后包括:
步骤S40,统计与当前页面关联存储的所述待恢复事务的存储时长,判断所述存储时长是否大于第二预设时长;
步骤S41,若所述存储时长大于第二预设时长,则清除所述待恢复事务。
为节约内存资源,存储的待恢复事务在满足一定条件时需清除,可以为用户手动清除,也可以在所述待恢复事务满足一定条件时由终端自动清除。本实施例中,在所述待恢复事务存储后,统计其存储时长,当所述待恢复事务的存储时长大于第二预设时长时,说明所述待恢复事务存储时长达到了一定阈值,用户对所述待恢复事务的需求已经小到无需将其继续存储了,所以可以清除,以节省内存资源,提升运行速度。所述第二预设时长为可以由用户预设,也可以由终端/应用程序预设。若所述存储时长小于第二预设时长,则所述待恢复事务还有较大恢复需求,可以消耗一定内存资源以随时满足用户恢复所述待恢复事务的需求。
本实施例通过统计与当前页面关联存储的所述待恢复事务的存储时长,在所述待恢复事务的存储时长大于第二预设时长时,清除所述待恢复事务,及时清除使用可能性较小的数据,节约内存资源。
进一步地,基于上述实施例,在本申请应用程序中的页面跳转方法的第五实施例中,所述步骤S10包括:
步骤S50,当处于应用程序非主页面的终端检测到用户基于新增的跳转控件输入的第三跳转指令时,主页面为目标页面。
当终端当前处于应用程序的非主页面时(非主页面顾名思义为:不是主页面的页面),从非主页面跳转到主页面在原有控件上增加一个功能,譬如,微信app中的“x”(关闭)控件,在返回主页面的同时保存当前非主页面的待恢复事务。在一种实施方式中,可以新增一个跳转控件,该新增的跳转功能在确保跳转回主页面的同时,可以保存当前非主页面的待恢复事务,与原有的返回控件区分开来,如图7所示。
所述跳转控件可以在主页面之后的第二个页面开始设置,主页面的第一个页面可以直接回到主页面,所以,在第一个页面可以不设置。
本实施例通过在非主页面设置跳转控件,可以实现从非主页面到主页面的直接跳转,结合之前的实施例,可以实现主页面和非主页面之间直接而快速的互相跳转,同时还能暂存界面正在处理的事务,丰富终端/应用程序的页面跳转功能,极大地方便用户,节省时间,减少重复编辑过程,提升用户体验。
此外,本申请实施例还提出一种存储介质,存储介质可以为非易失性可读存储介质,所述存储介质上存储有计算机可读指令,所述计算机可读指令被处理器执行时实现如上述实施例所述的步骤,具体内容已在上文详述,此处不再赘述。
需要说明的是,在本文中,术语“包括”、“包含”或者其任何其他变体意在涵盖非排他性的包含,从而使得包括一系列要素的过程、方法、物品或者系统不仅包括那些要素,而且还包括没有明确列出的其他要素,或者是还包括为这种过程、方法、物品或者系统所固有的要素。在没有更多限制的情况下,由语句“包括一个……”限定的要素,并不排除在包括该要素的过程、方法、物品或者系统中还存在另外的相同要素。
上述本申请实施例序号仅仅为了描述,不代表实施例的优劣。
通过以上的实施方式的描述,本领域的技术人员可以清楚地了解到上述实施例方法可借助软件加必需的通用硬件平台的方式来实现,当然也可以通过硬件,但很多情况下前者是更佳的实施方式。基于这样的理解,本申请的技术方案本质上或者说对现有技术做出贡献的部分可以以软件产品的形式体现出来,该计算机软件产品存储在如上所述的一个存储介质(如ROM/RAM、磁碟、光盘)中,包括若干指令用以使得一台终端设备(可以是固定终端,如物联网智能设备,包括智能空调、智能电灯、智能电源、智能路由器等智能家居;也可以是移动终端,包括智能手机、可穿戴的联网AR/VR装置、智能音箱、自动驾驶汽车等诸多联网设备)执行本申请各个实施例所述的方法。
以上仅为本申请的优选实施例,并非因此限制本申请的专利范围,凡是利用本申请说明书及附图内容所作的等效结构或等效流程变换,或直接或间接运用在其他相关的技术领域,均同理包括在本申请的专利保护范围内。

Claims (10)

  1. 一种应用程序中的页面跳转方法,其特征在于,所述应用程序中的页面跳转方法包括以下步骤:
    当检测到跳转指令时,根据所述跳转指令确定应用程序中待切换的目标页面;
    判断所述目标页面是否关联有待恢复事务;
    若所述目标页面关联有待恢复事务,则将该待恢复事务恢复至所述目标页面,跳转至应用程序中恢复后的所述目标页面。
  2. 如权利要求1所述的应用程序中的页面跳转方法,其特征在于,所述应用程序中的页面跳转方法还包括:
    当检测到跳转指令时,判断应用程序中的当前页面是否存在待恢复事务;
    若所述当前页面存在待恢复事务,则将该待恢复事务与当前页面关联存储。
  3. 如权利要求1所述的应用程序中的页面跳转方法,其特征在于,所述当检测到跳转指令时,根据所述跳转指令确定应用程序中待切换的目标页面的步骤包括:
    当处于应用程序主页面的终端检测到第一跳转指令时,确定应用程序上一次页面跳转活动的当前页面;
    所述上一次页面跳转活动的当前页面为目标页面。
  4. 如权利要求1所述的应用程序中的页面跳转方法,其特征在于,所述当检测到跳转指令时,根据所述跳转指令确定应用程序中待切换的目标页面的步骤包括:
    当处于应用程序主页面的终端检测到用户基于原有控件输入的第二跳转指令时,判断应用程序上一次页面跳转活动距今时长是否大于第一预设时长;
    若应用程序上一次页面跳转活动距今时长大于第一预设时长,则原有控件的原有功能对应的第一页面为目标页面;
    若应用程序上一次页面跳转活动距今时长小于第一预设时长,则上一次页面跳转活动的当前页面为目标页面。
  5. 如权利要求2所述的应用程序中的页面跳转方法,其特征在于,所述判断应用程序中的当前页面是否存在待恢复事务包括:
    检测应用程序的当前页面是否存在用户输入的编辑数据;
    若应用程序的当前页面存在用户输入的编辑数据,则该用户输入的编辑数据为当前页面对应待恢复事务,当前页面存在待恢复事务。
  6. 如权利要求2所述的应用程序中的页面跳转方法,其特征在于,所述若所述当前页面存在待恢复事务,则将该待恢复事务与当前页面关联存储的步骤之后包括:
    统计与当前页面关联存储的所述待恢复事务的存储时长,判断所述存储时长是否大于第二预设时长;
    若所述存储时长大于第二预设时长,则清除所述待恢复事务。
  7. 如权利要求1所述的应用程序中的页面跳转方法,其特征在于,所述当检测到跳转指令时,根据所述跳转指令确定应用程序中待切换的目标页面的步骤包括:
    当处于应用程序非主页面的终端检测到用户基于新增的跳转控件输入的第三跳转指令时,主页面为目标页面。
  8. 如权利要求4所述的应用程序中的页面跳转方法,其特征在于,所述当处于应用程序主页面的终端检测到用户基于原有控件输入的第二跳转指令时的步骤之后包括:
    判断用户在第三预设时长内是否输入两次或两次以上的第二跳转指令;
    若用户在第三预设时长内输入两次或两次以上的第二跳转指令,则原有控件的原有功能对应的第一页面为目标页面;
    若用户在第三预设时长内仅输入一次第二跳转指令,则判断应用程序上一次页面跳转活动距今时长是否大于第一预设时长。
  9. 一种终端,其特征在于,所述终端包括:存储器、处理器及存储在所述存储器上并可在所述处理器上运行的计算机可读指令,所述计算机可读指令被所述处理器执行时实现如下步骤:
    当检测到跳转指令时,根据所述跳转指令确定应用程序中待切换的目标页面;
    判断所述目标页面是否关联有待恢复事务;
    若所述目标页面关联有待恢复事务,则将该待恢复事务恢复至所述目标页面,跳转至应用程序中恢复后的所述目标页面。
  10. 一种存储介质,其特征在于,所述存储介质上存储有计算机可读指令,所述计算机可读指令被处理器执行时实现如下步骤:
    当检测到跳转指令时,根据所述跳转指令确定应用程序中待切换的目标页面;
    判断所述目标页面是否关联有待恢复事务;
    若所述目标页面关联有待恢复事务,则将该待恢复事务恢复至所述目标页面,跳转至应用程序中恢复后的所述目标页面。
PCT/CN2018/124008 2018-01-11 2018-12-26 应用程序中的页面跳转方法、终端及存储介质 WO2019137217A1 (zh)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201810025780.3 2018-01-11
CN201810025780.3A CN108287743B (zh) 2018-01-11 2018-01-11 应用程序中的页面跳转方法、终端及存储介质

Publications (1)

Publication Number Publication Date
WO2019137217A1 true WO2019137217A1 (zh) 2019-07-18

Family

ID=62835056

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2018/124008 WO2019137217A1 (zh) 2018-01-11 2018-12-26 应用程序中的页面跳转方法、终端及存储介质

Country Status (2)

Country Link
CN (1) CN108287743B (zh)
WO (1) WO2019137217A1 (zh)

Families Citing this family (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108287743B (zh) * 2018-01-11 2020-10-02 上海展扬通信技术有限公司 应用程序中的页面跳转方法、终端及存储介质
CN109634776A (zh) * 2018-10-16 2019-04-16 平安普惠企业管理有限公司 应用恢复方法、装置、设备及存储介质
CN110618848A (zh) * 2018-12-25 2019-12-27 北京时光荏苒科技有限公司 一种页面显示方法、装置、设备及存储介质
CN109871209A (zh) * 2018-12-30 2019-06-11 贝壳技术有限公司 列表页面状态恢复方法及装置
CN112905256B (zh) * 2019-12-03 2024-02-09 北京奇艺世纪科技有限公司 数据处理方法、装置、电子设备及存储介质
CN111881400B (zh) * 2020-07-31 2024-02-23 中国农业银行股份有限公司 网页跳转路径确定方法及装置
CN112364266A (zh) * 2020-11-11 2021-02-12 平安科技(深圳)有限公司 小程序和宿主应用无缝导航方法、装置、电子设备及介质
CN113434577A (zh) * 2021-06-24 2021-09-24 未鲲(上海)科技服务有限公司 业务数据处理方法、存储介质及设备

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20090300163A1 (en) * 2008-05-27 2009-12-03 Holm Eirik Systems and methods for automatic submission of forms on a web page
CN104035669A (zh) * 2013-03-04 2014-09-10 联想(北京)有限公司 基于电子设备的界面切换方法及装置
CN106126376A (zh) * 2016-06-23 2016-11-16 杭州迪普科技有限公司 数据恢复方法及装置
CN108287743A (zh) * 2018-01-11 2018-07-17 上海展扬通信技术有限公司 应用程序中的页面跳转方法、终端及存储介质

Family Cites Families (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105183364A (zh) * 2015-10-30 2015-12-23 小米科技有限责任公司 应用程序切换方法、装置及设备
CN106708360A (zh) * 2016-11-14 2017-05-24 乐视控股(北京)有限公司 应用界面的切换方法及其装置、电子设备

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20090300163A1 (en) * 2008-05-27 2009-12-03 Holm Eirik Systems and methods for automatic submission of forms on a web page
CN104035669A (zh) * 2013-03-04 2014-09-10 联想(北京)有限公司 基于电子设备的界面切换方法及装置
CN106126376A (zh) * 2016-06-23 2016-11-16 杭州迪普科技有限公司 数据恢复方法及装置
CN108287743A (zh) * 2018-01-11 2018-07-17 上海展扬通信技术有限公司 应用程序中的页面跳转方法、终端及存储介质

Also Published As

Publication number Publication date
CN108287743A (zh) 2018-07-17
CN108287743B (zh) 2020-10-02

Similar Documents

Publication Publication Date Title
WO2019137217A1 (zh) 应用程序中的页面跳转方法、终端及存储介质
WO2015030364A1 (en) Method for sharing media data and electronic device thereof
WO2017111358A1 (en) User terminal device, and mode conversion method and sound system for controlling volume of speaker thereof
WO2011021909A2 (en) Method and apparatus for providing contents via network, method and apparatus for receiving contents via network, and method and apparatus for backing up data via network, backup data providing device, and backup system
WO2014077520A1 (en) Electronic device and method for sending response message according to current status
EP3314482A1 (en) Method and device of tagging links included in a screenshot of webpage
WO2014058250A1 (en) User terminal device, sns providing server, and contents providing method thereof
WO2015041436A1 (en) Method of managing control right, client device therefor, and master device therefor
WO2015056968A1 (ko) 프로필 제공 방법 및 상기 방법을 수행하는 사용자 단말
WO2014189237A1 (en) System for remotely controlling electronic device and method of operating the same
WO2017148142A1 (zh) 桌面图标文件夹的名称切换方法、装置及电子设备
WO2014098539A1 (en) User terminal apparatus and control method thereof
WO2012062151A1 (zh) 处理网络数据的方法和系统
WO2019039739A1 (en) DISPLAY APPARATUS AND METHOD FOR CONTROLLING THE SAME
WO2014189275A1 (en) Apparatus and method of recognizing external device in a communication system
WO2016101441A1 (zh) 一种进行文件同步的方法及系统
WO2017126740A1 (ko) 단말 장치, 원격 제어 시스템 및 제어 방법
WO2017135776A1 (en) Display apparatus, user terminal apparatus, system, and controlling method thereof
WO2019037542A1 (zh) 电视信源的预览方法、装置及计算机可读存储介质
WO2017052072A1 (ko) 영상 표시 장치 및 그 동작 방법
WO2015037827A1 (en) Display apparatus and controlling method thereof
WO2012022215A1 (zh) 一种互联网中互动信息的交互方法、装置及系统
WO2013027879A1 (en) Content device and control method thereof
WO2020237849A1 (zh) 网络块设备快照读写方法、装置、设备及存储介质
WO2020235858A1 (en) Server and control method thereof

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: 18900112

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 18900112

Country of ref document: EP

Kind code of ref document: A1