GestureConverter_test: disable pointer controller with choreographer
These tests were unrealistic in that when the pointer choreographer flag
was enabled, the FakePointerController would continue keeping track of
the pointer position, even though the real PointerControllers would not
(see change I475f3286c83b90e161e186e62c2842e539434603). Modify the fake
so that it can be disabled, too.
Bug: 245989146
Test: atest inputflinger_tests:GestureConverterTest \
inputflinger_tests:GestureConverterTestWithChoreographer
Change-Id: I7c7dd535804ca1552fb731e6da9fd148c047791b
diff --git a/services/inputflinger/tests/FakePointerController.h b/services/inputflinger/tests/FakePointerController.h
index 061ae62..536b447 100644
--- a/services/inputflinger/tests/FakePointerController.h
+++ b/services/inputflinger/tests/FakePointerController.h
@@ -30,6 +30,9 @@
class FakePointerController : public PointerControllerInterface {
public:
+ FakePointerController() : FakePointerController(/*enabled=*/true) {}
+ FakePointerController(bool enabled) : mEnabled(enabled) {}
+
virtual ~FakePointerController() {}
void setBounds(float minX, float minY, float maxX, float maxY);
@@ -64,6 +67,7 @@
int32_t displayId) override;
void clearSpots() override;
+ const bool mEnabled;
bool mHaveBounds{false};
float mMinX{0}, mMinY{0}, mMaxX{0}, mMaxY{0};
float mX{0}, mY{0};