input_verifier: add isolated MotionEvent checks
Previously, we were checking the consistency of MotionEvents inside input_verifier in one large 'match' statement. However, the verifier should only be used to check whether a given MotionEvent makes sense in relation to all of the preceding motions. To improve the situation, in this CL some checks are moved into a separate function. Those checks allow us to test whether the event itself makes sense. If the event is bad, then no need to do the remaining checks in input_verifier. This CL makes the rust code a bit closer to the current checks implemented in the InputDispatcher. Bug: 211379801 Test: TEST=inputflinger_tests; m $TEST && $ANDROID_HOST_OUT/nativetest64/$TEST/$TEST Change-Id: I60437797980f4f8f050023419a03d80e4ee4e1f1
Loading
Please register or sign in to comment