CN110515717B - Background switching method, device and equipment of application program and storage medium - Google Patents

Background switching method, device and equipment of application program and storage medium Download PDF

Info

Publication number
CN110515717B
CN110515717B CN201910809102.0A CN201910809102A CN110515717B CN 110515717 B CN110515717 B CN 110515717B CN 201910809102 A CN201910809102 A CN 201910809102A CN 110515717 B CN110515717 B CN 110515717B
Authority
CN
China
Prior art keywords
application program
key
flashback
terminal
application
Prior art date
Legal status (The legal status 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 status listed.)
Active
Application number
CN201910809102.0A
Other languages
Chinese (zh)
Other versions
CN110515717A (en
Inventor
宋方
黄千洋
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Guangdong Oppo Mobile Telecommunications Corp Ltd
Original Assignee
Guangdong Oppo Mobile Telecommunications Corp Ltd
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 Guangdong Oppo Mobile Telecommunications Corp Ltd filed Critical Guangdong Oppo Mobile Telecommunications Corp Ltd
Priority to CN201910809102.0A priority Critical patent/CN110515717B/en
Publication of CN110515717A publication Critical patent/CN110515717A/en
Application granted granted Critical
Publication of CN110515717B publication Critical patent/CN110515717B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • 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/0487Interaction techniques based on graphical user interfaces [GUI] using specific features provided by the input device, e.g. functions controlled by the rotation of a mouse with dual sensing arrangements, or of the nature of the input device, e.g. tap gestures based on pressure sensed by a digitiser
    • G06F3/0488Interaction techniques based on graphical user interfaces [GUI] using specific features provided by the input device, e.g. functions controlled by the rotation of a mouse with dual sensing arrangements, or of the nature of the input device, e.g. tap gestures based on pressure sensed by a digitiser using a touch-screen or digitiser, e.g. input of commands through traced gestures
    • 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/46Multiprogramming arrangements
    • G06F9/48Program initiating; Program switching, e.g. by interrupt
    • G06F9/4806Task transfer initiation or dispatching

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)
  • User Interface Of Digital Computer (AREA)

Abstract

The application discloses a background switching method, device and equipment of an application program and a storage medium, and belongs to the field of application programs. The method comprises the following steps: displaying a user interface of an application program on the terminal; receiving a first trigger operation on the terminal, and switching the running state of the application program from a foreground running state to a background running state according to the first trigger operation; and when the running state of the application program is switched from the foreground running state to the background running state, a flashback key is displayed on the terminal, and the flashback key is used for displaying a user interface of the application program when triggered. According to the background switching method of the application program, when the application program is switched from the foreground running state to the background running state, the flashback key corresponding to the application program is displayed on the terminal, and even if a user interface of another application program is displayed on the terminal, the user interface of the application program can be quickly switched back through the flashback key, so that the man-machine interaction efficiency is improved.

Description

Background switching method, device and equipment of application program and storage medium
Technical Field
The present application relates to the field of applications, and in particular, to a method, an apparatus, a device, and a storage medium for switching an application in the background.
Background
Along with the development of intelligent terminals, application programs installed and operated on the terminals are continuously developed, so that the types of the application programs are more and the functions are more and more powerful.
On the terminal, only the user interface of the application running in the foreground is displayed on the interface of the terminal, and the application running in the background is not displayed on the interface. For example, a user interface of a game program is displayed on the terminal, so that the program running in the foreground of the terminal is the game program, and at the same time, the instant messaging program still runs in the background; the terminal can still receive the message in the instant messaging program, but the message is not displayed on the interface, and only when the instant messaging program is running in the foreground again, the message is displayed on the interface.
Because the information of the application program running in the background cannot be displayed on the interface of the terminal in real time, when a user views the information, the application program running in the foreground needs to be withdrawn from or placed in the background for running, and then the application program running in the background is switched back to the foreground for running, so that the steps are complex and the human-computer interaction efficiency is low.
Disclosure of Invention
In order to solve the problems of complex step and low interaction efficiency of background switching of application programs in the related art, the embodiment of the application provides a method, a device and equipment for background switching of application programs and a storage medium. The technical scheme is as follows:
In one aspect, a background switching method for an application program is provided, where the method includes:
displaying a user interface of an application program on the terminal;
receiving a first trigger operation on the terminal, and switching the running state of the application program from a foreground running state to a background running state according to the first trigger operation;
and when the running state of the application program is switched from the foreground running state to the background running state, displaying a flashback key on the terminal, wherein the flashback key is used for displaying a user interface of the application program when triggered.
In another aspect, a background switching device for an application program is provided, where the device includes:
the display module is used for displaying a user interface of the application program on the terminal;
the receiving module is used for receiving a first triggering operation on the terminal;
the switching module is used for switching the running state of the application program from the foreground running state to the background running state according to the first triggering operation;
and the display module is used for displaying a flashback key on the terminal when the running state of the application program is switched from the foreground running state to the background running state, and the flashback key is used for displaying a user interface of the application program when triggered.
In another aspect, a computer device is provided, the computer device including a processor and a memory, the memory storing at least one instruction, at least one program, a set of codes, or a set of instructions, the at least one instruction, the at least one program, the set of codes, or the set of instructions being loaded and executed by the processor to implement the background switching method of an application as described in the first aspect.
In another aspect, a computer readable storage medium is provided, in which at least one instruction, at least one program, a set of codes, or a set of instructions is stored, the at least one instruction, the at least one program, the set of codes, or the set of instructions being loaded and executed by a processor to implement the method of background switching of an application as described in the first aspect.
The technical scheme provided by the embodiment of the application has the beneficial effects that at least:
displaying a user interface of an application program on the terminal; receiving a first trigger operation on the terminal, and switching the running state of the application program from a foreground running state to a background running state according to the first trigger operation; and when the running state of the application program is switched from the foreground running state to the background running state, a flashback key is displayed on the terminal, and the flashback key is used for displaying a user interface of the application program when triggered.
According to the background switching method of the application program, when the application program is switched from the foreground running state to the background running state, the flashback key corresponding to the application program is displayed on the terminal, and even if a user interface of another application program is displayed on the terminal, the user interface of the application program can be quickly switched back through the flashback key, so that the man-machine interaction efficiency is improved.
Drawings
In order to more clearly illustrate the technical solutions of the embodiments of the present application, the drawings required for the description of the embodiments will be briefly described below, and it is apparent that the drawings in the following description are only some embodiments of the present application, and other drawings may be obtained according to these drawings without inventive effort for a person skilled in the art.
FIG. 1 is a flowchart of a background switching method for an application according to an exemplary embodiment of the present application;
FIG. 2 is an interface diagram of a method for closing a flashback key in accordance with an exemplary embodiment of the present application;
FIG. 3 is a schematic diagram of a setting interface for a flashback key function provided by an exemplary embodiment of the present application;
FIG. 4 is an interface schematic of a flashback key provided in an exemplary embodiment of the present application;
FIG. 5 is an interface schematic of a flashback key provided in another exemplary embodiment of the present application;
FIG. 6 is a flowchart of a background switching method for an application according to another exemplary embodiment of the present application;
FIG. 7 is a flowchart of a background switching method for an application according to another exemplary embodiment of the present application;
FIG. 8 is an interface diagram of a background switching method for an application according to an exemplary embodiment of the present application;
FIG. 9 is a flowchart of a background switching method for an application according to another exemplary embodiment of the present application;
FIG. 10 is a schematic diagram of a task queue provided by an exemplary embodiment of the present application;
FIG. 11 is a flowchart of a background switching method for an application according to another exemplary embodiment of the present application;
FIG. 12 is an interface diagram of a background switching method for an application according to another exemplary embodiment of the present application;
FIG. 13 is a block diagram illustrating a background switching device for an application according to an exemplary embodiment of the present application;
fig. 14 is a schematic structural view of a terminal according to an exemplary embodiment of the present application.
Detailed Description
Reference will now be made in detail to exemplary embodiments, examples of which are illustrated in the accompanying drawings. When the following description refers to the accompanying drawings, the same numbers in different drawings refer to the same or similar elements, unless otherwise indicated. The implementations described in the following exemplary examples do not represent all implementations consistent with the application. Rather, they are merely examples of apparatus and methods consistent with aspects of the application as detailed in the accompanying claims.
According to the scheme provided by the application, when people want to view information in the application program running in the background, the interface displayed on the terminal can be quickly switched back to the user interface of the application program running in the background through the flashback key. Illustratively, the terminal may be a mobile phone, a tablet computer, an electronic book reader, a smart watch, an MP3 player (Moving Picture Experts Group Audio Layer III, moving picture experts compression standard audio layer 3), an MP4 (Moving Picture Experts Group Audio Layer IV, moving picture experts compression standard audio layer 4) player, a notebook computer, a laptop portable computer, a desktop computer, and the like.
Referring to fig. 1, a flowchart of a background switching method of an application program according to an exemplary embodiment of the present application is shown, where the method is applied to a terminal, and the method includes:
step 101, displaying a user interface of an application program on the terminal.
A user interface of the application is displayed on the terminal, that is, the application is in a foreground running state.
Optionally, the user interface includes an exit control, where the exit control is used to exit the application program from the foreground operation and switch to the background operation when triggered. Or, a gesture operation is set on the user interface, and the gesture operation is used for exiting the application program from the foreground operation to the background operation when triggered. For example, the user interface of the application program comprises an exit button control, when the terminal receives the triggering operation of the user on the exit button control, the application program is exited from the foreground operation and is turned to the background operation, and the user can view the application program in the background operation on the multi-task interface. For another example, the terminal receives a sliding gesture operation triggered on the user interface of the application program, and returns to the desktop.
Optionally, the terminal includes an exit physical button, where the exit physical button is used to exit the application program from the foreground operation to the background operation when triggered. For example, the exit physical key may be a Home key, a user interface of the application program is displayed on the terminal, the terminal receives a trigger operation on the Home key, returns to the desktop from the user interface, and exits the application program from the foreground operation to the background operation.
Step 102, the terminal receives a first trigger operation on the terminal.
Optionally, the terminal receives a first trigger operation of the exit control on the user interface of the application program; or the terminal receives a first trigger operation of exiting the physical key.
Illustratively, the first triggering operation may include a single click operation, a multiple click operation, a long press operation, or the like, and the type of the first triggering operation is not limited in this embodiment.
Optionally, the first trigger operation may be a gesture operation, and the terminal receives the gesture operation on the user interface of the application program.
Illustratively, the gesture operation may include an upward swipe gesture operation, a leftward swipe gesture operation, a zigzag swipe gesture operation, or the like, and the type of the gesture operation is not limited in this embodiment.
And step 103, the terminal switches the running state of the application program from the foreground running state to the background running state according to the first triggering operation.
And after receiving the first triggering operation, the terminal switches the running state of the application program from the foreground running state to the background running state.
And 104, displaying a flashback key on the terminal when the running state of the application program is switched from the foreground running state to the background running state.
When the running state of the application program is switched from the foreground running state to the background running state, the terminal generates and displays a flashback key; wherein the flashback key is used to display a user interface of the application when triggered. Optionally, the flashback key is displayed at the uppermost layer on the interface of the terminal.
It should be noted that, information of an application program running in the background in the terminal is not displayed on an interface of the terminal, in order to expose key information of the application program in the background running state, optionally, when the terminal detects that the running state of the application program is switched from the foreground running state to the background running state, the terminal calls an application program programming interface (Application Programming Interface, API) of the application program to acquire the key information of the application program; and displaying the key information of the application program on the flashback key, and displaying the flashback key on the terminal, so that a user can know the key information of the application program running in the background through the displayed flashback key.
Optionally, a main program is run in the terminal; the terminal can detect the running state of the application program through the main program, when detecting that the running state of the application program is switched from the foreground running state to the background running state, the terminal can acquire the key information of the application program through calling the API of the application program by the main program, and can generate a flashback key carrying the key information of the application program through the main program.
It should be noted that, before the main program obtains the key information of the application program from the background service of the application program, it is also necessary to establish a communication relationship between processes, optionally, the terminal establishes an inter-process communication (InterProcess Communication, IPC) between the main program and the background service of the application program through a binding service (bindService); and then acquiring key information of the application program through the API of the main program calling application program based on the IPC.
Alternatively, when the display of the flashback key is canceled on the terminal, IPC between the main program and the background service of the application program is ended by an unbinding service (unbinding service).
In addition, during critical information transmission, the IPC may be disconnected, at which time the connection needs to be reestablished.
Wherein, the display of the cancel flashback key on the terminal can comprise two cancel situations:
In the first cancellation situation, a preset duration displayed by a flashback key is set in the terminal; the preset duration is the maximum display duration of the flashback key on the terminal when no trigger operation exists on the flashback key. And within the preset duration of the display of the flashback key, if the terminal does not receive the triggering operation on the flashback key, the terminal cancels the display of the flashback key.
For example, the preset duration set in the terminal is 60s; and starting timing from displaying the flashback key on the terminal, detecting whether triggering operation exists on the flashback key by the terminal through a main program within 60 seconds of timing, and if not, canceling display of the flashback key by the terminal at 61 seconds.
And in the second cancellation situation, the user can cancel the display of the flashback key autonomously, the terminal receives the deletion operation of the flashback key triggered on the terminal, and the display of the flashback key is cancelled. For example, the terminal receives a drag operation on the flashback key triggered on the interface, drags the flashback key to the edge of the interface to delete, and the flashback key is not displayed on the interface of the terminal. Illustratively, as shown in fig. 2, dragging the flashback key 01 to the edge area of the interface on the terminal loosens the hand, i.e., the flashback key 01 can be turned off.
The terminal cancels the display of the flashback key but does not close the main program, and when the running state of the application program is switched from the foreground running state to the background running state, the flashback key is correspondingly generated and displayed in the terminal. And the switch of the flashback key function (i.e., the operation of the main program) may be designed in a setting option of the terminal.
Illustratively, as shown in fig. 3, the setting interface 02 of the flashback key function in the terminal includes a switch 03 of the flashback key function; when the switch 03 of the flashback key function is in an on state, the flashback key function on the terminal takes effect; the flashback key function on the terminal fails when the switch 03 of the flashback key function is in an off state.
The setting interface 02 of the flashback key function also comprises a switch 04 of the flashback key function of the application program, and when the switch 04 of the flashback key function of the application program is in an on state, the application program can use the flashback key function; when the switch 04 of the flashback key function of the application is in an off state, the application cannot use the flashback key function.
Optionally, the application program comprises video software, and the key information comprises video playing progress; for example, when the video in the video software is played for 10 minutes and 25 seconds, the video software is cut to run in the background, and a flashback key is displayed on the terminal, and the playing progress of the video is displayed on the flashback key for 10 minutes and 25 seconds.
Or, the application program comprises teaching software, and the key information comprises learning lessons; for example, when the course in the teaching software is played to the second chapter, the teaching software is cut to the background to run, and correspondingly, a flashback key is displayed on the terminal, and the lesson time information 'second chapter' of the course is displayed on the flashback key.
Or, the application program comprises software with a timing function, and the key information comprises starting countdown or reserving waiting time; for example, when the virtual character needs to revive in the game software, the game software is cut to the background to run, and a flashback key is displayed on the terminal, and a virtual character reviving countdown is displayed on the flashback key.
Or, the application program comprises software with journey monitoring, and the key information comprises departure time, arrival time or next station place; for example, when the taxi arrives in the taxi calling software, the taxi calling software is cut to a background to run, and a flashback key is displayed on the terminal and the estimated arrival time of the taxi is displayed on the flashback key.
Or, the application program comprises software with a queuing function, and the key information comprises queuing information; for example, when the taxi arrives in the taxi calling software, the taxi calling software is cut to a background to run, a corresponding flashing key is displayed on the terminal, queuing information, namely the total number of current taxi calling orders and the number of the orders of the terminal user in the team, is displayed on the flashing key.
Illustratively, the status displays of the flashback key may include a general status display and a custom status display, as shown in FIG. 4, "12/30 is queuing", "02:15 first section training", and "00:12 waiting for revival" are waiting status displays, "driver accepted order", "done training", and "revived" are key outcome status displays.
In the waiting state, if the flashback key is not operated, the flashback key is in a static state, as shown by a flashback key 05 in fig. 5, and key information is displayed after clicking, as shown by a flashback key 06.
In summary, in the background switching method of the application program provided in the embodiment, a user interface of the application program is displayed on the terminal; receiving a first trigger operation on the terminal, and switching the running state of the application program from a foreground running state to a background running state according to the first trigger operation; and when the running state of the application program is switched from the foreground running state to the background running state, a flashback key is displayed on the terminal, and the flashback key is used for displaying a user interface of the application program when triggered.
According to the background switching method of the application program, when the application program is switched from the foreground running state to the background running state, the flashback key corresponding to the application program is displayed on the terminal, and even if a user interface of another application program is displayed on the terminal, the user interface of the application program can be quickly switched back through the flashback key, so that the man-machine interaction efficiency is improved.
According to the background switching method of the application program, the key information of the application program running in the background is displayed on the flashback key, so that the display function of the key information of the application program in the background is provided for a user, the user can check the key information of the application program without switching the application program running in the background back to the foreground again, the man-machine interaction efficiency is improved, meanwhile, the omission of messages is avoided, and the user experience is improved.
Illustratively, in the embodiment shown in fig. 1, the above-mentioned process of activating and deactivating the flashback key may be as shown in fig. 6, and the steps are as follows:
and 11, binding a main program and a background service of an application program by the terminal through the bindService. Wherein the application is a background running application.
Step 12, the terminal checks whether the application belongs to the white list. The terminal stores a white list, wherein the white list comprises application programs capable of using a flashback key function; alternatively, the terminal may check whether the application belongs to the whitelist through the package name and signature of the application.
When the application program belongs to the white list, the binding between the main program and the background service of the application program is successful; otherwise, the binding between the main program and the background service of the application program fails.
And step 13, when the binding is successful, the terminal transfers data through the API of the main program calling application program.
And step 14, the terminal judges whether the key information of the application program is obtained within a second preset time period. That is, in the second preset time period, the terminal judges whether the background service of the application program transmits the key information to the main program through the API; in the second preset time period, the main program obtains key information of the application program from background service of the application program, and step 15 is executed; otherwise, step 16 is performed.
And 15, displaying a flashback key by the terminal. When the terminal does not display a flashback key, the main program in the terminal generates and displays the flashback key according to the key information of the application program; when the flashback key is displayed on the terminal, the main program in the terminal updates the key information displayed on the flashback key according to the key information of the application program obtained at the time.
And 16, the terminal cancels the display of the flashback key.
And step 17, the terminal unbinding the background service of the main program and the application program through unbinding service.
Based on fig. 1, the function of the flashback key includes a user interface that displays the application when triggered, and thus steps 105 through 106 are added after step 104, as shown in fig. 7, to implement the function of quickly switching back the application running in the background to the foreground running, with the following exemplary steps:
step 105, the terminal receives a second trigger operation on the flashback key.
Illustratively, the second triggering operation may include a single click operation, a multiple click operation, a long press operation, or the like, and the type of the second triggering operation is not limited in this embodiment.
And step 106, the terminal displays a user interface of the application program on the terminal according to the second triggering operation.
And when the terminal receives the second triggering operation, the terminal displays a user interface of the application program. The user interface of the application may be the same user interface as the user interface in step 101, or a different user interface.
If the user interface of the application is a different user interface from the user interface in step 101, the user interface may be a regenerated user interface based on the key information of the application displayed on the flashback key.
For example, the application program is game software, a picture that the virtual character is reviving is displayed in the foreground runtime, and the reviving countdown of the virtual character is displayed on a flashback key in the background runtime; when the virtual character is successfully revived, a countdown is displayed on a flashback key to be '00:00', which indicates that the reviving is successful, the game software is switched back to the foreground operation, and a picture after the virtual character is revived is displayed, which is different from a picture that the virtual character is revived.
Illustratively, taking an application program as a taxi taking software as an example, the taxi taking software switches back to an interface of a foreground operation through a flashback key as shown in fig. 8, and a user interface 21 for calling a taxi by a user in the taxi taking software is displayed on a terminal; the terminal switches the running state of taxi taking software from a foreground running state to a background running state, returns to the desktop 22, and displays a flashback key 23 in the form of bubbles on the desktop 22, wherein the flashback key 23 displays queue information of taxi calling, and '12/30' indicates that 30 users are using taxi calling service, and the user with the terminal is ranked at the 12 th position; when the terminal receives a triggering operation on the flashback key 23, the terminal cuts back to the user interface 21.
In summary, in the background switching method of the application program provided in the embodiment, a user interface of the application program is displayed on the terminal; receiving a first trigger operation on the terminal, and switching the running state of the application program from a foreground running state to a background running state according to the first trigger operation; when the running state of the application program is switched from the foreground running state to the background running state, a flashback key is displayed on the terminal; receiving a second trigger operation on the flashback key; and displaying a user interface of the application program on the terminal according to the second triggering operation.
According to the background switching method of the application program, when the application program is switched from the foreground running state to the background running state, the flashback key corresponding to the application program is displayed on the terminal, and even if a user interface of another application program is displayed on the terminal, the user interface of the application program can be quickly switched back through the flashback key, so that the man-machine interaction efficiency is improved, and the user experience is also improved.
In the use process of the terminal, a plurality of application programs can be simultaneously operated in the background of the terminal, and when the operation states of at least two application programs are in the background operation states, the matching of the flashback key and the application programs can be realized in the following two modes:
The first way is to display the flashback key of the application program corresponding to the highest priority;
in a second way, the flashback keys of at least two applications are displayed by a list.
In a first manner, the at least two applications may include a first application and a second application, and determining the match between the flashback key and the application by determining the priorities of the first application and the second application, and illustratively, step 104 may be replaced with steps 1041 to 1043 based on fig. 1, as shown in fig. 9, and the steps are as follows:
in step 1041, when the running state of the application program is switched from the foreground running state to the background running state, the terminal determines whether the priority of the first application program is greater than the priority of the second application program.
When the priority of the first application is greater than or equal to the priority of the second application, step 1042 is executed; when the priority of the first application is smaller than the priority of the second application, step 1043 is performed.
Optionally, the priority of the application comprises a traffic priority. Alternatively, the priority of the application may be custom.
Illustratively, the terminal determines whether the service priority of the first application is greater than the service priority of the second application. Executing step 1042 when the service priority of the first application is greater than or equal to the service priority of the second application; when the service priority of the first application is smaller than that of the second application, step 1043 is performed.
Step 1042, a flashback key corresponding to the first application is displayed on the terminal.
Step 1043, displaying a flashback key corresponding to the second application program on the terminal.
The display of the flashback key may refer to step 104, and will not be described in detail herein.
Schematically, as shown in fig. 10, a task queue corresponding to a main program is set in a terminal, an application program running in the background creates a queue 1 and a queue 2 according to service priority, wherein the priority of service 1 in the queue 1 is greater than the priority of service 2 in the queue 2, if service 1 is the service of a first application program, service 2 is the service of a second application program, and a flashback key corresponding to the first application program is displayed in the terminal. It should be noted that, the terminal does not display the flashback key corresponding to the second application program, but the terminal is still in the background to periodically execute the service 2, and periodically update the data in the service 2.
When the running states of at least two application programs are in the background running state, the at least two application programs are arranged in the task queue according to the priority order, and the terminal displays a flashback key of the first application program corresponding to the highest priority; and when the display period of the first application program is up, if the key information of the second application program corresponding to the next priority is not invalid, displaying a flashback key corresponding to the second application program.
For example, the priority of the game software is higher than that of the calling software, the terminal firstly displays a flashback key of the game software, the flashback key comprises key information, and the revival countdown is 00:12; when the countdown is 00:00, i.e. the display period is up, the terminal is revived, the key information of the calling software is displayed, and 16/25 of the order is waited to be received, i.e. the order of the user is positioned at the 16 th position in 25 orders, and the order of the user is processed after the processing of the first 15 orders is completed; the order is not completed, the key information is still effective, and the terminal displays a flashback key of the calling software.
In summary, in the background switching method of the application program provided in the embodiment, a user interface of the application program is displayed on the terminal; receiving a first trigger operation on the terminal, and switching the running state of the application program from a foreground running state to a background running state according to the first trigger operation; when the running state of the application program is switched from the foreground running state to the background running state, judging whether the priority of the first application program is greater than that of the second application program; and when the priority of the first application program is greater than or equal to that of the second application program, displaying a flashback key corresponding to the first application program on the terminal.
According to the background switching method of the application program, when the application program is switched from the foreground running state to the background running state, the flashback key corresponding to the application program is displayed on the terminal, and even if a user interface of another application program is displayed on the terminal, the user interface of the application program can be quickly switched back through the flashback key, so that the man-machine interaction efficiency is improved, and the user experience is also improved.
When a plurality of application programs running in the background exist, the background switching method of the application programs adopts the priority to determine the matching of the application programs and the flashback keys, and the flashback keys of the application programs with high priority are preferentially displayed, so that key information of the background application programs which are more important is provided for users, the requirements of the users are met, and the user experience is improved.
In a second manner, the terminal displays, through the list, corresponding flashback keys for at least two existing application programs in a background running state, and may, illustratively, be replaced with steps 1044 to 1046 in step 104 based on fig. 1, as shown in fig. 11, where the steps are as follows:
step 1044, displaying the aggregated flashback key on the terminal,
when at least two application programs exist in the terminal and are in a background running state, the terminal displays an aggregated flashback key on an interface, and the aggregated flashback key is used for displaying a flashback key corresponding to each application program in the at least two application programs when triggered.
Illustratively, icons showing at least two applications may be aggregated on an aggregated flashback key.
In step 1045, the terminal receives a third trigger on the aggregated flashback key.
Illustratively, the third triggering operation may include a single click operation, a multiple click operation, a long press operation, or the like, and the type of the third triggering operation is not limited in this embodiment.
In step 1046, the terminal displays a flashback key corresponding to each of the at least two application programs according to the third trigger operation.
The at least two applications may include a first application and a second application; and after receiving the third triggering operation, the terminal displays the flashback keys respectively corresponding to the first application program and the second application program. That is, after the terminal receives the third trigger operation on the flashback key, n flashback keys are displayed on the terminal; each flashback key corresponds to an application program, and optionally, key information of the corresponding application program is displayed on each flashback key; n is a positive integer greater than 1.
After displaying the at least two flashback keys on the terminal, the terminal may receive a selection operation on a target flashback key in the at least two flashback keys; and displaying a user interface of the target application program corresponding to the target flashback key on the terminal according to the selection operation. Alternatively, the selection operation may include a single click operation, or a multiple click operation, or a long press operation, or a slide operation, or the like, and the type of the selection operation is not limited in this embodiment.
Illustratively, as shown in FIG. 12, a user interface 31 is displayed on the terminal, the user interface 31 including an aggregated flashback key 32; after the terminal receives the triggering operation on the aggregated flashback key 32, at least two flashback keys, such as a flashback key 33, a flashback key 34 and a flashback key 35 in the figure, are displayed on the user interface 31; the flashback key 33 is a flashback key corresponding to the calling software, the flashback key displays queue information of the calling service, and the user with the terminal among 30 calling users is ranked at the 12 th position; flashback key 34 is a flashback key corresponding to the exercise software, which shows that the first workout has been completed for 2 minutes 15 seconds; the flashback key 35 is a flashback key corresponding to the game software, and the flashback key displays a virtual character for 12 seconds from the revival.
When the terminal receives a selection operation on the flashback key 33, the terminal displays a user interface 36 of the calling software.
In summary, in the background switching method of the application program provided in the embodiment, a user interface of the application program is displayed on the terminal; receiving a first trigger operation on the terminal, and switching the running state of the application program from a foreground running state to a background running state according to the first trigger operation; when the running state of the application program is switched from the foreground running state to the background running state, a flashback key is displayed on the terminal; receiving a third trigger operation on the flashback key; and displaying a corresponding list on the terminal according to the third triggering operation.
According to the background switching method of the application programs, when a plurality of application programs running in the background exist, the flashback keys of the application programs are correspondingly displayed through the aggregated flashback keys, and the user interfaces of the corresponding application programs can be quickly switched back through the flashback keys, so that user experience is improved.
And the corresponding list items are also displayed with the key information of the corresponding application programs, so that a user can check the key information of a plurality of application programs running in the background through the list items, avoid missing the important information, meet the requirements of the user and improve the user experience.
In addition, in the process of executing the background switching method of the application program provided by the application, the terminal still manages the application program running in the background according to the original keep-alive mechanism, wherein the keep-alive mechanism comprises at least one of the following four items:
1) The process of the three-party application program follows a default process management mechanism;
2) Manually cleaning and killing (kill) the progress of the three-party application program by one key;
3) Processes of the three-party application program are dropped through a low memory management mechanism (Low Memory Killer, LMK) kill;
4) The terminal stores a white list of the three-party application program, and processes of the three-party application program which does not belong to the white list are removed through a cleaning program kill carried by the terminal.
The third party application refers to an application provided by a third party provider different from the provider of the terminal.
In addition, whether the application program can use the function of the flash key can be set through a function main switch, for example, the application program white list with the flash key function is artificially updated, then the application program white list with the flash key function is sent to the terminal through the cloud service, and when the application program in the terminal belongs to the application program white list with the flash key function, the function of the flash key can be used, so that the step of the background switching method of the application program provided by the application is executed.
The following are examples of the apparatus of the present application that may be used to perform the method embodiments of the present application. For details not disclosed in the embodiments of the apparatus of the present application, please refer to the embodiments of the method of the present application.
Referring to fig. 13, a block diagram of a background switching device for an application according to an exemplary embodiment of the application is shown. The background switching device of the application program may be used in a terminal to perform all or part of the steps performed by the terminal in the method provided by any of the embodiments shown in fig. 1 to 12. The background switching device of the application program comprises:
A display module 201 for displaying a user interface of an application program on a terminal;
a receiving module 202, configured to receive a first trigger operation on the terminal;
a switching module 203, configured to switch an operation state of the application from a foreground operation state to a background operation state according to the first trigger operation;
the display module 201 is configured to display a flashback key on the terminal when the running state of the application program is switched from the foreground running state to the background running state, where the flashback key is used to display a user interface of the application program when triggered.
In some embodiments, the display module 201 includes:
an acquiring submodule 2011, configured to call an application programming interface API of the application program to acquire key information of the application program;
and a display sub-module 2012, configured to display key information of the application program on the flashback key, and display the flashback key on the terminal.
In some embodiments of the present invention, in some embodiments,
the application program comprises video software, and the key information comprises video playing progress; or alternatively, the first and second heat exchangers may be,
the application program comprises teaching software, and the key information comprises a learning class time; or alternatively, the first and second heat exchangers may be,
The application program comprises software with a timing function, and the key information comprises starting countdown or reserving waiting time; or alternatively, the first and second heat exchangers may be,
the application program comprises software with journey monitoring, and the key information comprises departure time, arrival time or next station place; or alternatively, the first and second heat exchangers may be,
the application program comprises software with queuing functions, and the key information comprises queuing information.
In some embodiments, the terminal has a main program running therein;
the acquiring submodule 2011 is configured to call the API through the main program to acquire key information of the application program;
the display submodule 2012 is used for generating the flashback key carrying key information of the application program through the main program.
In some embodiments, the display module 201 further comprises:
a binding sub-module 2013, configured to establish an interprocess communication IPC between the main program and a background service of the application program through a binding service;
an acquiring submodule 2011 is used for acquiring key information of the application program based on the IPC through calling the API by the main program.
In some embodiments of the present invention, in some embodiments,
the receiving module 202 is configured to receive a second trigger operation on the flashback key;
The display module 201 is configured to display a user interface of the application program on the terminal according to the second trigger operation.
In some embodiments, the display module 201 is configured to cancel display of the flashback key if a triggering operation on the flashback key is not received within a preset duration of display of the flashback key.
In some embodiments, there are at least two running states of the application in the background running state; the at least two application programs comprise a first application program and a second application program;
the display module 201 is configured to display, on the terminal, the flashback key corresponding to the first application program when the priority of the first application program is greater than the priority of the second application program.
In some embodiments, there are at least two running states of the application in the background running state;
the display module 201 is configured to display an aggregated flashback key on the terminal;
the receiving module 202 is configured to receive a third triggering operation on the aggregated flashback key;
the display module 201 is configured to display the flashback key corresponding to each of at least two application programs according to the third trigger operation.
In some embodiments of the present invention, in some embodiments,
the receiving module 202 is configured to receive a selection operation on a target flashback key in at least two flashback keys;
the display module 201 is configured to display, on the terminal, a user interface of a target application program corresponding to a target flashback key according to the selection operation.
In summary, the background switching device for the application program provided in this embodiment displays the user interface of the application program on the terminal; receiving a first trigger operation on the terminal, and switching the running state of the application program from a foreground running state to a background running state according to the first trigger operation; and when the running state of the application program is switched from the foreground running state to the background running state, a flashback key is displayed on the terminal, and the flashback key is used for displaying a user interface of the application program when triggered.
According to the background switching device of the application program, when the application program is switched from the foreground operation state to the background operation state, the flashback key corresponding to the application program is displayed on the terminal, and even if a user interface of another application program is displayed on the terminal, the user interface of the application program can be quickly switched back through the flashback key, so that the man-machine interaction efficiency is improved.
The background switching device of the application program also provides the display function of the key information of the background application program for the user by displaying the key information of the application program running in the background on the flashback key, so that the user can check the key information of the application program without switching the application program running in the background back to the foreground, the man-machine interaction efficiency is improved, meanwhile, the omission of messages is avoided, and the user experience is improved.
Referring to fig. 14, a schematic structural diagram of a terminal according to an exemplary embodiment of the present application is shown, and as shown in fig. 14, the terminal includes a processor 310, a memory 320, a display assembly 330, and a sensor assembly 340, where the display assembly 330 is used to display an interface of a program running in a foreground in the terminal, and the sensor assembly 340 is used to collect respective sensor data. The memory 320 stores at least one instruction that is loaded and executed by the processor 310 to implement some or all of the steps performed by the terminal in the background switching method of an application program according to the above embodiments.
The embodiment of the application also provides a computer readable medium, which stores at least one instruction, and the at least one instruction is loaded and executed by a processor to implement all or part of the steps executed by a terminal in the background switching method of the application program according to each embodiment.
Embodiments of the present application also provide a computer program product storing at least one instruction that is loaded and executed by a processor to implement the background switching method of an application program as described in the above embodiments, and all or part of the steps performed by a terminal.
It should be noted that: when the background switching method of the application program provided in the above embodiment is executed in the terminal, only the above embodiments are exemplified, and in an actual program, the above function allocation may be performed by different functional modules according to needs, that is, the internal structure of the device is divided into different functional modules, so as to complete all or part of the functions described above. In addition, the apparatus and the method embodiments provided in the foregoing embodiments belong to the same concept, and specific implementation processes of the apparatus and the method embodiments are detailed in the method embodiments and are not repeated herein.
The foregoing embodiment numbers of the present application are merely for the purpose of description, and do not represent the advantages or disadvantages of the embodiments.
It will be understood by those skilled in the art that all or part of the steps for implementing the above embodiments may be implemented by hardware, or may be implemented by a program for instructing relevant hardware, where the program may be stored in a computer readable storage medium, and the storage medium may be a read-only memory, a magnetic disk or an optical disk, etc.
The foregoing description of the preferred embodiments of the application is not intended to limit the application to the precise form disclosed, and any such modifications, equivalents, and alternatives falling within the spirit and scope of the application are intended to be included within the scope of the application.

Claims (11)

1. A background switching method for an application program, the method comprising:
background service for binding the main program and the application program running in the background; checking whether the application program running in the background belongs to a white list or not, wherein the white list comprises application programs capable of using a flashback key function; when the application program belongs to a white list, the binding between the main program and the background service of the application program is successful; otherwise, the binding between the main program and the background service of the application program fails;
displaying a user interface of an application program on the terminal;
receiving a first trigger operation on the terminal, and switching the running state of the application program from a foreground running state to a background running state according to the first trigger operation; the running states of at least two application programs are in the background running state;
when the running states of at least two application programs are switched from the foreground running state to the background running state, an aggregated flashback key is displayed on the terminal;
Receiving a third trigger operation on the aggregated flashback key;
displaying a flashback key corresponding to each of at least two application programs according to the third triggering operation; calling an Application Programming Interface (API) of the application program to acquire key information of the application program; the terminal judges whether key information of the application program is obtained within a second preset time period, if the key information of the application program is obtained, the key information of the application program is displayed on the flashback key, and the flashback key is displayed on the terminal; if the key information of the application program is not obtained, the terminal cancels the display of the flashback key, and the terminal releases the binding between the main program and the background service of the application program;
and within the preset duration of the display of the flashback key, if the triggering operation on the flashback key is not received, canceling the display of the flashback key, or autonomously canceling the display of the flashback key by a user, receiving the deleting operation of the flashback key triggered on the terminal by the terminal, and canceling the display of the flashback key.
2. The method of claim 1, wherein the step of determining the position of the substrate comprises,
the application program comprises video software, and the key information comprises video playing progress; or alternatively, the first and second heat exchangers may be,
The application program comprises teaching software, and the key information comprises a learning class time; or alternatively, the first and second heat exchangers may be,
the application program comprises software with a timing function, and the key information comprises starting countdown or reserving waiting time; or alternatively, the first and second heat exchangers may be,
the application program comprises software with journey monitoring, and the key information comprises departure time, arrival time or next station place; or alternatively, the first and second heat exchangers may be,
the application program comprises software with queuing functions, and the key information comprises queuing information.
3. The method of claim 1, wherein the terminal has a main program running therein;
the calling the application programming interface API of the application program to acquire the key information of the application program comprises the following steps:
the key information of the application program is obtained by calling the API through the main program;
the displaying the key information of the application program on the flashback key comprises the following steps:
and generating the flashback key carrying key information of the application program through the main program.
4. A method according to claim 3, wherein before the acquiring key information of the application program by calling the API through the main program comprises:
Establishing inter-process communication IPC between the main program and background service of the application program through binding service;
the step of obtaining the key information of the application program by calling the API through the main program comprises the following steps:
and calling the API through the main program based on the IPC to acquire the key information of the application program.
5. The method according to any one of claims 1 to 4, wherein after displaying a flashback key corresponding to the application program on the terminal, the method comprises:
receiving a second trigger operation on the flashback key;
and displaying a user interface of the application program on the terminal according to the second triggering operation.
6. The method according to any one of claims 1 to 4, comprising, after displaying a flashback key of the application on the terminal:
and within the preset time length displayed by the flashback key, if the triggering operation on the flashback key is not received, canceling the display of the flashback key.
7. The method according to any one of claims 1 to 4, wherein there are at least two running states of the application in the background running state; the at least two application programs comprise a first application program and a second application program;
The displaying of the flashback key on the terminal comprises:
and when the priority of the first application program is higher than that of the second application program, displaying the flashback key corresponding to the first application program on the terminal.
8. A background switching device for an application program, the device comprising:
the display module is used for binding a main program and background services of application programs running in the background; checking whether the application program running in the background belongs to a white list or not, wherein the white list comprises application programs capable of using a flashback key function; when the application program belongs to a white list, the binding between the main program and the background service of the application program is successful; otherwise, the binding between the main program and the background service of the application program fails; displaying a user interface of an application program on the terminal;
the receiving module is used for receiving a first triggering operation on the terminal;
the switching module is used for switching the running state of the application program from the foreground running state to the background running state according to the first triggering operation; the running states of at least two application programs are in the background running state;
The display module is used for displaying an aggregated flashback key on the terminal when the running states of at least two application programs are switched from the foreground running state to the background running state; receiving a third trigger operation on the aggregated flashback key; displaying a flashback key corresponding to each of at least two application programs according to the third triggering operation; receiving a selection operation on a target flashback key in at least two flashback keys; displaying a user interface of a target application program corresponding to the target flashback key on the terminal according to the selection operation; calling an Application Programming Interface (API) of the application program to acquire key information of the application program; the terminal judges whether key information of the application program is obtained within a second preset time period, if the key information of the application program is obtained, the key information of the application program is displayed on the flashback key, and the flashback key is displayed on the terminal; if the key information of the application program is not obtained, the terminal cancels the display of the flashback key, and the terminal releases the binding between the main program and the background service of the application program; and within the preset duration of the display of the flashback key, if the triggering operation on the flashback key is not received, canceling the display of the flashback key, or autonomously canceling the display of the flashback key by a user, receiving the deleting operation of the flashback key triggered on the terminal by the terminal, and canceling the display of the flashback key.
9. A computer device comprising a processor and a memory, wherein the memory stores at least one instruction, at least one program, a set of codes, or a set of instructions, the at least one instruction, the at least one program, the set of codes, or the set of instructions being loaded and executed by the processor to implement the background switching method of an application of any of claims 1 to 7.
10. A computer readable storage medium having stored therein at least one instruction, at least one program, code set, or instruction set, the at least one instruction, the at least one program, the code set, or instruction set being loaded and executed by a processor to implement the background switching method of an application of any of claims 1 to 7.
11. A computer program product, characterized in that it stores at least one instruction that is loaded and executed by a processor to implement the background switching method of an application according to any of claims 1 to 7.
CN201910809102.0A 2019-08-29 2019-08-29 Background switching method, device and equipment of application program and storage medium Active CN110515717B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201910809102.0A CN110515717B (en) 2019-08-29 2019-08-29 Background switching method, device and equipment of application program and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201910809102.0A CN110515717B (en) 2019-08-29 2019-08-29 Background switching method, device and equipment of application program and storage medium

Publications (2)

Publication Number Publication Date
CN110515717A CN110515717A (en) 2019-11-29
CN110515717B true CN110515717B (en) 2023-09-01

Family

ID=68629214

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201910809102.0A Active CN110515717B (en) 2019-08-29 2019-08-29 Background switching method, device and equipment of application program and storage medium

Country Status (1)

Country Link
CN (1) CN110515717B (en)

Families Citing this family (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111638828A (en) * 2020-05-29 2020-09-08 维沃移动通信(杭州)有限公司 Interface display method and device
CN111857919A (en) * 2020-07-16 2020-10-30 北京字节跳动网络技术有限公司 Video processing method, device, terminal equipment and medium
CN114265645B (en) * 2020-09-15 2024-05-17 Oppo(重庆)智能科技有限公司 Information display method, device, terminal and storage medium
CN112691369A (en) * 2020-12-28 2021-04-23 维沃移动通信有限公司 Display method, display device, electronic equipment and storage medium
CN112783391B (en) * 2021-01-28 2022-06-03 维沃移动通信有限公司 Application program running method and device, electronic equipment and storage medium
CN115237511A (en) * 2021-04-23 2022-10-25 Oppo广东移动通信有限公司 Information display method and device
CN113568732A (en) * 2021-09-24 2021-10-29 统信软件技术有限公司 Application program switching method, computing device and storage medium
CN115576621B (en) * 2022-03-31 2023-11-03 荣耀终端有限公司 Application program loading method and electronic device

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107436758A (en) * 2016-05-28 2017-12-05 腾讯科技(深圳)有限公司 The method for information display and mobile terminal of a kind of mobile terminal
CN108021302A (en) * 2017-11-30 2018-05-11 维沃移动通信有限公司 A kind of display methods of application icon, terminal and computer-readable recording medium
CN109165076A (en) * 2018-10-17 2019-01-08 Oppo广东移动通信有限公司 Display methods, device, terminal and the storage medium of game application

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107436758A (en) * 2016-05-28 2017-12-05 腾讯科技(深圳)有限公司 The method for information display and mobile terminal of a kind of mobile terminal
CN108021302A (en) * 2017-11-30 2018-05-11 维沃移动通信有限公司 A kind of display methods of application icon, terminal and computer-readable recording medium
CN109165076A (en) * 2018-10-17 2019-01-08 Oppo广东移动通信有限公司 Display methods, device, terminal and the storage medium of game application

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
陈志峰.苹果iOS操作***.《计算机信息技术应用教程》.2015, *

Also Published As

Publication number Publication date
CN110515717A (en) 2019-11-29

Similar Documents

Publication Publication Date Title
CN110515717B (en) Background switching method, device and equipment of application program and storage medium
US11644943B2 (en) Method for icon display, terminal, and storage medium
CN102369534B (en) Unlock screen
CN107766128B (en) Method and device for starting application
CN105940365B (en) A kind of notification information processing method, device and terminal
CN111857500B (en) Message display method and device, electronic equipment and storage medium
CN107783803B (en) System optimization method and device of intelligent terminal, storage medium and intelligent terminal
CN107656671A (en) Suspend small window control method and device, terminal installation and computer-readable recording medium
CN109308241B (en) Method and device for monitoring starting process of application program, terminal equipment and storage medium
CN101867487A (en) Call out the system and method that connects symbol management association centre with figure
CN112269508B (en) Display method and device and electronic equipment
CN107911553A (en) Incoming call reminding method, equipment and computer-readable recording medium and mobile terminal
CN112134788B (en) Event processing method, device, storage medium, mobile terminal and computer
CN111263175A (en) Interaction control method and device for live broadcast platform, storage medium and electronic equipment
CN113032112A (en) Resource scheduling method and device, electronic equipment and storage medium
CN109976634A (en) A kind of game APP screenshot method and equipment
CN111459586A (en) Remote assistance method, device, storage medium and terminal
CN107864270A (en) A kind of method, terminal and computer-readable recording medium for handling incoming call
CN104333644B (en) Mobile communication terminal and method thereof for updating state of message
CN109658934B (en) Method and device for controlling multimedia app through voice
CN105554090B (en) Guide processing method, system and game system
CN107608744B (en) Application process management method and device and mobile terminal
CN114257641A (en) Gesture-based call center agent state change control
CN111346386B (en) Message processing method and device
CN112929254A (en) Message processing method and device and electronic equipment

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant