Search

CN-122027740-A - Prompting method, electronic device, readable storage medium and program product

CN122027740ACN 122027740 ACN122027740 ACN 122027740ACN-122027740-A

Abstract

The application provides a prompting method, electronic equipment, a readable storage medium and a program product, wherein the electronic equipment comprises a detection sensor, one or more processors, one or more memories and one or more programs, the detection sensor comprises an inertial sensor and/or a touch sensor, the one or more memories are used for storing the one or more programs, the electronic equipment is enabled to realize that whether a first operation exists or not is detected according to measurement data of the detection sensor, the first operation is an operation with risk of damaging a display screen and/or a frame of the electronic equipment, and in case of detecting the first operation, first prompting information is output and is used for prompting to stop executing the first operation. In the application, under the condition that the first operation is detected, the electronic equipment can output the first prompt information, so that the damage of the electronic equipment by a user can be avoided, and the service life of the electronic equipment and the use experience of the user are improved.

Inventors

  • LU HENGHUI
  • HE YIFAN
  • CHEN QIFAN
  • CAI WEIGANG

Assignees

  • 华为技术有限公司

Dates

Publication Date
20260512
Application Date
20251020

Claims (20)

  1. 1. An electronic device, comprising: A detection sensor including an inertial sensor and/or a touch sensor; one or more processors; one or more memories; The one or more memories store one or more programs that, when executed by the one or more processors, cause the electronic device to implement: detecting whether a first operation exists according to the measurement data of the detection sensor, wherein the first operation is an operation with risk of damaging a display screen and/or a frame of the electronic equipment; And under the condition that the first operation is detected, outputting first prompt information, wherein the first prompt information is used for prompting to stop executing the first operation.
  2. 2. The electronic device of claim 1, wherein the display screen of the electronic device includes a trigger hot zone that, when executed by the one or more processors, causes the electronic device to implement: And in response to detecting that the number of times the user slides in the trigger hot zone is greater than or equal to a first threshold value within a first preset duration, entering a mode of detecting the first operation.
  3. 3. The electronic device of claim 1 or 2, wherein the detection sensor comprises an inertial sensor and a touch sensor, which when executed by the one or more processors, cause the electronic device to implement: Acquiring touch measurement data acquired by the touch sensor and inertial measurement data acquired by the inertial sensor in N time periods; Outputting the first prompt information when the first operation exists in M time periods in the N time periods, wherein N is an integer greater than or equal to 1, and M is an integer greater than or equal to a second threshold and less than or equal to N.
  4. 4. The electronic device of claim 3, wherein the one or more programs, when executed by the one or more processors, cause the electronic device to implement: Determining a first detection result of each time period according to the inertia measurement data of each time period in the N time periods; Determining a second detection result of each time period according to the touch measurement data of each time period; and detecting whether the first operation exists in each time period according to the first detection result and the second detection result.
  5. 5. The electronic device of claim 4, wherein the M time periods comprise a first time period, a display screen of the electronic device comprising a trigger hot zone that, when executed by the one or more processors, causes the electronic device to implement: Determining that the first operation is detected in the first time period if the first detection result of the first time period indicates that the first operation is present and the second detection result of the first time period indicates that the trigger hot zone is touched.
  6. 6. The electronic device of any of claims 3-5, wherein there is a partially overlapping time interval for any two adjacent time periods of the N time periods.
  7. 7. The electronic device of claim 1 or 2, wherein the detection sensor comprises an inertial sensor that, when executed by the one or more processors, causes the electronic device to implement: Acquiring inertial measurement data acquired by the inertial sensor in T time periods; And outputting the first prompt information under the condition that K time periods in the T time periods exist in the first operation, wherein T is an integer greater than or equal to 1, and K is an integer greater than or equal to a third threshold and less than or equal to T.
  8. 8. The electronic device of claim 1 or 2, wherein the detection sensor comprises a touch sensor that, when executed by the one or more processors, causes the electronic device to implement: acquiring touch measurement data acquired by the touch sensors in P time periods; And outputting the first prompt information when the first operation exists in Q time periods in the P time periods, wherein P is an integer greater than or equal to 1, and Q is an integer greater than or equal to a fourth threshold and less than or equal to P.
  9. 9. The electronic device of any one of claims 1-8, wherein the one or more programs, when executed by the one or more processors, cause the electronic device to implement: and responding to the detection that the user starts the operation of the damage operation detection function on the setting interface, and entering a damage operation detection mode.
  10. 10. A method of prompting, the method being applied to an electronic device, the method comprising: Detecting whether a first operation exists according to measurement data of a detection sensor, wherein the first operation is an operation with risk of damaging a display screen and/or a frame of the electronic equipment, and the detection sensor comprises an inertial sensor and/or a touch sensor; And under the condition that the first operation is detected, outputting first prompt information, wherein the first prompt information is used for prompting to stop executing the first operation.
  11. 11. The method of claim 10, wherein the display screen of the electronic device includes a trigger hot zone, the method further comprising, prior to detecting the presence of the first operation based on the measurement data of the detection sensor: And in response to detecting that the number of times the user slides in the trigger hot zone is greater than or equal to a first threshold value within a first preset duration, entering a mode of detecting the first operation.
  12. 12. The method according to claim 10 or 11, wherein detecting whether the first operation is present or not based on the measurement data of the detection sensor comprises: Acquiring touch measurement data acquired by the touch sensor and inertial measurement data acquired by the inertial sensor in N time periods; And under the condition that the first operation is detected, outputting first prompt information, wherein the first prompt information comprises: Outputting the first prompt information when the first operation exists in M time periods in the N time periods, wherein N is an integer greater than or equal to 1, and M is an integer greater than or equal to a second threshold and less than or equal to N.
  13. 13. The method of claim 12, wherein prior to outputting the first prompt, the method further comprises: Determining a first detection result of each time period according to the inertia measurement data of each time period in the N time periods; Determining a second detection result of each time period according to the touch measurement data of each time period; and detecting whether the first operation exists in each time period according to the first detection result and the second detection result.
  14. 14. The method of claim 13, wherein the M time periods comprise a first time period, wherein the display screen of the electronic device comprises a trigger hot zone, wherein detecting whether the first operation is present for each time period based on the first detection result and the second detection result comprises: and determining that the first operation is detected in the first time period when the first detection result of the first time period indicates that the first operation exists and the second detection result of the first time period indicates that the trigger hot zone is touched.
  15. 15. The method according to any one of claims 12 to 14, wherein there is a partially overlapping time interval for any two adjacent time periods of the N time periods.
  16. 16. The method according to claim 10 or 11, wherein detecting whether the first operation is present or not based on the measurement data of the detection sensor comprises: Acquiring inertial measurement data acquired by the inertial sensor in T time periods; And under the condition that the first operation is detected, outputting first prompt information, wherein the first prompt information comprises: And outputting the first prompt information under the condition that K time periods in the T time periods exist in the first operation, wherein T is an integer greater than or equal to 1, and K is an integer greater than or equal to a third threshold and less than or equal to T.
  17. 17. The method according to claim 10 or 11, wherein detecting whether the first operation is present or not based on the measurement data of the detection sensor comprises: acquiring touch measurement data acquired by the touch sensors in P time periods; And under the condition that the first operation is detected, outputting first prompt information, wherein the first prompt information comprises: And outputting the first prompt information when the first operation exists in Q time periods in the P time periods, wherein P is an integer greater than or equal to 1, and Q is an integer greater than or equal to a fourth threshold and less than or equal to P.
  18. 18. The method of claim 11, wherein before entering the mode of detecting the first operation in response to detecting that a number of user swipes in the trigger hotzone is greater than or equal to a first threshold within a first preset time period, the method further comprises: and responding to the detection that the user starts the operation of the damage operation detection function on the setting interface, and entering a damage operation detection mode.
  19. 19. A computer readable storage medium having instructions stored thereon which, when run on an electronic device, cause the method of any of claims 10 to 18 to be performed.
  20. 20. A program product comprising program code which, when run on an electronic device, causes the method of any of claims 10 to 18 to be performed.

Description

Prompting method, electronic device, readable storage medium and program product Technical Field The present application relates to the field of electronics, and in particular, to a prompting method, an electronic device, a readable storage medium, and a program product. Background In the process of using the electronic device, dust may be accumulated in the display screen of the electronic device, gaps between the display screen and the frame, and the like. Due to the accumulation of dust, a user may quickly slide in the gap between the display screen, and the bezel using a sharp object such as a nail to perform ash removal. In addition, even if the user's intention is not ash removal, the user may quickly slide in the gap between the display screen, and the bezel using a sharp object such as a nail. The operation is easy to cause damage to the display screen and the frame of the electronic equipment, so that the use experience of a user is reduced, and the maintenance cost of the user is increased. Disclosure of Invention The application provides a prompting method, an electronic device, a readable storage medium and a program product, when the user makes an operation which possibly damages the electronic equipment, the electronic equipment can remind the user, and the use experience of the user is improved. In a first aspect, the application provides electronic equipment, which comprises a detection sensor, one or more processors, one or more memories and one or more programs, wherein the detection sensor comprises an inertial sensor and/or a touch sensor, the one or more memories store the one or more programs, the one or more programs are executed by the one or more processors, the electronic equipment is enabled to detect whether a first operation exists according to measurement data of the detection sensor, the first operation is an operation with risk of damaging a display screen and/or a frame of the electronic equipment, and in the case of detecting the first operation, first prompt information is output and used for prompting to stop executing the first operation. In the application, under the condition that the first operation is detected, the electronic equipment can output the first prompt information, and the first prompt information is used for prompting the user to stop executing the first operation, so that the damage of the electronic equipment by the user can be avoided, and the service life of the electronic equipment and the use experience of the user are improved. With reference to the first aspect, in certain implementations of the first aspect, the display screen of the electronic device includes a trigger hotzone that, when executed by the one or more processors, causes the electronic device to implement, in response to detecting that a number of times a user slides in the trigger hotzone within a first preset duration is greater than or equal to a first threshold, entering a mode of detecting the first operation. According to the application, the display screen of the electronic equipment comprises the trigger hot zone, and after the sliding times of the user in the trigger hot zone are greater than or equal to the first threshold value, the electronic equipment can detect whether the first operation exists, so that the first prompt information can be effectively prevented from being triggered and output by mistake, and the use experience of the user is improved. With reference to the first aspect, in certain implementation manners of the first aspect, the detection sensor includes an inertial sensor and a touch sensor, and when the one or more programs are executed by the one or more processors, the electronic device is caused to obtain touch measurement data collected by the touch sensor and inertial measurement data collected by the inertial sensor in N time periods, and output the first prompt information when the first operation exists in M time periods in the N time periods, where N is an integer greater than or equal to 1, and M is an integer greater than or equal to a second threshold and less than or equal to N. According to the application, the electronic device can acquire the inertia measurement data and the touch measurement data of a plurality of time periods, and determine whether the first operation exists in each time period according to the inertia measurement data and the touch measurement data of the plurality of time periods, and when the number of the time periods with the first operation is determined to be greater than or equal to the second threshold value, the electronic device can output the first prompt information, so that the first prompt information can be effectively prevented from being triggered and output by mistake, and the use experience of a user is improved. In addition, the electronic equipment jointly judges whether the first operation exists through the measurement data of the two different sensors, so that the detection accuracy is improv