This Non-provisional application claims priority under 35 U.S.C. ยง119(a) on Patent Application No(s). 102127273 filed in Taiwan, Republic of China on Jul. 30, 2013, the entire contents of which are hereby incorporated by reference.
1. Field of Invention
The invention relates to a method and an electronic device for touch control and, in particular, to a method and an electronic device with touch control functionalities for disabling a touch point.
2. Related Art
Handheld devices have become lighter and thinner with their sizes become larger. If the width of the frame of a handheld device is insufficient, to grip the device more firmly, it is inevitable for the user to touch the device inadvertently, which causes the confusion of the user. Currently on the market there exist handheld devices with erroneous-touch prevention functions, which disable the touch function directly or implement certain special touch rules to reduce the effect of erroneous touches. In the former design, the handheld device disables the touch function directly when, for example, the handheld device enters into a conversation mode. Alternatively, when the user put the handheld device near his or her face or ear, the system can detect a specific area (that is, the area touched by the face or ear of the user) and disable the touch function of the handheld device. Under this situation, the user can grip the handheld device without invoking any touch operations. However, in other operation modes, any touch may cause the response of the system, which results in the confusion of the user. In the later design, the touch function will temporarily disabled when, for example, a finger of the user touches one point of the touch screen and remains unmoved, and the touch function is resumed when the finger starts to move. With this design, it would be inconvenient when the user needs to grip the lateral side of the handheld device for a long time since the touch function might be disabled due to the touch of the finger. In short, the erroneous-touch prevention functions mentioned above are designed for specific use scenarios. Therefore, for handheld devices there is still no erroneous-touch prevention function designed for most practical usage scenarios.
In view of the issue in the prior art, an objective of the invention is to provide a method for disabling a touch point, which can be implemented in a handheld device. The method uses the time of the touch to determine whether it is a real touch operation or just a long touch on the touch screen due to other reasons (such as the grip of the device), therefore the unexpected touch behavior can be excluded effectively and application programs can keep operating normally.
The method of disabling a touch point according to the invention is adapted for an electronic device including a touch screen. The electronic device has a register table. The method including the steps of: periodically receiving touch information on the touch screen; generating touch point data corresponding to the touch information; updating the register table according to the touch point data; determining whether there exists a touch point in the register table that remains unmoved for more than a predetermined time period; and if yes, ignoring the touch point.
Another objective of the invention is to provide an electronic device implementing the touch point disabling method of the invention. Therefore, the electronic device can exclude the unexpected touch behavior effectively and keep operating normally.
The electronic device of the invention includes a touch screen and a processing module. The processing module is electrically connected with the touch screen and stores a register table. The processing module periodically receives touch information on the touch screen, generates touch point data corresponding to the touch information, updates the register table according to the touch point data, determines whether there exists a touch point in the register table that remains unmoved for more than a predetermined time period, and if yes, ignores the touch point.
Therefore, for example when the touch information is information having a touch point, and the touch point (or more touch points) remains unmoved for more than a predetermined time period (such as longer than the maximum time for an application program to respond to the touch operation), this touch point can be treated as an unexpected touch behavior (such as the long touch caused by gripping a handheld device) and can be ignored without passing relevant information of this touch point to relevant application program. To the application program, such touch point does not exist, thus the application program can respond to other touch operations of the user correctly, which conforms to the actual use scenario of a handheld device. The method of disabling a touch point and the electronic device implementing the same can exclude unexpected touch behaviors effectively, that is, touch point data related to this touch point is not passed to relevant application programs, so that the application programs can operate normally (such as to respond to other touch operations of the user).
The invention will become more fully understood from the detailed description and accompanying drawings, which are given for illustration only, and thus are not limitative of the present invention.
Please refer to
According to the method, touch point data corresponding to the touch information are generated, as shown in step S220. In practice, the touch point data corresponding to each of the touch points P1 and P2 may include an identification code, a type of the touch event, and a position coordinate. The identification code (such as a positive integer) is for identifying the corresponding touch point. The type of the touch event is for identifying the touch behavior (such as a lift action, a move action or a press action) of the corresponding touch point. The position coordinate is for recording the position (such as the coordinate on the touch screen 12) of the corresponding touch point. Afterward, the touch point data are recorded or updated in the register table 142, as shown in step S230. The register table 142 is used to track the status of each touch point P1 and P2. Every time when periodically receiving touch points P1 and P2, the touch points P1 and P2 in the register table 142 can be updated correctly based on the identification code in the touch point data generated correspondingly.
According to the method, the register table 142 is used to determine whether the touch point data include a touch point that remains unmoved for more than a predetermined time period (such as the touch point P1), as shown in step S240. If yes, then this touch point (such as touch point P1) is ignored, as shown in step S250. Practically, to ignore the touch point P1 means that the touch point data related to this touch point P1 are not passed to relevant application programs. For application programs, this touch point P1 does not exist. Under this situation, the physical contact at the touch point P1 does not affect the operation of application programs (including responding to other touch operations). Moreover, the predetermined time period mentioned previously may be set or adjusted by the user. For example, it can be set to be longer than the maximum time for an application program to respond to a touch operation, so that the original touch operation related to the application program would not be interfered by the execution of the method of the present embodiment.
Please refer to
Since the method of the embodiment is focused on the disable of the touch point which remains unmoved for a long time, practically the register table 142 may include the identification code corresponding to the touch point, the cumulative time of the touch point remains unmoved and a disable flag. The disable flag may be set to identify whether the cumulative time for the touch point to remain unmoved has exceeded a threshold to be disabled (that is, the predetermined time period mentioned previously). For example, setting the disable flag to be true means that the corresponding touch point is disabled, while setting the disable flag to be false means the corresponding touch point has not been disabled.
Next, how to update the register table 142 according to the touch point data will be explained. The register table 142 is used to determine whether the touch point in the touch point data is new, as shown in step S330. This may be realized by comparing the identification code of this touch point with the identification code recorded in the register table 142. For example, after the second receiving of the touch points P1 and P2, the identification codes corresponding to the touch points P1 and P2 are compared with the identification codes in the register table 142. Under this situation, since the identification codes of the touch points P1 and P2 are recorded in the register table 142, the determination result is no (and then proceeds to step S332). To the contrary, if the identification code in the touch point data does not exist in the register table 142, the corresponding touch point is new, that is, is received for the first time. Therefore, the register table 142 is updated to add the touch point data of the new touch point in the register table 142 (and then proceeds to step S331).
If the determination result of step S330 is yes, the record corresponding to the new touch point is added in the register table 142, as shown in step S331. The initial setting of the disable flag corresponding to the new touch point is false. If the determination result of step S330 is no, it is determined whether the touch point is disabled according to the register table 142, as shown in step S332. This can be realized by reading the setting of the disable flag in the register table 142 corresponding to this touch point. If the determination result of step S332 is yes, the touch point is already disabled and is ignored. Therefore the touch point data corresponding to the touch point are not passed to the application program, as shown in step S333. In the present embodiment, the disabled touch point is not further processed. Therefore the record in the register table 142 corresponding to this touch point can remain unchanged. However, the invention is not limited therein. Practically, whether the record in the register table 142 corresponding to the touch point needs to be changed can be determined in view of the need of practical applications.
If the determination result of step S332 is no, the register table 142 is updated according to the touch point data. Since the types of the touch events (such as a lift action, a move action or a press action) are different, different operations are performed in view of different types of the touch events. For concise purpose, the explanations below will be focused on the determination of the touch point that remains unmoved.
When the touch point moves slightly, that is, when the position of the touch point is still within an admissible area, the touch point is deemed to remain unmoved and the cumulative time in the register table 142 corresponding to the touch point is updated according to the touch point data, as shown is step S334. For example, the user may apply force at the thumb of the left hand to grip the handheld device more effectively, which causes the slight move of the touch point P1. Such slight move may be deemed as no movement which conforms to the expectation of the user. On the other hand, when the amount of the move of the touch point is larger, the touch point may be determined as undergoing a touch operation, and the touch point data corresponding to this touch point can be passed to the application program for further operations such as the move operation of the touch point P2. The admissible area may be set considering the overall behavior of ordinary users, or may be set by the user.
Moreover, when the touch point remains unmoved, the cumulative time in the register table 142 corresponding to the touch point is updated according to the touch point data, as shown in step S335. When the touch point is moved to leave the touch screen, the record of the touch point in the register table 142 is cleared, as shown in step S336. Practically, if the cumulative time of this removed touch point does not exceed the predetermined time period, the touch point data corresponding to this touch point are passed to relevant application programs for further operations, such as a single point touch control.
Moreover, after the steps S334 and S335, if it is determined that the touch point remains unmoved more than the predetermined time period according to the register table 142, the disable flag in the register table corresponding to the touch point is set to be true, that is, the touch point can be ignored, as shown in step S337. Practically, the electronic device 1 may generate a vibration simultaneously to inform the user that a touch point has been disabled. After one cycle the process can return to step S310 to execute the next cycle.
Note that the main purpose of the flowcharts shown in
Furthermore, as described in the previous embodiment, whether a touch point can be passed to relevant application programs is determined by the disable flag in the register table 142. That is, whether a touch point is disabled can be determined by filtering the register table 142. Therefore, logically the register table 142 can be treated as a filter to filter out the touch points that remain unmoved for more than the predetermined time period. Since it is necessary for the method for disabling the touch point according to the embodiment to determine whether the touch point remains unmoved for more than the predetermined time period, it has the effect of delaying touch operations. Moreover, logically, although the register table 142 may be represented by the form of a table, practically it may be implemented by various kinds of data structures and is not limited to the form of a table. Moreover, the register table 142 may also be implemented by multiple tables linked to each other. The invention is not limited therein.
In practical applications, the touch points remain unmoved for a long time may be still meaningful for certain application programs. For example, the throttle or brake buttons of a car racing game may be pressed for a long time. Therefore, the method for disabling a touch point according to the invention may be selectively executed in view of different application programs. Please refer to
In practical applications, the application program list may be editable and may include name of the application programs and whether the touch point disabling function is activated or not. In the previous embodiment, when the option is selected, the touch pint disabling function of the corresponding application programs is activated, and vice versa. The application programs listed in the application program list can be added, deleted or edited by the user. Alternatively, the addition or deletion of application programs may be done by the system automatically, while the edition of the list is still reserved to the user.
Please refer to
To sum up, the touch point disabling method and the device implementing this method according to the invention uses the duration of the touch point to prevent an application program from being affected by an unexpected touch behavior. Simply speaking, when a touch point (or more touch points) remains unmoved for more than a predetermined time period (such as longer than the maximum time for an application program to respond to the touch operation), this touch point can be treated as an unexpected touch behavior (such as the long touch caused by gripping the handheld device) and can be ignored without passing relevant information of this touch point to relevant application program. To the application program, such touch point does not exist, thus the application program can respond to other touch operations of the user correctly, which conforms to the actual use scenario of the handheld device. Therefore, the invention can solve the issue in the prior art that cannot distinguish an unexpected touch behavior and a normal touch behavior, and can provide a user a more convenient touch control environment.
Although the invention has been described with reference to specific embodiments, this description is not meant to be construed in a limiting sense. Various modifications of the disclosed embodiments, as well as alternative embodiments, will be apparent to persons skilled in the art. It is, therefore, contemplated that the appended claims will cover all modifications that fall within the true scope of the invention.
Number | Date | Country | Kind |
---|---|---|---|
102127273 | Jul 2013 | TW | national |