Update input event type to enum class
The native definitions for event type were changed to enum class. Update
the usages here.
Bug: 274073185
Test: m checkinput
Change-Id: If80dc6fc568da2d195606b5fbece7b7b5975e061
diff --git a/native/android/input.cpp b/native/android/input.cpp
index 432e21c..1bff97d 100644
--- a/native/android/input.cpp
+++ b/native/android/input.cpp
@@ -33,6 +33,7 @@
#include <errno.h>
using android::InputEvent;
+using android::InputEventType;
using android::InputQueue;
using android::KeyEvent;
using android::Looper;
@@ -41,7 +42,8 @@
using android::Vector;
int32_t AInputEvent_getType(const AInputEvent* event) {
- return static_cast<const InputEvent*>(event)->getType();
+ const InputEventType eventType = static_cast<const InputEvent*>(event)->getType();
+ return static_cast<int32_t>(eventType);
}
int32_t AInputEvent_getDeviceId(const AInputEvent* event) {