Set up a GestureInterpreter and feed it events

This is a minimal setup of the gestures library, in that it doesn't have
a timer provider or property provider, but it's enough to be able to
feed it events and have it report the gestures it has detected.

This CL depends on https://r.android.com/2310648 to pull in the
Android.bp file and `SetCallback` rename from upstream, and
https://r.android.com/2314880 to pull in the deprecation of screen DPI
hardware properties.

Bug: 251196347
Test: connect Apple Magic Trackpad 2, make gestures, check logcat

Change-Id: Ib40880360c3865f0a98b7a067b7efe9fd8178212
diff --git a/services/inputflinger/reader/InputDevice.cpp b/services/inputflinger/reader/InputDevice.cpp
index 6ca6298..150a8aa 100644
--- a/services/inputflinger/reader/InputDevice.cpp
+++ b/services/inputflinger/reader/InputDevice.cpp
@@ -211,7 +211,8 @@
     // Touchscreens and touchpad devices.
     // TODO(b/251196347): replace this with a proper flag.
     constexpr bool ENABLE_NEW_TOUCHPAD_STACK = false;
-    if (ENABLE_NEW_TOUCHPAD_STACK && classes.test(InputDeviceClass::TOUCHPAD)) {
+    if (ENABLE_NEW_TOUCHPAD_STACK && classes.test(InputDeviceClass::TOUCHPAD) &&
+        classes.test(InputDeviceClass::TOUCH_MT)) {
         mappers.push_back(std::make_unique<TouchpadInputMapper>(*contextPtr));
     } else if (classes.test(InputDeviceClass::TOUCH_MT)) {
         mappers.push_back(std::make_unique<MultiTouchInputMapper>(*contextPtr));