问题
I am new in android and want to create a log file of all key strokes pressed on keyboard in an android device. My app will display all the key pressed in a log file containing the key value and exact keyboard value of any type of keyboard user uses. As I know we can run our app in background using services and broadcastreciver concept, but i want to trap all the key strokes values to be stored in the log file from any other app or phone operation. Thanks for the help.
回答1:
The best way for you is to create an keyboard app first. In that app, you can do anything you want. Right now, I don't think it is possible to hook in native keyboard app to get keys pressed.
来源:https://stackoverflow.com/questions/22629145/create-a-log-of-all-keyboard-key-pressed-during-a-day-in-android