CN101106782A - Keyboard locking method for mobile terminal - Google Patents

Keyboard locking method for mobile terminal Download PDF

Info

Publication number
CN101106782A
CN101106782A CNA2007101300287A CN200710130028A CN101106782A CN 101106782 A CN101106782 A CN 101106782A CN A2007101300287 A CNA2007101300287 A CN A2007101300287A CN 200710130028 A CN200710130028 A CN 200710130028A CN 101106782 A CN101106782 A CN 101106782A
Authority
CN
China
Prior art keywords
keyboard
locking
application
key dish
locking key
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.)
Pending
Application number
CNA2007101300287A
Other languages
Chinese (zh)
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.)
ZTE Corp
Original Assignee
ZTE Corp
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 ZTE Corp filed Critical ZTE Corp
Priority to CNA2007101300287A priority Critical patent/CN101106782A/en
Publication of CN101106782A publication Critical patent/CN101106782A/en
Pending legal-status Critical Current

Links

Images

Landscapes

  • Telephone Function (AREA)
  • Input From Keyboards Or The Like (AREA)

Abstract

The invention provides a method for locking keyboard of a mobile terminal. The method includes: setting a keyboard-locking program in a keyboard detection program; allowing the keyboard detection program to perform keyboard-locking application if satisfaction for predetermined conditions is detected; packaging the independent module for logic application of the keyboard-locking application; performing suspension on the application (being activated) via the switching mechanism for applications when the keyboard-locking application starts; and recovering the suspended application when the keyboard-locking application exits. With the invention, logic of keyboard-locking application can be realized by using independent applications to achieve independency of the keyboard-locking application; and meanwhile, the specific implementation code has no influence on any implemented application, thereby greatly reducing coupling between applications and being suitable for all applications. Furthermore, the inventive method can be applied to mobile phones with any modes and has general applicability.

Description

The keyboard locking method of portable terminal
Technical field
The present invention relates to communication and electronic applications, particularly, relate to the keyboard locking method of portable terminal, by means of this method, portable terminal can lock keyboard under using arbitrarily.
Background technology
At present, all straight plate portable terminal (for example, mobile phone) all has the function of automatic locking keyboard and manual lock keyboard basically.So-called automatic locking keyboard is meant: if the user does not have actuation of keys in given time, system can automatically lock keyboard to prevent user's the misoperation that button causes that is not intended to so; The manual lock keyboard is meant: the user forces keyboard to enter lock-out state after manually pressing specific keystroke sequence in some way.In case mobile phone is in the lock state, can only could make mobile phone be in normal button operating state by the release keyboard by specific keystroke sequence so.
Yet, find that by observing and study present most of mobile phone terminals (except that the smart mobile phone that uses specific operation system) nearly all mobile phone can only carry out the locking of keyboard under standby interface.The purpose of locking keyboard mainly is in order to prevent misoperation, can not under using, other realize if can only under standby interface, lock keyboard so, under using, other just are easy to cause misoperation so, especially concern the application (for example file manager) of user's significant data for some, its misoperation may cause file modifying or deletion, and consequence is very serious sometimes.In order to reduce the harm that misoperation brings as much as possible, the best way is exactly can lock keyboard under all are used so.In addition, the locking of keyboard can also bring another kind of benefit, can make mobile phone enter energy-saving mode as early as possible to increase the stand-by time of mobile phone exactly.
Thereby, realize that the keyboard lockout under all application is a kind of very practical and valuable function, but still be unrealized relevant therewith technology at present.
Summary of the invention
Consider the above-mentioned problems in the prior art and propose the present invention, for this reason, the present invention aims to provide a kind of keyboard locking method of portable terminal, and it can realize the keyboard lockout under all application.
According to the present invention, a kind of keyboard locking method of portable terminal is provided, comprising: locking key dish trace routine is set in the keyboard detection program, is detecting under the situation that satisfies predetermined condition, locking key dish trace routine starts the locking key dish and uses; Using the logic of locking key dish application independently, module encapsulates; The handover mechanism that utilizes the locking key dish to use starting the application of hanging up current activation when the locking key dish is used, when withdrawing from the application of locking key dish, recovers the application that is suspended.
Wherein, locking key dish trace routine starts the processing that the locking key dish uses and further comprises: step S202, catch KeyEvent before KeyEvent being sent to the application of current activation in the keyboard detection program; Step S204 carries out preliminary treatment to the KeyEvent of catching, and judges whether to satisfy the predetermined condition that starts the application of locking key dish; Step S206 according to the judged result among the step S204, starts the locking key dish in a different manner and uses.
In step S202, obtain KeyEvent at system kernel and decipher with the application that becomes current activation and catch KeyEvent after the discernible KeyEvent code.
In addition, set in advance automatic locking keyboard timer,, then start the application of locking key dish and automatically lock keyboard, otherwise restart the reclocking of automatic locking keyboard timer if in the timing of automatic locking keyboard timer, do not have button operation.Set in advance long by " # " key timer, when pressing " # " key, start long by " # " key timer, if be released by " # " key in the timing of " # " key timer long, then cancellation is long by " # " key timer cancellation timing, if be not released by " # " key in the timing of " # " key timer, then start the locking key dish and use long.
Like this, in step S204, predetermined condition be following any: do not have button operation in the given time; The user has carried out the button operation of particular sequence.Correspondingly, in step S206,, directly start the locking key dish and be applied to the keyboard lockout state judging in the scheduled time do not have under the situation of button operation; Judging that the user has carried out under the situation of button operation of particular sequence, starts the locking key dish and is applied to the Subscriber Locked state of waiting for.
In addition, locking key dish trace routine needed also to judge that can the application of current activation locked before starting the application of locking key dish, was under the situation not in judged result, detect next time, and be under the situation that is in judged result, with the application locking of current activation.
The processing that the logic that the locking key dish is used uses module independently to encapsulate further comprises: step S402 copies the screen display of the application of current activation, the screen background of using as the locking key dish; Step S404 realizes the interface that the locking key dish is used according to the state machine pattern, makes the corresponding different interface of different state machine patterns, and according to the migration at Event triggered interface; Step S406 simulates the logic that the locking key dish is used by the migration at interface.
By the present invention, use independent utility to realize the logic that the locking key dish is used, can reach the independence that the locking key dish is used, simultaneously, the specific implementation code does not influence any application that has realized, has reduced the coupling between using greatly, can adapt to all application simultaneously.In addition, implementation of the present invention may be used on having general applicability in the mobile phone of all standards.
Description of drawings
Accompanying drawing is used to provide further understanding of the present invention, and constitutes the part of specification, is used from explanation the present invention with embodiments of the invention one, is not construed as limiting the invention.In the accompanying drawings:
Fig. 1 is the flow chart according to the keyboard locking method of the portable terminal of the embodiment of the invention;
Fig. 2 is the flow chart that starts the processing of locking key dish application according to locking key dish trace routine in the keyboard locking method of the portable terminal of the embodiment of the invention;
Fig. 3 is the flow chart according to the KeyEvent trace routine that starts the application of locking key dish in the keyboard locking method of the portable terminal of the embodiment of the invention;
Fig. 4 is the flow chart that uses the processing that module independently encapsulates according to the logic of in the keyboard locking method of the portable terminal of the embodiment of the invention locking key dish being used; And
Fig. 5 is the schematic diagram that uses module independently to encapsulate according to the logic of in the keyboard locking method of the portable terminal of the embodiment of the invention locking key dish being used.
Embodiment
Below in conjunction with accompanying drawing the preferred embodiments of the present invention are described, should be appreciated that preferred embodiment described herein only is used for description and interpretation the present invention, and be not used in qualification the present invention.
According to the embodiment of the invention, provide a kind of keyboard locking method of portable terminal.
As shown in Figure 1, this method comprises:
Step S102 is provided with locking key dish trace routine (trace routine that can comprise automatic locking keyboard and manual lock keyboard) in the keyboard detection program, detecting under the situation that satisfies predetermined condition, and locking key dish trace routine starts the locking key dish and uses; Step S104, using the logic of locking key dish application independently, module encapsulates; Step S106, the handover mechanism that utilizes the locking key dish to use is starting the application of hanging up current activation when the locking key dish is used, when withdrawing from the application of locking key dish, the application that recovery is suspended (this step is to realize automatically on most of mobile phone operating systems, otherwise needs the user manually to realize).
Wherein, locking key dish trace routine starts the processing that the locking key dish uses and further comprises: step S202, catch KeyEvent before KeyEvent being sent to the application of current activation in the keyboard detection program; Step S204 carries out preliminary treatment to the KeyEvent of catching, and judges whether to satisfy the predetermined condition that starts the application of locking key dish; Step S206 according to the judged result among the step S204, starts the locking key dish in a different manner and uses.
Below will describe the testing process of KeyEvent in the above-mentioned processing in detail further combined with Fig. 3.
The KeyEvent trace routine that startup locking key dish shown in Fig. 3 is used is that the locking key dish is used the correct key that starts.For convenience of explanation, suppose that the automatic locking keyboard is to be triggered without any button in the given time, trigger the back and start the application of locking key dish and directly enter lock-out state; The manual lock keyboard is to be triggered after length is by " # " key, point out the user to press and do the locking that software carries out keyboard this moment, if the user does not press this key at the appointed time, then close the locking key dish that just has been activated and use, and (following description is also based on this kind hypothesis) used in the current activation that recovers to be suspended.
It should be noted that the locking key dish is used must carry out after start is finished, because only after core application all normally starts, the locking key dish is just meaningful.
1, system's KeyEvent catches
In step S202, particularly, to obtain KeyEvent at system kernel and decipher with the application that becomes current activation after the discernible KeyEvent code, KeyEvent is caught in the application that KeyEvent is sent to current activation before.This is because the keyboard detection task of system normally is independent of application, has only to catch KeyEvent at this moment and just can carry out the most comprehensive judgement so that correctly lock judgement.
2, the startup flow process of locking key dish application
In order to carry out the keyboard lockout of success, be unable to do without the use of timer.
The automatic locking keypad function need set in advance automatic locking keyboard timer, so that starting the locking key dish after regularly finishing automatically uses, if in the timing of automatic locking keyboard timer, do not have button operation, then start the application of locking key dish and automatically lock keyboard, otherwise restart the reclocking of automatic locking keyboard timer.This is the logic of automatic locking keyboard.Certainly, the automatic locking keypad function can be closed in that module is set, and timing also can be set up module settings in addition.
The realization of manual lock keypad function also be unable to do without timer, because about fixed length is used for manually booting the locking key dish by " # " key, so in order to realize the manual lock keypad function, set in advance long by " # " key timer, when pressing " # " key, start long by " # " key timer, if be released by " # " key in the timing of " # " key timer long, then cancellation is long by " # " key timer cancellation timing, if be not released by " # " key in the timing of " # " key timer, then start the locking key dish and use long.
Notice that EVT_KEY, EVT_KEY_PRESS and EVT_KEY_RELEASE represent respectively that key-press event, button are pressed incident, button lifts incident among Fig. 3.
In addition, in order to give the flexible processing mode of using, the decision logic that can the application of a current activation locked (locking) is wherein arranged, locking key dish trace routine is before starting the application of locking key dish, need also to judge that can the application of current activation locked, here mainly be the inquiry current application whether allow to carry out keyboard lockout in case take corresponding operation (judged result for situation not under, detect next time, in judged result is under the situation that is, with the application locking of current activation).Notice that this application does not need to lock once more for the locking key dish, that is, in a single day system just is in the lock state and can not be locked once more.
Like this, in step S204, predetermined condition be following any: do not have button operation in the given time; The user has carried out the button operation of particular sequence.Correspondingly, in step S206,, directly start the locking key dish and be applied to the keyboard lockout state judging in the scheduled time do not have under the situation of button operation; Judging that the user has carried out under the situation of button operation of particular sequence, starts the locking key dish and is applied to the Subscriber Locked state of waiting for.
Based on content described above, further describe other subsequent treatment after the testing process of KeyEvent.
As shown in Figure 4, the processing among the step S104 further comprises: step S402 copies the screen display of the application of current activation, the screen background of using as the locking key dish; Step S404 realizes the interface that the locking key dish is used according to the state machine pattern, makes the corresponding different interface of different state machine patterns, and according to the migration at Event triggered interface; Step S406 simulates the logic that the locking key dish is used by the migration at interface.
Wherein, Fig. 5 shows the system mode transition graph that the locking key dish is used, and can find out realization logic (mechanism by a kind of state machine realizes) that the locking key dish uses clearly for the simplest realization applied logic by this figure, the interface state below the definition:
(a) released state: no interface, will close application this moment.
(b) wait locks: bottom strip left side soft key is for locking.
(c) manually lock successfully: bottom strip and background become ash, and prompting " successfully locking keyboard ", and bottom strip left side soft key is for locking.
(d) automatic lockout success: bottom strip and background become ash, and prompting " successfully locking keyboard ", the bottom strip that bottom strip is used for locking.
(e) lock-out state: bottom strip is the little image of a locking sign.
(f) release prompting: bottom strip and background become ash, and prompting " is carried by separating locking key by the # key earlier ".
(g) wait for release: background becomes ash, and prompting " please by separating locking key ", and bottom strip left side soft key is release.
(h) release success: bottom strip and background become ash, prompting " successful release keyboard ".
Need to prove that background above-mentioned is meant and enters the interface that the activation before the locking key dish is used is used that just activate application and be suspended front interface, it is to obtain by the copy current screen; Bottom strip is meant zone, mobile phone screen below, is mainly used to show the concrete function of current left and right sides soft key.
Can clearly find out the concrete event handling logic that the locking key dish is used according to Fig. 5: the locking key dish is used main hang-up and the recovery incident of handling key-press event and application.For key-press event, main " # " key and the left soft key (being responsible for locking or release) paid close attention to, other buttons then directly eject corresponding prompt, play the effect of final shield keyboard incident.For the hang-up incident, mainly be system mode to be set so that correct display interface when recovering; For the recovery incident, mainly be that the state of system is drawn the interface when hanging up.It should be noted that and do not show the processing of hanging up the recovery incident among the figure.
By the present invention, can solve present most mobile phone can only lock keyboard under standby interface limitation, make it possible to achieve the keyboard lockout under all application, thereby improved cellphone subscriber's experience.
The above is the preferred embodiments of the present invention only, is not limited to the present invention, and for a person skilled in the art, the present invention can have various changes and variation.Within the spirit and principles in the present invention all, any modification of being done, be equal to replacement, improvement etc., all should be included within protection scope of the present invention.

Claims (9)

1. the keyboard locking method of a portable terminal is characterized in that, comprising:
Locking key dish trace routine is set in the keyboard detection program, is detecting under the situation that satisfies predetermined condition, described locking key dish trace routine starts the locking key dish and uses;
Using the logic of described locking key dish application independently, module encapsulates; And the handover mechanism that utilizes described locking key dish to use, starting the application of hanging up current activation when described locking key dish is used, when withdrawing from described locking key dish and use, recover the application that is suspended.
2. keyboard locking method according to claim 1 is characterized in that, the processing that described locking key dish trace routine starts described locking key dish application further comprises:
Step S202 catches described KeyEvent before KeyEvent being sent to the application of described current activation in described keyboard detection program;
Step S204 carries out preliminary treatment to the described KeyEvent of catching, and judges whether to satisfy the described predetermined condition that starts described locking key dish application; And
Step S206 according to the judged result among the described step S204, starts described locking key dish in a different manner and uses.
3. keyboard locking method according to claim 2, it is characterized in that, in described step S202, obtain described KeyEvent at system kernel and decipher with the application that becomes described current activation and catch described KeyEvent after the discernible KeyEvent code.
4. keyboard locking method according to claim 2, it is characterized in that, set in advance automatic locking keyboard timer, if in the timing of described automatic locking keyboard timer, do not have button operation, then start the application of locking key dish and automatically lock keyboard, otherwise restart the reclocking of automatic locking keyboard timer.
5. keyboard locking method according to claim 2, it is characterized in that, set in advance long by " # " key timer, when pressing " # " key, start described length by " # " key timer, if be released by " # " key in the timing of " # " key timer in described length, then cancel described length by " # " key timer cancellation timing,, then start described locking key dish and use if be not released by " # " key in the timing of " # " key timer in described length.
6. according to claim 4 or 5 described keyboard locking methods, it is characterized in that, in described step S204, described predetermined condition be following any: do not have button operation in the given time; The user has carried out the button operation of particular sequence.
7. keyboard locking method according to claim 6 is characterized in that, in described step S206, judging in the scheduled time do not have under the situation of button operation, directly starts described locking key dish and is applied to the keyboard lockout state; Judging that the user has carried out under the situation of button operation of particular sequence, starting described locking key dish and be applied to and wait for user's manual locking keyboard.
8. according to each described keyboard locking method in the claim 1 to 5, it is characterized in that, described locking key dish trace routine is before starting described locking key dish application, need also to judge that can the application of described current activation locked, in judged result is under the situation not, detect, be under the situation that is in judged result next time, with the application locking of described current activation.
9. according to each described keyboard locking method in the claim 1 to 5, it is characterized in that the processing that the logic that described locking key dish is used uses module independently to encapsulate further comprises:
Step 8402 copies the screen display of the application of described current activation, the screen background of using as described locking key dish;
Step S404 realizes the interface that described locking key dish is used according to the state machine pattern, makes the corresponding different interface of different state machine patterns, and according to the migration at Event triggered interface; And
Step S406 simulates the logic that described locking key dish is used by the migration at interface.
CNA2007101300287A 2007-07-25 2007-07-25 Keyboard locking method for mobile terminal Pending CN101106782A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CNA2007101300287A CN101106782A (en) 2007-07-25 2007-07-25 Keyboard locking method for mobile terminal

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CNA2007101300287A CN101106782A (en) 2007-07-25 2007-07-25 Keyboard locking method for mobile terminal

Publications (1)

Publication Number Publication Date
CN101106782A true CN101106782A (en) 2008-01-16

Family

ID=39000407

Family Applications (1)

Application Number Title Priority Date Filing Date
CNA2007101300287A Pending CN101106782A (en) 2007-07-25 2007-07-25 Keyboard locking method for mobile terminal

Country Status (1)

Country Link
CN (1) CN101106782A (en)

Cited By (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101958973A (en) * 2010-09-19 2011-01-26 中兴通讯股份有限公司 Mobile terminal and keyboard locking method thereof
CN102098384A (en) * 2011-01-07 2011-06-15 中兴通讯股份有限公司 Unlocking method and locking method of multi-mode and multi-standby terminal and multi-mode and multi-standby terminal
CN102346624A (en) * 2010-07-30 2012-02-08 比亚迪股份有限公司 Mobile terminal and control method thereof
CN103067578A (en) * 2012-12-24 2013-04-24 惠州Tcl移动通信有限公司 Intelligent lock screen function achieving method based on mobile terminal and mobile terminal
CN106042016A (en) * 2015-04-15 2016-10-26 松下知识产权经营株式会社 Electric appliance
CN109002438A (en) * 2018-07-02 2018-12-14 北京分音塔科技有限公司 False-touch prevention method, apparatus and translator

Cited By (12)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102346624A (en) * 2010-07-30 2012-02-08 比亚迪股份有限公司 Mobile terminal and control method thereof
CN101958973A (en) * 2010-09-19 2011-01-26 中兴通讯股份有限公司 Mobile terminal and keyboard locking method thereof
CN101958973B (en) * 2010-09-19 2014-01-01 中兴通讯股份有限公司 Mobile terminal and keyboard locking method thereof
CN102098384A (en) * 2011-01-07 2011-06-15 中兴通讯股份有限公司 Unlocking method and locking method of multi-mode and multi-standby terminal and multi-mode and multi-standby terminal
WO2012092738A1 (en) * 2011-01-07 2012-07-12 中兴通讯股份有限公司 Unlocking and locking methods for multi-mode and multi-standby terminals and multi-mode and multi-standby terminal
CN102098384B (en) * 2011-01-07 2014-02-19 中兴通讯股份有限公司南京分公司 Unlocking method and locking method of multi-mode and multi-standby terminal and multi-mode and multi-standby terminal
CN103067578A (en) * 2012-12-24 2013-04-24 惠州Tcl移动通信有限公司 Intelligent lock screen function achieving method based on mobile terminal and mobile terminal
CN103067578B (en) * 2012-12-24 2015-12-23 惠州Tcl移动通信有限公司 A kind of intelligent screen lock function realizing method based on mobile terminal and mobile terminal
CN106042016A (en) * 2015-04-15 2016-10-26 松下知识产权经营株式会社 Electric appliance
US10471613B2 (en) 2015-04-15 2019-11-12 Panasonic Intellectual Property Management Co., Ltd. Electrical appliance with switchable operation modes
CN106042016B (en) * 2015-04-15 2019-12-24 松下知识产权经营株式会社 Electrical device
CN109002438A (en) * 2018-07-02 2018-12-14 北京分音塔科技有限公司 False-touch prevention method, apparatus and translator

Similar Documents

Publication Publication Date Title
CN101106782A (en) Keyboard locking method for mobile terminal
CN100521731C (en) Locking method of TV remote controller
CN101287036B (en) Method and device for preventing mobile phone from being woke-up in stand-by state
CN104133687A (en) Method for handling unhandled notification event and portable terminal
CN103235680B (en) The processing method and processing device that bluetooth connects
CN101699835A (en) Method for realizing safe use of mobile phone through safe lock and corresponding device
CN104660777B (en) The function setting method of touch-screen mobile phone and its physical button
CN103034446A (en) Method and device for unblocking operation interface of electronic device and switching themes
CN103064622A (en) Screen unlocking method and device for mobile terminal
CN101610600A (en) The electronic equipment of tool function of preventing misoperation of touch screen and method for preventing misoperation thereof
CN101727281A (en) System and method for one-key locking of computer monitor
CN103795854A (en) Method and apparatus for dialing quick contacts in mobile phone locked screen interface
CN103095915A (en) Method of preventing faulty operation based on touch screen mobile phone and mobile phone
CN106295305A (en) A kind of unlocking screen method and device of touch screen terminal
WO2023124589A1 (en) Method and apparatus for preventing processing by security processor from being interrupted
CN103945070A (en) Emergency call method and emergency call device based on voice recognition
CN102281358A (en) Method for preventing error operation in talk of capacitive touch screen mobile phone and mobile phone
CN102355519A (en) Malicious call dialing prevention method for mobile intelligent terminal and system thereof
CN102970422B (en) A kind of safety that realizes extracts method and the mobile phone of SD card
CN101995964A (en) Method and device for processing keyboard instruction, keyboard and terminal equipment
WO2011140765A1 (en) Task processing method and mobile terminal
CN106874096A (en) Application management method and mobile terminal based on dual system
CN100466827C (en) New message of short message presenting method
CN103558977B (en) The method and apparatus preventing false-lock screen
CN101958973B (en) Mobile terminal and keyboard locking method thereof

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
C12 Rejection of a patent application after its publication
RJ01 Rejection of invention patent application after publication

Open date: 20080116