{
GestureReceivedFunctor(SignalData& data) : signalData(data) { }
- void operator()(Actor actor, PinchGesture pinch)
+ void operator()(Actor actor, const PinchGesture& pinch)
{
signalData.functorCalled = true;
signalData.receivedGesture = pinch;
{
}
- void operator()( Actor actor, PinchGesture pinch )
+ void operator()( Actor actor, const PinchGesture& pinch )
{
GestureReceivedFunctor::operator()( actor, pinch );
END_TEST;
}
+int UtcDaliPinchGestureDetectorCopyConstructorP(void)
+{
+ TestApplication application;
+
+ PinchGestureDetector detector = PinchGestureDetector::New();;
+
+ PinchGestureDetector copy( detector );
+ DALI_TEST_CHECK( detector );
+ END_TEST;
+}
+
+int UtcDaliPinchGestureDetectorAssignmentOperatorP(void)
+{
+ TestApplication application;
+
+ PinchGestureDetector detector = PinchGestureDetector::New();;
+
+ PinchGestureDetector assign;
+ assign = detector;
+ DALI_TEST_CHECK( detector );
+
+ DALI_TEST_CHECK( detector == assign );
+ END_TEST;
+}
+
int UtcDaliPinchGestureDetectorNew(void)
{
TestApplication application;
detector.Attach(actor);
Integration::TouchEvent touchEvent(1);
- TouchPoint point(1, TouchPoint::Down, 20.0f, 20.0f);
+ Integration::Point point;
+ point.SetDeviceId( 1 );
+ point.SetState( PointState::DOWN );
+ point.SetScreenPosition( Vector2( 20.0f, 20.0f ) );
touchEvent.AddPoint(point);
application.ProcessEvent(touchEvent);
- TouchPoint point2(1, TouchPoint::Down, 20.0f, 20.0f, 20.0f, 20.0f);
+ Integration::Point point2;
+ point.SetDeviceId( 1 );
+ point.SetState( PointState::DOWN );
+ point.SetScreenPosition( Vector2( 20.0f, 20.0f ) );
touchEvent.AddPoint(point2);
application.ProcessEvent(touchEvent);
END_TEST;
Actor actor = Actor::New();
actor.SetSize(100.0f, 100.0f);
- actor.SetRotation(Dali::Degree(90.0f), Vector3::ZAXIS);
+ actor.SetOrientation(Dali::Degree(90.0f), Vector3::ZAXIS);
Stage::GetCurrent().Add(actor);
// Render and notify a couple of times
DALI_TEST_EQUALS(Vector2(10.0f, 10.0f), data.receivedGesture.screenCenterPoint, 0.01f, TEST_LOCATION);
// Rotate actor again and render and notify
- actor.SetRotation(Dali::Degree(180.0f), Vector3::ZAXIS);
+ actor.SetOrientation(Dali::Degree(180.0f), Vector3::ZAXIS);
application.SendNotification();
application.Render();
DALI_TEST_EQUALS(Vector2(10.0f, 10.0f), data.receivedGesture.screenCenterPoint, 0.01f, TEST_LOCATION);
// Rotate actor again and render and notify
- actor.SetRotation(Dali::Degree(270.0f), Vector3::ZAXIS);
+ actor.SetOrientation(Dali::Degree(270.0f), Vector3::ZAXIS);
application.SendNotification();
application.Render();
child.SetSize(100.0f, 100.0f);
child.SetAnchorPoint(AnchorPoint::CENTER);
child.SetParentOrigin(ParentOrigin::CENTER);
- child.SetRotation(Dali::Degree(90.0f), Vector3::ZAXIS);
+ child.SetOrientation(Dali::Degree(90.0f), Vector3::ZAXIS);
parent.Add(child);
TouchEventFunctor touchFunctor;
touchData.Reset();
// Do touch in the same area
- application.ProcessEvent( touchFunctor.GenerateSingleTouch( TouchPoint::Down, screenCoords ) );
+ application.ProcessEvent( touchFunctor.GenerateSingleTouch( PointState::DOWN, screenCoords ) );
DALI_TEST_EQUALS( false, data.functorCalled, TEST_LOCATION );
DALI_TEST_EQUALS( true, touchData.functorCalled, TEST_LOCATION );
touchData.Reset();
// Do touch in the same area
- application.ProcessEvent( touchFunctor.GenerateSingleTouch( TouchPoint::Down, screenCoords ) );
+ application.ProcessEvent( touchFunctor.GenerateSingleTouch( PointState::DOWN, screenCoords ) );
DALI_TEST_EQUALS( false, data.functorCalled, TEST_LOCATION );
DALI_TEST_EQUALS( true, touchData.functorCalled, TEST_LOCATION );