From: Dongsug Song Date: Tue, 31 Dec 2019 07:00:33 +0000 (+0900) Subject: Revert "[Tizen] Pan now possible without a touch down" X-Git-Tag: accepted/tizen/5.5/unified/20200102.110125^0 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=40156e52839edbb7f0191dbdcdc289373b0e5caf;hp=4f317a4101e4a68d5b461e1b57e329fd7508821a;p=platform%2Fcore%2Fuifw%2Fdali-core.git Revert "[Tizen] Pan now possible without a touch down" - some pan senario is not working (for example, scrolling) - revert temporarily This reverts commit e647a952be0dce4f90787548874203415b8f9154. Change-Id: I2a6ea6a137fa1f1a4937a57d4e7b3c4c63e2a505 --- diff --git a/dali/internal/event/events/pan-gesture/pan-gesture-processor.cpp b/dali/internal/event/events/pan-gesture/pan-gesture-processor.cpp index 3aadc05..05589ef 100644 --- a/dali/internal/event/events/pan-gesture/pan-gesture-processor.cpp +++ b/dali/internal/event/events/pan-gesture/pan-gesture-processor.cpp @@ -161,8 +161,13 @@ void PanGestureProcessor::Process( Scene& scene, const PanGestureEvent& panEvent mCurrentPanEmitters.clear(); ResetActor(); - // It's only possible on touch-down, which is the position we want to hit-test against when the pan actually starts - mPossiblePanPosition = panEvent.currentPosition; + HitTestAlgorithm::Results hitTestResults; + if( HitTest( scene, panEvent.currentPosition, hitTestResults ) ) + { + SetActor( &GetImplementation( hitTestResults.actor ) ); + mPossiblePanPosition = panEvent.currentPosition; + } + break; } @@ -179,7 +184,7 @@ void PanGestureProcessor::Process( Scene& scene, const PanGestureEvent& panEvent HitTestAlgorithm::Results hitTestResults; HitTest( scene, mPossiblePanPosition, hitTestResults ); // Hit test original possible position... - if ( hitTestResults.actor ) + if ( hitTestResults.actor && ( GetCurrentGesturedActor() == &GetImplementation( hitTestResults.actor ) ) ) { // Record the current render-task for Screen->Actor coordinate conversions mCurrentRenderTask = hitTestResults.renderTask; diff --git a/dali/internal/event/events/pan-gesture/pan-gesture-recognizer.cpp b/dali/internal/event/events/pan-gesture/pan-gesture-recognizer.cpp index 0b56574..0256821 100644 --- a/dali/internal/event/events/pan-gesture/pan-gesture-recognizer.cpp +++ b/dali/internal/event/events/pan-gesture/pan-gesture-recognizer.cpp @@ -99,7 +99,7 @@ void PanGestureRecognizer::SendEvent(const Integration::TouchEvent& event) { case Clear: { - if ( ( primaryPointState == PointState::DOWN ) || ( primaryPointState == PointState::STATIONARY ) || ( primaryPointState == PointState::MOTION )) + if ( ( primaryPointState == PointState::DOWN ) || ( primaryPointState == PointState::STATIONARY ) ) { mPrimaryTouchDownLocation = event.points[0].GetScreenPosition(); mPrimaryTouchDownTime = event.time;