- Vector3 targetParentOrigin(ParentOrigin::BOTTOM_RIGHT);
-
- try
- {
- animation.AnimateTo( Property(actor, Actor::PARENT_ORIGIN), targetParentOrigin );
- }
- catch (Dali::DaliException& e)
- {
- tet_printf("Assertion %s failed at %s\n", e.mCondition.c_str(), e.mLocation.c_str());
- DALI_TEST_ASSERT(e, "IsPropertyAnimatable(index)", TEST_LOCATION);
- }
- END_TEST;
-}
-
-int UtcDaliAnimationAnimateToActorParentOriginX(void)
-{
- TestApplication application;
-
- Actor actor = Actor::New();
- Stage::GetCurrent().Add(actor);
- float startValue(0.0f);
- DALI_TEST_EQUALS( actor.GetCurrentParentOrigin().x, startValue, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::PARENT_ORIGIN_X), startValue, TEST_LOCATION );
-
- // Build the animation
- float durationSeconds(1.0f);
- Animation animation = Animation::New(durationSeconds);
- float targetX(1.0f);
-
- try
- {
- animation.AnimateTo( Property(actor, Actor::PARENT_ORIGIN_X), targetX );
- }
- catch (Dali::DaliException& e)
- {
- tet_printf("Assertion %s failed at %s\n", e.mCondition.c_str(), e.mLocation.c_str());
- DALI_TEST_ASSERT(e, "IsPropertyAnimatable(index)", TEST_LOCATION);
- }
- END_TEST;
-}
-
-int UtcDaliAnimationAnimateToActorParentOriginY(void)
-{
- TestApplication application;
-
- Actor actor = Actor::New();
- Stage::GetCurrent().Add(actor);
- float startValue(0.0f);
- DALI_TEST_EQUALS( actor.GetCurrentParentOrigin().y, startValue, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::PARENT_ORIGIN_Y), startValue, TEST_LOCATION );
-
- // Build the animation
- float durationSeconds(1.0f);
- Animation animation = Animation::New(durationSeconds);
- float targetY(1.0f);
-
- try
- {
- animation.AnimateTo( Property(actor, Actor::PARENT_ORIGIN_Y), targetY );
- }
- catch (Dali::DaliException& e)
- {
- tet_printf("Assertion %s failed at %s\n", e.mCondition.c_str(), e.mLocation.c_str());
- DALI_TEST_ASSERT(e, "IsPropertyAnimatable(index)", TEST_LOCATION);
- }
- END_TEST;
-}
-
-int UtcDaliAnimationAnimateToActorParentOriginZ(void)
-{
- TestApplication application;
-
- Actor actor = Actor::New();
- Stage::GetCurrent().Add(actor);
- float startValue(0.5f);
- DALI_TEST_EQUALS( actor.GetCurrentParentOrigin().z, startValue, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::PARENT_ORIGIN_Z), startValue, TEST_LOCATION );
-
- // Build the animation
- float durationSeconds(1.0f);
- Animation animation = Animation::New(durationSeconds);
- float targetZ(1.0f);
-
- try
- {
- animation.AnimateTo( Property(actor, Actor::PARENT_ORIGIN_Z), targetZ );
- }
- catch (Dali::DaliException& e)
- {
- tet_printf("Assertion %s failed at %s\n", e.mCondition.c_str(), e.mLocation.c_str());
- DALI_TEST_ASSERT(e, "IsPropertyAnimatable(index)", TEST_LOCATION);
- }
- END_TEST;
-}
-
-int UtcDaliAnimationAnimateToActorAnchorPoint(void)
-{
- TestApplication application;
-
- Actor actor = Actor::New();
- Stage::GetCurrent().Add(actor);
- DALI_TEST_EQUALS( actor.GetCurrentAnchorPoint(), AnchorPoint::CENTER, TEST_LOCATION );
-
- // Build the animation
- float durationSeconds(1.0f);
- Animation animation = Animation::New(durationSeconds);
- Vector3 targetAnchorPoint(AnchorPoint::TOP_LEFT);
-
- try
- {
- animation.AnimateTo( Property(actor, Actor::ANCHOR_POINT), targetAnchorPoint);
- }
- catch (Dali::DaliException& e)
- {
- tet_printf("Assertion %s failed at %s\n", e.mCondition.c_str(), e.mLocation.c_str());
- DALI_TEST_ASSERT(e, "IsPropertyAnimatable(index)", TEST_LOCATION);
- }
- END_TEST;
-}
-
-int UtcDaliAnimationAnimateToActorAnchorPointX(void)
-{
- TestApplication application;
-
- Actor actor = Actor::New();
- Stage::GetCurrent().Add(actor);
- float startValue(0.5f);
- DALI_TEST_EQUALS( actor.GetCurrentAnchorPoint().x, startValue, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::ANCHOR_POINT_X), startValue, TEST_LOCATION );
-
- // Build the animation
- float durationSeconds(1.0f);
- Animation animation = Animation::New(durationSeconds);
- float targetX(1.0f);
-
- try
- {
- animation.AnimateTo( Property(actor, Actor::ANCHOR_POINT_X), targetX );
- }
- catch (Dali::DaliException& e)
- {
- tet_printf("Assertion %s failed at %s\n", e.mCondition.c_str(), e.mLocation.c_str());
- DALI_TEST_ASSERT(e, "IsPropertyAnimatable(index)", TEST_LOCATION);
- }
- END_TEST;
-}
-
-int UtcDaliAnimationAnimateToActorAnchorPointY(void)
-{
- TestApplication application;
-
- Actor actor = Actor::New();
- Stage::GetCurrent().Add(actor);
- float startValue(0.5f);
- DALI_TEST_EQUALS( actor.GetCurrentAnchorPoint().y, startValue, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::ANCHOR_POINT_Y), startValue, TEST_LOCATION );
-
- // Build the animation
- float durationSeconds(1.0f);
- Animation animation = Animation::New(durationSeconds);
- float targetY(0.0f);
-
- try
- {
- animation.AnimateTo( Property(actor, Actor::ANCHOR_POINT_Y), targetY );
- }
- catch (Dali::DaliException& e)
- {
- tet_printf("Assertion %s failed at %s\n", e.mCondition.c_str(), e.mLocation.c_str());
- DALI_TEST_ASSERT(e, "IsPropertyAnimatable(index)", TEST_LOCATION);
- }
- END_TEST;
-}
-
-int UtcDaliAnimationAnimateToActorAnchorPointZ(void)
-{
- TestApplication application;
-
- Actor actor = Actor::New();
- Stage::GetCurrent().Add(actor);
- float startValue(0.5f);
- DALI_TEST_EQUALS( actor.GetCurrentAnchorPoint().z, startValue, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::ANCHOR_POINT_Z), startValue, TEST_LOCATION );
-
- // Build the animation
- float durationSeconds(1.0f);
- Animation animation = Animation::New(durationSeconds);
- float targetZ(100.0f);
-
- try
- {
- animation.AnimateTo( Property(actor, Actor::ANCHOR_POINT_Z), targetZ );
- }
- catch (Dali::DaliException& e)
- {
- tet_printf("Assertion %s failed at %s\n", e.mCondition.c_str(), e.mLocation.c_str());
- DALI_TEST_ASSERT(e, "IsPropertyAnimatable(index)", TEST_LOCATION);
- }
- END_TEST;
-}
-
-int UtcDaliAnimationAnimateToActorSize(void)
-{
- TestApplication application;
-
- Actor actor = Actor::New();
- Stage::GetCurrent().Add(actor);
- DALI_TEST_EQUALS( actor.GetCurrentSize(), Vector3::ZERO, TEST_LOCATION );
-
- // Build the animation
- float durationSeconds(1.0f);
- Animation animation = Animation::New(durationSeconds);
- Vector3 targetSize(100.0f, 100.0f, 100.0f);
- animation.AnimateTo( Property(actor, Actor::SIZE), targetSize );
-
- Vector3 ninetyNinePercentProgress(targetSize * 0.99f);