Revert "[Tizen] When a touch-up occurs, a hover-down event is generated."
authorEunki, Hong <eunkiki.hong@samsung.com>
Wed, 25 Oct 2023 07:35:42 +0000 (16:35 +0900)
committerEunki, Hong <eunkiki.hong@samsung.com>
Wed, 25 Oct 2023 07:35:42 +0000 (16:35 +0900)
This reverts commit 221eeb04b57a0612baa1fdd4f5ba41f69a6b0aed.

automated-tests/src/dali/utc-Dali-TouchEventCombiner.cpp
dali/integration-api/events/touch-event-combiner.cpp

index f9664c4..1b6eb75 100644 (file)
@@ -911,58 +911,3 @@ int UtcDaliTouchEventCombinerInvalidState(void)
   }
   END_TEST;
 }
-
-int UtcDaliTouchEventCombinerHoverDownAfterTouchUp(void)
-{
-  TouchEventCombiner combiner;
-  unsigned long      time(0u);
-
-  // Motion event
-  {
-    Integration::TouchEvent touchEvent;
-    Integration::HoverEvent hoverEvent;
-    Integration::Point      point = GeneratePoint(1, PointState::MOTION, 100.0f, 100.0f);
-    point.SetDeviceClass(Device::Class::Type::MOUSE);
-
-    DALI_TEST_EQUALS(Integration::TouchEventCombiner::DISPATCH_HOVER, combiner.GetNextTouchEvent(point, time, touchEvent, hoverEvent), TEST_LOCATION);
-    DALI_TEST_EQUALS(hoverEvent.GetPointCount(), 1u, TEST_LOCATION);
-    DALI_TEST_EQUALS(hoverEvent.points[0].GetDeviceId(), point.GetDeviceId(), TEST_LOCATION);
-    DALI_TEST_EQUALS(hoverEvent.points[0].GetState(), PointState::STARTED, TEST_LOCATION);
-    DALI_TEST_EQUALS(hoverEvent.points[0].GetScreenPosition(), point.GetScreenPosition(), TEST_LOCATION);
-  }
-
-
-  time++;
-
-  // down event
-  {
-    Integration::TouchEvent touchEvent;
-    Integration::HoverEvent hoverEvent;
-    Integration::Point      point = GeneratePoint(1, PointState::DOWN, 100.0f, 100.0f);
-    point.SetDeviceClass(Device::Class::Type::MOUSE);
-
-    DALI_TEST_EQUALS(Integration::TouchEventCombiner::DISPATCH_BOTH, combiner.GetNextTouchEvent(point, time, touchEvent, hoverEvent), TEST_LOCATION);
-    DALI_TEST_EQUALS(hoverEvent.GetPointCount(), 1u, TEST_LOCATION);
-    DALI_TEST_EQUALS(hoverEvent.points[0].GetDeviceId(), point.GetDeviceId(), TEST_LOCATION);
-    DALI_TEST_EQUALS(hoverEvent.points[0].GetState(), PointState::FINISHED, TEST_LOCATION);
-    DALI_TEST_EQUALS(hoverEvent.points[0].GetScreenPosition(), point.GetScreenPosition(), TEST_LOCATION);
-  }
-
-  time++;
-
-  // up event
-  {
-    Integration::TouchEvent touchEvent;
-    Integration::HoverEvent hoverEvent;
-    Integration::Point      point = GeneratePoint(1, PointState::UP, 103.0f, 103.0f);
-    point.SetDeviceClass(Device::Class::Type::MOUSE);
-
-    DALI_TEST_EQUALS(Integration::TouchEventCombiner::DISPATCH_BOTH, combiner.GetNextTouchEvent(point, time, touchEvent, hoverEvent), TEST_LOCATION);
-    DALI_TEST_EQUALS(hoverEvent.GetPointCount(), 1u, TEST_LOCATION);
-    DALI_TEST_EQUALS(hoverEvent.points[0].GetDeviceId(), point.GetDeviceId(), TEST_LOCATION);
-    DALI_TEST_EQUALS(hoverEvent.points[0].GetState(), PointState::DOWN, TEST_LOCATION);
-    DALI_TEST_EQUALS(hoverEvent.points[0].GetScreenPosition(), point.GetScreenPosition(), TEST_LOCATION);
-  }
-
-  END_TEST;
-}
index 7423590..9aa64a8 100644 (file)
@@ -188,16 +188,6 @@ TouchEventCombiner::EventDispatchType TouchEventCombiner::GetNextTouchEvent(cons
             iter = mHoveredPoints.erase(iter);
           }
         }
-
-        if(deviceType == Device::Class::Type::MOUSE)
-        {
-          hoverEvent.time = time;
-          Point hoverPoint(point);
-          hoverPoint.SetState(PointState::STARTED); // The first hover event received
-          mHoveredPoints.push_back(PointInfo(hoverPoint, time));
-          hoverEvent.AddPoint(hoverPoint);
-          dispatchEvent = TouchEventCombiner::DISPATCH_BOTH;
-        }
       }
       break;
     }