tap->SetSourceType(tapEvent.sourceType);
tap->SetSourceData(tapEvent.sourceData);
- DALI_TRACE_SCOPE(gTraceFilter, "DALI_EMIT_TAP_GESTURE_SIGNAL");
+ DALI_TRACE_BEGIN_WITH_MESSAGE_GENERATOR(gTraceFilter, "DALI_EMIT_TAP_GESTURE_SIGNAL", [&](std::ostringstream& oss) {
+ oss << "[" << gestureDetectors.size() << "]";
+ });
Dali::Actor actorHandle(actor);
const GestureDetectorContainer::const_iterator endIter = gestureDetectors.end();
{
static_cast<TapGestureDetector*>(*iter)->EmitTapGestureSignal(actorHandle, Dali::TapGesture(tap.Get()));
}
+
+ DALI_TRACE_END_WITH_MESSAGE_GENERATOR(gTraceFilter, "DALI_EMIT_TAP_GESTURE_SIGNAL", [&](std::ostringstream& oss) {
+ oss << "[" << gestureDetectors.size() << "]";
+ });
}
} // unnamed namespace
{
// Do a hit test and if an actor has been hit then save to see if tap event is still valid on a tap( same actor being hit )
HitTestAlgorithm::Results hitTestResults;
- if(HitTest(scene, tapEvent.point, hitTestResults))
+ if(GetFeededActor())
+ {
+ SetActor(GetFeededActor());
+ mCurrentTapActor.SetActor(GetCurrentGesturedActor());
+
+ // Indicate that we've processed a touch down. Bool should be sufficient as a change in actor will result in a cancellation
+ mPossibleProcessed = true;
+ }
+ else if(HitTest(scene, tapEvent.point, hitTestResults))
{
SetActor(&GetImplementation(hitTestResults.actor));
mCurrentTapActor.SetActor(GetCurrentGesturedActor());
{
// Ensure that we're processing a hit on the current actor and that we've already processed a touch down
HitTestAlgorithm::Results hitTestResults;
- if(GetCurrentGesturedActor() && HitTest(scene, tapEvent.point, hitTestResults) && mPossibleProcessed)
+ if(GetCurrentGesturedActor())
{
- // Check that this actor is still the one that was used for the last touch down ?
- if(mCurrentTapActor.GetActor() == &GetImplementation(hitTestResults.actor))
+ if(GetFeededActor())
+ {
+ hitTestResults.actor = Dali::Actor(GetFeededActor());
+ hitTestResults.renderTask = GetFeededRenderTask();
+ // Check that this actor is still the one that was used for the last touch down ?
+ if(mCurrentTapActor.GetActor() == &GetImplementation(hitTestResults.actor))
+ {
+ mCurrentTapEvent = &tapEvent;
+ ProcessAndEmitActor(hitTestResults, GetFeededGestureDetector());
+ }
+ mCurrentTapEvent = nullptr;
+ mPossibleProcessed = false;
+ }
+ else if(HitTest(scene, tapEvent.point, hitTestResults) && mPossibleProcessed)
{
- mCurrentTapEvent = &tapEvent;
- ProcessAndEmit(hitTestResults);
+ // Check that this actor is still the one that was used for the last touch down ?
+ if(mCurrentTapActor.GetActor() == &GetImplementation(hitTestResults.actor))
+ {
+ mCurrentTapEvent = &tapEvent;
+ ProcessAndEmit(hitTestResults);
+ }
+ mCurrentTapEvent = nullptr;
+ mPossibleProcessed = false;
}
- mCurrentTapEvent = nullptr;
- mPossibleProcessed = false;
}
break;
}