Android - How to Generate Key Presses Programmatically
After reading through this " How to Generate Key Presses Programmatically Android " and the associated answers, I created a class that extends InputMethodService
, but is empty otherwise.
I create an instance of that class and then do something like this _imsExtend.getCurrentInputConnectio开发者_StackOverflow中文版n()
, but it appears that getCurrentInputConnection()
returns a null pointer and causes issues thereafter.
What am I forgetting to do? I am guessing I need to setup some of the parameters of _imsExtend
, but what?
精彩评论