Disclosure of Invention
The invention aims to solve the technical problems that in order to overcome the defects of the prior art, the invention provides the method and the device for unlocking the track of the touch screen of the mobile terminal, the terminal equipment and the storage medium.
In order to solve the technical problems, the technical scheme adopted by the invention is as follows:
a track unlocking processing method for a touch screen of a mobile terminal comprises the following steps:
acquiring a touch track detected by a touch screen of the mobile terminal;
judging whether the acquired touch track is a single-line track;
when the touch track is a single-line track, acquiring the number of high points in the single-line touch track;
and when the number of the high points in the single-line touch track is equal to the preset number of the high points for unlocking, controlling to unlock the mobile terminal.
The method for unlocking the touch track of the touch screen of the mobile terminal comprises the following steps of:
the number of high points for unlocking the mobile terminal is preset.
The method for unlocking the touch track of the touch screen of the mobile terminal comprises the following steps of:
when the touch screen detects that the touch point is touched, the coordinates of the touch point are recorded in time sequence;
and when the touch screen detects the release, finishing the recording to acquire the touch track detected by the touch screen of the mobile terminal.
The method for processing the track unlocking of the touch screen of the mobile terminal comprises the following steps of:
judging whether the condition that the same time point comprises two touch points exists in all the touch points recorded in the acquired touch track;
when the condition that the same time point contains two touch points exists, judging that the acquired touch track is not a single-line track;
and when the condition that the same time point contains two touch points does not exist, judging that the acquired touch track is a single-line track.
The mobile terminal touch screen track unlocking processing method comprises the following steps of:
and when the touch track is a single-line track, acquiring the number of high points bent towards the same direction in the single-line touch track.
The mobile terminal touch screen track unlocking processing method comprises the following steps that when the number of high points in a single-line touch track is equal to the preset number of high points for unlocking, the mobile terminal is controlled to be unlocked, and the steps comprise:
comparing the number of high points in the current single-line touch track with the preset number of high points for unlocking;
and judging whether the number of high points in the current single-line touch track is equal to the preset number of high points for unlocking or not, and controlling to unlock the mobile terminal if the number of high points in the current single-line touch track is equal to the preset number of high points for unlocking.
The method for processing the track unlocking of the touch screen of the mobile terminal comprises the following steps of judging whether the number of high points in the current single-line touch track is equal to the preset number of high points for unlocking or not:
and setting that the current single-line touch track to be judged comprises N touch points, wherein the touch point coordinates of the current single-line touch track to be judged are as follows in chronological order: y1, Y2, … …, YN;
wherein the touch points arranged at the front record earlier time than the touch points arranged at the back;
performing filtering processing on the current single-line touch track to be judged for a plurality of times until the number of high points before and after the filtering processing is the same;
and judging whether the number of the current single-line touch track high points is the same as the preset number of the high points or not.
A mobile terminal touch screen track unlocking processing device comprises:
the track acquisition module is used for acquiring a touch track detected by a touch screen of the mobile terminal;
the judging module is used for judging whether the acquired touch track is a single-line track;
the high point acquisition module is used for acquiring the number of high points in the single-line touch track when the touch track is the single-line track;
and the unlocking control module is used for controlling the unlocking of the mobile terminal when the number of the high points in the single-line touch track is equal to the preset number of the high points for unlocking.
A terminal device comprises a memory, a processor and a mobile terminal touch screen track unlocking processing program which is stored on the memory and can run on the processor, wherein when the processor executes the mobile terminal touch screen track unlocking processing program, the steps of any one of the mobile terminal touch screen track unlocking processing methods are realized.
A computer readable storage medium, wherein a mobile terminal touch screen track unlocking processing program is stored thereon, and when the mobile terminal touch screen track unlocking processing program is executed by a processor, the steps of any one of the mobile terminal touch screen track unlocking processing methods are realized.
Has the advantages that: compared with the prior art, the invention provides a mobile terminal touch screen track unlocking processing method, which comprises the steps of obtaining a touch track detected by a mobile terminal touch screen in advance; and judging whether the track is a single-line track or not, if so, acquiring the coordinates of the touch point on the track and then carrying out corresponding processing to judge whether unlocking is successful or not. After the unlocking is finished, the unlocking track path is not unique, the unlocking mode is more flexible, and the method is convenient for a user to operate and use, so that the selection margin of unlocking when one track is drawn through the touch screen is greatly enriched, the user experience is improved, convenience is provided for the user, and convenience is provided for the user to use.
Detailed Description
In order to make the objects, technical solutions and effects of the present invention clearer and clearer, the present invention is further described in detail below with reference to the accompanying drawings and examples. It should be understood that the specific embodiments described herein are merely illustrative of the invention and are not intended to limit the invention.
It should be noted that, if directional indications (such as up, down, left, right, front, and back … …) are involved in the embodiment of the present invention, the directional indications are only used to explain the relative positional relationship between the components, the movement situation, and the like in a specific posture (as shown in the drawing), and if the specific posture is changed, the directional indications are changed accordingly.
In addition, if there is a description of "first", "second", etc. in an embodiment of the present invention, the description of "first", "second", etc. is for descriptive purposes only and is not to be construed as indicating or implying relative importance or implicitly indicating the number of technical features indicated. Thus, a feature defined as "first" or "second" may explicitly or implicitly include at least one such feature. In addition, technical solutions between various embodiments may be combined with each other, but must be realized by a person skilled in the art, and when the technical solutions are contradictory or cannot be realized, such a combination should not be considered to exist, and is not within the protection scope of the present invention.
Today, people and various terminal devices such as mobile phones, tablets, computers and televisions are surrounded by people and various terminal devices such as videos and videos in life. Terminal devices have slowly penetrated into the corners of people's lives.
With the development of science and technology and the continuous improvement of the living standard of people, various mobile terminals such as mobile phones are more and more popular, and the mobile phones become indispensable communication tools in the life of people. The functions of mobile phones are more and more, and most of the mobile phones have a touch screen function at present.
The touch screen is an input device widely used by the mobile terminal, when a user touches the touch screen, touch coordinate points need to be sent to the central processor, or the central processor needs to read the touch coordinate points from the touch screen and then collects a track for operation.
With the rapid development of the mobile terminal technology, the screen of the mobile terminal is larger and larger at present, and generally occupies a plane of the mobile terminal, and the touch screen is also arranged on the plane, so that the input area of the touch screen is very large, and the touch screen is used on the mobile terminal in a large amount, especially on the intelligent mobile terminal, the touch screen is almost used as a main input device at present, and therefore the unlocking of the intelligent mobile terminal is also almost based on the unlocking of the touch screen. In the prior art, the most common unlocking modes of a touch screen of a mobile terminal are sliding unlocking, password input unlocking, specific pattern drawing unlocking and the like. After the existing unlocking method which is used more is set, the unlocking touch track path is limited, the unlocking mode is inflexible, and the unlocking method is sometimes inconvenient for users to use.
In order to solve the problems in the prior art, the embodiment provides a method for unlocking a touch track of a touch screen of a mobile terminal, and the method of the embodiment is used for acquiring the touch track detected by the touch screen of the mobile terminal; judging whether the acquired touch track is a single-line track; when the touch track is a single-line track, acquiring the number of high points in the single-line touch track; and when the number of the high points in the single-line touch track is equal to the preset number of the high points for unlocking, controlling to unlock the mobile terminal. After the unlocking is finished, the path of the unlocking track is not unique, and the unlocking mode is flexible, so that the selection margin of unlocking when one track is drawn through the touch screen is greatly enriched, the user experience is improved, and convenience is provided for the user.
For example, a user can set 4 high points on the mobile terminal for unlocking the mobile terminal, and when the user wants to unlock the mobile terminal, the user only needs to draw a single-line track touch line with 4 high points (also called vertexes) on the touch screen.
Exemplary method
The method for processing the track unlocking of the touch screen of the mobile terminal can be applied to terminal equipment, and particularly as shown in fig. 1, the method for processing the track unlocking of the touch screen of the mobile terminal comprises the following steps:
s100, acquiring a touch track detected by a touch screen of the mobile terminal;
in the embodiment of the invention, the mobile terminal mobile phone is taken as an example to describe the invention in detail, when the mobile terminal mobile phone needs to be unlocked, a user operates and draws an unlocking graph on a touch screen of the mobile terminal mobile phone, and the touch screen of the mobile terminal mobile phone can detect the touch track of the user on the touch screen in real time and acquire the touch track detected by the touch screen of the mobile terminal.
Preferably, as shown in fig. 2, the step of acquiring the touch trajectory detected by the touch screen of the mobile terminal specifically includes:
step S101, when the touch screen detects that the touch is touched, recording coordinates of touch points according to time;
in the embodiment of the invention, when the user operates on the touch screen and the touch screen detects that the user is touched, the coordinates of the touch points are recorded in time sequence.
And S102, when the touch screen detects the release, finishing the recording to acquire the touch track detected by the touch screen of the mobile terminal.
In the embodiment of the invention, when the user finishes drawing the unlocking track line on the touch screen, the touch is released, and when the touch screen detects the release, the recording is finished to obtain the touch track detected by the touch screen of the mobile terminal.
Step S200, judging whether the acquired touch track is a single-line track;
in the embodiment of the invention, when the touch track operated by the user is acquired, whether the acquired touch track is a single-line track or not is judged in real time. I.e., whether the current touch trajectory is a single line trajectory. According to the invention, a complex touch line is not needed for unlocking, a single line track is adopted, so that the unlocking memory is conveniently reduced, and the unlocking efficiency is accelerated.
Specifically, as shown in fig. 3, the step of determining whether the acquired touch trajectory is a single-line trajectory in step S200 includes:
step S201, judging whether the condition that the same time point comprises two touch points exists in all the touch points recorded in the acquired touch track;
in the embodiment of the invention, when judging whether the condition that the same time point comprises two touch points exists in all the touch points recorded in the acquired touch track. In the embodiment of the invention, the single-line track only has one touch point at the same time. If two touch points exist at the same time, two fingers touch the touch points, and the single-line track is not formed.
Step S202, when the condition that the same time point comprises two touch points exists, judging that the acquired touch track is not a single-line track;
in the embodiment of the present invention, as described above, when it is determined that two touch points are included at the same time point in all touch points recorded in the acquired touch trajectory, it is determined that the acquired touch trajectory is not a single-line trajectory. (ii) a For example, if a time point in the recorded trace includes two touch points p1 and p2, it is considered that the user touches two touch points at the same time, so the trace is not a single-line trace. The invention has simple and convenient judgment and does not occupy excessive memory.
Step S203, when there is no situation that two touch points are included at the same time point, it is determined that the acquired touch trajectory is a single-line trajectory.
In the embodiment of the invention, when the situation that the same time point comprises two touch points does not exist in all the touch points recorded in the acquired touch track, the acquired touch track is judged to be a single-line track. That is, in the embodiment of the present invention, the single-line trace has only one touch point at the same time.
Step S300, when the touch track is a single-line track, acquiring the number of high points in the single-line touch track;
in the embodiment of the invention, when the touch track is a single-line track, the number of high points in the single-line touch track is acquired. The number of high points in this embodiment is as shown in fig. 4, the touch line BC drawn on thetouch screen 10 by the user shown in fig. 4 with the starting point at point B and the terminal point C is a single-line trajectory line, and the high points a1, a2, and A3 in fig. 4 are 3 high point numbers. In the present invention, when the touch trajectory is a single-line trajectory, the number of high points in the single-line touch trajectory, for example, the high points a1, a2, and A3 shown in fig. 4, is 3.
In the specific implementation of the present invention, before S100, a step of:
the number of high points for unlocking the mobile terminal is preset. For example, the number of high points for unlocking the mobile terminal is preset to be 3.
In a preferred embodiment of the present invention, the number of high points in the same direction is used for determining the number of high points. For example, as shown in fig. 4, when the touch trajectory is a single-line trajectory, the number of high points bent in the same direction in the single-line touch trajectory is acquired. The high points a1, a2, and A3 bent in the same direction as shown in fig. 4 are 3 high points.
And S400, when the number of the high points in the single-line touch track is equal to the preset number of the high points for unlocking, controlling to unlock the mobile terminal.
In the embodiment of the invention, when the number of high points in the single-line touch track is equal to the preset number of high points for unlocking, the unlocking of the mobile terminal is controlled. For example, when the preset number of high points for unlocking is 3, and the number of high points in the single-line touch track currently operated by the user on the touch screen of the lock screen is also 3, the number of high points is equal to the preset number of high points for unlocking, the mobile terminal is controlled to be unlocked.
Specifically, as shown in fig. 5, step S300 in this embodiment includes:
step S301, comparing the number of high points in the current single-line touch track with the preset number of high points for unlocking;
as shown in fig. 4, in the embodiment of the present invention, the number of high points bent in the same direction in the current single-line touch trajectory is preferably compared with the preset number of high points for unlocking.
And S302, judging whether the number of high points in the current single-line touch track is equal to the preset number of high points for unlocking or not, and controlling to unlock the mobile terminal if the number of high points in the current single-line touch track is equal to the preset number of high points for unlocking.
Specifically, the step of judging whether the number of high points in the current single-line touch track is equal to the preset number of high points for unlocking includes:
and setting that the current single-line touch track to be judged comprises N touch points, wherein the touch point coordinates of the current single-line touch track to be judged are as follows in chronological order: y1, Y2, … …, YN;
wherein the touch points arranged at the front record earlier time than the touch points arranged at the back;
performing filtering processing on the current single-line touch track to be judged for a plurality of times until the number of high points before and after the filtering processing is the same;
in the embodiment of the present invention, the filtering process includes:
c21, setting that the track to be filtered contains M touch points, wherein the touch point coordinates of the track to be filtered are as follows according to the time sequence: z < 1 >, Y < 2 >, … …, and Z < M >;
and C22, filtering the track to be filtered to obtain track touch point coordinates according to the following time sequence: x < 1 >, X < 2 >, … …, and X < H >;
wherein, X < 1 > -Z < 2 > -Z < 1 >, X < 2 > -Z < 3 > -Z < 2 >, X < 3 > -Z < 4 > -Z < 3 >, … …, and X < H > -Z < M > -Z < 1 >.
Preferably, the high point in the embodiment of the present invention is data whose current data is larger than the previous data and whose current data is smaller than the next data.
And judging whether the number of the current single-line touch track high points is the same as the preset number of the high points or not.
And when the number of high points in the current single-line touch track is judged to be equal to the preset number of high points for unlocking, controlling to unlock the mobile terminal.
Therefore, in the embodiment of the invention, the method is adopted to obtain the touch track detected by the touch screen of the mobile terminal in advance; and judging whether the track is a single-line track or not, if so, acquiring the coordinates of the touch point on the track and then carrying out corresponding processing to judge whether unlocking is successful or not. After the unlocking is finished, the unlocking track path is not unique, the unlocking mode is more flexible, and the method is convenient for a user to operate and use, so that the selection margin of unlocking when one track is drawn through the touch screen is greatly enriched, the user experience is improved, convenience is provided for the user, and convenience is provided for the user to use.
Exemplary device
As shown in fig. 6, an embodiment of the present invention provides a device for unlocking a touch screen track of a mobile terminal, where the device includes:
thetrack acquisition module 10 is configured to acquire a touch track detected by a touch screen of the mobile terminal;
a judgingmodule 20, configured to judge whether the acquired touch trajectory is a single-line trajectory;
a highpoint obtaining module 30, configured to obtain the number of high points in the single-line touch trajectory when the touch trajectory is a single-line trajectory;
and an unlockingcontrol module 40, configured to control to unlock the mobile terminal when the number of high points in the single-line touch trajectory is equal to the preset number of high points for unlocking, which is specifically described above.
In one implementation, thetrajectory acquisition module 10 includes:
the recording unit is used for starting to record the coordinates of the touch points according to time when the touch screen detects that the touch screen is touched;
and the release acquisition unit is used for acquiring the touch track detected by the touch screen of the mobile terminal after recording is finished when the touch screen detects release.
In one implementation, the determiningmodule 20 includes:
the judging unit is used for judging whether the condition that the same time point comprises two touch points exists in all the touch points recorded in the acquired touch track;
the confirming unit is used for judging that the acquired touch track is not a single-line track when the same time point contains two touch points;
and the judging unit is used for judging that the acquired touch track is a single-line track when the condition that the same time point contains two touch points does not exist.
In one implementation, the unlockingcontrol module 40 includes:
the comparison unit is used for comparing the number of high points in the current single-line touch track with the preset number of high points for unlocking;
and the unlocking control unit is used for judging whether the number of high points in the current single-line touch track is equal to the preset number of high points for unlocking or not, and controlling to unlock the mobile terminal if the number of high points in the current single-line touch track is equal to the preset number of high points for unlocking.
Based on the above embodiments, the present invention further provides a terminal device, and a schematic block diagram thereof may be as shown in fig. 7. The terminal equipment comprises a processor, a memory, a network interface, a display screen and a touch screen which are connected through a system bus. Wherein the processor of the terminal device is configured to provide computing and control capabilities. The memory of the terminal equipment comprises a nonvolatile storage medium and an internal memory. The non-volatile storage medium stores an operating system and a computer program. The internal memory provides an environment for the operation of an operating system and computer programs in the non-volatile storage medium. The network interface of the terminal device is used for connecting and communicating with an external terminal through a network. The computer program is executed by a processor to realize a mobile terminal touch screen track unlocking processing method. The display screen of the terminal equipment can be a liquid crystal display screen or an electronic ink display screen, and the touch screen of the terminal equipment is arranged on the terminal equipment in advance.
It will be understood by those skilled in the art that the block diagram of fig. 7 is only a block diagram of a part of the structure related to the solution of the present invention, and does not constitute a limitation to the terminal device to which the solution of the present invention is applied, and a specific terminal device may include more or less components than those shown in the figure, or combine some components, or have a different arrangement of components.
In one embodiment, a terminal device is provided, where the terminal device includes a memory, a processor, and a mobile terminal touch screen trajectory unlocking processing program stored in the memory and executable on the processor, and when the processor executes the mobile terminal touch screen trajectory unlocking processing program, the following operation instructions are implemented:
acquiring a touch track detected by a touch screen of the mobile terminal;
judging whether the acquired touch track is a single-line track;
when the touch track is a single-line track, acquiring the number of high points in the single-line touch track;
and when the number of the high points in the single-line touch track is equal to the preset number of the high points for unlocking, controlling to unlock the mobile terminal, specifically as described above.
The step of obtaining the touch track detected by the touch screen of the mobile terminal comprises the following steps:
the number of high points for unlocking the mobile terminal is preset.
The step of acquiring the touch track detected by the touch screen of the mobile terminal comprises the following steps:
when the touch screen detects that the touch point is touched, the coordinates of the touch point are recorded in time sequence;
and when the touch screen detects the release, finishing the recording to acquire the touch track detected by the touch screen of the mobile terminal.
Wherein, the step of judging whether the acquired touch track is a single-line track comprises:
judging whether the condition that the same time point comprises two touch points exists in all the touch points recorded in the acquired touch track;
when the condition that the same time point contains two touch points exists, judging that the acquired touch track is not a single-line track;
and when the condition that the same time point contains two touch points does not exist, judging that the acquired touch track is a single-line track.
Wherein, when the touch track is a single-line track, the step of acquiring the number of high points in the single-line touch track comprises:
and when the touch track is a single-line track, acquiring the number of high points bent towards the same direction in the single-line touch track.
Wherein, when the number of the high points in the single-line touch track is equal to the preset number of the high points for unlocking, the step of controlling to unlock the mobile terminal comprises the following steps:
comparing the number of high points in the current single-line touch track with the preset number of high points for unlocking;
and judging whether the number of high points in the current single-line touch track is equal to the preset number of high points for unlocking or not, and controlling to unlock the mobile terminal if the number of high points in the current single-line touch track is equal to the preset number of high points for unlocking.
The step of judging whether the number of high points in the current single-line touch track is equal to the preset number of high points for unlocking or not comprises the following steps:
and setting that the current single-line touch track to be judged comprises N touch points, wherein the touch point coordinates of the current single-line touch track to be judged are as follows in chronological order: y1, Y2, … …, YN;
wherein the touch points arranged at the front record earlier time than the touch points arranged at the back;
performing filtering processing on the current single-line touch track to be judged for a plurality of times until the number of high points before and after the filtering processing is the same;
and judging whether the number of the current single-line touch track high points is the same as the preset number of the high points or not.
It will be understood by those skilled in the art that all or part of the processes of the methods of the embodiments described above can be implemented by hardware instructions of a computer program, which can be stored in a non-volatile computer-readable storage medium, and when executed, can include the processes of the embodiments of the methods described above. Any reference to memory, storage, databases, or other media used in embodiments provided herein may include non-volatile and/or volatile memory. Non-volatile memory can include read-only memory (ROM), Programmable ROM (PROM), Electrically Programmable ROM (EPROM), Electrically Erasable Programmable ROM (EEPROM), or flash memory. Volatile memory can include Random Access Memory (RAM) or external cache memory. By way of illustration and not limitation, RAM is available in a variety of forms such as Static RAM (SRAM), Dynamic RAM (DRAM), Synchronous DRAM (SDRAM), Double Data Rate SDRAM (DDRSDRAM), Enhanced SDRAM (ESDRAM), Synchronous Link DRAM (SLDRAM), Rambus Direct RAM (RDRAM), direct bus dynamic RAM (DRDRAM), and memory bus dynamic RAM (RDRAM).
In summary, the invention discloses a method and a device for processing track unlocking of a touch screen of a mobile terminal, a terminal device and a storage medium, wherein the method comprises the following steps: acquiring a touch track detected by a touch screen of the mobile terminal; judging whether the acquired touch track is a single-line track; when the touch track is a single-line track, acquiring the number of high points in the single-line touch track; and when the number of the high points in the single-line touch track is equal to the preset number of the high points for unlocking, controlling to unlock the mobile terminal. After the unlocking is finished, the path of the unlocking track is not unique, and the unlocking mode is flexible, so that the selection margin of unlocking when one track is drawn through the touch screen is greatly enriched, the user experience is improved, and convenience is provided for the user.
Finally, it should be noted that: the above examples are only intended to illustrate the technical solution of the present invention, but not to limit it; although the present invention has been described in detail with reference to the foregoing embodiments, it will be understood by those of ordinary skill in the art that: the technical solutions described in the foregoing embodiments may still be modified, or some technical features may be equivalently replaced; and such modifications or substitutions do not depart from the spirit and scope of the corresponding technical solutions of the embodiments of the present invention.