Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit d2c3adc9 authored by Michael Wright's avatar Michael Wright
Browse files

Make deliverInputEvent tracing asynchronous

Change-Id: I640ed4003194d6d4b202680e5c8fffc81749d60f
parent fde7865c
Loading
Loading
Loading
Loading
+12 −13
Original line number Diff line number Diff line
@@ -5532,8 +5532,8 @@ public final class ViewRootImpl implements ViewParent,
    }

    private void deliverInputEvent(QueuedInputEvent q) {
        Trace.traceBegin(Trace.TRACE_TAG_VIEW, "deliverInputEvent");
        try {
        Trace.asyncTraceBegin(Trace.TRACE_TAG_VIEW, "deliverInputEvent",
                q.mEvent.getSequenceNumber());
        if (mInputEventConsistencyVerifier != null) {
            mInputEventConsistencyVerifier.onInputEvent(q.mEvent, 0);
        }
@@ -5544,12 +5544,11 @@ public final class ViewRootImpl implements ViewParent,
        } else {
            finishInputEvent(q);
        }
        } finally {
            Trace.traceEnd(Trace.TRACE_TAG_VIEW);
        }
    }

    private void finishInputEvent(QueuedInputEvent q) {
        Trace.asyncTraceEnd(Trace.TRACE_TAG_VIEW, "deliverInputEvent",
                q.mEvent.getSequenceNumber());
        if (q.mReceiver != null) {
            boolean handled = (q.mFlags & QueuedInputEvent.FLAG_FINISHED_HANDLED) != 0;
            q.mReceiver.finishInputEvent(q.mEvent, handled);