分析:
打开log
请将下列文件中的相关日志打开,将0置为非0值,如1,单编后将库文件push到system/lib下,重启手机,并重新在问题复现的条件下抓取日志,感谢!
frameworks/base/services/input/InputReader.cpp
define DEBUG_RAW_EVENTS 1
define DEBUG_HACKS 1
define DEBUG_VIRTUAL_KEYS 1
define DEBUG_POINTERS 1
define DEBUG_POINTER_ASSIGNMENT 1
define DEBUG_GESTURES 1
define DEBUG_VIBRATOR 1
frameworks/base/services/input/InputDispatcher.cpp
define DEBUG_INBOUND_EVENT_DETAILS 1
define DEBUG_OUTBOUND_EVENT_DETAILS 1
define DEBUG_DISPATCH_CYCLE 1
define DEBUG_REGISTRATION 1
define DEBUG_INJECTION 1
define DEBUG_FOCUS 1
define DEBUG_APP_SWITCH 1
define DEBUG_HOVER 1
AKEY_EVENT_ACTION_UP
struct RawEvent {
nsecs_t when; //事件发生的时间
int32_t deviceId; //产生此事件的设备,比如发送FINISHED_DEVICE_SCAN,不需要填此项
int32_t type; //事件类型(如:DEVICE_ADDED,DEVICE_REMOVED,FINISHED_DEVICE_SCAN)
int32_t scanCode;
int32_t keyCode;
int32_t value;
uint32_t flags;
};