Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 2a5c6eae authored by Treehugger Robot's avatar Treehugger Robot Committed by Android (Google) Code Review
Browse files

Merge "Remove enabled flag enable_touchpad_no_focus_change" into main

parents 2672f489 bfeea1ed
Loading
Loading
Loading
Loading
+0 −7
Original line number Diff line number Diff line
@@ -143,13 +143,6 @@ flag {
  bug: "341717757"
}

flag {
  name: "enable_touchpad_no_focus_change"
  namespace: "input"
  description: "Prevents touchpad gesture changing window focus."
  bug: "364460018"
}

flag {
  name: "enable_input_policy_profile"
  namespace: "input"
+1 −2
Original line number Diff line number Diff line
@@ -82,7 +82,6 @@ GestureConverter::GestureConverter(InputReaderContext& readerContext,
                                   const InputDeviceContext& deviceContext, int32_t deviceId)
      : mDeviceId(deviceId),
        mReaderContext(readerContext),
        mEnableNoFocusChange(input_flags::enable_touchpad_no_focus_change()),
        // We can safely assume that ABS_MT_POSITION_X and _Y axes will be available, as EventHub
        // won't classify a device as a touchpad if they're not present.
        mXAxisInfo(deviceContext.getAbsoluteAxisInfo(ABS_MT_POSITION_X).value()),
@@ -690,7 +689,7 @@ NotifyMotionArgs GestureConverter::makeMotionArgs(nsecs_t when, nsecs_t readTime
    if (action == AMOTION_EVENT_ACTION_CANCEL) {
        flags |= AMOTION_EVENT_FLAG_CANCELED;
    }
    if (mEnableNoFocusChange && isGestureNoFocusChange(mCurrentClassification)) {
    if (isGestureNoFocusChange(mCurrentClassification)) {
        flags |= AMOTION_EVENT_FLAG_NO_FOCUS_CHANGE;
    }
    if (mCurrentClassification == MotionClassification::TWO_FINGER_SWIPE) {
+0 −1
Original line number Diff line number Diff line
@@ -106,7 +106,6 @@ private:

    const int32_t mDeviceId;
    InputReaderContext& mReaderContext;
    const bool mEnableNoFocusChange;
    bool mEnableSystemGestures{true};

    bool mThreeFingerTapShortcutEnabled{false};
+0 −8
Original line number Diff line number Diff line
@@ -285,8 +285,6 @@ TEST_F(GestureConverterTest, DragWithButton) {
}

TEST_F(GestureConverterTest, Scroll) {
    input_flags::enable_touchpad_no_focus_change(true);

    const nsecs_t downTime = 12345;
    InputDeviceContext deviceContext(*mDevice, EVENTHUB_ID);
    GestureConverter converter(*mReader->getContext(), deviceContext, DEVICE_ID);
@@ -957,8 +955,6 @@ TEST_F(GestureConverterTest, DisablingSystemGestures_EndsOngoingMultiFingerSwipe
}

TEST_F(GestureConverterTest, Pinch_Inwards) {
    input_flags::enable_touchpad_no_focus_change(true);

    InputDeviceContext deviceContext(*mDevice, EVENTHUB_ID);
    GestureConverter converter(*mReader->getContext(), deviceContext, DEVICE_ID);
    converter.setDisplayId(ui::LogicalDisplayId::DEFAULT);
@@ -1026,8 +1022,6 @@ TEST_F(GestureConverterTest, Pinch_Inwards) {
}

TEST_F(GestureConverterTest, Pinch_Outwards) {
    input_flags::enable_touchpad_no_focus_change(true);

    InputDeviceContext deviceContext(*mDevice, EVENTHUB_ID);
    GestureConverter converter(*mReader->getContext(), deviceContext, DEVICE_ID);
    converter.setDisplayId(ui::LogicalDisplayId::DEFAULT);
@@ -1179,8 +1173,6 @@ TEST_F(GestureConverterTest, ResetWithButtonPressed) {
}

TEST_F(GestureConverterTest, ResetDuringScroll) {
    input_flags::enable_touchpad_no_focus_change(true);

    InputDeviceContext deviceContext(*mDevice, EVENTHUB_ID);
    GestureConverter converter(*mReader->getContext(), deviceContext, DEVICE_ID);
    converter.setDisplayId(ui::LogicalDisplayId::DEFAULT);