Method for preventing screenshot, terminal device and storage medium

By generating notification messages and display controls during screen sharing, the problem of screenshot privacy protection in screen sharing is solved, achieving efficient prevention of screenshots and improved user experience.

CN115145663BActive Publication Date: 2026-06-09HUAWEI TECH CO LTD

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
HUAWEI TECH CO LTD
Filing Date
2021-03-31
Publication Date
2026-06-09

AI Technical Summary

Technical Problem

Existing screen sharing software cannot effectively prevent one user's screen content from being screenshotted by another user, thus posing a privacy protection issue.

Method used

By generating and sending a notification message, the system instructs the other terminal to prohibit screenshots and displays controls in the display window to inform the user of the current status. By combining the target area information with the screenshot attributes, the system can prevent screenshots.

Benefits of technology

It effectively prevents screenshots, protects privacy, improves user experience, and simplifies operation processes.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN115145663B_ABST
    Figure CN115145663B_ABST
Patent Text Reader

Abstract

The embodiment of the application is suitable for the field of communication technology, and provides a method for preventing screen capture, a terminal device and a storage medium. A first terminal device and a second terminal device perform a screen sharing service, and the method for preventing screen capture comprises the following steps: the first terminal device generates a first notification message and sends the first notification message to the second terminal device. The first notification message comprises first indication information for indicating that the second terminal device is prohibited from capturing a screen. The second terminal device sets screen capture attribute information of a display window of the screen sharing service according to the first indication information. The second terminal device sends a first response message to the first terminal device. The first terminal device displays a first control in the display window of the screen sharing service, and the display state of the first control indicates that the second terminal device is prohibited from capturing a screen. The method for preventing screen capture provided by the embodiment of the application has a simple message flow and a small number of messages, and realizes the prevention of screen capture of a peer terminal device.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of communication technology, and in particular to a method, terminal device and storage medium for preventing screenshots. Background Technology

[0002] With the development of communication and terminal technologies, devices communicating with each other can share screen content. For example, two terminal devices making a video call can share their screens.

[0003] During screen sharing, due to privacy concerns, one user may not want the other user to screenshot or save the video feed or shared content. Current screen sharing software does not offer this functionality. Summary of the Invention

[0004] This application provides a method, terminal device, and storage medium for preventing screenshots, thereby preventing screenshots from being taken by the other end device.

[0005] In a first aspect, a method for preventing screenshots is provided, applied to a first terminal device, wherein the first terminal device and a second terminal device are performing a screen sharing service. The method for preventing screenshots includes: generating a first notification message, the first notification message including first indication information, the first indication information being used to instruct the second terminal device to prohibit screenshots; sending the first notification message to the second terminal device; receiving a first response message sent by the second terminal device; and displaying a first control in the display window of the screen sharing service, the first control being used to set whether to prohibit screenshots by the second terminal device, the display status of the first control indicating that screenshots by the second terminal device are prohibited.

[0006] The first aspect provides a method for preventing screenshots, applied to a first terminal device (terminal A in this embodiment) performing a screen-sharing service. Terminal A sends a first notification message to a second terminal device (terminal B in this embodiment), carrying first instruction information instructing terminal B to prohibit screenshots. After receiving the first notification message, terminal B sets the display window of the screen-sharing service to prohibit screenshots according to the first instruction information, thereby preventing screenshots and protecting privacy. Due to the simple message flow and the small number of interactive messages, the efficiency of preventing screenshots is very high. Moreover, terminal A displays a first control in the display window of the screen-sharing service to prompt the user that screenshots by terminal B are currently prohibited, facilitating subsequent user operations and improving the user experience.

[0007] In one possible implementation, the first notification message also includes location information of a first target area, which is an area where the second terminal device is prohibited from taking screenshots.

[0008] In one possible implementation, the first notification message is a screen sharing service establishment request message, and the first response message is a screen sharing service establishment response message.

[0009] In one possible implementation, generating the first notification message includes: displaying a service initiation interface for the screen sharing service; the service initiation interface includes a second control, which is used to set whether to prohibit the second terminal device from taking screenshots; receiving a user's target operation on the second control, which is used to set the prohibition of the second terminal device from taking screenshots; and generating the first notification message in response to the target operation.

[0010] In one possible implementation, before generating the first notification message, the process further includes: determining that the screen sharing service is a preset service.

[0011] In one possible implementation, the first terminal device and the second terminal device are sharing a screen. Before generating the first notification message, the display state of the first control in the display window indicates that the second terminal device is allowed to take a screenshot. Generating the first notification message includes: receiving a first operation by the user on the first control, the first operation on the first control being used to set the second terminal device to prevent screenshots; and generating the first notification message in response to the first operation by the user on the first control.

[0012] In one possible implementation, the first terminal device and the second terminal device are sharing a screen, and the display window further includes a region selection control for selecting a first target region; the method further includes: receiving a first operation from the user on the region selection control; in response to the first operation from the user on the region selection control, receiving a first region selection operation from the user in the display window; in response to the first region selection operation, determining the first target region and obtaining the location information of the first target region.

[0013] In one possible implementation, before determining the first target area, the method further includes: displaying a confirmation button and a cancel button in a display window; and receiving user input to the confirmation button.

[0014] In one possible implementation, after receiving the user's selection operation of the first region in the display window, the method further includes: displaying the boundary of the first target region in the display window.

[0015] In one possible implementation, the display window further includes a region selection control, which is used to select a second target region, the second target region being an area where the second terminal device is prohibited from taking screenshots; the method further includes: receiving a second operation from the user on the region selection control; responding to the second operation from the user on the region selection control, receiving a second region selection operation from the user in the display window; responding to the second region selection operation, determining the second target region and obtaining the location information of the second target region; and sending the location information of the second target region to the second terminal device.

[0016] In one possible implementation, after sending the first notification message to the second terminal device and before receiving the first response message sent by the second terminal device, the method further includes: starting a first timer; if the first timer times out, retransmitting the first notification message to the second terminal device.

[0017] One possible implementation further includes: receiving a second operation by a user on a first control, the second operation on the first control being used to set permission for a second terminal device to take a screenshot; generating a second notification message in response to the second operation by the user on the first control; the second notification message including second indication information, the second indication information being used to indicate permission for the second terminal device to take a screenshot; sending the second notification message to the second terminal device; and receiving a second response message sent by the second terminal device.

[0018] In one possible implementation, after sending the second notification message to the second terminal device and before receiving the second response message sent by the second terminal device, the method further includes: starting a second timer; if the second timer times out, retransmitting the second notification message to the second terminal device.

[0019] In one possible implementation, the display window also includes a preset icon, which is used to indicate that the display window should not be used for screenshots.

[0020] Secondly, a method for preventing screenshots is provided, applied to a second terminal device, wherein the second terminal device and a first terminal device are performing a screen sharing service. The method for preventing screenshots includes: receiving a first notification message sent by the first terminal device, the first notification message including first instruction information, the first instruction information being used to instruct the second terminal device to prohibit screenshots; setting screenshot attribute information of the display window of the screen sharing service according to the first instruction information; and sending a first response message to the first terminal device.

[0021] One possible implementation also includes: displaying a preset icon in the display window, the preset icon being used to indicate that the display window should not be used for screenshots.

[0022] In one possible implementation, the first notification message further includes location information of a first target area, which is an area where the second terminal device is prohibited from taking screenshots; and sets the screenshot attribute information of the display window of the screen sharing service according to the first instruction information, including: setting the screenshot attribute information according to the first instruction information and the location information of the first target area.

[0023] One possible implementation also includes: displaying the boundary of the region corresponding to the first target region in the display window based on the location information of the first target region.

[0024] One possible implementation further includes: receiving a user's first screenshot operation; responding to the first screenshot operation, taking a screenshot and generating a screenshot image based on screenshot attribute information, wherein the area in the screenshot image corresponding to the first target area is a preset fill pattern.

[0025] One possible implementation further includes: receiving a second screenshot operation from the user; generating a prompt message in response to the second screenshot operation; the prompt message indicating that the display window should not take screenshots; and outputting the prompt message.

[0026] In one possible implementation, the first notification message is a screen sharing service establishment request message, and the first response message is a screen sharing service establishment response message.

[0027] One possible implementation further includes: receiving location information of a second target area sent by a first terminal device, wherein the second target area is an area where the second terminal device is prohibited from taking screenshots; and updating screenshot attribute information based on the location information of the second target area.

[0028] One possible implementation further includes: receiving a second notification message sent by a first terminal device, the second notification message including second indication information, the second indication information being used to indicate that the second terminal device is allowed to take a screenshot; updating the screenshot attribute information of the display window of the screen sharing service according to the second indication information; and sending a second response message to the first terminal device.

[0029] Thirdly, a terminal device is provided as a first terminal device, which performs a screen sharing service with a second terminal device. The terminal device includes: a processing module for generating a first notification message, the first notification message including first indication information, the first indication information being used to instruct the second terminal device to prohibit screenshotting; a sending module for sending the first notification message to the second terminal device; a receiving module for receiving a first response message sent by the second terminal device; and the processing module is further configured to display a first control in the display window of the screen sharing service, the first control being used to set whether to prohibit screenshotting by the second terminal device, the display status of the first control indicating that screenshotting by the second terminal device is prohibited.

[0030] In one possible implementation, the first notification message also includes location information of a first target area, which is an area where the second terminal device is prohibited from taking screenshots.

[0031] In one possible implementation, the first notification message is a screen sharing service establishment request message, and the first response message is a screen sharing service establishment response message.

[0032] In one possible implementation, the processing module is specifically used for: displaying a service initiation interface for screen sharing; the service initiation interface includes a second control, which is used to set whether to prohibit the second terminal device from taking screenshots; the control receiving module receives the user's target operation on the second control, which is used to set the prohibition of the second terminal device from taking screenshots; and in response to the target operation, generating a first notification message.

[0033] In one possible implementation, the processing module is further configured to determine that the screen sharing service is a preset service before generating the first notification message.

[0034] In one possible implementation, the first terminal device and the second terminal device are sharing a screen. Before generating the first notification message, the display status of the first control in the display window indicates that the second terminal device is allowed to take a screenshot. The receiving module is also used to receive the user's first operation on the first control, which is used to set the second terminal device to be prohibited from taking screenshots. The processing module is specifically used to generate the first notification message in response to the user's first operation on the first control.

[0035] In one possible implementation, the first terminal device and the second terminal device are sharing a screen, and the display window also includes a region selection control for selecting a first target region; the receiving module is also used to receive a first operation of the user on the region selection control; the processing module is also used to control the receiving module to receive the first region selection operation of the user in the display window in response to the first operation of the user on the region selection control; in response to the first region selection operation, determine the first target region and obtain the location information of the first target region.

[0036] In one possible implementation, the processing module is further configured to display a confirmation button and a cancel button in a display window before determining the first target area; the receiving module is further configured to receive the user's operation on the confirmation button.

[0037] In one possible implementation, the processing module is also used to display the boundary of the first target area in the display window.

[0038] In one possible implementation, the display window further includes a region selection control for selecting a second target region, which is an area where the second terminal device is prohibited from taking screenshots; a receiving module for receiving a second operation by the user on the region selection control; a processing module for responding to the second operation by the user on the region selection control, controlling the receiving module to receive the second region selection operation by the user in the display window; in response to the second region selection operation, determining the second target region and obtaining the location information of the second target region; and a sending module for sending the location information of the second target region to the second terminal device.

[0039] In one possible implementation, the processing module is further configured to start a first timer after the sending module sends the first notification message to the second terminal device and before the receiving module receives the first response message sent by the second terminal device; if the first timer expires, the sending module is further configured to resend the first notification message to the second terminal device.

[0040] In one possible implementation, the receiving module is further configured to receive a second operation by the user on the first control, the second operation on the first control being configured to allow the second terminal device to take a screenshot; the processing module is further configured to generate a second notification message in response to the second operation by the user on the first control; the second notification message includes second indication information, the second indication information being configured to indicate that the second terminal device is allowed to take a screenshot; the sending module is further configured to send the second notification message to the second terminal device; and the receiving module is further configured to receive a second response message sent by the second terminal device.

[0041] In one possible implementation, the processing module is further configured to start a second timer after the sending module sends the second notification message to the second terminal device and before the receiving module receives the second response message sent by the second terminal device; if the second timer expires, the sending module is further configured to resend the second notification message to the second terminal device.

[0042] In one possible implementation, the display window also includes a preset icon, which is used to indicate that the display window should not be used for screenshots.

[0043] Fourthly, a terminal device is provided as a second terminal device, which performs a screen sharing service with a first terminal device. The terminal device includes: a receiving module for receiving a first notification message sent by the first terminal device, the first notification message including first indication information, the first indication information being used to instruct the second terminal device to prohibit screenshotting; a processing module for setting screenshot attribute information of the display window of the screen sharing service according to the first indication information; and a sending module for sending a first response message to the first terminal device.

[0044] In one possible implementation, the processing module is also used to display a preset icon in the display window, the preset icon being used to indicate that the display window should not be used for screenshots.

[0045] In one possible implementation, the first notification message also includes the location information of the first target area, which is an area where the second terminal device is prohibited from taking screenshots; the processing module is specifically used to: set screenshot attribute information according to the first instruction information and the location information of the first target area.

[0046] In one possible implementation, the processing module is further configured to display the boundary of the region corresponding to the first target region in the display window based on the location information of the first target region.

[0047] In one possible implementation, the receiving module is further configured to receive the user's first screenshot operation; the processing module is further configured to respond to the first screenshot operation by taking a screenshot and generating a screenshot image based on the screenshot attribute information, wherein the area in the screenshot image corresponding to the first target area is a preset fill pattern.

[0048] In one possible implementation, the receiving module is further configured to receive a second screenshot operation from the user; the processing module is further configured to generate a prompt message in response to the second screenshot operation; the prompt message is used to instruct the display window to disable screenshots; and the prompt message is output.

[0049] In one possible implementation, the first notification message is a screen sharing service establishment request message, and the first response message is a screen sharing service establishment response message.

[0050] In one possible implementation, the receiving module is further configured to receive location information of a second target area sent by the first terminal device, wherein the second target area is an area where the second terminal device is prohibited from taking screenshots; the processing module is further configured to update screenshot attribute information according to the location information of the second target area.

[0051] In one possible implementation, the receiving module is further configured to receive a second notification message sent by the first terminal device, the second notification message including second indication information, the second indication information being used to indicate that the second terminal device is allowed to take a screenshot; the processing module is further configured to update the screenshot attribute information of the display window of the screen sharing service according to the second indication information; and the sending module is further configured to send a second response message to the first terminal device.

[0052] Fifthly, a terminal device is provided, the terminal device including a processor, the processor being configured to couple with a memory, read instructions from the memory, and cause the terminal device to execute the method provided in the first or second aspect according to the instructions.

[0053] In a sixth aspect, a program is provided that, when executed by a processor, performs the method provided in the first or second aspect.

[0054] In a seventh aspect, a computer-readable storage medium is provided, wherein instructions are stored therein, which, when executed on a computer or processor, implement the method provided in the first or second aspect.

[0055] Eighthly, a program product is provided, the program product comprising a computer program stored in a readable storage medium, wherein at least one processor of a device can read the computer program from the readable storage medium, and the at least one processor executes the computer program to cause the device to implement the method provided in the first or second aspect. Attached Figure Description

[0056] Figure 1 System architecture diagram provided for embodiments of this application;

[0057] Figure 2 A schematic diagram of a terminal screen sharing provided in an embodiment of this application;

[0058] Figure 3 Another schematic diagram of terminal screen sharing provided in the embodiments of this application;

[0059] Figure 4 A flowchart illustrating a method for preventing screenshots provided in an embodiment of this application;

[0060] Figure 5 A schematic diagram of a service initiation interface for screen sharing service provided in an embodiment of this application;

[0061] Figure 6 This is a schematic diagram of an interface of terminal A provided in an embodiment of this application;

[0062] Figure 7 This is a schematic diagram of another interface of terminal A provided in an embodiment of this application;

[0063] Figure 8 This is a schematic diagram of an interface of terminal B provided in an embodiment of this application;

[0064] Figure 9 This is a schematic diagram illustrating an interface change in which a user selects a prohibited screenshot area in the display window of the screen sharing service on terminal A, as provided in an embodiment of this application.

[0065] Figure 10 This is a schematic diagram illustrating another interface change for a user selecting a prohibited screenshot area in the display window of the screen sharing service on terminal A, as provided in an embodiment of this application.

[0066] Figure 11 This is a schematic diagram of the interface of terminal B after a user takes a screenshot of terminal B, as provided in an embodiment of this application.

[0067] Figure 12 This is a schematic diagram of another interface of terminal B after a user takes a screenshot of terminal B, which is provided in an embodiment of this application.

[0068] Figure 13 Another flowchart of the method for preventing screenshots provided in this application embodiment;

[0069] Figure 14 This is another schematic diagram of the interface of terminal A provided in an embodiment of this application;

[0070] Figure 15 A schematic diagram of the structure of a terminal provided in an embodiment of this application;

[0071] Figure 16 This is a schematic diagram of the structure of a terminal device provided in an embodiment of this application. Detailed Implementation

[0072] The embodiments of this application are described below with reference to the accompanying drawings.

[0073] The method for preventing screenshots provided in this application is applied between terminals sharing their screens. For example, Figure 1 This is a system architecture diagram provided for an embodiment of this application. Figure 1 As shown, the system may include terminal A and terminal B. Terminal A and terminal B perform screen sharing. Optionally, terminal A and terminal B have an application (APP) installed to implement screen sharing. This embodiment of the application does not limit the name or developer of the application. This embodiment of the application does not limit the number of terminals performing screen sharing. For example, three or more terminals may conduct video calls.

[0074] This application does not limit the name and type of the terminal. For example, a terminal may also be called a terminal device, electronic device, or communication device. Examples of terminals include: mobile phones, tablet computers, laptop computers, PDAs, wearable devices, etc.

[0075] For ease of explanation, this application uses the example of screen sharing between terminal A and terminal B to illustrate the embodiment.

[0076] It should be noted that the embodiments of this application do not limit the screen sharing service. For example, it may include, but is not limited to, video call service or screen projection service.

[0077] First, let's explain the screen sharing between terminal A and terminal B.

[0078] Optionally, in one implementation, Figure 2 This is a schematic diagram illustrating a terminal screen sharing embodiment provided in this application. In this implementation, terminal A and terminal B display the same screen. Figure 2 As shown, terminal A and terminal B are performing a screen sharing service, such as screen casting. Both terminal A and terminal B are displaying the relevant interface for the screen casting service in full screen. Figure 2 (a) shows display window 11 in terminal A used for displaying the screen mirroring service. Figure 2 (b) shows display window 12 in terminal B used for displaying the screen projection service. Display window 11 and display window 12 have the same layout and display the same content.

[0079] Alternatively, in another implementation, Figure 3This is another schematic diagram illustrating terminal screen sharing provided in an embodiment of this application. In this implementation, the screen layouts displayed by terminal A and terminal B are different, but they include the same shared content. Figure 3 As shown, terminal A and terminal B are engaged in a screen-sharing service, such as a video call. Both terminal A and terminal B are displaying the relevant interface for the video call in full screen. Figure 3 In (a), the display window 21 on terminal A includes window 211 and window 212. To highlight information from the other end, window 211 displays the image X captured by the camera of terminal B, and window 212 displays the image Y captured by the camera of terminal A. Figure 3 In (b) of the diagram, window 22 on terminal B includes window 221 and window 222. Similarly, to highlight information from the other end, window 221 displays the image X captured by terminal B's camera, and window 222 displays the image Y captured by terminal A's camera. In this implementation, content displayed at a certain location on one terminal's screen may be displayed at a different location on another terminal's screen. For example, for... Figure 3 When region 2121 in window 212 of (a) is mapped to terminal B, specifically: Figure 3 (b) In the region 2221 of window 222.

[0080] It should be noted that this application embodiment does not limit the position or size of the display window used for displaying screen sharing services on different terminals. Optionally, it can be displayed in full screen, for example... Figure 2 and Figure 3 As shown. Optional, it can also be displayed in a non-full-screen mode.

[0081] It should be noted that the above Figure 2 and Figure 3 This is merely an example and does not limit the screen sharing between terminal A and terminal B. Since terminal A and terminal B may have different types and screen sizes, they can have different display layouts when sharing screens.

[0082] This application provides a method for preventing screenshots, applied to terminals performing screen sharing services. One terminal sends an instruction to other terminals, instructing them to disable screenshots. Correspondingly, other terminals set their screen sharing service display windows to disable screenshots based on the instruction. The screenshot prevention method provided by this application has a simple message flow, requires few interaction messages, and achieves high efficiency in preventing screenshots. Furthermore, by displaying relevant information in the screen sharing service display window to prompt the user whether screenshots are currently disabled, the user experience is improved.

[0083] The technical solution of this application will be described in detail below through specific embodiments. The following embodiments can be combined with each other, and the same or similar concepts or processes may not be described again in some embodiments.

[0084] The terms “first,” “second,” “third,” “fourth,” etc. (if present) in the embodiments of this application are used to distinguish similar objects and are not necessarily used to describe a specific order or sequence.

[0085] It should be noted that in this embodiment, "screenshot" has the following meanings: obtaining a screenshot image through a screenshot operation, or obtaining a screenshot video through a screenshot operation. This embodiment does not limit the name of the screenshot; for example, it can also be called screen recording.

[0086] Figure 4 This is a flowchart illustrating a method for preventing screenshots provided in an embodiment of this application. The executing entities of this embodiment include terminal A and terminal B, and it relates to the initial establishment phase of a screen sharing service. Figure 4 As shown, the method for preventing screenshots provided in this embodiment may include:

[0087] S401. Terminal A generates a screen sharing service establishment request message. The establishment request message includes first indication information, which is used to instruct Terminal B to prohibit screenshotting.

[0088] Specifically, terminal A is the initiator of the screen sharing service, and terminal B is the recipient of the screen sharing service. When terminal A initiates the screen sharing service, it includes a first instruction in the establishment request message, instructing terminal B to prohibit screenshots.

[0089] Optionally, in one implementation, if terminal A determines that the screen sharing service is a preset service, it generates a screen sharing service establishment request message, which includes first indication information. This embodiment does not limit the preset service. For example, the preset service may include, but is not limited to, at least one of the following: video call service or screen projection service.

[0090] Optionally, in another implementation, in S401, terminal A generates an establishment request message, which may include:

[0091] Terminal A displays the screen sharing service initiation interface. This interface includes a second control used to configure whether to prevent Terminal B from taking screenshots.

[0092] Terminal A receives the user's target operation on the second control, which is used to set terminal B to prevent screenshots.

[0093] Terminal A responds to the target operation by generating an establishment request message.

[0094] For example, in combination Figure 5 This will be explained. In this example, screen sharing is a video call service. For example... Figure 5 As shown in (a), the video call service initiation interface 51 includes several functional controls, including: a "Create Contact" control, a "Save to Existing Contact" control, a "Video Call" control 52, a "Send Message" control, and a "Disable Screenshot" control 53. Control 53 is the second control, and its different display states indicate whether to disable screenshots on terminal B. When a user initiates a video call through terminal A, after entering the call number "111 1111 1111", they click control 53 to disable screenshots on terminal B. Correspondingly, terminal A responds to the user's click on control 53 by changing the display form of control 53, for example, by changing the display color. Figure 5 As shown in (b) above. The user continues to click control 52 to initiate a video call. Accordingly, terminal A responds to the user's click on control 52 by generating a setup request message, which includes first indication information.

[0095] It needs to be explained that, Figure 5 This is just an example and does not limit the interface for initiating a business.

[0096] As can be seen, in this implementation, users can set whether to block screenshots from terminal B on the service initiation interface of the screen sharing service. The operation is simple and can be set according to user needs, which improves the flexibility of setting to block screenshots from terminal B and enhances the user experience.

[0097] Optionally, to simplify user operations, the second control in the business initiation interface can be set to disable screenshots from terminal B by default.

[0098] Optionally, the request message may also include the location information of the first target area, which is the area where terminal B is prohibited from taking screenshots.

[0099] S402, Terminal A sends an establishment request message to Terminal B.

[0100] Correspondingly, terminal B receives the establishment request message sent by terminal A.

[0101] S403. Terminal B sets the screenshot attribute information of the display window of the screen sharing service according to the first instruction information.

[0102] The display window for the screen sharing service can be found in [reference needed]. Figure 2 or Figure 3 The explanations in the text will not be repeated here.

[0103] Specifically, terminal B executes the screen sharing service based on the establishment request message, and terminal B sets the screenshot attribute information of the display window of the screen sharing service according to the first instruction information. At this time, the screenshot attribute information can instruct the display window to disable screenshots.

[0104] This embodiment does not limit the specific content of the screenshot attribute information. Optionally, the screenshot attribute information includes screenshot indication information, used to indicate whether the display window prohibits screenshots. For example, the screenshot indication information is 1 bit, where a value of 1 indicates that the display window prohibits screenshots, and a value of 0 indicates that the display window allows screenshots. As another example, the screenshot indication information is 2 bits, where a value of binary 11 indicates that the entire area of ​​the display window prohibits screenshots, a value of binary 10 indicates that a portion of the display window prohibits screenshots, and a value of binary 00 indicates that the display window allows screenshots.

[0105] S404. Terminal B sends a screen sharing service establishment response message to Terminal A.

[0106] Correspondingly, terminal A receives the establishment response message sent by terminal B.

[0107] S405. Terminal A displays the first control in the screen sharing service display window. The first control is used to set whether to prohibit Terminal B from taking screenshots, and the display status of the first control indicates that Terminal B is prohibited from taking screenshots.

[0108] Specifically, terminal A executes the screen sharing service based on the establishment response message. Furthermore, it displays a first control in the screen sharing service's display window. The current display status of this first control prompts the user that terminal B is prohibited from taking screenshots, facilitating subsequent user operations and improving the user experience.

[0109] In this embodiment, the implementation method of the first control is not limited. For example, it can be a button control or a switch control.

[0110] Optional, in one example, Figure 6 This is a schematic diagram of an interface of terminal A provided in an embodiment of this application. Figure 6 As shown in (a), the display window 61 of the screen sharing service on terminal A includes a first control 62, which is a button control. The display status of the first control 62 indicates that terminal B is prohibited from taking screenshots. Figure 6 As shown in (b), the display status of the first control 62 indicates whether terminal B is allowed to take a screenshot. Different display colors of the first control indicate whether terminal B is allowed to take a screenshot.

[0111] Optionally, in another example, Figure 7 This is another schematic diagram of the interface of terminal A provided in an embodiment of this application. For example... Figure 7As shown in (a), the display window 71 of the screen sharing service on terminal A includes a first control 72, which is a toggle control. The display status of the first control 72 indicates that terminal B is prohibited from taking screenshots. Figure 7 As shown in (b), the display state of the first control 72 indicates whether terminal B is allowed to take a screenshot. Different display states of the switch control indicate whether terminal B is allowed to take a screenshot.

[0112] As can be seen, the screenshot prevention method provided in this embodiment is applied to the scenario of initial establishment of a screen sharing service by a terminal. Terminal A sends a screen sharing service establishment request message to Terminal B, which carries first indication information instructing Terminal B to prohibit screenshots. After receiving the screen sharing service establishment request message, Terminal B sets the display window of the screen sharing service to prohibit screenshots according to the first indication information, thereby preventing screenshots and protecting privacy. The screenshot prevention method provided in this embodiment has a simple message flow, a small number of interaction messages, and high efficiency in preventing screenshots. Moreover, by displaying a first control in the display window of the screen sharing service, Terminal A prompts the user that screenshots by Terminal B are currently prohibited, facilitating subsequent user operations and improving the user experience.

[0113] Optionally, after S404, it may also include:

[0114] S406. Terminal B displays a preset icon in the display window of the screen sharing service. The preset icon is used to indicate that the display window should not be screenshotted.

[0115] The display window for the screen sharing service on terminal B can be found in [reference needed]. Figure 2 or Figure 3 The relevant explanations will not be repeated here.

[0116] By displaying a preset icon in a window on terminal B, the user is prompted that terminal B or the display window prohibits screenshots, thus avoiding subsequent invalid screenshot operations by the user and improving the user experience.

[0117] It should be noted that this embodiment does not limit the position of the preset icon in the display window on terminal B, nor the pattern of the preset icon. For example, Figure 8 This is a schematic diagram of an interface of terminal B provided in an embodiment of this application. Figure 8 As shown in (a), a preset icon 82 is displayed in window 81 on terminal B.

[0118] It should be noted that this embodiment does not limit the execution order of S406 and S405.

[0119] Optionally, the method for preventing screenshots provided in this embodiment may further include, after S405:

[0120] Terminal B receives the user's second screenshot.

[0121] Terminal B responds to the second screenshot operation by generating a prompt message. The prompt message indicates that screenshots are prohibited in the displayed window.

[0122] Terminal B outputs a prompt message.

[0123] For example, in combination Figure 12 Please provide an explanation. Figure 12 This is an illustration of another interface of terminal B after a user takes a screenshot of terminal B, as provided in an embodiment of this application. Figure 12 As shown in (a), terminal B currently displays the screen sharing service display window 1201, which includes a preset icon 1202, prompting the user to disable screenshots on terminal B. If the user performs a second screenshot operation, terminal B responds to the second screenshot operation as follows: Figure 12 As shown in (b), a prompt box 1203 pops up in the display window 1201. The prompt box 1203 displays the message "Screen recording is currently disabled". The user can click the close button 1204 to close the prompt box 1203.

[0124] As can be seen, in this implementation, screenshots are currently disabled on terminal B. When a user attempts to take a screenshot, terminal B generates a notification message prompting the user to disable screenshots on terminal B, thus improving the security of disabling screenshots on terminal B.

[0125] Optionally, the method for preventing screenshots provided in this embodiment may further include, after terminal A sends an establishment request message to terminal B in S402 and before terminal A receives the establishment response message sent by terminal B in S404:

[0126] Terminal A starts the first timer.

[0127] If the first timer expires, terminal A will resend the first notification message to terminal B.

[0128] Specifically, during communication, due to changes in the communication environment, terminal B may not receive the establishment request message sent by terminal A, or terminal A may not receive the establishment response message sent by terminal B. After terminal A sends the establishment request message to terminal B, terminal A starts a first timer. In this embodiment, the value of the first timer is not limited. If the first timer expires and terminal A does not receive the establishment response message sent by terminal B, it retransmits the establishment response message to terminal B to improve the success rate of service establishment. Optionally, the maximum number of retransmissions of the establishment response message from terminal A to terminal B can be set. In this embodiment, the specific value is not limited. If terminal A receives the establishment response message sent by terminal B before the first timer expires, the first timer is stopped, and step S405 is executed.

[0129] Optionally, the display window for screen sharing on terminal A may also include a region selection control. This control is used to select a second target region, which is the area where terminal B is prohibited from taking screenshots. Following S405, it may also include:

[0130] Terminal A receives the user's second operation on the region selection control.

[0131] Terminal A responds to the user's second operation on the region selection control by receiving the user's second region selection operation in the display window.

[0132] Terminal A responds to the second area selection operation, determines the second target area, and obtains the location information of the second target area.

[0133] Terminal A sends the location information of the second target area to Terminal B. Correspondingly, Terminal B receives the location information of the second target area sent by Terminal A.

[0134] Terminal B updates the screenshot attribute information based on the location information of the second target area.

[0135] The second target area can be found in [reference]. Figure 3 Explanation of regions 2121 and 2221.

[0136] For example, in combination Figure 9 Please provide an explanation. Figure 9 This is a schematic diagram illustrating an interface change in which a user selects a prohibited screenshot area in the display window of the screen sharing service on terminal A, as provided in an embodiment of this application. Figure 9 As shown in (a), the display window 91 of the screen sharing service on terminal A includes a region selection control 92. The user can click the region selection control 92 to select a second target region. Correspondingly, in response to the user's click on the region selection control 92, terminal A updates the display state of the region selection control 92, for example, by changing its color, and waits to receive a second region selection operation from the user to continue selecting a second target region. Figure 9 As shown in (b), the user slides from position X to position Y in display window 91 (i.e., the second region selection operation), selecting the second target region 93. Correspondingly, terminal A responds to the user's second region selection operation, determining position X and position Y to obtain the location information of the second target region. After determining the second target region, the terminal can update the display format of the region selection control 92, for example, by changing the display color, such as... Figure 9 As shown in (c), this allows the user to select the area where terminal B is prohibited from taking screenshots the next time.

[0137] Optionally, in one implementation, the location information of the second target area may include the coordinates of the vertices of the display window on terminal A and the coordinates of the vertices of the second target area. In this embodiment, the number of vertices is not limited.

[0138] Optionally, in another implementation, the location information of the second target area may include the coordinates of the vertices of the second target area in a relative coordinate system, which is a coordinate system with a vertex of the display window on terminal A as the origin and the two sides containing that vertex as the coordinate axes.

[0139] As can be seen, in this implementation, the user can select a second target area to prevent terminal B from taking screenshots. Terminal A sends the location information of the second target area to terminal B. Terminal B updates its screenshot attribute information based on the received location information. At this point, the screenshot attribute information indicates that terminal B is prohibited from taking screenshots and specifies the prohibited area. Based on the location information of the second target area, terminal B can determine the area corresponding to the second target area in the screen sharing service display window on terminal B. By allowing the user to select a second target area, the user can prevent terminal B from taking screenshots in a specific area, improving the flexibility and accuracy of screenshot prevention and enhancing the user experience.

[0140] Optionally, before terminal A determines the second target area, it may also include:

[0141] The confirmation and cancel buttons are displayed in the display window.

[0142] Receive user confirmation button input.

[0143] For example, in combination Figure 10 Please provide an explanation. Figure 10 (a) and Figure 9 (b) is the same. For example Figure 10 As shown in (a), the user performs a second region selection operation in window 91 on terminal A, and then, as... Figure 10 As shown in (b), a confirm button 94 and a cancel button 95 are displayed in window 91 on terminal A. The user can click the confirm button 94 to confirm the selection of the second target area 93. Alternatively, the user can click the cancel button 95 to reselect the second target area. When the user clicks the confirm button 94, terminal A responds to the user's action by confirming the second target area.

[0144] As can be seen, by displaying the confirm and cancel buttons, terminal A allows users to further confirm whether the selected target area is correct, improving the accuracy of the selection operation and ensuring that users can reselect the target area, thus enhancing the flexibility of the operation and improving the user experience.

[0145] Optionally, after receiving the user's selection operation in the second area of ​​the display window, terminal A may further include:

[0146] Terminal A displays the boundary of the second target area in the display window.

[0147] For example, in combination Figure 9 Please provide an explanation. For example... Figure 9 As shown in (c), after the user selects the second region in the display window 91, the boundary of the second target region 93 can be continuously displayed in the display window 91, thereby prompting the user to prohibit the terminal B from taking screenshots, so as to facilitate the user's subsequent operations, such as reselecting the second target region for the user's operation.

[0148] Optionally, after updating the screenshot attribute information based on the location information of the second target area, terminal B may further include:

[0149] Terminal B displays the boundary of the area corresponding to the second target area in the display window based on the location information of the second target area.

[0150] For example, in combination Figure 3 Please provide an explanation. For example... Figure 3 As shown in (a), assume the second target area is area 2121. Based on the received location information of the second target area, terminal B can determine that the area corresponding to area 2121 in display window 22 is area 2221. Terminal B can continuously display the boundary of area 2221 in display window 22.

[0151] As can be seen, by displaying the boundary of the area corresponding to the second target area in the display window, terminal B can prompt the user about the area where terminal B is prohibited from taking screenshots, thereby avoiding unnecessary screenshot operations by the user.

[0152] Optionally, after updating the screenshot attribute information based on the location information of the second target area, terminal B may further include:

[0153] Terminal B updates the preset icons in the display window. The updated preset icons are used to indicate that screenshots are not allowed in certain areas of the display window.

[0154] For example, in combination Figure 8 Please provide an explanation. For example... Figure 8 As shown in (a), the window 81 on terminal B includes a preset icon 82, used to indicate that terminal B is prohibited from taking screenshots. After terminal B updates the screenshot attribute information according to the location information of the second target area, as shown in (a), Figure 8 As shown in (b), the preset icon 82 is updated to the preset icon 83. The preset icon 83 is used to indicate that terminal B is prohibited from taking screenshots of a portion of the display window.

[0155] Optionally, after updating the screenshot attribute information based on the location information of the second target area, terminal B may further include:

[0156] Terminal B receives the user's first screenshot.

[0157] Terminal B responds to the first screenshot operation by taking a screenshot and generating a screenshot image based on the screenshot attribute information. The area in the screenshot image that corresponds to the second target area is a preset fill pattern.

[0158] For example, in combination Figure 11 Please provide an explanation. Figure 11 This is a schematic diagram of the interface of terminal B after a user takes a screenshot of terminal B, as provided in an embodiment of this application. Figure 11 As shown in (a), terminal B currently displays a screen sharing service display window 1101. Display window 1101 includes a preset icon 1102, prompting the user to prohibit terminal B from taking screenshots of certain areas within the display window. If the user performs a first screenshot operation, terminal B responds by determining that screenshotting is currently prohibited based on the screenshot attribute information of display window 1101, and terminal B can then take a screenshot and generate a screenshot image. However, the area in the screenshot image corresponding to the second target area is filled with a preset pattern. For example, as shown... Figure 11 As shown in (b) of the screenshot, area 1104 in the screenshot image 1103 is filled with shadow.

[0159] It should be noted that this embodiment does not limit the implementation method of the preset fill pattern.

[0160] As can be seen, in this implementation, screenshots by terminal B are currently prohibited. Even if the user takes a screenshot and terminal B generates a screenshot image, the area in the screenshot image that is prohibited from being screenshotted is filled with a preset fill pattern, protecting privacy and effectively preventing terminal B from taking screenshots, thus improving the security of preventing terminal B from taking screenshots.

[0161] Optionally, the method for preventing screenshots provided in this embodiment may further include, after S405:

[0162] Terminal A receives a second operation from the user on the first control. This second operation on the first control is used to set whether Terminal B is allowed to take screenshots.

[0163] In response to the user's second operation on the first control, terminal A generates a second notification message. The second notification message includes second instruction information, which instructs terminal B to take a screenshot.

[0164] Terminal A sends a second notification message to Terminal B. Correspondingly, Terminal B receives the second notification message sent by Terminal A.

[0165] Terminal B updates the screenshot attribute information of the display window of the screen sharing service according to the second instruction information.

[0166] Terminal B sends a second response message to terminal A. Correspondingly, terminal A receives the second response message sent by terminal B.

[0167] For example, in combination Figure 6 Please provide an explanation. For example... Figure 6 As shown in (a), the display window 61 on terminal A includes a first control 62. The display state of the first control 62 indicates that terminal B is prohibited from taking screenshots. The user can click the first control 62 to allow terminal B to take screenshots. Correspondingly, in response to the user clicking the first control 62, terminal A updates the display state of the first control 62, for example, by changing the display color. Figure 6 As shown in (b) above, Terminal A sends a second notification message to Terminal B. Correspondingly, Terminal B receives the second notification message sent by Terminal A. Terminal B updates its screenshot attribute information according to the second indication information in the second notification message. At this time, the screenshot attribute information indicates that Terminal B is allowed to take a screenshot.

[0168] In this implementation, users can set terminal B to allow screenshots, which improves the flexibility of operation.

[0169] Optionally, if terminal B displays a preset icon in the screen sharing service display window, then the display of the preset icon will be stopped.

[0170] By stopping the display of preset icons, the system prompts the user that screenshots are currently allowed on terminal B, facilitating subsequent user operations.

[0171] Optionally, after terminal A sends the second notification message to terminal B and before terminal A receives the second response message sent by terminal B, the process may further include:

[0172] Start the second timer.

[0173] If the second timer expires, the second notification message will be resent to terminal B.

[0174] The technical principle of the second timer is similar to that of the first timer mentioned above, and will not be repeated here.

[0175] Figure 13 This is another flowchart illustrating a method for preventing screenshots provided in this application. The executing entities in this embodiment include terminal A and terminal B, and it involves a scenario where terminal A and terminal B have already executed a screen sharing service and are sharing their screens. A first control is displayed in the screen sharing service display window on terminal A, and the display status of the first control indicates that terminal B is allowed to take a screenshot. For example... Figure 13 As shown, the method for preventing screenshots provided in this embodiment may include:

[0176] S1301. Terminal A receives the user's first operation on the first control. The first operation on the first control is used to set terminal B to be prohibited from taking screenshots.

[0177] S1302, Terminal A responds to the user's first operation on the first control and generates a first notification message. The first notification message includes first instruction information, which is used to instruct Terminal B to prohibit screenshotting.

[0178] S1303, Terminal A sends a first notification message to Terminal B. Correspondingly, Terminal B receives the first notification message sent by Terminal A.

[0179] S1304. Terminal B sets the screenshot attribute information of the display window of the screen sharing service according to the first instruction information.

[0180] S1305, Terminal B sends a first response message to Terminal A. Correspondingly, Terminal A receives the first response message sent by Terminal B.

[0181] S1306. Terminal A displays a first control in the display window of the screen sharing service. The first control is used to set whether to prohibit Terminal B from taking screenshots. The display status of the first control indicates that Terminal B is prohibited from taking screenshots.

[0182] The following is combined Figure 14 An example is provided. Figure 14 As shown in (a), the display window 1401 for screen sharing on terminal A includes a first control 1402, which is a button control. The display state of the first control 1402 indicates whether terminal B is allowed to take a screenshot. The user can click the first control 1402 to disable screenshots on terminal B. Correspondingly, in response to the user clicking the first control 1402, terminal A updates the display state of the first control 1402, for example, by adjusting the display color. Figure 14 As shown in (b) above, Terminal A sends a first notification message to Terminal B. Correspondingly, Terminal B receives the first notification message from Terminal A. Terminal B sets the screenshot attribute information of the display window for the screen sharing service on Terminal B according to the first instruction information in the first notification message. At this time, the screenshot attribute information indicates that Terminal B is prohibited from taking screenshots.

[0183] As can be seen, in the screenshot prevention method provided in this embodiment, the terminal has already executed the screen sharing service and is currently sharing the screen. User operation triggers terminal A to send a first notification message to terminal B, which carries first instruction information instructing terminal B to prohibit screenshots. After receiving the first notification message, terminal B sets the display window of the screen sharing service to prohibit screenshots according to the first instruction information, thereby preventing screenshots and protecting privacy. The screenshot prevention method provided in this embodiment has a simple message flow, a small number of interaction messages, and high efficiency in preventing screenshots. Moreover, terminal A displays a first control in the display window of the screen sharing service to prompt the user that screenshots by terminal B are currently prohibited, facilitating subsequent user operations and improving the user experience.

[0184] Optionally, the method for preventing screenshots provided in this embodiment may further include, after step S1305:

[0185] S1307. Terminal B displays a preset icon in the display window. The preset icon is used to indicate that the display window should not be screenshotted.

[0186] S1307 can be found here. Figure 4 The relevant description of S406 in the illustrated embodiment will not be repeated here.

[0187] Optionally, in the method for preventing screenshots provided in this embodiment, the display window on terminal A may also include a preset icon, which is used to indicate that the display window is prohibited from taking screenshots.

[0188] The preset icons can be found here. Figure 4 The descriptions of the preset icons in the illustrated embodiments will not be repeated here.

[0189] Optionally, after terminal A sends the first notification message to terminal B in S1303, and before terminal A receives the first response message sent by terminal B in S1305, the following steps are also included:

[0190] Terminal A starts the first timer.

[0191] If the first timer expires, terminal A will resend the first notification message to terminal B.

[0192] The first timer can be referred to in the relevant description of the first timer in the aforementioned embodiment, and the principle is similar, so it will not be repeated here.

[0193] Optionally, the first notification message may also include location information of the first target area, where the first target area is the area where terminal B is prohibited from taking screenshots. Correspondingly, in S1304, terminal B sets the screenshot attribute information of the display window of the screen sharing service according to the first instruction information, which may include:

[0194] Terminal B sets the screenshot attribute information of the display window of the screen sharing service according to the first instruction information and the location information of the first target area.

[0195] Optionally, the window displayed on terminal A may further include a region selection control, which is used to select a first target region. The method for preventing screenshots provided in this embodiment may further include:

[0196] Terminal A receives the user's first operation on the region selection control.

[0197] Terminal A responds to the user's first operation on the area selection control by receiving the user's first area selection operation in the display window.

[0198] Terminal A responds to the first area selection operation, determines the first target area, and obtains the location information of the first target area.

[0199] Optionally, before terminal A determines the first target area, it may also include:

[0200] Terminal A displays an OK button and a Cancel button in the display window.

[0201] Terminal A receives the user's confirmation button input.

[0202] Optionally, after receiving the user's selection operation in the first area of ​​the display window, terminal A may further include:

[0203] Terminal A displays the boundary of the first target area in the display window.

[0204] Optionally, the method for preventing screenshots provided in this embodiment may further include:

[0205] Terminal B displays the boundary of the area corresponding to the first target area in the display window based on the location information of the first target area.

[0206] The region selection control can be found in the description of the region selection control in the aforementioned embodiments; the first target region, the user's first operation on the region selection control, the first region selection operation, and the location information of the first target region can be found in the descriptions of the second target region, the user's second operation on the region selection control, the second region selection operation, and the location information of the second target region in the aforementioned embodiments. The principles and effects are similar, and will not be repeated here.

[0207] Optionally, the window displayed on terminal A further includes a region selection control, which is used to select a second target region, the second target region being the area where terminal B is prohibited from taking screenshots. The method for preventing screenshots provided in this embodiment may also include:

[0208] Terminal A receives the user's second operation on the region selection control.

[0209] Terminal A responds to the user's second operation on the region selection control by receiving the user's second region selection operation in the display window.

[0210] Terminal A responds to the second area selection operation, determines the second target area, and obtains the location information of the second target area.

[0211] Terminal A sends the location information of the second target area to Terminal B. Correspondingly, Terminal B receives the location information of the second target area sent by Terminal A.

[0212] Terminal B updates the screenshot attribute information based on the location information of the second target area.

[0213] The region selection control can be found in the description of the region selection control in the aforementioned embodiments; the second target region, the user's second operation on the region selection control, the second region selection operation, and the location information of the second target region can be found in the descriptions of the second target region, the user's second operation on the region selection control, the second region selection operation, and the location information of the second target region in the aforementioned embodiments. The principles and effects are similar, and will not be repeated here.

[0214] Optionally, the method for preventing screenshots provided in this embodiment may further include:

[0215] Terminal B receives the user's first screenshot.

[0216] Terminal B responds to the first screenshot operation by taking a screenshot and generating a screenshot image based on the screenshot attribute information. The area in the screenshot image corresponding to the first target area is a preset fill pattern.

[0217] Optionally, the method for preventing screenshots provided in this embodiment may further include:

[0218] Terminal B receives the user's second screenshot.

[0219] Terminal B responds to the second screenshot operation by generating a prompt message. The prompt message indicates that screenshots are prohibited in the displayed window.

[0220] Terminal B outputs a prompt message.

[0221] The first and second screenshot operations can be found in the descriptions of the first and second screenshot operations in the foregoing embodiments. The principles and effects are similar, and will not be repeated here.

[0222] Optionally, the method for preventing screenshots provided in this embodiment may further include:

[0223] Terminal A receives a second operation from the user on the first control. This second operation on the first control is used to set whether Terminal B is allowed to take screenshots.

[0224] In response to the user's second operation on the first control, terminal A generates a second notification message. The second notification message includes second instruction information, which instructs terminal B to take a screenshot.

[0225] Terminal A sends a second notification message to Terminal B. Correspondingly, Terminal B receives the second notification message sent by Terminal A.

[0226] Terminal B updates the screenshot attribute information of the display window of the screen sharing service according to the second instruction information.

[0227] Terminal B sends a second response message to terminal A. Correspondingly, terminal A receives the second response message sent by terminal B.

[0228] Optionally, after terminal A sends the second notification message to terminal B and before terminal A receives the second response message sent by terminal B, the process further includes:

[0229] Terminal A starts the second timer.

[0230] If the second timer expires, terminal A will resend the second notification message to terminal B.

[0231] The user's second operation on the first control, the second notification message, and the second timer can be found in the descriptions of these aspects in the foregoing embodiments. The principles and effects are similar and will not be repeated here.

[0232] It is understood that, in order to achieve the above functions, the terminal includes hardware and / or software modules corresponding to the execution of each function. Based on the algorithm steps of the examples described in the embodiments disclosed herein, this application can be implemented in hardware or a combination of hardware and computer software. Whether a function is executed in hardware or by computer software driving hardware depends on the specific application and design constraints of the technical solution. Those skilled in the art can use different methods to implement the described functions for each specific application in conjunction with the embodiments, but such implementation should not be considered beyond the scope of this application.

[0233] This application embodiment can divide the terminal into functional modules according to the above method example. For example, each function can be divided into its own functional module, or two or more functions can be integrated into one module. It should be noted that the module division in this application embodiment is illustrative and only represents one logical functional division. In actual implementation, there may be other division methods. It should also be noted that the module names in this application embodiment are illustrative and are not limited in actual implementation.

[0234] For example, Figure 15 This is a schematic diagram of a terminal provided in an embodiment of this application. The terminal provided in this embodiment can be terminal A or terminal B in the method embodiments of this application. Figure 15 As shown, the terminal provided in this embodiment may include: a receiving module 1501, a processing module 1502, and a sending module 1503.

[0235] When the terminal is designated as terminal A, terminal A and terminal B perform screen sharing services. Terminal A may include:

[0236] Processing module 1502 is used to generate a first notification message, the first notification message including first indication information, the first indication information being used to indicate that the second terminal device is prohibited from taking screenshots;

[0237] Sending module 1503 is used to send the first notification message to the second terminal device;

[0238] The receiving module 1501 is used to receive the first response message sent by the second terminal device;

[0239] The processing module 1502 is further configured to display a first control in the display window of the screen sharing service, the first control being configured to set whether to prohibit the second terminal device from taking screenshots, and the display status of the first control indicating that the second terminal device is prohibited from taking screenshots.

[0240] Optionally, the first notification message may also include location information of a first target area, which is an area where the second terminal device is prohibited from taking screenshots.

[0241] Optionally, the first notification message is the establishment request message for the screen sharing service, and the first response message is the establishment response message for the screen sharing service.

[0242] Optionally, the processing module 1502 is specifically used for:

[0243] The screen sharing service initiation interface is displayed; the service initiation interface includes a second control, which is used to set whether to prohibit the second terminal device from taking screenshots;

[0244] The control receiving module 1501 receives the user's target operation on the second control, the target operation being used to set the second terminal device to prevent screenshots;

[0245] In response to the target operation, the first notification message is generated.

[0246] Optionally, the processing module 1502 is further configured to determine that the screen sharing service is a preset service before generating the first notification message.

[0247] Optionally, when the first terminal device and the second terminal device are sharing a screen, before the first notification message is generated, the display status of the first control in the display window indicates that the second terminal device is allowed to take a screenshot;

[0248] The receiving module 1501 is also used to receive a first operation by the user on the first control, wherein the first operation on the first control is used to set the second terminal device to prevent screenshots.

[0249] The processing module 1502 is specifically used to generate the first notification message in response to the user's first operation on the first control.

[0250] Optionally, the first terminal device and the second terminal device are sharing a screen, and the display window further includes a region selection control, which is used to select the first target region;

[0251] The receiving module 1501 is also used to receive the user's first operation on the area selection control;

[0252] The processing module 1502 is further configured to, in response to the user's first operation on the region selection control, control the receiving module 1501 to receive the user's first region selection operation in the display window; in response to the first region selection operation, determine the first target region and obtain the location information of the first target region.

[0253] Optionally, the processing module 1502 is further configured to display a confirmation button and a cancel button in the display window before determining the first target area;

[0254] The receiving module 1501 is also used to receive the user's operation on the confirmation button.

[0255] Optionally, the processing module 1502 is also configured to display the boundary of the first target area in the display window.

[0256] Optionally, the display window further includes a region selection control, which is used to select a second target region, the second target region being the region where the second terminal device is prohibited from taking screenshots;

[0257] The receiving module 1501 is also used to receive a second operation by the user on the area selection control;

[0258] The processing module 1502 is further configured to, in response to the user's second operation on the region selection control, control the receiving module 1501 to receive the user's second region selection operation in the display window; in response to the second region selection operation, determine the second target region and obtain the location information of the second target region;

[0259] The sending module 1503 is also used to send the location information of the second target area to the second terminal device.

[0260] Optionally, the processing module 1502 is further configured to start a first timer after the sending module 1503 sends the first notification message to the second terminal device and before the receiving module 1501 receives the first response message sent by the second terminal device;

[0261] If the first timer times out, the sending module 1503 is also used to resend the first notification message to the second terminal device.

[0262] Optionally, the receiving module 1501 is further configured to receive a second operation by the user on the first control, wherein the second operation on the first control is configured to allow the second terminal device to take a screenshot;

[0263] The processing module 1502 is further configured to generate a second notification message in response to the user's second operation on the first control; the second notification message includes second indication information, which is used to indicate that the second terminal device is allowed to take a screenshot;

[0264] The sending module 1503 is also used to send the second notification message to the second terminal device;

[0265] The receiving module 1501 is also used to receive a second response message sent by the second terminal device.

[0266] Optionally, the processing module 1502 is further configured to start a second timer after the sending module 1503 sends the second notification message to the second terminal device and before the receiving module 1501 receives the second response message sent by the second terminal device;

[0267] If the second timer times out, the sending module 1503 is also used to resend the second notification message to the second terminal device.

[0268] Optionally, the display window may also include a preset icon, which is used to indicate that the display window should not be used for screenshots.

[0269] When the terminal is designated as terminal B, terminal B performs screen sharing services with terminal A. Terminal B may include:

[0270] The receiving module 1501 is configured to receive a first notification message sent by the first terminal device, the first notification message including first indication information, the first indication information being used to indicate that the second terminal device is prohibited from taking screenshots;

[0271] Processing module 1502 is used to set the screenshot attribute information of the display window of the screen sharing service according to the first indication information;

[0272] The sending module 1503 is used to send a first response message to the first terminal device.

[0273] Optionally, the processing module 1502 is further configured to display a preset icon in the display window, the preset icon being used to indicate that the display window is not allowed to take screenshots.

[0274] Optionally, the first notification message may also include location information of the first target area, which is an area where the second terminal device is prohibited from taking screenshots;

[0275] Processing module 1502 is specifically used for:

[0276] The screenshot attribute information is set according to the first instruction information and the location information of the first target area.

[0277] Optionally, the processing module 1502 is further configured to display the boundary of the region corresponding to the first target region in the display window according to the location information of the first target region.

[0278] Optionally, the receiving module 1501 is also used to receive the user's first screenshot operation;

[0279] The processing module 1502 is further configured to respond to the first screenshot operation by taking a screenshot and generating a screenshot image based on the screenshot attribute information, wherein the area in the screenshot image corresponding to the first target area is a preset fill pattern.

[0280] Optionally, the receiving module 1501 is also used to receive the user's second screenshot operation;

[0281] The processing module 1502 is further configured to respond to the second screenshot operation by generating a prompt message; the prompt message is used to instruct the display window to disable screenshots; and output the prompt message.

[0282] Optionally, the first notification message is the establishment request message for the screen sharing service, and the first response message is the establishment response message for the screen sharing service.

[0283] Optionally, the receiving module 1501 is further configured to receive the location information of the second target area sent by the first terminal device, wherein the second target area is an area where the second terminal device is prohibited from taking screenshots;

[0284] The processing module 1502 is also used to update the screenshot attribute information according to the location information of the second target area.

[0285] Optionally, the receiving module 1501 is further configured to receive a second notification message sent by the first terminal device, the second notification message including second indication information, the second indication information being used to indicate that the second terminal device is allowed to take a screenshot;

[0286] The processing module 1502 is further configured to update the screenshot attribute information of the display window of the screen sharing service according to the second instruction information;

[0287] The sending module 1503 is also used to send a second response message to the first terminal device.

[0288] Please refer to Figure 16 This illustration shows another structure of the terminal device provided in the embodiments of this application. The terminal device can be terminal A or terminal B in the embodiments of this application. The terminal device includes: a processor 1601, a receiver 1602, a transmitter 1603, a memory 1604, and a bus 1605. The processor 1601 includes one or more processing cores. The processor 1601 executes various application and information processing functions by running software programs and modules. The receiver 1602 and the transmitter 1603 can be implemented as a communication component, which can be a baseband chip. The memory 1604 is connected to the processor 1601 via the bus 1605. The memory 1604 can be used to store at least one program instruction, and the processor 1601 is used to execute at least one program instruction to implement the technical solution of the above embodiments. Its implementation principle and technical effects are similar to those of the related embodiments of the above methods, and will not be repeated here.

[0289] When the terminal is powered on, the processor can read the software program from the memory, interpret and execute the instructions of the software program, and process the data of the software program. When data needs to be transmitted via the antenna, the processor performs baseband processing on the data to be transmitted and outputs the baseband signal to the control circuit in the control circuit. The control circuit performs radio frequency processing on the baseband signal and transmits the radio frequency signal outward in the form of electromagnetic waves through the antenna. When data is sent to the terminal, the control circuit receives the radio frequency signal through the antenna, converts the radio frequency signal into a baseband signal, and outputs the baseband signal to the processor. The processor converts the baseband signal into data and processes the data.

[0290] Those skilled in the art will understand that, for ease of explanation, Figure 16 Only one memory and processor are shown. In a real terminal, multiple processors and memories may exist. Memory can also be called storage medium or storage device, etc., and this application embodiment does not limit this.

[0291] As an optional implementation, the processor may include a baseband processor and a central processing unit (CPU). The baseband processor is mainly used for processing communication data, while the CPU is mainly used for executing software programs and processing the data of those programs. Those skilled in the art will understand that the baseband processor and CPU can be integrated into a single processor or they can be separate processors interconnected via technologies such as buses. Those skilled in the art will understand that a terminal may include multiple baseband processors to adapt to different network standards, and a terminal may include multiple CPUs to enhance its processing capabilities. The various components of the terminal can be connected via various buses. The baseband processor can also be described as a baseband processing circuit or a baseband processing chip. The CPU can also be described as a central processing circuit or a central processing chip. The function of processing communication protocols and communication data can be built into the processor or stored in memory as software programs, with the processor executing the software programs to implement the baseband processing function. The memory can be integrated into the processor or located independently outside the processor. The memory includes a cache, which can store frequently accessed data / instructions.

[0292] In the embodiments of this application, the processor may be a general-purpose processor, a digital signal processor, an application-specific integrated circuit (ASIC), a field-programmable gate array (FPGA), or other programmable logic devices, discrete gate or transistor logic devices, or discrete hardware components, capable of implementing or executing the methods, steps, and logic block diagrams disclosed in the embodiments of this application. The general-purpose processor may be a microprocessor or any conventional processor. The steps of the methods disclosed in the embodiments of this application can be directly manifested as being executed by a hardware processor, or executed by a combination of hardware and software modules within the processor.

[0293] In the embodiments of this application, the memory can be non-volatile memory, such as a hard disk drive (HDD) or a solid-state drive (SS), or it can be volatile memory, such as random-access memory (RAM). Memory is any other medium capable of carrying or storing desired program code in the form of instructions or data structures and accessible by a computer, and is not limited thereto.

[0294] The memory in the embodiments of this application can also be a circuit or any other device capable of performing storage functions, used to store program instructions and / or data. The methods provided in the various embodiments of this application can be implemented entirely or partially through software, hardware, firmware, or any combination thereof. When implemented in software, it can be implemented entirely or partially in the form of a computer program product. The computer program product includes one or more computer instructions. When the computer program instructions are loaded and executed on a computer, all or part of the processes or functions described in the embodiments of this application are generated. The computer can be a general-purpose computer, a special-purpose computer, a computer network, network equipment, user equipment, or other programmable device. The computer instructions can be stored in a computer-readable storage medium or transmitted from one computer-readable storage medium to another. For example, the computer instructions can be transmitted from one website, computer, server, or data center to another via wired (e.g., coaxial cable, fiber optic, digital subscriber line (DSL)) or wireless (e.g., infrared, wireless, microwave, etc.) means. The computer-readable storage medium can be any available medium that a computer can access or a data storage device such as a server or data center that integrates one or more available media. The available medium can be magnetic media (e.g., floppy disk, hard disk, magnetic tape), optical media (e.g., digital video disc (DWD), or semiconductor media (e.g., SSD), etc.

[0295] This application provides a computer program product that, when run on a terminal, causes the terminal to execute the technical solutions described in the above embodiments. Its implementation principle and technical effects are similar to the related embodiments described above, and will not be repeated here.

[0296] This application provides a computer-readable storage medium storing program instructions. When these program instructions are executed by a terminal, the terminal performs the technical solutions described in the above embodiments. The implementation principle and technical effects are similar to those of the related embodiments described above, and will not be repeated here. In summary, the above embodiments are only used to illustrate the technical solutions of this application, and not to limit them. Although this application has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some of the technical features; and these modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the scope of the technical solutions of the embodiments of this application.

Claims

1. A method for preventing screenshots, characterized in that, The method, applied to a first terminal device, wherein the first terminal device and a second terminal device perform a screen sharing service, includes: A first notification message is generated, the first notification message including first instruction information, the first instruction information being used to instruct the second terminal device to prohibit screenshots; the first notification message also includes location information of a first target area; the first target area is the area where screenshots are prohibited on the second terminal device; The first notification message is sent to the second terminal device; wherein, the second terminal device sets the screenshot attribute information of the display window of the screen sharing service according to the first instruction information and the location information of the first target area; Receive the first response message sent by the second terminal device; A first control is displayed in the display window of the screen sharing service. The first control is used to set whether to prohibit the second terminal device from taking screenshots. The display status of the first control indicates that the second terminal device is prohibited from taking screenshots. The first terminal device and the second terminal device are sharing a screen. The display window further includes a region selection control for selecting a first target region. Before generating the first notification message, the method further includes: Receive the user's first operation on the area selection control; In response to the user's first operation on the region selection control, receive the user's first region selection operation in the display window; In response to the first region selection operation, the first target region is determined, and the location information of the first target region is obtained.

2. The method according to claim 1, characterized in that, The first notification message is the establishment request message for the screen sharing service, and the first response message is the establishment response message for the screen sharing service.

3. The method according to claim 2, characterized in that, The generation of the first notification message includes: The screen sharing service initiation interface is displayed; the service initiation interface includes a second control, which is used to set whether to prohibit the second terminal device from taking screenshots; Receive a user's target operation on the second control, the target operation being used to set the second terminal device to prevent screenshots; In response to the target operation, the first notification message is generated.

4. The method according to claim 2, characterized in that, Before generating the first notification message, the process also includes: The screen sharing service is determined to be a preset service.

5. The method according to claim 1, characterized in that, The first terminal device and the second terminal device are sharing a screen. Before the first notification message is generated, the display status of the first control in the display window indicates that the second terminal device is allowed to take a screenshot. The generation of the first notification message includes: Receive a first operation from the user on the first control, wherein the first operation on the first control is used to set the second terminal device to prevent screenshots; In response to the user's first operation on the first control, the first notification message is generated.

6. The method according to claim 1, characterized in that, Before determining the first target region, the method further includes: The display window shows a confirm button and a cancel button; Receive the user's operation on the confirmation button.

7. The method according to claim 5, characterized in that, After receiving the user's selection operation in the first area of ​​the display window, the method further includes: The boundary of the first target area is displayed in the display window.

8. The method according to any one of claims 1-7, characterized in that, The display window also includes a region selection control, which is used to select a second target region, the second target region being the region where the second terminal device is prohibited from taking screenshots; The method further includes: Receive a second operation from the user on the region selection control; In response to the user's second operation on the region selection control, receive the user's second region selection operation in the display window; In response to the second region selection operation, the second target region is determined, and the location information of the second target region is obtained; The location information of the second target area is sent to the second terminal device; the second terminal device updates the screenshot attribute information based on the location information of the second target area.

9. The method according to any one of claims 1-7, characterized in that, After sending the first notification message to the second terminal device and before receiving the first response message sent by the second terminal device, the method further includes: Start the first timer; If the first timer times out, the first notification message is resent to the second terminal device.

10. The method according to any one of claims 1-7, characterized in that, Also includes: Receive a second operation from the user on the first control, wherein the second operation on the first control is used to set the second terminal device to take a screenshot; In response to the user's second operation on the first control, a second notification message is generated; the second notification message includes second indication information, which is used to indicate that the second terminal device is allowed to take a screenshot. Send the second notification message to the second terminal device; Receive the second response message sent by the second terminal device.

11. The method according to claim 10, characterized in that, After sending the second notification message to the second terminal device and before receiving the second response message sent by the second terminal device, the method further includes: Start the second timer; If the second timer times out, the second notification message is resent to the second terminal device.

12. The method according to any one of claims 1, 5-7, characterized in that, The display window also includes a preset icon, which is used to indicate that the display window should not be screenshotted.

13. A method for preventing screenshots, characterized in that, The method, applied to a second terminal device that performs a screen-sharing service with a first terminal device, includes: The system receives a first notification message sent by the first terminal device. The first notification message includes first indication information, which is used to instruct the second terminal device to prohibit screenshots. The first notification message is generated by the first terminal and also includes location information of a first target area. The first target area is the area where screenshots are prohibited by the second terminal device. Set the screenshot attribute information of the display window of the screen sharing service according to the first instruction information and the location information of the first target area; Send a first response message to the first terminal device; The first terminal device and the second terminal device are sharing a screen. The display window further includes a region selection control, which is used to select a first target region. Before the first terminal generates a first notification message, selecting the first target region includes: the first terminal device receiving a first operation from the user on the region selection control; the first terminal device responding to the user's first operation on the region selection control by receiving the user's first region selection operation in the display window; and the first terminal device responding to the first region selection operation by determining the first target region and obtaining the location information of the first target region.

14. The method according to claim 13, characterized in that, Also includes: A preset icon is displayed in the display window to indicate that screenshots are not allowed.

15. The method according to claim 13, characterized in that, Also includes: The boundary of the region corresponding to the first target region is displayed in the display window based on the location information of the first target region.

16. The method according to claim 15, characterized in that, Also includes: Receive the user's first screenshot action; In response to the first screenshot operation, a screenshot image is generated based on the screenshot attribute information, wherein the area in the screenshot image corresponding to the first target area is a preset fill pattern.

17. The method according to any one of claims 13-15, characterized in that, Also includes: Receive the user's second screenshot request; In response to the second screenshot operation, a prompt message is generated; The prompt message is used to instruct the display window to disable screenshots; Output the aforementioned prompt message.

18. The method according to any one of claims 13-16, characterized in that, The first notification message is the establishment request message for the screen sharing service, and the first response message is the establishment response message for the screen sharing service.

19. The method according to any one of claims 13-16, characterized in that, Also includes: Receive the location information of the second target area sent by the first terminal device, wherein the second target area is an area where the second terminal device is prohibited from taking screenshots; The screenshot attribute information is updated based on the location information of the second target area.

20. The method according to any one of claims 13-16, characterized in that, Also includes: Receive a second notification message sent by the first terminal device, the second notification message including second indication information, the second indication information being used to indicate that the second terminal device is allowed to take a screenshot; Update the screenshot attribute information of the display window of the screen sharing service according to the second instruction information; Send a second response message to the first terminal device.

21. A terminal device, characterized in that, The terminal device includes a processor configured to be coupled to a memory, and to read instructions from the memory and, according to the instructions, cause the terminal device to perform the method as described in any one of claims 1-12, or the method as described in any one of claims 13-20.

22. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores computer instructions that, when executed on an electronic device, cause the electronic device to perform the method as described in any one of claims 1-12, or the method as described in any one of claims 13-20.

23. A computer program product containing instructions, characterized in that, When the computer program product is run on a terminal, it causes the terminal to perform the method as described in any one of claims 1-12, or the method as described in any one of claims 13-20.