Android showStatusIcon on inactive InputConnection异常

来源:互联网 发布:pop设置ip和端口 编辑:程序博客网 时间:2024/04/30 01:28

在开发的时候突然发现在输入文本框中点击输入法的删除按钮,发现app莫名其妙退出 了。log信息如下:

01-31 16:57:59.524: W/IInputConnectionWrapper(1259): clearMetaKeyStates on inactive InputConnection01-31 16:57:59.624: W/IInputConnectionWrapper(1259): clearMetaKeyStates on inactive InputConnection01-31 16:57:59.624: W/IInputConnectionWrapper(1259): beginBatchEdit on inactive InputConnection01-31 16:57:59.624: W/IInputConnectionWrapper(1259): getTextBeforeCursor on inactive InputConnection01-31 16:57:59.624: W/IInputConnectionWrapper(1259): endBatchEdit on inactive InputConnection01-31 16:57:59.624: W/IInputConnectionWrapper(1259): sendKeyEvent on inactive InputConnection01-31 16:57:59.624: W/IInputConnectionWrapper(1259): sendKeyEvent on inactive InputConnection01-31 16:57:59.624: W/IInputConnectionWrapper(1259): clearMetaKeyStates on inactive InputConnection01-31 16:57:59.684: W/IInputConnectionWrapper(1259): showStatusIcon on inactive InputConnection

后来各种查找,发现原来自己在Activity中重写了onKeyDown方法直接退出了Activity。


所以出现了这种Warn的时候请看看自己代码是否重写了onKeyDown或onKeyUp方法,检查下是否有逻辑上的错误。


1 0
原创粉丝点击