Rename sequenceNum to ID.
This is for consistency with ID in other places. Change it to signed
type to match Java int type.
Bug: 144889238
Test: atest inputflinger_tests
Change-Id: I8b6782a67f28aa13f7feaed2c97b8e87105019db
Merged-In: I8b6782a67f28aa13f7feaed2c97b8e87105019db
(cherry picked from commit 6a5a14e75b1a0fb377c670cb9a1e9ace60c5da74)
diff --git a/services/inputflinger/benchmarks/InputDispatcher_benchmarks.cpp b/services/inputflinger/benchmarks/InputDispatcher_benchmarks.cpp
index 238cc39..3b18813 100644
--- a/services/inputflinger/benchmarks/InputDispatcher_benchmarks.cpp
+++ b/services/inputflinger/benchmarks/InputDispatcher_benchmarks.cpp
@@ -229,7 +229,7 @@
const nsecs_t currentTime = now();
// Define a valid motion event.
- NotifyMotionArgs args(/* sequenceNum */ 0, currentTime, DEVICE_ID, AINPUT_SOURCE_TOUCHSCREEN,
+ NotifyMotionArgs args(/* id */ 0, currentTime, DEVICE_ID, AINPUT_SOURCE_TOUCHSCREEN,
ADISPLAY_ID_DEFAULT, POLICY_FLAG_PASS_TO_USER, AMOTION_EVENT_ACTION_DOWN,
/* actionButton */ 0, /* flags */ 0, AMETA_NONE, /* buttonState */ 0,
MotionClassification::NONE, AMOTION_EVENT_EDGE_FLAG_NONE, 1,
@@ -259,14 +259,14 @@
for (auto _ : state) {
// Send ACTION_DOWN
motionArgs.action = AMOTION_EVENT_ACTION_DOWN;
- motionArgs.sequenceNum = 0;
+ motionArgs.id = 0;
motionArgs.downTime = now();
motionArgs.eventTime = motionArgs.downTime;
dispatcher->notifyMotion(&motionArgs);
// Send ACTION_UP
motionArgs.action = AMOTION_EVENT_ACTION_UP;
- motionArgs.sequenceNum = 1;
+ motionArgs.id = 1;
motionArgs.eventTime = now();
dispatcher->notifyMotion(&motionArgs);