Application state sensing method, electronic equipment and storage medium

By receiving the application status parameters of the second device in the first device, the problem of difficulty in application status perception in cross-device calls is solved, and the user experience and operation efficiency are improved.

CN119311190APending Publication Date: 2025-01-14HONOR DEVICE CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202310855584.X
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2023-07-12
Publication Date
2025-01-14

AI Technical Summary

Technical Problem

When calling applications across devices, the call initiating device cannot sense the application status in the called device in real time, resulting in delays in user operations and erroneous operations, affecting the user experience.

Method used

By displaying cross-device application call controls in the first device, sending a call request to the second device, and receiving status parameters of the target interface, displaying prompt data in the running interface of the first application based on this parameter, and real-time perception and display of the second The status of the application.

Benefits of technology

Real-time state perception and display of the first device for the second application is realized, helping users make quick operation decisions, and improving user experience and cross-device call efficiency.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119311190A_ABST
    Figure CN119311190A_ABST
Patent Text Reader

Abstract

The embodiment of the invention provides an application state sensing method, electronic equipment and a storage medium, in the method, first equipment displays a running interface of a first application, and the running interface comprises a cross-equipment application calling control; in response to a triggering operation of a user on the cross-device application calling control, the first device sends a calling request for a second application in the second device to the second device; the first device receives the state parameter of the target interface sent by the second device; the first device can display prompt data corresponding to the state parameters of the target interface in the running interface of the first application based on the state parameters of the target interface. Therefore, the state of the second application in the cross-device application calling process can be perceived. Afterwards, the first device displays the perceived application state to the user, so that the user can know the actual state of the second application in real time according to the prompt data, an operation decision for the first application can be quickly made, and the use experience of the user is improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of computer technology, and in particular to a method for sensing an application state, an electronic device, and a storage medium. Background Art

[0002] With the rapid development of computer technology, the types of electronic devices such as mobile phones, tablet computers or laptops are gradually increasing. Different types of electronic devices are suitable for different application scenarios. For example, small electronic devices such as mobile phones and watches are easy to carry. Laptops, desktops and other computers have larger screens, which are easy to operate and can achieve more functions. In order to meet people's growing needs, a large number of applications (hereinafter referred to as applications) are usually installed in electronic devices. In some application scenarios, if users use applications that exist in electronic devices themselves in electronic devices, they may not be able to meet their constantly upgraded and evolving user needs. For example, in shooting scenarios, large electronic devices such as tablet computers or laptops may not be able to capture the expected images when users use the camera applications of the electronic devices themselves due to their large size and poor cameras. Therefore, the technology of calling applications across devices has become a development trend in industries such as the Internet.

[0003] Cross-device application calling means that one electronic device acts as the calling initiator and the other electronic device acts as the called device. When the first application is running on the calling initiator device, the first device initiates a call to the second application in the called device. The second application can obtain the data required by the first application based on its own functions and send the data to the first application. For example, when the notepad application is running on the calling initiator device, the first device can initiate a call to the camera application in the second device to the second device, and the camera application can send the captured image to the notepad application.

[0004] However, when calling applications across devices, the second application may fail to be called, or the process of the second application may be cleared. However, at this time, the first application that calls the initiating device cannot obtain relevant information about the second application. This can easily lead to users misjudging the progress of calling applications across devices, delaying users' operational decisions on the first application, or users' erroneous operations on the first application. For example, when the second application fails to be called, the user may think that the second application is running normally, and will not re-call the second application of the second device, or call the second application of other electronic devices; when the second application starts too slowly, the user may also think that the second application failed to be called, and may re-call the second application of the second device. These situations may prolong the process of cross-device calling, resulting in the failure to meet user needs in a timely manner. Summary of the invention

[0005] The present application provides an application status perception method, electronic device and storage medium, the purpose of which is to enable the calling initiating device to perceive the application status of the second application in the called device in real time, so that the calling initiating device can prompt the user of the application status of the second application in real time to avoid affecting the user's operation decision on the first application, thereby improving the user's usage experience. .

[0006] In order to achieve the above objectives, this application adopts the following technical solutions:

[0007] In the first aspect, the present application provides a method for perceiving an application status, which is applied to a first device and specifically includes: the first device displays a running interface of a first application, wherein the running interface includes a cross-device application call control for triggering a function of a cross-device application call; in response to a user's triggering operation on the cross-device application call control, the first device can send a call request for a second application in the second device to a second device; the first device then receives the state parameters of a target interface sent by the second device; wherein the target interface is a display interface of the function of the second application requested by the call request; subsequently, based on the state parameters of the target interface, the first device can display prompt data corresponding to the state parameters of the target interface in the running interface of the first application to prompt the user.

[0008] It can be seen that the second device can start the target interface based on the call request, and the function displayed on the target interface is the function requested by the call request. The second device then feeds back the state parameters of the target interface to the first device. Therefore, when the first device receives the state parameters of the target interface, it can also perceive the state of the second application in the process of cross-device application calling. Afterwards, the first device will display the perceived application state to the user, so that the user can understand the actual state of the second application in real time according to the prompt data, and then quickly make operational decisions on the first application (such as continuing to wait or triggering the re-call function, etc.), which improves the user's experience.

[0009] In a possible implementation, the first device includes a first distributed application service, and the second device includes a second distributed application service and an activity management service; the first device sends a call request to a second application in the second device to the second device, specifically including: in response to a user triggering operation on a cross-device application call control, the first application of the first device first sends the call request to the first distributed application service of the first device; the first distributed application service of the first device then sends the call request to the second distributed application service of the second device, so that the second distributed application service can send the call request to the activity management service;

[0010] The above-mentioned first device receives the status parameters of the target interface sent by the second device, specifically including: the first distributed application service of the first device receives the status parameters of the target interface sent by the second distributed application service of the second device; wherein, the status parameters of the target interface are sent by the activity management service of the second device to the second distributed application service when the interface state of the target interface changes for the latest time; and then the first application receives the status parameters of the target interface sent by the first distributed application service.

[0011] Through the distributed application service, the function of calling applications across devices can be realized. Therefore, the first device and the second device can jointly realize the function of the first application calling the second application across devices based on the first distributed application service and the second distributed application service. At the same time, since the activity management service is used to perform operations such as starting, switching and closing applications, the activity management service can start the target interface of the camera application based on the call request, and can also identify whether the interface state of the target interface has changed in order to provide feedback. Therefore, the method of perceiving the application state can be smoothly executed through the first distributed application service, the second distributed application service and the activity management service of the second device.

[0012] In a possible implementation, the state parameters of the target interface include a function interface identifier associated with the target interface, the function interface identifier is generated by the second device based on a call request, and the function interface identifier and the target interface are associated by the second device when the target interface is started; the above-mentioned application state perception method may also include: in response to the user's closing operation on the second application in the running interface of the first application, the first device can generate a closing request for the target interface based on the function interface identifier; wherein the closing request includes the function interface identifier; the first device then sends a closing request to the second device, so that the second device can close the target interface associated with the function interface identifier based on the function interface identifier in the closing request.

[0013] When the user closes the second application in the first device, since the first device has received the functional interface identifier associated with the above-mentioned target interface, the first device can generate a closing request including the functional interface identifier, so that the second device can determine that the interface to be closed is the target interface based on the functional interface identifier, which can avoid closing other applications by mistake and improve the success rate of closing the camera application, thereby accurately responding to user needs and improving the user experience.

[0014] In a possible implementation, the above-mentioned sending of a close request to the second device so that the second device can close the target interface based on the functional interface identifier in the close request specifically includes: the first application of the first device sends the close request to the first distributed application service of the first device; the first distributed application service then sends the close request to the second distributed application service, so that the second distributed application service can determine the activity record name based on the functional interface identifier in the close request and the correspondence between the functional interface identifier and the activity record name of the target interface, and the second distributed application service then sends the activity record name to the activity management service so that the activity management service can close the target interface based on the activity record name; wherein, the activity record name is the name of the activity record corresponding to the target interface.

[0015] The target interface can be closed collaboratively through the capabilities of the first distributed application service, the second distributed application service, and the activity management service of the second device mentioned above. Since the activity record is generated when the activity management service starts the target interface, it means that the activity record name of the activity record exists in the activity management service, so the activity management service can accurately close the target interface based on the received activity record name.

[0016] In a possible implementation, based on the status parameters of the target interface, the first device displays prompt data corresponding to the status parameters of the target interface in the running interface of the first application, specifically including: in the running interface of the first application, the first device can display prompt data corresponding to the status parameters of the target interface in the form of text and / or graphics; at the same time, the first device can also prompt that the status parameters of the target interface are updated by voice and / or vibration.

[0017] Since the first device displays prompt data in text and / or graphic form in the running interface through the display screen, and issues prompts in voice through the speaker and in vibration through the motor, the user can see, hear or feel at least two prompts, which can improve the success rate of the prompts, thereby allowing the user to understand the actual application status of the camera application in real time.

[0018] In a possible implementation, the first application may be a notepad application, the second application may be a camera application, and the target interface may be a camera preview interface. The above method may further include: the first device receives an image captured by the camera application of the second device; after receiving the image, the first device may insert the image at the position where the cursor flashes in the running interface of the notepad application; wherein the image is captured by the second device in response to a trigger operation of a shooting control in the camera application; and the camera preview interface of the camera application is started by the second device in response to a call request.

[0019] In this way, in a scenario where the first device needs to call the second device to obtain an image, the notepad application of the first device can insert the image captured by the camera application to meet user needs.

[0020] In a possible implementation, the method may further include: the first device receives the state parameters of the associated interface sent by the second device; wherein the associated interface is a display interface of the associated functions of the function of the second application requested by the call request; accordingly, the above-mentioned display of prompt data corresponding to the state parameters of the target interface in the running interface of the first application based on the state parameters of the target interface specifically includes: based on the state parameters of the target interface and the state parameters of the associated interface, displaying prompt data corresponding to the state parameters of the target interface and the state parameters of the associated interface in the running interface of the first application. Thus, the first device can obtain the state of the associated interface on the basis of knowing the state of the target interface, so that the user can grasp the actual state of the second application in more detail, further improving the user's experience.

[0021] In the second aspect, the present application provides a method for perceiving application status, which is applied to a second device, and the method includes: the second device receives a call request from a first application of the first device to a second application of the second device, which is sent by a first device; in response to the call request, the second device sends the status parameters of the target interface to the first device, so that the first device can display prompt data corresponding to the status parameters of the target interface in the running interface of the first application based on the status parameters of the target interface to prompt the user; wherein the target interface is a display interface of the function of the second application requested by the call request.

[0022] It can be seen that after receiving the call request, the second device can feedback the display interface of the function requested in the call request, that is, the status parameters of the target interface to the first device, so that the first device can perceive the status of the second application in the process of calling the application across devices and display it to the user, so that the user can understand the actual status of the second application in real time according to the prompt data, and then can quickly make operational decisions on the first application (such as continuing to wait or triggering the re-calling function, etc.), thereby improving the user experience.

[0023] In a possible implementation, in response to the call request, the second device sends the status parameters of the target interface to the first device, specifically including: in response to the call request, the second device first generates a function interface identifier, which is used to indicate the function interface in the second application corresponding to the call request; the second device then associates the function interface identifier with the target interface; subsequently, the second device can send the status parameters of the target interface to the first device.

[0024] By associating the target interface and the functional interface identifier, the second device can send the status parameters of the target interface with the functional interface identifier to the first device, and can accurately send the status parameters of the target interface corresponding to the call request, avoiding the situation of sending the status parameters of other interfaces, so that the first device can display accurate prompt data in the running interface of the first application, so that the user can understand the actual status of the second application in real time, thereby improving the user experience.

[0025] In a possible implementation, the above-mentioned associating the function interface identifier with the target interface specifically includes: the second device first adds the function interface identifier to the activity record corresponding to the target interface; then the second device parses the activity record corresponding to the target interface to obtain the function interface identifier to associate the function interface identifier with the target interface. Since the second device needs to parse the corresponding activity record when starting the target interface, the function interface identifier is first added to the activity record, and the activity record can be parsed again during parsing, and then the function interface identifier can be associated with the target interface. So that in the subsequent steps, the target interface that needs to send status parameters can be determined based on the function interface identifier.

[0026] In a possible implementation, the method further includes: the second device receives a closing request for the target interface of the second application sent by the first device; wherein the closing request includes a functional interface identifier; and then the first device can close the target interface indicated by the functional interface identifier based on the functional interface identifier in the closing request. Since the second device can determine the target interface for its indication based on the functional interface identifier after receiving the closing request including the functional interface identifier, the target interface can be accurately closed, and the user's needs can be accurately responded to, thereby improving the user's experience.

[0027] In a possible implementation, the method further includes: the second device stores the correspondence between the function interface identifier and the activity record name of the target interface; accordingly, the second device closes the target interface based on the function interface identifier in the close request, specifically including: the second device can determine the corresponding activity record name based on the function interface identifier in the close request and the stored correspondence between the function interface identifier and the activity record name; then based on the activity record name, the second device can accurately close the second target interface. Since the correspondence between the function interface identifier and the activity record name of the target interface is stored in the second device, after receiving the close request including the function interface identifier, the activity record name used to indicate the target interface can be determined, thereby more accurately closing the target interface required to be closed by the close request, thereby improving the user experience.

[0028] In a third aspect, the present application provides an electronic device comprising a processor and a memory; the memory stores a computer program and transmits the computer program to the processor; the processor is used to execute the method of the first aspect or the second aspect mentioned above according to the computer program.

[0029] In a fourth aspect, the present application provides a computer-readable storage medium, in which a computer program is stored. When the computer program is executed by a processor, the method of the first aspect or the second aspect described above is implemented.

[0030] In a fifth aspect, the present application provides a computer program product, including a computer program, which implements the method of the first aspect or the second aspect when executed by a processor.

[0031] It can be understood that the beneficial effects that can be achieved by the electronic device, computer storage medium, and computer program product provided above can refer to the beneficial effects in the first aspect, the second aspect, and any possible design methods thereof, and will not be repeated here. BRIEF DESCRIPTION OF THE DRAWINGS

[0032] Figure 1 A schematic diagram of the composition of an electronic device provided in an embodiment of the present application;

[0033] Figure 2 A schematic diagram of the software structure of an electronic device provided in an embodiment of the present application;

[0034] Figure 3a An application scenario of an application state perception method provided in an embodiment of the present application;

[0035] Figure 3b Another application scenario of the method for perceiving application status provided in the embodiment of the present application;

[0036] Figure 4 A signaling interaction diagram of an application state perception method provided in an embodiment of the present application;

[0037] Figure 5 A schematic diagram of a process of a user calling a mobile phone camera application across devices provided in an embodiment of the present application;

[0038] Figure 6 A schematic diagram of different interface states of a camera preview interface of a camera application provided in an embodiment of the present application;

[0039] Figure 7a A schematic diagram of a notepad application displaying prompt data on a tablet computer provided in an embodiment of the present application;

[0040] Figure 7bA schematic diagram of another tablet computer notepad application displaying prompt data provided by an embodiment of the present application;

[0041] Figure 8 A signaling interaction diagram of another method for perceiving application status provided in an embodiment of the present application;

[0042] Fig. 9 A schematic diagram of a process of associating multiple functional interface identifiers with multiple functional interfaces one by one provided in an embodiment of the present application;

[0043] Fig.10 A schematic diagram of displaying prompt data for a notepad application of another tablet computer provided in an embodiment of the present application;

[0044] Fig.11 A signaling interaction diagram of a method for closing an application across devices provided in an embodiment of the present application;

[0045] Fig.12a A schematic diagram of a process of a user turning off a camera application of a mobile phone across devices provided in an embodiment of the present application;

[0046] Figure 12b A schematic diagram of another process of a user closing a mobile phone camera application across devices provided in an embodiment of the present application;

[0047] Fig.12c A schematic diagram of another process of a user turning off a mobile phone's camera application across devices provided in an embodiment of the present application. DETAILED DESCRIPTION

[0048] The terms "first", "second", "third", etc. in the specification, claims and drawings of this application are used to distinguish different objects rather than to limit a specific order.

[0049] In the embodiments of the present application, words such as "exemplary" or "for example" are used to indicate examples, illustrations or descriptions. Any embodiment or design described as "exemplary" or "for example" in the embodiments of the present application should not be interpreted as being more preferred or more advantageous than other embodiments or designs. Specifically, the use of words such as "exemplary" or "for example" is intended to present related concepts in a specific way.

[0050] In order to make the description of the following embodiments clear and concise, a brief introduction to the related technology is first given:

[0051] Activity: An application usually consists of multiple Activities, and an Activity represents an application interface in the application.

[0052] Activity Manager Service (AMS): AMS is An important component in the system, responsible for managing the application life cycle, task stack, process, etc. AMS can control the start, stop, switch and other operations of the application. When AMS starts the application interface of the application, it can be considered as starting an Activity.

[0053] Activity Record: It is used to record all the information of the corresponding Activity. When AMS starts an Activity, AMS will create an Activity Record for the Activity to record all the information of the Activity. An application interface can be started multiple times, so an Activity can correspond to multiple ActivityRecords to record the information after each start of the application interface. Generally speaking, an Activity Record corresponds to only one Activity.

[0054] Activity State: refers to the interface state of the application interface, which is stored in the Activity Record. Generally speaking, the application interface can have multiple different interface states.

[0055] The following is a comparative explanation of the technical advantages of an application status perception method provided by the present application in combination with related technologies. For ease of understanding, an example scenario is used for explanation. In this example scenario, the initiating device is a tablet computer, the first application is a notepad application, the called device is a mobile phone, and the second application is a camera application.

[0056] In the related art, the notepad application of the tablet computer supports inserting images, and the images can be obtained by shooting through the camera application of the mobile phone, so the notepad application needs to call the camera application of the mobile phone. If the camera application in the mobile phone completes shooting and obtains the image, the camera application of the mobile phone will send the image to the notepad application of the tablet computer, and then the image shot by the camera application of the mobile phone will be displayed on the notepad application of the tablet computer. In the above process of calling the application across devices, there may be situations where the cross-device application call is unsuccessful, such as the camera application of the mobile phone being occupied, the camera application fails to start, and the camera application may take too long to shoot (for example, due to the user adjusting the shooting angle of the mobile phone, or the user adjusting the shooting settings of the camera application, etc.). At present, the notepad application of the tablet computer can only display the image obtained by shooting when the camera application finishes shooting. When the camera application of the mobile phone encounters the above other situations, on the one hand, the notepad application of the tablet computer cannot obtain relevant messages, and on the other hand, it cannot display these situations to the user, resulting in the user being unable to control the actual status of the called camera application in real time. This may delay the user's decision to operate the notepad application, or easily lead to the user's misoperation of the notepad application, making it inconvenient for the user to subsequently interact with the notepad application of the tablet computer. In other words, when the notepad application does not display an image, the user may not be able to determine whether to continue waiting for the camera application of the mobile phone to capture an image, or to perform an interactive operation in the notepad application to call a second application of another electronic device. This can easily prolong the cross-device call process, which in turn leads to the inability to meet user needs in a timely manner, reducing the user's experience.

[0057] In order to solve the above problems, the embodiment of the present application provides a method for perceiving application status, an electronic device and a storage medium. In the method, the first device displays the running interface of the first application, and the running interface includes a cross-device application call control for triggering the function of the cross-device application call; in response to the user's triggering operation of the cross-device application call control, the first device can send a call request for the second application in the second device to the second device; the first device then receives the state parameter of the target interface sent by the second device; wherein the target interface is a display interface of the function of the second application requested by the call request; then, based on the state parameter of the target interface, the first device can display the prompt data corresponding to the state parameter of the target interface in the running interface of the first application to prompt the user. It can be seen that when the first device receives the state parameter of the target interface, the state of the second application in the process of cross-device application call can be perceived. Afterwards, the first device displays the perceived application state to the user, so that the user can understand the actual state of the second application in real time according to the prompt data, and then can quickly make an operation decision on the first application (such as continuing to wait or triggering the re-call function, etc.), which improves the user's experience.

[0058] In order to make the technical solution of the present application clearer and easier to understand, the electronic devices such as the tablet computer and mobile phone mentioned above and their software structure block diagram are first specifically introduced below.

[0059] In the embodiments of the present application, the first device (the electronic device of the caller) and the second device (the electronic device of the callee) are both electronic devices, and the present application does not limit the type of electronic devices. For example, the electronic device may be a mobile phone powered by multiple batteries, a tablet computer, a wearable electronic device (such as a smart watch), a laptop computer, an augmented reality (AR) device, a virtual reality (VR) device, and a vehicle-mounted device.

[0060] See also Figure 1 , which is a schematic diagram of the structure of an electronic device provided in an embodiment of the present application.

[0061] The electronic device may include a processor 110, an external memory interface 120, an internal memory 121, a universal serial bus (USB) interface 130, a charging management module 140, a power management module 141, a battery 142, an antenna 1, an antenna 2, a mobile communication module 150, a wireless communication module 160, an audio module 170, a speaker 170A, a receiver 170B, a microphone 170C, an earphone interface 170D, a sensor module 180, a button 190, a motor 191, an indicator 192, a camera 193, a display screen 194, and a subscriber identification module (SIM) card interface 195, etc.

[0062] It is to be understood that the structure illustrated in the embodiment of the present invention does not constitute a specific limitation on the electronic device. In other embodiments of the present application, the electronic device may include more or fewer components than shown in the figure, or combine certain components, or split certain components, or arrange the components differently. The components shown in the figure may be implemented in hardware, software, or a combination of software and hardware.

[0063] The processor 110 may include one or more processing units, for example, the processor 110 may include an application processor (AP), a modem processor, a graphics processor (GPU), an image signal processor (ISP), a controller, a video codec, a digital signal processor (DSP), a baseband processor, and / or a neural-network processing unit (NPU), etc. Different processing units may be independent devices or integrated into one or more processors.

[0064] The controller can generate operation control signals according to the instruction operation code and timing signal to complete the control of instruction fetching and execution.

[0065] The charging management module 140 is used to receive charging input from a charger. The charger can be a wireless charger or a wired charger. While the charging management module 140 charges the battery 142, it can also power the electronic device through the power management module 141.

[0066] The power management module 141 is used to connect the battery 142, the charging management module 140 and the processor 110. The power management module 141 receives input from the battery 142 and / or the charging management module 140, and supplies power to the processor 110, the internal memory 121, the display screen 194, the camera 193, and the wireless communication module 160. The power management module 141 can also be used to monitor parameters such as battery capacity, battery cycle number, and battery health status (leakage, impedance).

[0067] The wireless communication function of the electronic device can be implemented through antenna 1, antenna 2, mobile communication module 150, wireless communication module 160, modem processor and baseband processor.

[0068] The electronic device implements the display function through a GPU, a display screen 194, and an application processor. The GPU is a microprocessor for image processing, which connects the display screen 194 and the application processor. The GPU is used to perform mathematical and geometric calculations for graphics rendering. The processor 110 may include one or more GPUs that execute program instructions to generate or change display information.

[0069] Display screen 194 is used to display images, videos, etc.

[0070] In some embodiments, when the electronic device is a first device, the display screen 194 can be used to display application identifiers of different applications, multiple application interfaces of each application, such as the running interface of the first application; it can also be used to display controls that trigger different functions, such as a call control that triggers a cross-device call to a second application in a second device; it can also be used to display images captured by a camera application, text edited by a user in a text editing application; it can also be used to display different prompt data including text prompt data, image prompt data, etc., to prompt the user.

[0071] In some embodiments, when the electronic device is a second device, the display screen 194 can be used to display the application interface of the second application, such as the camera preview interface, image beautification interface, and shooting settings interface of the camera application; it can also be used to display images captured by photography beautification applications, videos played by video playback applications, etc.

[0072] The electronic device can realize the shooting function through an image signal processor (ISP), a camera 193, a video codec, a GPU, a display screen 194 and an application processor.

[0073] Video codecs are used to compress or decompress digital videos. Electronic devices can support one or more video codecs. In this way, electronic devices can play or record videos in multiple coding formats, such as Moving Picture Experts Group (MPEG) 1, MPEG2, MPEG3, MPEG4, etc.

[0074] In some embodiments, if the second application is a camera application, the video encoder in the second device can encode the video captured by the camera application to reduce the size of the video, so as to facilitate the first device to transmit the device to the second device. After the first device receives the video sent by the second device, the video decoder of the first device can decode the video so that the first application can play the video in the running interface.

[0075] The external memory interface 120 can be used to connect an external memory card, such as a Micro SD card, to expand the storage capacity of the electronic device. The external memory card communicates with the processor 110 through the external memory interface 120 to implement a data storage function. For example, files such as music and videos can be stored in the external memory card.

[0076] The internal memory 121 can be used to store computer executable program codes, which include instructions. The internal memory 121 may include a program storage area and a data storage area. Among them, the program storage area may store an operating system, an application required for at least one function (such as a sound playback function, an image playback function, etc.), etc. The data storage area may store data created during the use of the electronic device (such as audio data, a phone book, etc.), etc. In addition, the internal memory 121 may include a high-speed random access memory, and may also include a non-volatile memory, such as at least one disk storage device, a flash memory device, a universal flash storage (UFS), etc. The processor 110 executes various functional applications and data processing of the electronic device by running instructions stored in the internal memory 121 and / or instructions stored in a memory provided in the processor.

[0077] The electronic device can implement audio functions such as music playing and recording through the audio module 170, the speaker 170A, the receiver 170B, the microphone 170C, the headphone jack 170D, and the application processor.

[0078] The audio module 170 is used to convert digital audio information into analog audio signal output, and is also used to convert analog audio input into digital audio signals. The audio module 170 can also be used to encode and decode audio signals. In some embodiments, the audio module 170 can be arranged in the processor 110, or some functional modules of the audio module 170 can be arranged in the processor 110.

[0079] The speaker 170A, also called a "speaker", is used to convert an audio electrical signal into a sound signal. The electronic device can listen to music or listen to a hands-free call through the speaker 170A.

[0080] The key 190 includes a power key, a volume key, etc. The key 190 can be a mechanical key or a touch key. The electronic device can receive key input and generate key signal input related to user settings and function control of the electronic device.

[0081] Motor 191 can generate vibration prompts. Motor 191 can be used for incoming call vibration prompts, and can also be used for touch vibration feedback. For example, touch operations acting on different applications (such as taking pictures, audio playback, etc.) can correspond to different vibration feedback effects. For touch operations acting on different areas of the display screen 194, motor 191 can also correspond to different vibration feedback effects. Different application scenarios (for example: time reminders, receiving messages, alarm clocks, games, etc.) can also correspond to different vibration feedback effects. The touch vibration feedback effect can also support customization.

[0082] In some embodiments, when the first device receives the status parameters of the function interface of the second application sent by the second device, the display screen 194 of the first device can display text prompt data corresponding to the status parameters of the function interface, and at the same time, the motor 191 can also generate vibration prompt data.

[0083] Indicator 192 may be an indicator light, which may be used to indicate charging status, power changes, messages, missed calls, notifications, etc.

[0084] The SIM card interface 195 is used to connect a SIM card. The SIM card can be connected to and separated from the electronic device by inserting it into the SIM card interface 195 or pulling it out from the SIM card interface 195. The electronic device can support 1 or N SIM card interfaces, where N is a positive integer greater than 1. The SIM card interface 195 can support Nano SIM cards, Micro SIM cards, SIM cards, and the like. Multiple cards can be inserted into the same SIM card interface 195 at the same time. The types of the multiple cards can be the same or different. The SIM card interface 195 can also be compatible with different types of SIM cards. The SIM card interface 195 can also be compatible with external memory cards. The electronic device interacts with the network through the SIM card to implement functions such as calls and data communications. In some embodiments, the electronic device uses an eSIM, i.e., an embedded SIM card. The eSIM card can be embedded in an electronic device and cannot be separated from the electronic device.

[0085] In addition, on top of the above components, there is an intelligent operating system running, for example, System. Applications can be installed and run on the intelligent operating system.

[0086] The operating system of the electronic device may adopt a layered architecture, an event-driven architecture, a micro-kernel architecture, a micro-service architecture, or a cloud architecture. The software architecture of the system is used as an example to illustrate the software structure of the electronic device. The electronic device includes the first device and the second device in the embodiment of the present application.

[0087] Figure 2 The software structure block diagram of the electronic device of the embodiment of the present application. The layered architecture divides the software into several layers, each layer has a clear role and division of labor. The layers communicate with each other through software interfaces. In some embodiments, the Android system is divided into four layers, from top to bottom, namely, the application layer, the application framework layer, the Android runtime (Android runtime) and the system library, and the kernel layer.

[0088] The application layer can include a series of application packages. Figure 2As shown, the application package may include applications such as camera, notepad, gallery, call, map, navigation, Bluetooth, WLAN, music, video, calendar, etc.

[0089] In some embodiments, the application layer of the first device includes the first application, and the application layer of the second device includes the second application. Both the first application and the second application include a distributed application collaboration service, through which the first application of the first device can call the second application of the second device across devices. Among them, the first application is an application that can realize the cross-device calling function, and the second application is an application that can realize the remote cross-device calling and data distribution function. Among them, the second application and other applications can be remotely called and started across devices, so this type of application can also be called a remote application.

[0090] The application framework layer provides application programming interface (API) and programming framework for the applications in the application layer. The application framework layer includes some predefined functions. Figure 2 As shown, the application framework layer may include distributed application framework services, activity management services, window managers, view systems, content providers, phone managers, resource managers, notification managers, and the like.

[0091] The distributed application framework service specifically includes distributed application service, package management service (PackageManagerService, PMS), distributed package management service (DistributedPackageManagerService, DPMS) and application information database.

[0092] Among them, the distributed application service is used to provide cross-device application calling services.

[0093] In some embodiments, the first distributed application service of the first device provides the first device with the ability to discover the existence of a remote application in the second device, and the first device can perform a cross-device remote application call service on the second device. The second distributed application service of the second device provides the second device with the ability to have the remote application discovered and remotely called by other electronic devices, for example, the second application of the second device can be called by the first application of the first device across devices.

[0094] It should be noted that the first distributed application service of the first device also provides the ability for the remote application to be discovered and remotely called by other electronic devices, and the remote application of the first device can be called across devices by other electronic devices including the second device. The second distributed application service of the second device provides it with the ability to discover the existence of remote applications in other electronic devices and call the remote applications across devices. In other words, two electronic devices that both have distributed application services can make cross-device application calls to each other, and this application does not limit this.

[0095] Activity Manager Service (AMS): Yes An important component in the system, responsible for managing the life cycle, task stack, process, etc. of the application. Used to control the start, stop, switch, etc. of the application. In some embodiments, the activity management service of the second device can control the start, stop, switch, etc. of the second application.

[0096] The window manager is used to manage window programs. The window manager can obtain the display screen size, determine whether there is a status bar, lock the screen, capture the screen, etc.

[0097] The view system includes visual controls, such as controls for displaying text, controls for displaying images, etc. The view system can be used to build applications. A display interface can be composed of one or more views. For example, a display interface including a text notification icon can include a view for displaying text and a view for displaying images.

[0098] Content providers are used to store and retrieve data and make it accessible to applications. The data may include videos, images, audio, calls made and received, browsing history and bookmarks, phone books, etc.

[0099] The phone manager is used to provide communication functions for electronic devices, such as the management of call status (including answering, hanging up, etc.).

[0100] The resource manager provides various resources for applications, such as localized strings, icons, images, layout files, video files, and so on.

[0101] The notification manager enables applications to display notification information in the status bar. It can be used to convey notification-type messages and can disappear automatically after a short stay without user interaction. For example, the notification manager is used to notify download completion, message reminders, etc. The notification manager can also be a notification that appears in the system top status bar in the form of a chart or scroll bar text, such as notifications of applications running in the background, or a notification that appears on the screen in the form of a dialog window. For example, a text message is displayed in the status bar, a prompt sound is emitted, an electronic device vibrates, an indicator light flashes, etc.

[0102] Android Runtime includes core libraries and virtual machines. Android runtime is responsible for Scheduling and management of the system.

[0103] The core library consists of two parts: one part is the function that needs to be called by the Java language, and the other part is the Android core library.

[0104] The application layer and the application framework layer run in a virtual machine. The virtual machine executes the Java files of the application layer and the application framework layer as binary files. The virtual machine is used to perform functions such as object life cycle management, stack management, thread management, security and exception management, and garbage collection.

[0105] The system library may include multiple functional modules, such as surface manager, media library, 3D graphics processing library (such as OpenGL ES), 2D graphics engine (such as SGL), etc.

[0106] The surface manager is used to manage the display subsystem and provide the fusion of 2D and 3D layers for multiple applications.

[0107] The media library supports playback and recording of a variety of commonly used audio and video formats, as well as static image files, etc. The media library can support a variety of audio and video encoding formats, such as: MPEG4, H.264, MP3, AAC, AMR, JPG, PNG, etc.

[0108] The 3D graphics processing library is used to implement 3D graphics drawing, image rendering, compositing, and layer processing.

[0109] A 2D graphics engine is a drawing engine for 2D drawings.

[0110] The kernel layer is the layer between hardware and software. The kernel layer contains at least display driver, camera driver, audio driver, and sensor driver.

[0111] In order to enable those skilled in the art to more clearly understand the technical solution of the present application, the application scenario of the technical solution of the present application is first described below.

[0112] The method for perceiving application status provided in the embodiment of the present application can be implemented in a scenario where an application in a first device calls an application in a second device.

[0113] For example, in a scenario where a first application needs to call a second application to obtain pictures or videos, the second application can implement a shooting function that is called by the first application across devices, and can send the pictures or videos it has taken to the first application across devices.

[0114] Specifically, take the scenario where the first application needs to call the second application to obtain an image as an example. A video is usually composed of multiple video frames, each of which is a picture in the video, that is, each video frame can be used as a picture. Therefore, for ease of explanation, in the following embodiments, pictures and videos are referred to as images.

[0115] In some embodiments, the first application may be an application with functions such as inserting images, editing images, sending images, scanning images, etc. During the operation of the first application, the first application may obtain images and insert, edit, send, scan, etc. the images. The second application may be an application with functions such as taking images. During the operation of the second application, the second application may take photos, record audio and video, etc. Exemplarily, the first application may be a document editing application such as a notebook, memo, WPS, office, or a shopping, banking, video editing, image processing, social, etc. application. The second application may be a photography and beauty application such as a system camera and a beauty camera, or a video playback application. This application does not limit this.

[0116] As another example, in a scenario where the first application needs to call the second application to obtain contact information, the second application may be an address book application, which may implement a cross-device query function for contact information by the first application, and may send the queried contact information to the first application across devices.

[0117] For example, in a scenario where the first application needs to call the second application to obtain audio, the second application can be a recorder application, which can implement the audio recording function called by the first application across devices, and can send the recorded audio to the first application across devices. This application does not limit this.

[0118] Figure 3a An application scenario of an application state perception method provided in an embodiment of the present application, Figure 3b Another application scenario of the perception method of application status provided in the embodiment of the present application. Figure 3a and Figure 3b As shown, the following takes the first device as a tablet computer 310, the first application as a notepad application, the second device as a mobile phone 320, and the second application as a camera application as an example to exemplarily illustrate the application scenario of the method for perceiving the application state provided in the embodiment of the present application:

[0119] like Figure 3a and Figure 3bAs shown, the scenario includes: a tablet computer 310 and a mobile phone 320. The tablet computer 310 and the mobile phone 320 are already in communication connection, for example, they are logged into the same user account, and are interconnected through smart interconnection services, and can implement functions such as data transmission and calling remote applications. When the user uses the notepad application of the tablet computer 310 to record today's exercise, he hopes to insert an image of his personal exercise location into the file edited by the notepad, but the tablet computer is large in size and has limited camera capabilities, and it is not possible to easily capture the ideal image. At this time, the user can trigger the cross-device application calling function of the notepad application of the tablet computer 310 to call the camera application of the mobile phone 320 which has a smaller size and better camera capabilities, so as to capture the image expected by the user. Combined with Figure 3a As shown, when the user triggers the function of calling the camera application of the mobile phone 320 in the notepad application of the tablet computer 310, the mobile phone 320 can try to start the camera application. At the same time, the tablet computer 310 can sense that the interface state of the camera preview interface of the camera application is starting, and the tablet computer 310 can pop up a text prompt box 311 for displaying a text prompt "The camera application is starting".

[0120] It should be noted that only Figure 3a The scenario described above in which the mobile phone 320 is starting a camera application is used for illustration. In actual scenarios, a buffer icon may be displayed in the interface of the mobile phone 320 to prompt the user that the mobile phone 320 is starting an addition application. Alternatively, a pop-up window of a camera application may be displayed in the interface of the mobile phone 320. This is not specifically limited in the present application.

[0121] In addition, it is understandable that when the mobile phone 320 is in the process of launching the camera application, the user may happen to have the need to launch other applications such as the chat application. In some embodiments, if the mobile phone 320 is launching the camera application and has not yet successfully launched, the user triggers the chat application of the mobile phone 320, and the mobile phone 320 can first respond to the user's triggering operation and display the running interface of the chat application, but then continue to execute the step of launching the camera application. That is, if Figure 3b The shooting preview interface shown covers the running interface of the chat application. In some embodiments, the mobile phone 320 may no longer respond to the user's triggering operation during the process of the mobile phone 320 starting the camera application. That is, when the user operates the icon of the chat application at this time, the mobile phone 320 will not start the chat application. Figure 3b The mobile phone 320 will continue to respond to the user's triggering operation only when the camera preview interface shown is displayed. This application does not limit this.

[0122] Combination Figure 3bAs shown, when the mobile phone 320 successfully starts the camera application and enters the camera preview interface of the camera application, the tablet computer 310 can sense that the interface state of the camera preview interface of the camera application is in the running state, that is, the camera application is shooting, and the tablet computer 310 can pop up a text prompt box 312 to display the text prompt "The camera application is shooting". The mobile phone 320 feeds back the state of the camera application to the tablet computer 310 in real time, so that the notepad application can perceive the operation of the camera application across devices, that is, it can perceive the entire shooting process such as the camera application startup and entering the camera preview interface. So that the notepad application can give different prompts to the user, so that the user can understand the actual state of the camera application it calls in real time, thereby improving the user's experience.

[0123] Embodiment 1:

[0124] The following still takes the example that the first device is a tablet computer 310, the second device is a mobile phone 320, the first application is a notepad application, and the second application is a camera application to explain in detail the method for perceiving the application status provided in the embodiment of the present application.

[0125] It can be understood that the camera preview interface is a function interface in the camera application, and the function displayed in the camera preview interface is shooting, which is the same as the function requested in the image acquisition scene. That is, the camera preview interface is the display interface of the function of the camera application requested by the notepad application to call the camera application. Therefore, the camera preview interface in the following embodiments is the target interface.

[0126] See also Figure 4 , which is a signaling interaction diagram of a method for perceiving an application state provided in an embodiment of the present application. The method for perceiving an application state may specifically include the following steps:

[0127] S401: The tablet computer 310 establishes a communication connection with the mobile phone 320.

[0128] After the tablet computer 310 establishes a communication connection with the mobile phone 320 , the mobile phone 320 can synchronize its function of supporting remote applications to the tablet computer 310 , so that the tablet computer 310 can find that the mobile phone 320 has the function of supporting remote applications, so as to implement the calling of cross-device applications.

[0129] In some embodiments, the tablet computer 310 can establish a near field communication connection with the mobile phone 320. Near field communication connection methods include: Bluetooth, Wireless Fidelity (Wireless Fidelity, WIFI), Near Field Communication (Near Field Communication, NFC), etc. Exemplarily, the tablet computer 310 can log in to the same user account as the mobile phone 320 and interconnect through the smart interconnection service (MagicLink). In some embodiments, the tablet computer 310 can establish an Internet connection with the mobile phone 320. Internet connection refers to the communication and interaction between the tablet computer 310 and the mobile phone 320 and the Internet through the network. It should be noted that the embodiment of the present application can use at least one of the above-mentioned communication connection methods to establish a communication connection, and the present application does not limit this.

[0130] S402 : the notepad application of the tablet computer 310 receives a user's call operation on the camera application of the mobile phone 320 .

[0131] It is understandable that there may be multiple electronic devices that support cross-device camera application calls, and the tablet computer 310 can display multiple electronic devices that support remote cameras, and the display content of each electronic device is used to trigger the call of the camera application of the corresponding electronic device to capture an image. Exemplarily, the display content may include at least one of the device graphics, device model, device type, or device name of each electronic device that supports the remote camera to represent the corresponding electronic device, and this application does not limit this.

[0132] In some embodiments, the running interface of the notepad application may include an image acquisition control, and the user may trigger the image acquisition control; in response to the user's image acquisition operation, the running interface of the notepad application may display at least one electronic device that supports the camera application call, including the mobile phone 320; then, the tablet computer 310 may receive the user's selection trigger operation on the camera application of the mobile phone 320 (i.e., the trigger operation on the cross-device application call control). Thus, the notepad application of the tablet computer 310 may receive the user's call operation on the camera application of the mobile phone 320.

[0133] Exemplarily, the triggering operation of the image acquisition control and the selection triggering operation of the camera application in the mobile phone 320 may be a click, a long press, or a slide, etc., and the present application does not limit the operation form.

[0134] For ease of understanding, the following Figure 5 The process of a user calling the camera application of the mobile phone 320 is described in detail.

[0135] like Figure 5As shown, the tablet computer 310 displays the running interface of the notepad application, on which a plurality of controls with different functions are displayed. Among them, the control 501 is used to implement the function of inserting an image. The user can click on the control 501, and in response to the user's click operation, the tablet computer 310 can pop up an interface 502 for displaying a plurality of options for obtaining images. The interface 502 includes "local gallery", "shooting" (i.e., representing shooting using the tablet computer 310 itself), "calling the camera application of the mobile phone 320" and "calling the camera application of tablet A". The user can select the option to trigger "calling the camera application of the mobile phone 320" from the plurality of options displayed on the interface 502, so that the notepad application of the tablet computer 310 can call the camera application of the mobile phone 320 across devices.

[0136] In the above introduction, Figure 5 The process shown in the figure of the user calling the camera application of the mobile phone 320 across devices is used as an example for explanation. The present application does not limit the calling operation of the camera application of the mobile phone 320.

[0137] S403 : In response to the user's operation of calling the camera application of the mobile phone 320 , the notepad application of the tablet computer 310 sends a call request for the camera application to the first distributed application service of the tablet computer 310 .

[0138] In response to the user's calling operation, the notepad application of the tablet computer 310 can generate a calling request for the camera application in the mobile phone 320, and send the calling request for the camera application to the first distributed application service. The first distributed application service of the tablet computer 310 provides the tablet computer 310 with the ability to discover electronic devices with remote applications and call remote applications.

[0139] In some embodiments, the request to call the camera application may be in the form of a request from the tablet computer 310. The standard string in the system is A system-preset string used to indicate a call request to the camera application.

[0140] For example, the standard string for indicating a call request to the camera application may be "android.media.action.IMAGE_CAPTURE". This application does not limit this. Specifically, in response to the user's call operation to the camera application, the notepad application of the tablet computer 310 may send the "android.media.action.IMAGE_CAPTURE" string to the first distributed application service of the tablet computer 310, so that the first distributed application service of the tablet computer 310 performs the operation of calling the camera application across devices.

[0141] In some embodiments, the call request for the camera application may be a custom string pre-set by a developer or other technical personnel to indicate the call request for the camera application. This application does not limit this.

[0142] S404: The first distributed application service of the tablet computer 310 sends a call request for a camera application to the second distributed application service of the mobile phone 320 .

[0143] In the embodiment of the present application, the tablet computer 310 calls the camera application of the mobile phone 320 across devices, so it needs to be implemented by the first distributed application service of the tablet computer 310 and the second distributed application service of the mobile phone 320.

[0144] The second distributed application service of the mobile phone 320 is used to provide the mobile phone 320 with the ability to remotely call applications across devices, that is, the ability of remote applications to support remote applications, and the ability of the mobile phone 320 to synchronize its remote applications with the tablet computer 310.

[0145] S405: In response to the call request for the camera application, the second distributed application service of the mobile phone 320 generates a function interface identifier.

[0146] In some embodiments, the function interface identifier may be a group of random characters, and the present application does not limit the content of the random characters and the number of random characters.

[0147] Exemplarily, the second distributed application service of mobile phone 320 can randomly generate a set of numbers as the function interface identifier, for example, the function interface identifier can be "354654651797". The second distributed application service of mobile phone 320 can also randomly generate a set of letters as the function interface identifier, for example, the function interface identifier can be "jkhgouiah". The second distributed application service of mobile phone 320 can also randomly generate a set of randomly combined letters and numbers as the function interface identifier, for example, the function interface identifier can be "74shfi7vwe". This application is not limited to this.

[0148] In addition, in order to avoid duplication of the function interface identifier with other identifiers, which may cause erroneous operation of the tablet computer 310 and the mobile phone 320, the mobile phone 320 can generate a unique function interface identifier, that is, the function interface identifier is different from other identifiers, and there is no set of random characters that is the same as the function interface identifier in the mobile phone 320 and the tablet computer 310.

[0149] It should be noted that the present application does not limit the number of function interface identifiers generated by the second distributed application service of the mobile phone 320. In some embodiments, in response to a call request to a camera application, the second distributed application service of the mobile phone 320 may generate a function interface identifier. In some embodiments, in response to a call request to a camera application, the second distributed application service of the mobile phone 320 may generate multiple function interface identifiers. For ease of understanding, in the embodiments below, a specific description is given by taking the second distributed application service of the mobile phone 320 generating a function interface identifier in response to a call request to a camera application as an example.

[0150] S406: The second distributed application service of the mobile phone 320 sends a call request for the camera application and a function interface identifier to the activity management service of the mobile phone 320.

[0151] Among them, the activity management service (Activity Manager Service) AMS of the mobile phone 320 can control the start, stop, switch and other operations of multiple applications including the camera application in the mobile phone 320.

[0152] S407: The activity management service of the mobile phone 320 starts the shooting interface of the camera application, and associates the function interface identifier with the camera preview interface of the camera application.

[0153] It is understandable that the camera application includes multiple application interfaces, each of which displays different functions, that is, each application interface can implement different functions.

[0154] For example, the camera preview interface of the camera application displays the shooting function, the image beautification interface of the camera application displays the function of beautifying the image captured by the camera preview interface, or beautifying existing images in the gallery, and the shooting settings interface of the camera application displays functions such as adjusting shooting parameters.

[0155] In some embodiments, the second distributed application service of the mobile phone 320 only generates a function interface identifier, and the camera preview interface is the target interface of the camera application, that is, the display interface of the function of the camera application requested in the call request. Therefore, the camera preview interface of the camera application is associated with the function interface identifier so as to feedback the state parameters of the camera preview interface in subsequent steps. This application does not limit this.

[0156] For ease of understanding, in the following embodiments, the activity management service of the mobile phone 320 associates the function interface identifier with the camera preview interface of the camera application as an example for specific description. In some embodiments, when the camera preview interface of the camera application is started, the activity management service of the mobile phone 320 associates the camera preview interface with the function interface identifier. When other application interfaces are started, the association step is not performed.

[0157] Next, the process of associating the function interface identifier with the camera preview interface of the camera application by the activity management service of the mobile phone 320 is described in detail.

[0158] In actual applications, when the activity management service starts the application interface Activity, it will create an Activity Record corresponding to the Activity, and then the activity management service will parse the Activity Record to start the Activity. Among them, the Activity Record includes multiple sets of key-value pairs (Key, Value) (keywords), such as (the process where the Activity is located, the process name), (the interface state of the Activity, the interface state) and (the application package of the Activity, the application package name), etc.

[0159] In some embodiments, when the activity management service of the mobile phone 320 starts the camera preview interface of the camera application, the interface identification item is used as the keyword Key, the generated function interface identification item is used as the value Value corresponding to the interface identification item, and (interface identification item, function interface identification) is added to the Activity Record corresponding to the camera preview interface. When the activity management service of the mobile phone 320 starts the camera preview interface of the camera application, the (interface identification item, function interface identification) contained in the Activity Record can be parsed, thereby realizing the association between the function interface identification and the camera preview interface of the camera application.

[0160] Thereafter, if the interface state of an application interface changes, the activity management service of the mobile phone 320 can determine whether the changed application interface is a camera preview interface according to whether the application interface has an associated functional interface identifier, that is, whether the Activity Record corresponding to the application interface has a functional interface identifier. After determining that it is a camera preview interface, the state parameters of the camera preview interface can be sent to the second distributed application service of the mobile phone 320.

[0161] In some embodiments, the interface identification item can be a custom string. For example, the interface identification item can be "KEY_DISTRIBUTED_START_ACTIVITY_SESSION", and the function interface identification item can be "activitysession". At this time, if it is necessary to realize the association between the function interface identification and the camera preview interface of the camera application, the activity management service of the mobile phone 320 can add (KEY_DISTRIBUTED_START_ACTIVITY_SESSION, activity session) as a pair of key-value pairs (Key, Value) to the Activity Record corresponding to the camera preview interface. When the camera preview interface is started and the Activity Record needs to be parsed, the (KEY_DISTRIBUTED_START_ACTIVITY_SESSION, activitysession) key-value pair contained in the Activity Record is parsed. This application does not limit this.

[0162] S408 : The activity management service of the mobile phone 320 sends the state parameters of the camera preview interface of the camera application to the second distributed application service of the mobile phone 320 .

[0163] The states of the application interface usually include the start state, the running state, the pause state, the stop state and the destruction state. The interface states of different application interfaces correspond to different state parameters one by one. After receiving the state parameters, the interface state corresponding to the state parameters can be known according to the corresponding relationship between the interface state and the state parameters.

[0164] In some embodiments, the startup state may correspond to state parameter 1, and the running state may correspond to state parameter 2. This application does not limit this.

[0165] In some embodiments, the activity management service may send the state parameters of the camera preview interface after the latest change to the second distributed application service. Exemplarily, if the state parameters of the camera preview interface sent by the activity management service to the second distributed application service correspond to the startup state, and then the state of the camera preview interface changes to the running state, the state parameters of the camera preview interface sent by the activity management service to the second distributed application service correspond to the running state. That is, the activity management service may send the state parameters of the camera preview interface to the second distributed application service in real time.

[0166] For ease of understanding, the following Figure 6 The different interface states of the camera preview interface of the camera application are specifically described.

[0167] like Figure 6As shown, interface 610 is a camera preview interface of a camera application in a startup state, at which time the activity management service of the mobile phone 320 is starting the application interface of the camera application, and the main interface of the mobile phone 320 is displayed. If the interface state of the camera preview interface is in a startup state, the activity management service of the mobile phone 320 sends the state parameter of the camera preview interface of the camera application to the second distributed application service of the mobile phone 320, corresponding to the startup state.

[0168] like Figure 6 As shown, interface 620 is a camera preview interface of a camera application in a running state. At this time, the activity management service of the mobile phone 320 has successfully started the camera preview interface of the camera application, and the camera preview interface of the camera application is fully displayed in interface 620. If the interface state of the camera preview interface is in a running state, the activity management service of the mobile phone 320 can send the state parameter of the camera preview interface of the camera application to the second distributed application service of the mobile phone 320 corresponding to the running state.

[0169] like Figure 6 As shown, the interface 630 is a camera preview interface of the camera application in a paused state, which may be in response to the user's triggering operation on the floating window control, and the activity management service of the mobile phone 320 sets the camera preview interface of the camera application as a floating window 631 to be displayed in the interface 630. If the interface state of the camera preview interface is in a paused state, the activity management service of the mobile phone 320 may send the state parameter of the camera preview interface of the camera application to the second distributed application service of the mobile phone 320 corresponding to the paused state.

[0170] In addition, the activity management service of the mobile phone 320 may also start a transparent application interface to cover the camera preview interface of the camera application. At this time, the interface state of the camera preview interface of the camera application is also a paused state, and this application does not limit this.

[0171] like Figure 6 As shown, interface 640 is a camera preview interface of a camera application in a stopped state. At this time, the user has finished shooting, and the obtained image interface completely covers the camera preview interface. If the interface state of the camera preview interface is in a stopped state, the activity management service of the mobile phone 320 can send the state parameter of the camera preview interface of the camera application to the second distributed application service of the mobile phone 320 corresponding to the stopped state.

[0172] In addition, the activity management service of mobile phone 320 may also start other application interfaces of a non-transparent camera application, or the application interfaces of other applications may cover the camera preview interface of the camera application. At this time, the interface state of the camera preview interface of the camera application is also in a stopped state, and this application does not limit this.

[0173] like Figure 6As shown, interface 650 is the main interface of mobile phone 320, and the interface state of the camera preview interface of the camera application is the destroyed state. This may be in response to the user's destruction operation on the application process of the camera application, for example Figure 6 As shown, in response to the user's swiping up operation on the camera application process, the second distributed application service of the mobile phone 320 closes the camera application, that is, closes the camera preview interface of the camera application. If the interface state of the camera preview interface is in the destroyed state, the activity management service of the mobile phone 320 can send the state parameter of the camera preview interface of the camera application to the second distributed application service of the mobile phone 320 corresponding to the destroyed state.

[0174] S409: The second distributed application service of the mobile phone 320 sends the state parameters of the camera preview interface to the first distributed application service of the tablet computer 310.

[0175] Based on the above example, in some embodiments, the second distributed application service may send the state parameters of the camera preview interface after the latest change to the first distributed application service.

[0176] S410: The first distributed application service of the tablet computer 310 sends the state parameters of the camera preview interface to the notebook application.

[0177] Based on the above example, in some embodiments, the first distributed application service may send the state parameters of the camera preview interface after the latest change to the notebook application.

[0178] S411: The notebook application of the tablet computer 310 displays prompt data corresponding to the state parameters of the camera preview interface to prompt the user.

[0179] Based on the above example, in some embodiments, the prompt data displayed by the notebook application may change with the state parameters of the camera preview interface after the latest change received.

[0180] In some embodiments, the prompt data may be prompt data in text form. For example, if the state parameter of the camera preview interface corresponds to the startup state, the notebook application of the tablet computer 310 may display text prompt data "starting" on its display screen, etc., which is not limited in this application. In some embodiments, the prompt data may also be prompt data in graphic form.

[0181] In addition, in order to improve the success rate of prompting, while displaying the prompt data, voice and / or vibration methods can also be used to further prompt the user.

[0182] In some embodiments, if the status parameters of the camera preview interface correspond to the operating status, the text prompt data "shooting" can be displayed in the operating interface of the notebook, and the speaker of the tablet computer 310 can issue a voice prompt data "shooting", etc. This application does not limit this.

[0183] In some embodiments, if the state parameters of the camera preview interface correspond to the destruction state, the notebook application of the tablet computer 310 can display the text prompt data "Exit shooting" on the running interface, and the motor of the tablet computer 310 generates vibrations of a pre-set specific vibration frequency, etc. This application does not limit this.

[0184] As can be seen from the above, this application does not limit the type of prompt data and the amount of prompt data.

[0185] In addition, this application does not make any specific limitations on the correspondence between the interface status of the camera preview interface and the prompt data.

[0186] In some embodiments, the interface state of the camera preview interface and the prompt data may be in a one-to-one correspondence, that is, when the interface state of the camera preview interface changes, the prompt data will also change accordingly.

[0187] In some embodiments, the interface state of the camera preview interface and the prompt data may have a many-to-one correspondence relationship, that is, the interface state of the camera preview interface may change, but the prompt data may remain unchanged.

[0188] For example, if the camera preview interface of the camera application is in the running state or the paused state, the notebook application of the tablet computer 310 can display the text prompt data "shooting" on its display screen; if the camera preview interface of the camera application is in the stopped state or the destroyed state, the notebook application of the tablet computer 310 can display the text prompt data "shooting has been exited" on its display screen. This application does not limit this.

[0189] It is understandable that when the user completes shooting and obtains an image through the camera application of the mobile phone 320, and the mobile phone 320 transmits the image to the tablet computer 310, the tablet computer 310 no longer has the need to perceive the interface status of the camera preview interface, and the mobile phone 320 no longer needs to send the interface status of the camera preview interface of the camera application to the tablet computer 310.

[0190] Therefore, in some embodiments, the method for sensing the application state may further include steps 1 and 2:

[0191] Step 1: In response to the user's image confirmation operation, the camera application of the mobile phone 320 sends an image to the notepad application of the tablet computer 310 .

[0192] In some embodiments, the camera application includes a shooting control, which is used to implement the function of shooting an image. In response to the user's triggering operation on the shooting control, the camera application can shoot and obtain an image. At this time, the camera application displays the captured image and can also display an image confirmation control. The user's image confirmation operation can be a triggering operation for the image confirmation control. In response to the user's image confirmation operation, the mobile phone 320 can send the image to the tablet computer 310.

[0193] Step 2: The notepad application of the tablet computer 310 displays the image captured by the camera application of the mobile phone 320 and prompt data corresponding to the completion of the shooting.

[0194] In some embodiments, after receiving the image captured by the camera application, the tablet computer 310 can insert the image at the position where the cursor flashes in the running interface of the notepad application.

[0195] For example, taking the prompt data as text prompt data, the notebook application of the tablet computer 310 may display text prompt data such as “shooting completed”, etc., which is not limited in the present application.

[0196] For ease of understanding, the following embodiments take the prompt data as text prompt data as an example, and combine Figure 7a-Figure 7b The prompt data corresponding to the state parameters of the camera preview interface displayed by the notebook application of the tablet computer 310 is described.

[0197] like Figure 7a As shown, if the interface state of the camera preview interface of the camera application is in the running state, in response to the user's destruction operation on the application process of the camera application, the activity management service of the mobile phone 320 closes the camera application, and the interface state of the camera preview interface will change from the running state to the destroyed state. At this time, the mobile phone 320 can feedback to the tablet computer 310 that the interface state of the camera preview interface has changed to the destroyed state, and the tablet computer 310 can display text prompt data 711 "shooting abnormality". In addition, the user can choose to trigger the re-call control to restart the camera application of the mobile phone 320 across devices, and the user can also choose to trigger the cancel control to close the text prompt data 711, which is not limited in this application.

[0198] like Figure 7bAs shown, in response to the user's confirmation operation on the image captured by the camera application, the camera application of the mobile phone 320 sends the image to the notepad application of the mobile phone 320. So that the notepad application displays the image after receiving it. At the same time, the tablet computer 310 can also display text prompt data "shooting completed". In addition, if the user has the need to call the camera application across devices again, he can choose to trigger the re-call control to quickly start the camera application of the mobile phone 320 across devices again; if the image displayed in the notepad application has met the user's needs, the user can also choose to trigger the cancel control and continue to use the notepad application.

[0199] In addition, the mobile phone 320 can send the function interface identifier to the tablet computer 310. In some embodiments, the function interface identifier can be sent synchronously when the mobile phone 320 sends the state parameters of the camera preview interface to the tablet computer 310 (for example, the state parameters carry the function interface identifier, that is, the state parameters include parameters for indicating the camera preview interface and also include the function interface identifier); in some embodiments, the function interface identifier can also be sent after the state parameters of the camera preview interface are sent. Therefore, this application does not limit the time for sending the function interface identifier, and it can be sent after the function interface identifier is generated by the second distributed application service of the mobile phone 320.

[0200] In addition, in order to further improve the accuracy of the prompt data displayed by the notebook application of the tablet computer 310, in S408, when the mobile phone 320 sends the status parameters of the camera preview interface to the tablet computer 310, the function interface identifier associated with the camera preview interface is simultaneously sent.

[0201] Accordingly, after S408, the embodiment of the present application may further include: after the second distributed application service of the mobile phone 320 receives the state parameter of the camera preview interface, identifying whether there is a corresponding function interface identifier.

[0202] If it exists, then continue to execute the subsequent step S409. It indicates that the camera preview interface is the application interface of the camera application called by the tablet computer 310;

[0203] If it does not exist, the subsequent steps can be stopped.

[0204] Similarly, after S409, the embodiment of the present application may further include: after the first distributed application service of the tablet computer 310 receives the state parameter of the camera preview interface, identifying whether there is a corresponding function interface identifier.

[0205] If it exists, then continue to execute the subsequent step S410. It indicates that the camera preview interface is the application interface of the camera application called by the tablet computer 310;

[0206] If it does not exist, the subsequent steps can be stopped.

[0207] In addition, after S407, the method for perceiving the application status may also include: the activity management service of the mobile phone 320 sends the correspondence between the function interface identifier and the activity record name of the camera preview interface to the second distributed application service of the mobile phone 320 for saving, so that if the tablet computer 310 subsequently sends other requests to the second distributed application service of the mobile phone 320 (for example, a close request in the later embodiment), the second can determine whether the request is related to the camera preview interface based on the correspondence, which is facilitating the execution of subsequent steps.

[0208] It should be noted that the second distributed application service can also save the correspondence between the function interface identifier and the activity name, preset name, etc. of the camera preview interface. This application does not limit this. The application interface to be closed can be determined as the camera preview interface based on the stored correspondence.

[0209] It can be seen that in the embodiment of the present application, the notepad application of the tablet computer can perceive the interface state changes of the camera preview interface in the camera application of the mobile phone in real time, and can display the prompt data corresponding to the state parameters of the camera preview interface in real time in the running interface of the notepad application, so that the user can grasp the actual state of the camera application called by the cross-device call operation in real time, and can quickly make interactive decisions with the notepad application according to the actual state of the camera application to meet their own needs. Therefore, the perception method of the application state provided in the embodiment of the present application can improve the user experience.

[0210] Embodiment 2:

[0211] It is understandable that, as described in the above embodiment, the camera application usually includes multiple functional interfaces, among which there may be at least one functional interface (the target interface, the camera preview interface in the above text) showing the function in the camera application requested by the call request, and there is also at least one functional interface (the associated interface) showing the associated function of the function in the camera application requested by the call request. That is to say, after entering the camera preview interface, the user may trigger the operation to enter the shooting adjustment interface, or after the camera preview interface captures the image, the user may trigger the image beautification interface. When entering these functional interfaces of the camera application, it is still in the state of wanting to capture the image or beautify the image and send it to the tablet computer. For example, the shooting adjustment interface can realize functions such as adjusting the shooting parameters to capture an image that is more in line with the user's expectations; the image beautification interface can beautify the captured image to obtain a photo that is more in line with the user's expectations. The camera applications of the mobile phone are all in the process of calling the application across devices. Therefore, in order to enable the user to more fully understand the progress of the shooting process, the mobile phone 310 can send the status parameters of different functional interfaces (target interface and associated interface) to the tablet computer 320 so that it can understand the status of the camera application in more detail.

[0212] An embodiment of the present application provides another method for perceiving application status.

[0213] Next, another method for perceiving application status provided in an embodiment of the present application will be described in detail by taking the example that the first device is a tablet computer 310, the second device is a mobile phone 320, the first application is a notepad application, and the second application is a camera application.

[0214] See also Figure 8 , which is a signaling interaction diagram of another method for perceiving application status provided in an embodiment of the present application. The method for perceiving application status may specifically include the following steps:

[0215] S801: The tablet computer 310 establishes a communication connection with the mobile phone 320.

[0216] S802: The notepad application of the tablet computer 310 receives a user's call operation on the camera application of the mobile phone 320 .

[0217] S803 : In response to the user's calling operation on the camera application of the mobile phone 320 , the notepad application of the tablet computer 310 sends a call request for the camera application to the first distributed application service of the tablet computer 310 .

[0218] S804: The first distributed application service of the tablet computer 310 sends a call request for the camera application to the second distributed application service of the mobile phone 320.

[0219] It should be noted that the specific implementation of S801-S804 can refer to S401-S404 in the above embodiment, which will not be repeated here.

[0220] S805: In response to the call request for the camera application, the second distributed application service of the mobile phone 320 generates a plurality of function interface identifiers.

[0221] The function interface identifier needs to be associated with the shooting interface (target interface) in subsequent steps, and also needs to be associated with the image beautification interface and the shooting parameter adjustment interface (associated interface). Therefore, the function interface identifier can be used to indicate the function interface (target interface and associated interface) corresponding to the call request in the second application.

[0222] In some embodiments, the camera application includes a camera preview interface that displays a shooting function, an image beautification interface that displays an image beautification function, and a shooting setting interface that displays a shooting parameter adjustment function.

[0223] For example, if the camera application of mobile phone 320 includes a target interface, namely a camera preview interface, and two associated interfaces, namely an image beautification interface and a shooting settings interface, then in response to a call request to the camera application, the second distributed application service of mobile phone 320 can generate three functional interface identifiers to associate them one by one with the three application interfaces in subsequent steps.

[0224] For ease of understanding, in the following embodiments, a camera application of mobile phone 320 includes a camera preview interface, an image beautification interface, and a shooting settings interface, which are three display pages for the function requested by the call request, or a display interface of functions associated with the requested function, and the second distributed application service of mobile phone 320 generates three function interface identifiers including a first function interface identifier, a second function interface identifier, and a third function interface identifier, as an example for specific explanation.

[0225] It should be noted that, in order to distinguish the above three different function interfaces according to different function interface identifiers, the first function interface identifier, the second function interface identifier and the third function interface identifier are different function interface identifiers.

[0226] S806: The second distributed application service of the mobile phone 320 sends a call request for the camera application and a plurality of function interface identifiers to the activity management service of the mobile phone 320 .

[0227] In some embodiments, the second distributed application service of the mobile phone 320 sends a call request for the camera application as well as the first function interface identifier, the second function interface identifier, and the third function interface identifier to the activity management service of the mobile phone 320 .

[0228] S807: When the activity management service of the mobile phone 320 starts the target interface of the camera application, the target interface is associated with its corresponding functional interface identifier. When starting the associated interface, the associated interface is associated with its corresponding functional interface identifier.

[0229] In some embodiments, when the activity management service of mobile phone 320 starts the camera preview interface, the camera preview interface as a target interface can be associated with the first functional interface identifier; when starting the shooting settings interface, the shooting settings interface as an associated interface can be associated with the second functional interface identifier; and when starting the image beautification interface, the image beautification interface as an associated interface can be associated with the third functional interface identifier.

[0230] For example, the following is combined with Fig. 9 The process of associating multiple function interface identifiers with multiple function interfaces of the camera application one by one is described in detail.

[0231] Take associating the shooting setting interface with the second function interface identifier as an example.

[0232] When the activity management service of the mobile phone 320 starts the shooting setting interface of the camera application, the second interface identification item is first used as the keyword Key in the key-value pair, and the generated second function interface identification item is used as the value Value in the key-value pair; then the (second interface identification item, second function interface identification) key-value pair is added to the second activity record corresponding to the shooting setting interface. When the activity management service of the mobile phone 320 starts the shooting setting interface of the camera application, the (second interface identification item, second function interface identification) key-value pair contained in the second activity record is parsed, thereby realizing the association between the second function interface identification and the shooting setting interface of the camera application.

[0233] Similarly, the process of associating the camera preview interface with the first function interface identifier and the process of associating the image beautification interface with the third function interface identifier are not described in detail here.

[0234] S808: The activity management service of the mobile phone 320 sends the state parameters of the target interface and the state parameters of the associated interface to the second distributed application service of the mobile phone 320.

[0235] It can be understood that the mobile phone 320 launches the camera preview interface (target interface) of the camera application in response to the call request, and then in response to the user's triggering operation of the switch control of the image beautification interface or the shooting parameter adjustment interface (associated interface), the mobile phone 320 can launch the associated interface.

[0236] Therefore, in some embodiments, if the user does not operate to trigger the switching control, there may only be state parameters of the target interface. That is, at this time, the activity management service sends the state parameters of the target interface to the second distributed application service in the same manner as in step S408 of the first embodiment.

[0237] In some embodiments, if the user operates to trigger the switching control, so that the mobile phone starts the associated interface, then there are state parameters of the target interface (the target interface is covered by the associated interface, and the target interface is in a stopped state) and state parameters of the associated interface (the associated interface covers the target interface, and the associated interface is in a running state). At this time, the activity management service can send the state parameters of the target interface and the state parameters of the associated interface to the second distributed application service. Exemplarily, if the camera preview interface of the camera application is in a running state, and the user has a need to adjust the shooting parameters, the user can operate the trigger to switch the camera application from the camera preview interface to the shooting setting interface. In response to the user's triggering operation on the switching control, the activity management service of the mobile phone 320 can start the shooting setting interface so that it completely covers the camera preview interface. Then the interface state of the camera preview interface will change from the running state to the stopped state, and the shooting setting interface will change to the started state, and soon change to the running state. Therefore, the state parameters of the camera preview interface correspond to the stopped state, and the state parameters of the shooting setting interface first correspond to the started state, and then to the running state.

[0238] S809: The second distributed application service of the mobile phone 320 sends the state parameters of the target interface and the state parameters of the associated interface to the first distributed application service of the tablet computer 310.

[0239] S810: The first distributed application service of the tablet computer 310 sends the state parameters of the target interface and the state parameters of the associated interface to the notebook application.

[0240] It should be noted that the specific implementation of S809-S810 can refer to S409-S411, and the embodiments of this application will not be repeated here.

[0241] S811: The notebook application of the tablet computer 310 displays prompt data corresponding to the state parameters of the target interface and the state parameters of the associated interface to prompt the user.

[0242] It should be noted that the present application does not specifically limit the correspondence between the state parameters of the target interface and the state parameters of the associated interface and the prompt data. In some embodiments, it can be a one-to-one correspondence. That is, when the state parameters of any interface change, the prompt data will also change accordingly. In some embodiments, it can also be a many-to-one correspondence. That is, it is possible that the received state parameters change, but the prompt data remains unchanged.

[0243] For example, if the status parameters of the camera preview interface received by the notebook application from the camera application correspond to the stop state, and the status parameters of the image beautification interface correspond to the running state, the displayed prompt data may be "shooting completed, image beautification in progress", which is not limited in this application.

[0244] For example, if the state parameter of the camera preview interface received by the notebook application corresponds to the stop state, and the state parameter of the shooting parameter adjustment interface corresponds to the running state, the prompt data displayed may be "Adjusting shooting parameters, please wait", which is not limited in this application. Fig.10 The steps of displaying the prompt data corresponding to the state parameters of the target interface and the state parameters of the associated interface by the notebook application of the tablet computer 310 are described in detail.

[0245] like Fig.10 As shown, when the camera preview interface is fully displayed in the camera application, it indicates that the camera preview interface is in the running state, and at this time, the prompt data 1101 in the tablet computer 310 shows "the camera application is shooting". If the user has the need to adjust the shutter sound, adjust the shooting parameters, etc., he can click the setting control in the camera application. In response to the user's triggering operation on the setting control 1002, the activity management service of the mobile phone 320 can start the shooting setting interface so that the shooting setting interface completely covers the camera preview interface. After the shooting setting interface is successfully started, it indicates that the interface state of the camera preview interface changes to the stopped state, and the interface state of the shooting setting interface changes to the running state. At this time, the prompt data displayed in the tablet computer can change to "adjusting the shooting settings, please wait", to prompt the user to wait for a while.

[0246] It can be seen that in the embodiment of the present application, the notepad application of the tablet computer can obtain the interface status of other functional interfaces in the camera application in real time based on the interface status changes of the camera preview interface in the camera application of the mobile phone in real time. The notepad application of the tablet computer can perceive each stage of the camera application in the shooting process in more detail, and can also display the prompt data corresponding to the status parameters, so that the user can grasp the actual status of the camera application called by the cross-device call operation in real time. Therefore, the perception method of the application status provided in the embodiment of the present application can further improve the user experience.

[0247] Embodiment three:

[0248] It is understandable that during the process of the first application of the first device calling the second application of the second device across devices, the user may have the need to stop the cross-device call at any time. To solve this problem, this embodiment provides a method for the first device to close the second application of the second device across devices (hereinafter referred to as closing the cross-device application).

[0249] Next, based on Example 1, a method for closing an application across devices provided in an embodiment of the present application is specifically described.

[0250] For ease of understanding, a method for closing applications across devices provided in an embodiment of the present application is described in detail below by taking the first device being a tablet computer 310, the second device being a mobile phone 320, the first application being a notepad application, and the second application being a camera application as an example.

[0251] It should be emphasized that the technical solution provided in the embodiment of the present application is implemented on the basis that the tablet computer 310 has received the function interface identifier and the second distributed application service of the mobile phone 320 has saved the correspondence between the function interface identifier and the activity record name of the camera preview interface.

[0252] See also Fig.11 , which is a signaling interaction diagram for closing an application across devices provided in an embodiment of the present application. The process of closing an application across devices may specifically include the following steps:

[0253] S1101: The notepad application of the tablet computer 320 receives a cross-device closing operation of the camera application in the mobile phone 320 from the user.

[0254] In some embodiments, the cross-device closing operation may be an operation in which the user closes the camera application in the notepad application.

[0255] For example, the notepad application may include a camera application closing control, and the user may trigger the camera application closing control. The triggering operation of the camera application closing control may be clicking, long pressing, or sliding the image acquisition control, etc., which is not limited in this application.

[0256] In some embodiments, the cross-device closing operation may be an operation of the user exiting the notepad application.

[0257] For example, the notepad application may include a return control for returning to the main interface, which may be triggered by the user; the notepad application may include an exit control for exiting the application, which may be triggered by the user; and the user may also destroy the application process of the notepad application. This application does not limit this.

[0258] In some embodiments, the cross-device closing operation may be that the user disconnects the communication connection between the tablet computer 310 and the mobile phone 320 .

[0259] Exemplarily, the user disconnects the WLAN to which the tablet computer 310 is connected, etc. This application does not limit this.

[0260] For ease of understanding, the following Figure 12a-12c The cross-device closing operation of the camera application in the mobile phone 320 by the user is explained in detail.

[0261] like Fig.12a As shown, at this time, according to the text prompt "Camera application is shooting", it can be determined that the notepad application of the tablet computer 310 is cross-device calling the camera application of the mobile phone 310. If the user has the need to cancel the cross-device application call, the cancel control 1201 below the text prompt content can be triggered to make the notepad application receive the user's cross-device closing operation on the camera application in the mobile phone 320.

[0262] like Figure 12b As shown, the user can also choose to trigger the exit control 1202 of the notepad application, so that the tablet computer 310 exits the notepad application, indicating that it is also necessary to close the call operation of the camera application of the mobile phone 310. Therefore, the notepad application receives the user's cross-device closing operation of the camera application in the mobile phone 320.

[0263] like Fig.12c As shown, the user can also choose to trigger the sliding operation to make the tablet computer 310 display the notification bar interface, and then click the WLAN icon to disconnect the communication connection between the tablet computer 310 and the mobile phone 320. Since the cross-device application calling technology is based on the communication connection between the two, after the communication connection is disconnected, the notepad application also receives the user's cross-device closing operation on the camera application in the mobile phone 320.

[0264] S1102: In response to the user's cross-device closing operation on the camera application in the mobile phone 320, the notepad application of the tablet computer 320 sends a closing request for the camera application to the first distributed application service of the tablet computer 320. The closing request for the camera application carries the functional interface identifier corresponding to the camera preview interface of the camera application. In response to the user's cross-device closing operation, the notepad application of the tablet computer 310 may generate a closing request for the camera application and send the closing request for the camera application to the first distributed application service.

[0265] In some embodiments, the request to close the camera application may be in the form of a request from the tablet computer 310. The standard string in the system is A system-preset string used to indicate a request to close the camera app.

[0266] In some embodiments, the request to close the camera application may be a custom string pre-set by a developer or other technical personnel to indicate the request to close the camera application. This application does not limit this.

[0267] S1103: The first distributed application service of the tablet computer 320 sends a request for closing the target interface in the camera application to the second distributed application service of the mobile phone 320 .

[0268] S1104: The second distributed application service of the mobile phone 320 determines the activity record name corresponding to the camera preview interface according to the function interface identifier carried in the closing request for the target interface in the camera application and the correspondence between the saved function interface identifier and the activity record name of the camera preview interface.

[0269] In some embodiments, the activity record name of the camera preview interface is Activity Record1, and the function interface identifier is sessionid1. The second distributed application service has saved a corresponding relationship in the form of (sessionid1, ActivityRecord1). Therefore, when the second distributed application service receives the sessionid1 carried in the close request, it can determine the Activity Record1 corresponding to the camera preview interface.

[0270] S1105: The second distributed application service of the mobile phone 320 sends the activity record name corresponding to the camera preview interface to the activity management service of the mobile phone 320.

[0271] S1106 : According to the activity record name corresponding to the camera preview interface, the activity management service of the mobile phone 320 closes the camera preview interface of the camera application of the mobile phone 320 .

[0272] In some embodiments, based on the above example, the activity management service of mobile phone 320 can find the activity record of the camera preview interface based on the activity record name Activity Record1, and then the activity management service can close the camera preview interface of the camera application of mobile phone 320, that is, end the camera application.

[0273] It can be seen that in the embodiment of the present application, when the user has the need to stop calling the application process across devices, the user is provided with the function of actively closing the camera application. When the notepad application of the tablet computer obtains the user's closing operation on the camera application, a closing request for the target interface in the camera application can be generated based on the stored function interface identifier, and the closing request can be sent across devices to enable the activity management service of the camera application to close the camera preview interface (target interface) of the camera application. On the basis of enabling the user to understand the actual status of the camera application in real time, the user's closing request can be responded to at any time to close the target interface in the camera application across devices, further improving the user's experience.

[0274] The present application also provides an electronic device, which may include: a memory and one or more processors. The memory is coupled to the processor. The memory is used to store a computer program. When the processor executes the computer program, the electronic device may perform the functions or steps performed by the first device or the second device in the above method embodiment.

[0275] This embodiment also provides a computer-readable storage medium, in which a computer program is stored. When the computer program runs on an electronic device, the electronic device executes each function or step executed by the first device or the second device in the above method embodiment.

[0276] This embodiment further provides a computer program product. When the computer program product runs on a computer, it enables the computer to execute each function or step executed by the first device or the second device in the above method embodiment.

[0277] Among them, the electronic device, computer-readable storage medium or computer program product provided in this embodiment is used to execute the corresponding application status perception method provided above. Therefore, the beneficial effects that can be achieved can refer to the beneficial effects in the corresponding method provided above and will not be repeated here.

[0278] Finally, it should be noted that the above embodiments are only used to illustrate the technical solution of the present application and are not intended to limit it. Although the present application has been described in detail with reference to the preferred embodiments, a person of ordinary skill in the art should understand that the technical solution of the present application may be modified or replaced by equivalents without departing from the spirit and scope of the technical solution of the present application.

Claims

1. A method for sensing application status, characterized in that: Applied to a first device, the method includes: Displaying a running interface of a first application; wherein the running interface of the first application includes a cross-device application calling control; In response to a triggering operation on the cross-device application calling control, sending a calling request for a second application in the second device to a second device; receiving a state parameter of a target interface sent by the second device; the target interface being a display interface of a function of the second application requested by the call request; Based on the state parameters of the target interface, prompt data corresponding to the state parameters of the target interface are displayed in the running interface of the first application.

2. The method according to claim 1, characterized in that The first device includes a first distributed application service, and the second device includes a second distributed application service and an activity management service; in response to a triggering operation on the cross-device application call control, sending a call request for a second application in the second device to the second device specifically includes: In response to a triggering operation on the cross-device application calling control, the first application sends the calling request to the first distributed application service; The first distributed application service sends the call request to the second distributed application service, so that the second distributed application service sends the call request to the activity management service, and the activity management service starts the target interface based on the call request; The receiving the state parameter of the target interface sent by the second device specifically includes: The first distributed application service receives the state parameter of the target interface sent by the second distributed application service; the state parameter of the target interface is sent by the activity management service to the second distributed application service when the interface state of the target interface changes the latest time; The first application receives the state parameter of the target interface sent by the first distributed application service.

3. The method according to claim 1, characterized in that The state parameter of the target interface includes a function interface identifier associated with the target interface, the function interface identifier is generated by the second device based on the call request, and the function interface identifier and the target interface are associated by the second device when starting the target interface; the method further includes: In response to a closing operation of the second application in the running interface of the first application, generating a closing request for the target interface based on the functional interface identifier; the closing request includes the functional interface identifier; The closing request is sent to the second device so that the second device closes the target interface based on the functional interface identifier in the closing request.

4. The method according to claim 3, characterized in that The first device includes a first distributed application service, and the second device includes a second distributed application service and an activity management service; sending the closing request to the second device so that the second device closes the target interface based on the functional interface identifier in the closing request specifically includes: The first application sends the closing request to the first distributed application service; The first distributed application service sends the close request to the second distributed application service, so that the second distributed application service determines the activity record name based on the function interface identifier in the close request and the correspondence between the function interface identifier and the activity record name of the target interface, and sends the activity record name to the activity management service, and the activity management service closes the target interface based on the activity record name; wherein the activity record name is the name of the activity record corresponding to the target interface.

5. The method according to claim 1, characterized in that: The displaying, based on the state parameter of the target interface, prompt data corresponding to the state parameter of the target interface in the running interface of the first application specifically includes: In the running interface of the first application, prompt data corresponding to the status parameters of the target interface are displayed in the form of text and / or graphics; and the status parameters of the target interface are prompted to be updated through voice and / or vibration.

6. The method according to claim 1, characterized in that The first application includes a notepad application, the second application includes a camera application, the target interface includes a camera preview interface, and the method further includes: Receiving an image captured by the camera application of the second device; wherein the image is captured by the second device in response to a triggering operation of a capture control in the camera application; and the camera preview interface of the camera application is started by the second device in response to the call request; The image is inserted at the position where the cursor flashes in the running interface of the notepad application.

7. The method according to claim 1, characterized in that The method further comprises: receiving a state parameter of an associated interface sent by the second device; the associated interface being a display interface of an associated function of a function of the second application requested by the call request; The displaying, based on the state parameter of the target interface, prompt data corresponding to the state parameter of the target interface in the running interface of the first application specifically includes: Based on the state parameters of the target interface and the state parameters of the associated interface, prompt data corresponding to the state parameters of the target interface and the state parameters of the associated interface are displayed in the running interface of the first application.

8. A method for sensing application status, characterized in that: Applied to the second device, the method includes: receiving a request sent by a first device for a first application of the first device to call a second application of the second device; In response to the calling request, the status parameters of the target interface are sent to the first device so that the first device displays prompt data corresponding to the status parameters of the target interface in the running interface of the first application based on the status parameters of the target interface; the target interface is the display interface of the function of the second application requested by the calling request.

9. The method according to claim 8, characterized in that The sending, in response to the calling request, the state parameter of the target interface to the first device specifically includes: In response to the calling request, generating a function interface identifier; the function interface identifier is used to indicate the function interface corresponding to the calling request in the second application; Associating the functional interface identifier with the target interface; Sending the state parameters of the target interface to the first device.

10. The method according to claim 9, characterized in that The associating the functional interface identifier with the target interface specifically includes: Adding the functional interface identifier to the activity record corresponding to the target interface; The activity record corresponding to the target interface is parsed to obtain the functional interface identifier to associate the functional interface identifier with the target interface.

11. The method according to claim 9, characterized in that The method further comprises: receiving a closing request for the target interface of the second application sent by the first device; the closing request including the functional interface identifier; Based on the functional interface identifier in the closing request, the target interface is closed.

12. The method according to claim 11, characterized in that The method further comprises: Storing the correspondence between the functional interface identifier and the activity record name of the target interface; Closing the target interface based on the functional interface identifier in the closing request specifically includes: Determine the activity record name based on the function interface identifier in the closing request and the corresponding relationship between the function interface identifier and the activity record name; Based on the activity record name, the target interface is closed.

13. An electronic device, characterized in that: The electronic device comprises a memory and a processor; The memory is used to store a computer program and transmit the computer program to the processor; The processor is used to execute the steps of a method for perceiving an application state as described in any one of claims 1 to 7 according to the computer program, or to execute the steps of a method for perceiving an application state as described in any one of claims 8 to 12.

14. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores a computer program, which, when executed by a processor, implements the steps of a method for perceiving an application state as described in any one of claims 1 to 7, or executes the steps of a method for perceiving an application state as described in any one of claims 8 to 12.