Loading services/inputflinger/dispatcher/DebugConfig.h +10 −0 Original line number Diff line number Diff line Loading @@ -68,6 +68,16 @@ const bool DEBUG_CHANNEL_CREATION = const bool DEBUG_INJECTION = android::base::ShouldLog(android::base::LogSeverity::DEBUG, LOG_TAG "Injection"); /** * Generally, we always log whenever events are dropped. However, to reduce logspam, some messages * are suppressed. * Log additional debug messages about dropped input events with this flag. * Enable this via "adb shell setprop log.tag.InputDispatcherDroppedEventsVerbose DEBUG". * Requires system_server restart via `adb shell stop && adb shell start`. */ const bool DEBUG_DROPPED_EVENTS_VERBOSE = android::base::ShouldLog(android::base::LogSeverity::DEBUG, LOG_TAG "DroppedEventsVerbose"); /** * Log debug messages about input focus tracking. * Enable this via "adb shell setprop log.tag.InputDispatcherFocus DEBUG" (requires restart) Loading services/inputflinger/dispatcher/InputDispatcher.cpp +9 −8 Original line number Diff line number Diff line Loading @@ -2040,10 +2040,10 @@ void InputDispatcher::dispatchEventLocked(nsecs_t currentTime, if (connection != nullptr) { prepareDispatchCycleLocked(currentTime, connection, eventEntry, inputTarget); } else { if (DEBUG_FOCUS) { ALOGD("Dropping event delivery to target with channel '%s' because it " "is no longer registered with the input dispatcher.", inputTarget.inputChannel->getName().c_str()); if (DEBUG_DROPPED_EVENTS_VERBOSE) { LOG(INFO) << "Dropping event delivery to target with channel " << inputTarget.inputChannel->getName() << " because it is no longer registered with the input dispatcher."; } } } Loading Loading @@ -2461,10 +2461,11 @@ std::vector<InputTarget> InputDispatcher::findTouchedWindowTargetsLocked( // If the pointer is not currently down, then ignore the event. if (!tempTouchState.isDown(entry.deviceId) && maskedAction != AMOTION_EVENT_ACTION_HOVER_EXIT) { if (DEBUG_DROPPED_EVENTS_VERBOSE) { LOG(INFO) << "Dropping event because the pointer for device " << entry.deviceId << " is not down or we previously " "dropped the pointer down event in display " << displayId << ": " << entry.getDescription(); << " is not down or we previously dropped the pointer down event in " << "display " << displayId << ": " << entry.getDescription(); } outInjectionResult = InputEventInjectionResult::FAILED; return {}; } Loading Loading
services/inputflinger/dispatcher/DebugConfig.h +10 −0 Original line number Diff line number Diff line Loading @@ -68,6 +68,16 @@ const bool DEBUG_CHANNEL_CREATION = const bool DEBUG_INJECTION = android::base::ShouldLog(android::base::LogSeverity::DEBUG, LOG_TAG "Injection"); /** * Generally, we always log whenever events are dropped. However, to reduce logspam, some messages * are suppressed. * Log additional debug messages about dropped input events with this flag. * Enable this via "adb shell setprop log.tag.InputDispatcherDroppedEventsVerbose DEBUG". * Requires system_server restart via `adb shell stop && adb shell start`. */ const bool DEBUG_DROPPED_EVENTS_VERBOSE = android::base::ShouldLog(android::base::LogSeverity::DEBUG, LOG_TAG "DroppedEventsVerbose"); /** * Log debug messages about input focus tracking. * Enable this via "adb shell setprop log.tag.InputDispatcherFocus DEBUG" (requires restart) Loading
services/inputflinger/dispatcher/InputDispatcher.cpp +9 −8 Original line number Diff line number Diff line Loading @@ -2040,10 +2040,10 @@ void InputDispatcher::dispatchEventLocked(nsecs_t currentTime, if (connection != nullptr) { prepareDispatchCycleLocked(currentTime, connection, eventEntry, inputTarget); } else { if (DEBUG_FOCUS) { ALOGD("Dropping event delivery to target with channel '%s' because it " "is no longer registered with the input dispatcher.", inputTarget.inputChannel->getName().c_str()); if (DEBUG_DROPPED_EVENTS_VERBOSE) { LOG(INFO) << "Dropping event delivery to target with channel " << inputTarget.inputChannel->getName() << " because it is no longer registered with the input dispatcher."; } } } Loading Loading @@ -2461,10 +2461,11 @@ std::vector<InputTarget> InputDispatcher::findTouchedWindowTargetsLocked( // If the pointer is not currently down, then ignore the event. if (!tempTouchState.isDown(entry.deviceId) && maskedAction != AMOTION_EVENT_ACTION_HOVER_EXIT) { if (DEBUG_DROPPED_EVENTS_VERBOSE) { LOG(INFO) << "Dropping event because the pointer for device " << entry.deviceId << " is not down or we previously " "dropped the pointer down event in display " << displayId << ": " << entry.getDescription(); << " is not down or we previously dropped the pointer down event in " << "display " << displayId << ": " << entry.getDescription(); } outInjectionResult = InputEventInjectionResult::FAILED; return {}; } Loading