CN111414098A - Touch screen control method and device, electronic equipment and computer readable storage medium - Google Patents

Touch screen control method and device, electronic equipment and computer readable storage medium Download PDF

Info

Publication number
CN111414098A
CN111414098A CN202010354523.1A CN202010354523A CN111414098A CN 111414098 A CN111414098 A CN 111414098A CN 202010354523 A CN202010354523 A CN 202010354523A CN 111414098 A CN111414098 A CN 111414098A
Authority
CN
China
Prior art keywords
click event
touch screen
touch
area
sliding operation
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CN202010354523.1A
Other languages
Chinese (zh)
Other versions
CN111414098B (en
Inventor
周海涛
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Oppo Chongqing Intelligent Technology Co Ltd
Original Assignee
Oppo Chongqing Intelligent Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Oppo Chongqing Intelligent Technology Co Ltd filed Critical Oppo Chongqing Intelligent Technology Co Ltd
Priority to CN202010354523.1A priority Critical patent/CN111414098B/en
Publication of CN111414098A publication Critical patent/CN111414098A/en
Application granted granted Critical
Publication of CN111414098B publication Critical patent/CN111414098B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/01Input arrangements or combined input and output arrangements for interaction between user and computer
    • G06F3/03Arrangements for converting the position or the displacement of a member into a coded form
    • G06F3/041Digitisers, e.g. for touch screens or touch pads, characterised by the transducing means
    • G06F3/0416Control or interface arrangements specially adapted for digitisers
    • G06F3/0418Control or interface arrangements specially adapted for digitisers for error correction or compensation, e.g. based on parallax, calibration or alignment
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/01Input arrangements or combined input and output arrangements for interaction between user and computer
    • G06F3/03Arrangements for converting the position or the displacement of a member into a coded form
    • G06F3/041Digitisers, e.g. for touch screens or touch pads, characterised by the transducing means
    • G06F3/0412Digitisers structurally integrated in a display

Landscapes

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

Abstract

The application relates to a touch screen control method and device, electronic equipment and a computer readable storage medium. Monitoring whether a sliding operation occurs on the touch screen within a preset time period, and prohibiting the intercepted first click event from being reinjected into the system when the sliding operation does not occur on the touch screen within the preset time period and the second click event is detected in a normal touch area. And eliminating the first click event on the system, and controlling the touch screen to respond to the second click event. Thereby avoiding the phenomenon of screen disconnection.

Description

Touch screen control method and device, electronic equipment and computer readable storage medium
Technical Field
The present application relates to the field of computer technologies, and in particular, to a touch screen control method and apparatus, an electronic device, and a computer-readable storage medium.
Background
With the continuous development of computer technology, touch screens with narrow-bezel or bezel-less designs have become the standard configuration for electronic devices. However, the design of the narrow frame or the frameless frame brings about a certain use trouble while bringing about a better visual effect to the user. For example, when a user holds an electronic device with a narrow frame or a frameless design, the phenomenon that the joint of the thumb of the palm of the hand is easy to touch the screen by mistake often occurs, and obviously, the phenomenon of touching by mistake brings serious trouble to the user.
In order to solve the problem, a conventional method is to set a false touch prevention area on a touch screen, and directly replace the touch operation occurring in the false touch prevention area with the touch operation occurring in a normal touch area, so as to eliminate the touch operation occurring in the false touch prevention area. However, after a navigation manner of a sliding operation is added to a new android version, a touch operation occurring in a wrong touch prevention area cannot be eliminated in the new navigation manner, and therefore, a conflict exists between the touch operation occurring in the wrong touch prevention area and the touch operation occurring in a normal touch area, so that a screen touch interruption phenomenon occurs, and normal use of a user is seriously affected.
Therefore, there is a strong need to solve the problem of the screen touch interruption in the navigation mode of the sliding operation.
Disclosure of Invention
The embodiment of the application provides a touch screen control method and device, electronic equipment and a computer readable storage medium, which can avoid the phenomenon of screen disconnection in a sliding operation navigation mode.
A touch screen control method comprises an error touch prevention area and a normal touch area, and comprises the following steps:
when a first click event is detected in the false touch prevention area, reporting the first click event to a system, and intercepting the first click event in the reporting process;
monitoring whether a sliding operation occurs on the touch screen within a preset time period;
when the sliding operation on the touch screen is not monitored in the preset time period and a second click event is detected in the normal touch area, the intercepted first click event is prohibited from being injected into the system again;
and eliminating the first click event on the system, and controlling the touch screen to respond to the second click event.
A touch screen control device, including preventing mistake on the touch screen and touching the area and normally touching the area, the device includes:
the first click event intercepting module is used for reporting a first click event to a system when the first click event is detected in the false touch prevention area, and intercepting the first click event in the reporting process;
the sliding operation monitoring module is used for monitoring whether sliding operation occurs on the touch screen within a preset time period;
the injection prohibiting module is used for prohibiting reinjection of the intercepted first click event into the system when the sliding operation on the touch screen is not monitored in the preset time period and a second click event is detected in the normal touch area;
and the second click event response module is used for eliminating the first click event on the system and controlling the touch screen to respond to the second click event.
An electronic device comprising a memory and a processor, the memory having stored therein a computer program, which, when executed by the processor, causes the processor to perform the steps of the touch screen control method as described above.
A computer-readable storage medium, on which a computer program is stored which, when being executed by a processor, carries out the steps of the touchscreen control method as described above.
According to the touch screen control method and device, the electronic equipment and the computer readable storage medium, when the first click event is detected in the false touch prevention area, the first click event is reported to the system, and the first click event is intercepted in the reporting process. Monitoring whether a sliding operation occurs on the touch screen within a preset time period, and prohibiting the intercepted first click event from being reinjected into the system when the sliding operation does not occur on the touch screen within the preset time period and the second click event is detected in a normal touch area. And eliminating the first click event on the system, and controlling the touch screen to respond to the second click event.
Since the first click event intercepted would otherwise need to be re-injected into the system when no sliding operation on the touch screen is monitored for a preset period of time. However, within a preset time period, a second click event is detected in the normal touch area, which indicates that the first click event is a false touch, and at this time, the first click event must be eliminated on the system. However, if the intercepted first click event is injected into the system again, the first click event and the second click event occur on the system at the same time, and the system cannot recognize that the screen is disconnected. In the application, when the sliding operation on the touch screen is not monitored within the preset time period and the second click event is detected in the normal touch area, the intercepted first click event is prohibited from being injected into the system again, so that two click events cannot occur on the system at the same time, namely the first click event is eliminated. And then, controlling the touch screen to only respond to the second click event, thereby avoiding the phenomenon of screen disconnection.
Drawings
In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings used in the description of the embodiments or the prior art will be briefly described below, it is obvious that the drawings in the following description are only some embodiments of the present application, and for those skilled in the art, other drawings can be obtained according to the drawings without creative efforts.
FIG. 1 is a diagram of an application environment of a touch screen control method according to an embodiment;
FIG. 2 is a flow diagram of a touch screen control method in one embodiment;
FIG. 3 is a flow diagram of the method of FIG. 2 for disabling reinjection of an intercepted first click event into the system;
FIG. 4 is a flowchart of a touch screen control method on a version before and on an Android Q version;
FIG. 5 is a schematic view of a touch screen of an electronic device in one embodiment;
FIG. 6 is a schematic view of a touch screen of an electronic device in another embodiment;
FIG. 7 is a flow diagram of a touch screen control method in accordance with an exemplary embodiment;
FIG. 8 is a block diagram of a touch screen control device according to an embodiment;
fig. 9 is a schematic diagram of an internal structure of an electronic device in one embodiment.
Detailed Description
In order to make the objects, technical solutions and advantages of the present application more apparent, the present application is described in further detail below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative of the present application and are not intended to limit the present application.
It will be understood that, as used herein, the terms "first," "second," and the like may be used herein to describe various elements, but these elements are not limited by these terms. These terms are only used to distinguish one element from another. For example, a first click event may be referred to as a second click event, and similarly, a second click event may be referred to as a first click event, without departing from the scope of the present application. Both the first click event and the second click event are click events, but they are not the same click event.
Fig. 1 is an application scenario diagram of a touch screen control method in an embodiment. As shown in fig. 1, the application environment includes an electronic device. The electronic device 100 comprises a touch screen, the touch screen comprises a false touch prevention area 120 and a normal touch area 140, when a first click event is detected in the false touch prevention area, the first click event is reported to a system, and the first click event is intercepted in the reporting process; monitoring whether a sliding operation occurs on the touch screen within a preset time period; when the sliding operation on the touch screen is not monitored within a preset time period and a second click event is detected in a normal touch area, the intercepted first click event is prohibited from being injected into the system again; and eliminating the first click event on the system, and controlling the touch screen to respond to the second click event.
The touch screen control method in the embodiment of the present application is described by taking the electronic device in fig. 1 as an example. The touch screen comprises a false touch prevention area and a normal touch area, wherein the false touch prevention area is arranged at the edge of the touch screen of the electronic equipment, and when a false touch event occurs in the false touch prevention area, the false touch event cannot be reported to the system. Therefore, the problem that false touch causes false response of the electronic equipment is solved. The normal touch area is an area on the touch screen of the electronic device, which can normally respond to the touch event of the user.
When a user holds electronic equipment with a narrow frame or no frame, the phenomenon that the joint of the thumb of the palm of the hand is easy to touch the screen by mistake often occurs, and obviously, the phenomenon of touching by mistake brings serious trouble to the user. Before Android Q version, in order to solve this problem, when a user touches an erroneous touch prevention area on a touch screen by mistake, if a touch operation also occurs in a normal touch area, the touch operation occurring in the erroneous touch prevention area is directly replaced with the touch operation occurring in the normal touch area, so as to eliminate the touch operation occurring in the erroneous touch prevention area. Therefore, in the conventional method, as long as a touch operation occurs in the normal touch area while a false touch occurs in the false touch prevention area, only the touch event of the normal touch area is reported, and the touch event of the false touch prevention area is not reported. However, after a navigation mode of a sliding operation is added to the android q version, the touch operation in the anti-false touch area, which occurs in the above case, cannot be eliminated in the new navigation mode.
In the Android Q version, when a first click event is detected in the false touch prevention area, the first click event is reported to the system, and the first click event is intercepted in the reporting process. It is then determined whether a swipe operation has occurred and if no swipe operation has occurred, the intercepted first click event will be reinjected to the system. If in the process, the touch operation happens in the normal touch area, the touch operation occurring in the normal touch area needs to be adopted to replace the touch operation occurring in the false touch prevention area (i.e. the first click event) at the screen firmware layer so as to eliminate the first click event. However, if the intercepted first click event is re-injected into the system after the first click event is eliminated. Then the first click event is not actually eliminated. At this time, the system receives two click events at the same time, and the system cannot identify which click event should be responded, so that the system does not respond to the two click events, thereby causing a screen touch interruption phenomenon and seriously affecting the normal use of a user. The screen touch interruption phenomenon refers to a phenomenon that an operation is performed on the touch screen, and the system does not recognize the operation and does not respond.
In order to solve the problems in the Android Q version, a touch screen control method is provided. Fig. 2 is a flowchart illustrating a touch screen control method according to an embodiment, which includes steps 220 to 280.
Wherein the content of the first and second substances,
and step 220, when the first click event is detected in the false touch prevention area, reporting the first click event to a system, and intercepting the first click event in the reporting process.
When the screen firmware detects a first click event in the false touch prevention area, the screen firmware reports the first click event to an android system interface application or an upper layer application (such as SystemUI) through a system framework layer, and reports the first click event to other applications on the android system. In the reporting process, the first click event is intercepted through the SystemUI, so that the first click event cannot be continuously reported to other applications. The first click event is reported to other applications, and after the other applications receive the first click event, the other applications can trigger a response to the first click event.
And 240, monitoring whether the sliding operation occurs on the touch screen within a preset time period.
After the first click event is intercepted through the SystemUI, the SystemUI monitors whether a sliding operation occurs on the touch screen within a preset time period. The preset time period is set correspondingly according to the general duration of the sliding operation, for example, the preset time period is set to be any value between 200 and 300 ms. Of course, the duration of the preset time period is not limited in this application, and may be any other reasonable value. The sliding operation may be a sliding operation that occurs at any position on the touch screen, which is not limited in this application. For example, the sliding operation may be performed only in the erroneous touch prevention area, only in the normal touch area, or across both areas. In the Android Q version, a back function or a multitask function and the like can be realized on a display interface through sliding operation, which is convenient for a user to use.
And step 260, when the sliding operation on the touch screen is not monitored in the preset time period and the second click event is detected in the normal touch area, prohibiting the intercepted first click event from being injected into the system again.
The method includes the steps that the SystemUI monitors whether sliding operation occurs on the touch screen within a preset time period, and when the sliding operation does not occur on the touch screen within the preset time period and a second click event is detected in a normal touch area within the preset time period, the SystemUI prohibits reinjection of the intercepted first click event into the android system.
Step 280, eliminating the first click event on the system and controlling the touch screen to respond to the second click event.
The first click event is then dismissed by the screen firmware in the android system, so that only one click event, i.e., the second click event, exists on the android system at this time. Therefore, the screen firmware transmits the second click event through the system framework layer, transmits the second click event to the system UI, receives the second click event through the system UI, reports the second click event to other applications, and triggers a response to the first click event through the other applications.
In the embodiment of the present application, since the sliding operation on the touch screen is not monitored within the preset time period, the intercepted first click event needs to be re-injected into the system. However, within a preset time period, a second click event is detected in the normal touch area, which indicates that the first click event is a false touch, and at this time, the first click event must be eliminated on the system. However, if the intercepted first click event is injected into the system again, the first click event and the second click event occur on the system at the same time, and the system cannot recognize that the screen is disconnected. In the application, when the sliding operation on the touch screen is not monitored within the preset time period and the second click event is detected in the normal touch area, the intercepted first click event is prohibited from being injected into the system again, so that two click events cannot occur on the system at the same time, namely the first click event is eliminated. And then, controlling the touch screen to only respond to the second click event, thereby avoiding the phenomenon of screen disconnection.
In one embodiment, a touch screen control method is provided, further comprising:
and when the sliding operation on the touch screen is monitored in a preset time period, controlling the touch screen to respond to the sliding operation and ignoring the first click event.
When the screen firmware detects a first click event in the false touch prevention area, the screen firmware reports the first click event to the system UI through the system frame layer and reports the first click event to other applications on the android system. In the reporting process, the first click event is intercepted through the SystemUI, so that the first click event cannot be continuously reported to other applications. After the first click event is intercepted through the SystemUI, the SystemUI monitors whether a sliding operation occurs on the touch screen within a preset time period. When the sliding operation on the touch screen is monitored in a preset time period, the system UI reports the sliding operation to other applications, and the other applications trigger the response to the sliding operation. That is, the control touch screen response sliding operation is completed and the first click event is ignored. Specifically, the manner of ignoring the first click event may be to delete the first click event, which is not limited in the present application.
In the embodiment of the application, on the Android Q version, after the first click event is intercepted through the systemin, the systemin monitors whether a sliding operation occurs on the touch screen within a preset time period. When the sliding operation on the touch screen is monitored in a preset time period, the system UI reports the sliding operation to other applications, and the other applications trigger the response to the sliding operation. The back-off function or the multi-task function and the like can be realized on the display interface through sliding operation, and the use of a user is facilitated.
In one embodiment, step 260, when the sliding operation on the touch screen is not monitored within the preset time period and the second click event is detected in the normal touch area, prohibiting the intercepted first click event from being re-injected into the system, including:
when the sliding operation on the touch screen is not monitored within a preset time period and a second click event is detected in a normal touch area, sending a point vanishing notification event;
receiving a vanishing point notification event, and prohibiting reinjection of the intercepted first click event into the system based on the vanishing point notification event.
Specifically, as shown in fig. 3, it is a processing flow chart of the touch control method in one embodiment. The flow involves screen firmware 320, system framework layer 340, upper layer applications (e.g., SystemUI)360, and other applications 380. Generally, when a click event occurs on the touch screen, the screen firmware 320 transmits the click event through the system framework layer 340, transmits the click event to the SystemUI360, transmits the click event to the other applications 380 through the SystemUI360, and finally responds to the click event by the other applications 380. Wherein, the system UI comprises a click elimination decision module for controlling the process of eliminating click events. And when the sliding operation on the touch screen is not monitored in the preset time period and a second click event is detected in a normal touch area in the preset time period, a click elimination notification event is sent by the screen firmware to prompt the click elimination decision module in the system UI to eliminate the first click event on the system. Among them, Firmware is a program written in EPROM (erasable programmable read only memory) or EEPROM (electrically erasable programmable read only memory), and is a program that serves as the most basic and bottom layer of a system and can be generally upgraded by a user through a specific refresh program. Accordingly, the screen firmware is the firmware built in the touch screen. The other application refers to software installed on the electronic device and providing a certain function to the user, for example, WeChat, QQ, etc., which is not limited in this application.
After the screen firmware sends out the vanishing point notification event, event transmission is carried out through a system framework layer, the event is transmitted to the SystemUI, and the vanishing point notification event is received by a vanishing point processing decision module in the SystemUI. After a vanishing point processing decision module in the SystemUI receives a vanishing point notification event, re-injection of the intercepted first click event into the system is inhibited based on the vanishing point notification event. Finally, the first click event is eliminated on the system, and the touch screen is controlled to respond to the second click event.
In the embodiment of the application, the system ui monitors whether the sliding operation occurs on the touch screen within a preset time period, and when the sliding operation does not occur on the touch screen within the preset time period and a second click event is detected in a normal touch area within the preset time period, the screen firmware sends out a click elimination notification event to prompt the system ui that the first click event is eliminated on the system by the screen firmware at the time. Thus, after the System UI receives a vanishing point notification event, reinjection of the intercepted first click event into the system is prohibited based on the vanishing point notification event. When the first click event is eliminated, an elimination point notification event is sent to the SystemUI in advance, so that the SystemUI prohibits reinjection of the intercepted first click event into the system based on the elimination point notification event. Therefore, the phenomenon that after the first click event is eliminated and the first click event is injected into the system again, two click events can occur on the system at the same time, and the screen is broken.
In one embodiment, dismissing the first click event and controlling the touch screen to respond to the second click event includes:
and replacing the first click event with the second click event, and controlling the touch screen to respond to the second click event.
As shown in fig. 4(a), in the Android version before the Android Q version, assuming that when the user holds the electronic device by hand, a certain part of the palm touches a certain position of the anti-false touch area on the touch screen of the electronic device, although the user touches the electronic device unconsciously, a Pointer 0 is formed at this time, and the coordinates of the Pointer are (a, b), and the click event is reported. And when the user keeps the click event of the Pointer 0 all the time, the user just clicks the normal touch area on the touch screen to form a click event with coordinates (c, d), and at the moment, the click event is not endowed with the Pointer Id temporarily. Then, at this time, the system automatically considers the click event of Pointer 0 as a false touch, so the screen firmware triggers the cancel action, that is, the screen firmware directly cancels the report of the click event with the coordinate (a, b) of Pointer 0, and directly replaces the coordinate (c, d) of Pointer 0. And then, the screen firmware replaces the coordinates with the click event of the Pointer 0 after (c, d) for reporting, reports the click event corresponding to the updated Pointer 0 to other applications, and triggers the response to the second click event by the other applications. Thus, the effect of preventing the accidental touch is realized.
Each finger has a fixed PointerId from pressing and moving to leaving the screen, and the value of the PointerId can be any value. Typically, Pointer ids are named sequentially according to the order in which the fingers click on the touch screen. However, when the user keeps the click event of Pointer 0 all the time in the anti-touch area, the user just clicks the normal touch area on the touch screen again to form a click event with coordinates (c, d), and at this time, the click event is not temporarily given Pointer Id.
As shown in fig. 4(b), in the Android Q version, when the user just clicks a normal touch area on the touch screen to form a click event with coordinates (c, d), the screen firmware first issues a cancel notification event to prompt the system ui that the screen firmware will cancel the click event with coordinates (a, b) on the system. Inhibiting the reinjection of the intercepted click event with coordinates (a, b) into the system. Therefore, the phenomenon that after the click event with the coordinates (a, b) is eliminated, the click event with the coordinates (a, b) is injected into the system again, and two pointers 0 with different coordinates appear on the system at the same time, so that the screen is broken and touched is avoided.
In the embodiment of the application, after the system UI receives the vanishing point notification event, the intercepted first click event is prohibited from being injected into the system again based on the vanishing point notification event. When the first click event is eliminated, an elimination point notification event is sent to the SystemUI in advance, so that the SystemUI prohibits reinjection of the intercepted first click event into the system based on the elimination point notification event. Therefore, the phenomenon that after the first click event is eliminated and the first click event is injected into the system again, two click events can occur on the system at the same time, and the screen is broken.
In one embodiment, the first click event comprises a first click event identity and a first coordinate, and the second click event comprises a second coordinate; replacing the first click event with a second click event, comprising:
and replacing the second coordinate of the second click event with the first coordinate of the first click event, and assigning the identity of the first click event to the second click event.
In the embodiment of the application, in the Android Q version, if a user touches an electronic device by hand, a certain part of the palm touches a certain position of a false touch prevention area on a touch screen of the electronic device, although the user touches the electronic device unconsciously, a Pointer 0 with coordinates (a, b) is formed at this time, and the first click event is reported. At this time, the first click event identity is Pointer 0 and the first coordinate is (a, b).
And when the user keeps the click event of the Pointer 0 all the time, the user just clicks a normal touch area on the touch screen to form a second click event with coordinates (c, d), and at the moment, the PointId is not endowed to the click event temporarily. Then, at this time, the system automatically considers the click event of the Pointer 0 as a false touch, so that the screen firmware triggers a click cancellation action, namely the screen firmware directly cancels the report of the click event with the coordinate (a, b) of the Pointer 0, replaces the second coordinate of the second click event with the first coordinate of the first click event, and assigns the identity of the first click event to the second click event. The method specifically comprises the following steps: the coordinates of Pointer 0 are directly replaced with (c, d). And then, the screen firmware replaces the coordinates with the click event of the Pointer 0 after (c, d) for reporting, reports the click event corresponding to the updated Pointer 0 to other applications, and triggers the response to the second click event by the other applications. Thus, the effect of preventing the accidental touch is realized.
In one embodiment, a touch screen control method is provided, further comprising:
when the sliding operation on the touch screen is not monitored within a preset time period and a second click event is not detected in a normal touch area, re-injecting the intercepted first click event into the system;
the touch screen is controlled to respond to the first click event.
Specifically, after the first click event is intercepted through the systemin, the systemin monitors whether a sliding operation occurs on the touch screen within a preset time period. When the sliding operation on the touch screen is not monitored within the preset time period and the second click event is not detected in the normal touch area, it is indicated that the first click event on the false touch prevention area is not false touch. At this time, the intercepted first click event is re-injected into the system, and the touch screen is controlled to respond to the first click event.
In the embodiment of the application, on the Android Q version, the first click event is intercepted through the systemin, and then whether a sliding operation occurs on the touch screen or not and whether a second click event is detected in a normal touch area or not are monitored according to the systemin within a preset time period. The intercepted first click event may also be re-injected according to the result of the detection. Therefore, the sliding operation is compatible with the first click event and the second click event which occur on the touch screen under the condition of elimination, and the phenomenon of screen disconnection is avoided.
In one embodiment, a first setting area of an edge of the touch screen is determined as a sliding operation intercepting area within which a sliding operation occurs.
As shown in fig. 5, a schematic view of a touch screen of an electronic device is provided. The first setting area at the peripheral edge of the touch screen may be set as a sliding operation intercepting area, which includes four rectangular frame areas, such as a first sliding operation intercepting area 502, a second sliding operation intercepting area 504, a third sliding operation intercepting area 506, and a fourth sliding operation intercepting area 508. Of course, in other embodiments, the sliding operation intercepting region may be formed by other irregular graphic regions, which is not limited in this application. And the first sliding operation intercepting region 502, the second sliding operation intercepting region 504, the third sliding operation intercepting region 506 and the fourth sliding operation intercepting region 508 may not be completely identical in area and shape. The sliding operation may be set as a two-side sliding operation, and specifically, the sliding operation that will occur in the above four regions is referred to as a two-side sliding operation.
In the embodiment of the application, on the Android Q version, whether a sliding operation occurs is monitored in a sliding operation intercepting region through screen firmware, and an event corresponding to the sliding operation is reported to other applications, so that a back-off function or a multi-task function is realized, and the use of a user is facilitated.
In one embodiment, a touch screen control method is provided, further comprising:
determining a second set area at the edge of the touch screen as a false touch prevention area, wherein the area of the first set area is larger than or equal to that of the second set area;
and determining the area except the false touch prevention area in the touch screen as a normal touch area.
As shown in fig. 5, a first setting area of the peripheral edge of the touch screen is set as a sliding operation intercepting area. As shown in fig. 6, a schematic view of a touch screen of an electronic device is provided. The second setting area of the touch screen edge comprises areas positioned at the left and right edges of the touch screen of the electronic equipment. The area of the first setting area is larger than or equal to the area of the second setting area, namely the sliding operation intercepting area comprises an error touch preventing area. Of course, the sliding operation intercepting region may also include a part of the normal touch region, which is not limited in this application. When the touch screen of the electronic device is in a vertical state, the second set area at the edge of the touch screen is the first anti-false-touch area 622 and the second anti-false-touch area 624 formed by rectangular frames in the left diagram of fig. 6. Of course, in other embodiments, the first anti-false-touch area 622 and the second anti-false-touch area 624 may be formed by other irregular pattern areas, which is not limited in this application. And the first and second anti-false touch regions 622 and 624 may not be completely symmetrical. The first and second anti-false touch regions 622 and 624 constitute an anti-false touch region 620 when the touch screen of the electronic device is in an upright state. The area of the touch screen excluding the erroneous-touch prevention area 620 is determined as a normal touch area.
When the touch screen of the electronic device is in a horizontal state, the second set area at the edge of the touch screen is the third anti-false-touch area 642 and the fourth anti-false-touch area 644 which are formed by rectangular frames in the right diagram of fig. 6. Of course, in other embodiments, the third anti-touch region 642 and the fourth anti-touch region 644 may be formed by other irregular pattern regions, which is not limited in this application. And the third mis-touch prevention region 642 and the fourth mis-touch prevention region 644 may not be completely symmetrical. The third erroneous-touch prevention area 642 and the fourth erroneous-touch prevention area 644 constitute an erroneous-touch prevention area 640 when the touch screen of the electronic device is in a landscape state. The area of the touch screen excluding the erroneous-touch prevention area 640 is determined as a normal touch area.
In the embodiment of the application, the touch screen of the electronic equipment is divided into the false touch prevention area and the normal touch area. The false touch prevention area is located at the edge of the touch screen, and the area except the false touch prevention area is determined as a normal touch area. In this way, the click event occurring in the false touch prevention area can be replaced by the click event occurring in the normal touch area, so that the click event generated by the false touch can be eliminated, and the click of the user can be accurately responded.
In a specific embodiment, as shown in fig. 7, there is provided a touch screen control method including the steps of:
step 702, monitoring whether a first click event occurs in the anti-false touch area; if yes, go to step 704;
step 704, reporting the first click event to a system, and intercepting the first click event in the reporting process; step 706 is entered;
step 706, monitoring whether a sliding operation occurs on the touch screen within a preset time period; if yes, go to step 708; if not, go to step 710;
step 708, controlling the touch screen to respond to the sliding operation, and ignoring the first click event;
step 710, monitoring whether a second click event occurs in a normal touch area within a preset time period; if yes, go to step 712; if not, go to step 716;
step 712, sending a vanishing point notification event, receiving the vanishing point notification event, and prohibiting reinjecting the intercepted first click event into the system based on the vanishing point notification event; step 714 is entered;
and 714, replacing the first click event with the second click event, and controlling the touch screen to respond to the second click event.
And 716, re-injecting the intercepted first click event into the system, and controlling the touch screen to respond to the first click event.
In the embodiment of the application, on the Android Q version, after the first click event is intercepted through the systemin, the systemin monitors whether a sliding operation occurs on the touch screen within a preset time period. When the sliding operation on the touch screen is monitored in a preset time period, the system UI reports the sliding operation to other applications, and the other applications trigger the response to the sliding operation.
And when the sliding operation on the touch screen is not monitored within the preset time period and a second click event is detected in the normal touch area, sending out a point vanishing notification event. Receiving a vanishing point notification event, and prohibiting reinjection of the intercepted first click event into the system based on the vanishing point notification event. And replacing the first click event with the second click event, and controlling the touch screen to respond to the second click event. Therefore, the sliding operation is compatible with the first click event and the second click event which occur on the touch screen under the condition of elimination, and the phenomenon of screen disconnection is avoided.
It should be understood that, although the steps in the flowchart of fig. 7 are shown in order as indicated by the arrows, the steps are not necessarily performed in order as indicated by the arrows. The steps are not performed in the exact order shown and described, and may be performed in other orders, unless explicitly stated otherwise. Moreover, at least a portion of the steps in fig. 7 may include multiple sub-steps or multiple stages that are not necessarily performed at the same time, but may be performed at different times, and the order of performance of the sub-steps or stages is not necessarily sequential, but may be performed in turn or alternately with other steps or at least a portion of the sub-steps or stages of other steps.
In one embodiment, as shown in fig. 8, there is further provided a touch screen control apparatus 800 including a mis-touch prevention area and a normal touch area on a touch screen, the apparatus including:
the first click event intercepting module 820 is configured to report the first click event to the system when the first click event is detected in the false touch prevention area, and intercept the first click event in the reporting process;
a sliding operation monitoring module 840, configured to monitor whether a sliding operation occurs on the touch screen within a preset time period;
the injection prohibiting module 860 is used for prohibiting reinjection of the intercepted first click event into the system when the sliding operation on the touch screen is not monitored within a preset time period and a second click event is detected in a normal touch area;
and a second click event response module 880, configured to eliminate the first click event on the system, and control the touch screen to respond to the second click event.
In one embodiment, the touch screen control device 800 is further configured to control the touch screen to ignore the first click event in response to the sliding operation when the sliding operation on the touch screen is monitored within the preset time period.
In one embodiment, the injection forbidding module 860 is further configured to issue a vanishing point notification event when the sliding operation on the touch screen is not monitored within the preset time period and the second click event is detected in the normal touch area; receiving a vanishing point notification event, and prohibiting reinjection of the intercepted first click event into the system based on the vanishing point notification event.
In one embodiment, the second click event response module 880 is further configured to replace the first click event with a second click event on the system, and control the touch screen to respond to the second click event.
In one embodiment, the first click event comprises a first click event identity and a first coordinate, and the second click event comprises a second coordinate; replacing the first click event with a second click event, comprising:
and replacing the second coordinate of the second click event with the first coordinate of the first click event, and assigning the identity of the first click event to the second click event.
In one embodiment, the touch screen control device 800 is further configured to reinject the intercepted first click event to the system when the sliding operation on the touch screen is not monitored within the preset time period and the second click event is not detected in the normal touch area; the touch screen is controlled to respond to the first click event.
In one embodiment, the touch screen control device 800 is further configured to determine a first setting area of the edge of the touch screen as a sliding operation intercepting area within which the sliding operation occurs.
In one embodiment, the touch screen control device 800 is further configured to determine a second setting area of the edge of the touch screen as a false touch prevention area, where an area of the first setting area is greater than or equal to the second setting area; and determining the area except the false touch prevention area in the touch screen as a normal touch area.
The division of each module in the touch screen control device is only used for illustration, and in other embodiments, the touch screen control device may be divided into different modules as needed to complete all or part of the functions of the touch screen control device.
For specific limitations of the touch screen control device, reference may be made to the above limitations of the touch screen control method, which are not described herein again. The modules in the touch screen control device can be wholly or partially implemented by software, hardware and a combination thereof. The modules can be embedded in a hardware form or independent from a processor in the computer device, and can also be stored in a memory in the computer device in a software form, so that the processor can call and execute operations corresponding to the modules.
Fig. 9 is a schematic diagram of an internal structure of an electronic device in one embodiment. As shown in fig. 9, the electronic device includes a processor and a memory connected by a system bus. Wherein, the processor is used for providing calculation and control capability and supporting the operation of the whole electronic equipment. The memory may include a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system and a computer program. The computer program can be executed by a processor for implementing a touch screen control method provided in the following embodiments. The internal memory provides a cached execution environment for the operating system computer programs in the non-volatile storage medium. The electronic device may be any terminal device such as a mobile phone, a tablet computer, a PDA (Personal digital assistant), a Point of sale (POS), a vehicle-mounted computer, and a wearable device.
The implementation of each module in the touch screen control device provided in the embodiments of the present application may be in the form of a computer program. The computer program may be run on an electronic device or a server. The program modules constituting the computer program may be stored on a memory of the electronic device or the server. Which when executed by a processor, performs the steps of the method described in the embodiments of the present application.
The embodiment of the application also provides a computer readable storage medium. One or more non-transitory computer-readable storage media containing computer-executable instructions that, when executed by one or more processors, cause the processors to perform the steps of the touch screen control method.
A computer program product containing instructions which, when run on a computer, cause the computer to perform a touch screen control method.
Suitable non-volatile memory may include read-only memory (ROM), Programmable ROM (PROM), Electrically Programmable ROM (EPROM), Electrically Erasable Programmable ROM (EEPROM), or flash memory.
The above examples only express several embodiments of the present application, and the description thereof is more specific and detailed, but not construed as limiting the scope of the present application. It should be noted that, for a person skilled in the art, several variations and modifications can be made without departing from the concept of the present application, which falls within the scope of protection of the present application. Therefore, the protection scope of the present patent shall be subject to the appended claims.

Claims (11)

1. A touch screen control method is characterized in that a touch screen comprises an error touch prevention area and a normal touch area, and the method comprises the following steps:
when a first click event is detected in the false touch prevention area, reporting the first click event to a system, and intercepting the first click event in the reporting process;
monitoring whether a sliding operation occurs on the touch screen within a preset time period;
when the sliding operation on the touch screen is not monitored in the preset time period and a second click event is detected in the normal touch area, the intercepted first click event is prohibited from being injected into the system again;
and eliminating the first click event on the system, and controlling the touch screen to respond to the second click event.
2. The method of claim 1, further comprising:
and when the sliding operation on the touch screen is monitored in the preset time period, controlling the touch screen to respond to the sliding operation and ignoring the first click event.
3. The method of claim 1, wherein the prohibiting reinjection of the intercepted first click event into the system when a swipe operation on the touch screen is not monitored for the preset time period and a second click event is detected in the normal touch area comprises:
when the sliding operation on the touch screen is not monitored in the preset time period and a second click event is detected in the normal touch area, sending a point vanishing notification event;
receiving the vanishing point notification event, and prohibiting reinjection of the intercepted first click event into the system based on the vanishing point notification event.
4. The method of claim 1, wherein said eliminating said first click event on the system, controlling said touch screen to respond to said second click event, comprises:
and replacing the first click event with the second click event on the system, and controlling the touch screen to respond to the second click event.
5. The method of claim 4, wherein the first click event comprises a first click event identity and a first coordinate, and wherein the second click event comprises a second coordinate; the replacing the first click event with the second click event includes:
and replacing the second coordinate of the second click event with the first coordinate of the first click event, and assigning the identity of the first click event to the second click event.
6. The method of claim 1, further comprising:
when the sliding operation on the touch screen is not monitored in the preset time period and a second click event is not detected in the normal touch area, re-injecting the intercepted first click event into the system;
and controlling the touch screen to respond to the first click event.
7. The method according to any one of claims 1 to 6, further comprising:
and determining a first set area of the edge of the touch screen as the sliding operation intercepting area, wherein the sliding operation occurs in the sliding operation intercepting area.
8. The method of claim 7, further comprising:
determining a second set area on the edge of the touch screen as the false touch prevention area, wherein the area of the first set area is larger than or equal to the second set area;
and determining the area except the false touch prevention area in the touch screen as the normal touch area.
9. The touch screen control device is characterized by comprising an error touch prevention area and a normal touch area on a touch screen, and the device comprises:
the first click event intercepting module is used for reporting a first click event to a system when the first click event is detected in the false touch prevention area, and intercepting the first click event in the reporting process;
the sliding operation monitoring module is used for monitoring whether sliding operation occurs on the touch screen within a preset time period;
the injection prohibiting module is used for prohibiting reinjection of the intercepted first click event into the system when the sliding operation on the touch screen is not monitored in the preset time period and a second click event is detected in the normal touch area;
and the second click event response module is used for eliminating the first click event on the system and controlling the touch screen to respond to the second click event.
10. An electronic device comprising a memory and a processor, wherein the memory stores a computer program, and wherein the computer program, when executed by the processor, causes the processor to perform the steps of the touch screen control method according to any one of claims 1 to 8.
11. A computer-readable storage medium, on which a computer program is stored, which, when being executed by a processor, carries out the steps of the touch screen control method according to any one of claims 1 to 8.
CN202010354523.1A 2020-04-29 2020-04-29 Touch screen control method and device, electronic equipment and computer readable storage medium Active CN111414098B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010354523.1A CN111414098B (en) 2020-04-29 2020-04-29 Touch screen control method and device, electronic equipment and computer readable storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010354523.1A CN111414098B (en) 2020-04-29 2020-04-29 Touch screen control method and device, electronic equipment and computer readable storage medium

Publications (2)

Publication Number Publication Date
CN111414098A true CN111414098A (en) 2020-07-14
CN111414098B CN111414098B (en) 2022-05-13

Family

ID=71492194

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010354523.1A Active CN111414098B (en) 2020-04-29 2020-04-29 Touch screen control method and device, electronic equipment and computer readable storage medium

Country Status (1)

Country Link
CN (1) CN111414098B (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2023098628A1 (en) * 2021-11-30 2023-06-08 维沃移动通信有限公司 Touch-control operation method and apparatus, and electronic device
CN116679864A (en) * 2022-09-27 2023-09-01 荣耀终端有限公司 Touch interaction processing method and electronic equipment

Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104731502A (en) * 2015-03-27 2015-06-24 努比亚技术有限公司 Double-click recognition method and device based on virtual partition touch screen and mobile terminal
WO2016155597A1 (en) * 2015-03-30 2016-10-06 努比亚技术有限公司 Frameless terminal-based application control method and device
CN106406633A (en) * 2016-12-16 2017-02-15 广东欧珀移动通信有限公司 Touch screen edge error touch prevention method and device and mobile terminal
CN106681554A (en) * 2016-12-16 2017-05-17 广东欧珀移动通信有限公司 Mobile terminal touch screen control method and device and mobile terminal
CN106708363A (en) * 2016-12-16 2017-05-24 广东欧珀移动通信有限公司 Mistaken touch preventive method and device for display interface and mobile terminal
CN107422916A (en) * 2017-07-26 2017-12-01 广东欧珀移动通信有限公司 A kind of response method of touch operation, device, storage medium and terminal
CN108108612A (en) * 2016-11-25 2018-06-01 阿里巴巴集团控股有限公司 The method and apparatus that anti-automatic is clicked on
WO2018191972A1 (en) * 2017-04-21 2018-10-25 华为技术有限公司 Touch control method and apparatus
CN110913068A (en) * 2019-11-14 2020-03-24 青岛海信移动通信技术股份有限公司 Communication terminal and sliding touch event response method

Patent Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104731502A (en) * 2015-03-27 2015-06-24 努比亚技术有限公司 Double-click recognition method and device based on virtual partition touch screen and mobile terminal
WO2016155597A1 (en) * 2015-03-30 2016-10-06 努比亚技术有限公司 Frameless terminal-based application control method and device
CN108108612A (en) * 2016-11-25 2018-06-01 阿里巴巴集团控股有限公司 The method and apparatus that anti-automatic is clicked on
CN106406633A (en) * 2016-12-16 2017-02-15 广东欧珀移动通信有限公司 Touch screen edge error touch prevention method and device and mobile terminal
CN106681554A (en) * 2016-12-16 2017-05-17 广东欧珀移动通信有限公司 Mobile terminal touch screen control method and device and mobile terminal
CN106708363A (en) * 2016-12-16 2017-05-24 广东欧珀移动通信有限公司 Mistaken touch preventive method and device for display interface and mobile terminal
WO2018191972A1 (en) * 2017-04-21 2018-10-25 华为技术有限公司 Touch control method and apparatus
CN107422916A (en) * 2017-07-26 2017-12-01 广东欧珀移动通信有限公司 A kind of response method of touch operation, device, storage medium and terminal
CN110913068A (en) * 2019-11-14 2020-03-24 青岛海信移动通信技术股份有限公司 Communication terminal and sliding touch event response method

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2023098628A1 (en) * 2021-11-30 2023-06-08 维沃移动通信有限公司 Touch-control operation method and apparatus, and electronic device
CN116679864A (en) * 2022-09-27 2023-09-01 荣耀终端有限公司 Touch interaction processing method and electronic equipment
CN116679864B (en) * 2022-09-27 2024-03-29 荣耀终端有限公司 Touch interaction processing method and electronic equipment

Also Published As

Publication number Publication date
CN111414098B (en) 2022-05-13

Similar Documents

Publication Publication Date Title
CN109918247B (en) Method and device for detecting abnormal jumping points of touch screen and electronic equipment
RU2607271C2 (en) Method for preventing misoperation of touchscreen, touchscreen and mobile terminal
EP3220251B1 (en) Method and system based on mobile terminal for turning off screen during call to prevent inadvertent touch
EP3951596A1 (en) Proxy gesture recognizer
EP3982242A2 (en) Event recognition
CN111414098B (en) Touch screen control method and device, electronic equipment and computer readable storage medium
CN111966258B (en) Permission setting method and device and electronic equipment
US10893089B2 (en) System and method for controlling a mouse or cursor position in response to one or more input events from a local computer and/or remote computer
CN107506092B (en) Input control method and terminal
EP3640783B1 (en) Touch operation response method and device
US20140253482A1 (en) Information processing apparatus, information processing method, and program
US20200341611A1 (en) Touch method and terminal
KR20120072932A (en) Method and apparatus for providing touch interface
CN109117013B (en) Electronic equipment, and false touch prevention method and system
CN106325720B (en) Information processing method and information processing apparatus
US11482037B2 (en) User interface display method of terminal, and terminal
CN114341784A (en) Touch event processing method and device, mobile terminal and storage medium
CN112947829A (en) Misoperation processing method and device, electronic equipment and readable storage medium
CN109739427B (en) Screen operation method and device, display equipment and storage medium
CN109885356A (en) ADB debugs port open method, apparatus, Android device and readable storage medium storing program for executing
WO2019072169A1 (en) Detection method and device for preventing accidental touch and terminal
CN108416210B (en) Program protection method and device
CN110908559A (en) Display method and device of shortcut application panel, electronic equipment and storage medium
WO2019237921A1 (en) Touch recognition method, terminal, and storage medium
WO2019024507A1 (en) Touch control method and device, and terminal

Legal Events

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