/*
- * Copyright (c) 2014 Samsung Electronics Co., Ltd.
+ * Copyright (c) 2017 Samsung Electronics Co., Ltd.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
#include <stdlib.h>
#include <dali/public-api/dali-core.h>
+#include <dali/devel-api/actors/actor-devel.h>
+#include <dali/devel-api/object/handle-devel.h>
#include <dali-test-suite-utils.h>
using std::max;
END_TEST;
}
+int UtcDaliAnimationSetLoopCountP(void)
+{
+ TestApplication application;
+
+ Actor actor = Actor::New();
+ Stage::GetCurrent().Add(actor);
+
+ // Build the animation
+ float durationSeconds(1.0f);
+ Animation animation = Animation::New(durationSeconds);
+ Vector3 targetPosition(10.0f, 10.0f, 10.0f);
+ animation.AnimateTo(Property(actor, Actor::Property::POSITION), targetPosition, AlphaFunction::LINEAR);
+
+ // Start the animation
+ animation.SetLoopCount(3);
+ DALI_TEST_CHECK(animation.IsLooping());
+ animation.Play();
+
+ bool signalReceived(false);
+ AnimationFinishCheck finishCheck(signalReceived);
+ animation.FinishedSignal().Connect(&application, finishCheck);
+
+ application.Render(0);
+ application.SendNotification();
+ application.Render(0);
+ application.SendNotification();
+ application.Render(0);
+ application.SendNotification();
+ application.Render(0);
+ application.SendNotification();
+
+ // Loop
+ float intervalSeconds = 3.0f;
+
+ application.Render(static_cast<unsigned int>(durationSeconds*intervalSeconds*1000.0f));
+ application.Render(static_cast<unsigned int>(durationSeconds*intervalSeconds*1000.0f));
+
+ application.Render(0);
+ application.SendNotification();
+ application.Render(0);
+ application.SendNotification();
+ application.Render(0);
+ application.SendNotification();
+ application.Render(0);
+ application.SendNotification();
+ finishCheck.CheckSignalNotReceived();
+
+ application.Render(static_cast<unsigned int>(durationSeconds*intervalSeconds*1000.0f));
+
+ application.SendNotification();
+ finishCheck.CheckSignalReceived();
+ DALI_TEST_EQUALS( targetPosition, actor.GetCurrentPosition(), TEST_LOCATION );
+
+ finishCheck.Reset();
+
+ application.Render(static_cast<unsigned int>(durationSeconds*intervalSeconds*1000.0f));
+ application.SendNotification();
+ finishCheck.CheckSignalNotReceived();
+
+ application.Render(static_cast<unsigned int>(durationSeconds*intervalSeconds*1000.0f));
+ application.Render(static_cast<unsigned int>(durationSeconds*intervalSeconds*1000.0f));
+ application.Render(static_cast<unsigned int>(durationSeconds*intervalSeconds*1000.0f));
+ application.Render(static_cast<unsigned int>(durationSeconds*intervalSeconds*1000.0f));
+ application.SendNotification();
+ finishCheck.CheckSignalNotReceived();
+
+ END_TEST;
+}
+
+int UtcDaliAnimationSetLoopCountP2(void)
+{
+ TestApplication application;
+
+ //
+ // switching between forever and loop count
+ //
+
+ Actor actor = Actor::New();
+ Stage::GetCurrent().Add(actor);
+
+ // Build the animation
+ float durationSeconds(1.0f);
+ Animation animation = Animation::New(durationSeconds);
+ Vector3 targetPosition(10.0f, 10.0f, 10.0f);
+ animation.AnimateTo(Property(actor, Actor::Property::POSITION), targetPosition, AlphaFunction::LINEAR);
+ animation.SetEndAction(Animation::Discard);
+
+ // Start the animation
+ animation.SetLoopCount(3);
+ DALI_TEST_CHECK(animation.IsLooping());
+ animation.Play();
+
+ bool signalReceived(false);
+ AnimationFinishCheck finishCheck(signalReceived);
+ animation.FinishedSignal().Connect(&application, finishCheck);
+
+ float intervalSeconds = 3.0f;
+
+ application.SendNotification();
+ application.Render(static_cast<unsigned int>(durationSeconds*intervalSeconds*1000.0f));
+ application.SendNotification();
+ application.Render(static_cast<unsigned int>(durationSeconds*intervalSeconds*1000.0f));
+ application.SendNotification();
+ application.Render(static_cast<unsigned int>(durationSeconds*intervalSeconds*1000.0f));
+ application.SendNotification();
+
+ application.SendNotification();
+ finishCheck.CheckSignalReceived();
+
+ finishCheck.Reset();
+
+ // Loop forever
+ animation.SetLooping(true);
+ DALI_TEST_CHECK(animation.IsLooping());
+
+ application.Render(static_cast<unsigned int>(durationSeconds*intervalSeconds*1000.0f));
+ application.SendNotification();
+ finishCheck.CheckSignalNotReceived();
+
+ application.Render(static_cast<unsigned int>(durationSeconds*intervalSeconds*1000.0f));
+ application.SendNotification();
+ application.Render(static_cast<unsigned int>(durationSeconds*intervalSeconds*1000.0f));
+ application.SendNotification();
+ application.Render(static_cast<unsigned int>(durationSeconds*intervalSeconds*1000.0f));
+ application.SendNotification();
+ application.Render(static_cast<unsigned int>(durationSeconds*intervalSeconds*1000.0f));
+ application.SendNotification();
+ application.SendNotification();
+ finishCheck.CheckSignalNotReceived();
+
+ finishCheck.Reset();
+
+ // Loop N again
+ animation.SetLoopCount(3);
+ DALI_TEST_CHECK(animation.IsLooping());
+ animation.Play();
+
+ application.SendNotification();
+ application.Render(static_cast<unsigned int>(durationSeconds*intervalSeconds*1000.0f));
+ application.SendNotification();
+ application.Render(static_cast<unsigned int>(durationSeconds*intervalSeconds*1000.0f));
+ application.SendNotification();
+ finishCheck.CheckSignalNotReceived();
+
+ application.Render(static_cast<unsigned int>(durationSeconds*intervalSeconds*1000.0f));
+ application.SendNotification();
+ finishCheck.CheckSignalReceived();
+
+ finishCheck.Reset();
+
+ // loop forever
+ animation.SetLooping(true);
+ DALI_TEST_CHECK(animation.IsLooping());
+
+ application.Render(static_cast<unsigned int>(durationSeconds*intervalSeconds*1000.0f));
+ application.SendNotification();
+ finishCheck.CheckSignalNotReceived();
+
+ application.Render(static_cast<unsigned int>(durationSeconds*intervalSeconds*1000.0f));
+ application.SendNotification();
+ application.Render(static_cast<unsigned int>(durationSeconds*intervalSeconds*1000.0f));
+ application.SendNotification();
+ application.Render(static_cast<unsigned int>(durationSeconds*intervalSeconds*1000.0f));
+ application.SendNotification();
+ application.Render(static_cast<unsigned int>(durationSeconds*intervalSeconds*1000.0f));
+ application.SendNotification();
+ finishCheck.CheckSignalNotReceived();
+
+ finishCheck.Reset();
+
+ // Loop N again
+ animation.SetLoopCount(3);
+ DALI_TEST_CHECK(animation.IsLooping());
+
+ application.SendNotification();
+ application.Render(static_cast<unsigned int>(durationSeconds*intervalSeconds*1000.0f));
+ application.SendNotification();
+ application.Render(static_cast<unsigned int>(durationSeconds*intervalSeconds*1000.0f));
+ application.SendNotification();
+ finishCheck.CheckSignalNotReceived();
+
+ application.Render(static_cast<unsigned int>(durationSeconds*intervalSeconds*1000.0f));
+ application.SendNotification();
+ finishCheck.CheckSignalNotReceived(); // we never hit play
+
+ finishCheck.Reset();
+
+
+ END_TEST;
+}
+
+int UtcDaliAnimationSetLoopCountP3(void)
+{
+ TestApplication application;
+
+ //
+ // switching between forever and loop count
+ //
+ Actor actor = Actor::New();
+ Stage::GetCurrent().Add(actor);
+
+ // Build the animation
+ float durationSeconds(1.0f);
+ Animation animation = Animation::New(durationSeconds);
+ Vector3 targetPosition(10.0f, 10.0f, 10.0f);
+ animation.AnimateTo(Property(actor, Actor::Property::POSITION), targetPosition, AlphaFunction::LINEAR);
+ animation.SetEndAction(Animation::Discard);
+
+ float intervalSeconds = 3.0f;
+
+ bool signalReceived(false);
+ AnimationFinishCheck finishCheck(signalReceived);
+ animation.FinishedSignal().Connect(&application, finishCheck);
+
+ // loop forever
+ animation.SetLooping(true);
+ DALI_TEST_CHECK(animation.IsLooping());
+
+ application.Render(static_cast<unsigned int>(durationSeconds*intervalSeconds*1000.0f));
+ application.SendNotification();
+ finishCheck.CheckSignalNotReceived();
+
+ application.Render(static_cast<unsigned int>(durationSeconds*intervalSeconds*1000.0f));
+ application.SendNotification();
+ application.Render(static_cast<unsigned int>(durationSeconds*intervalSeconds*1000.0f));
+ application.SendNotification();
+ application.Render(static_cast<unsigned int>(durationSeconds*intervalSeconds*1000.0f));
+ application.SendNotification();
+ application.Render(static_cast<unsigned int>(durationSeconds*intervalSeconds*1000.0f));
+ application.SendNotification();
+ finishCheck.CheckSignalNotReceived();
+
+ finishCheck.Reset();
+
+ // Loop N again
+ animation.SetLoopCount(3);
+ DALI_TEST_CHECK(animation.IsLooping());
+
+ application.SendNotification();
+ application.Render(static_cast<unsigned int>(durationSeconds*intervalSeconds*1000.0f));
+ application.SendNotification();
+ application.Render(static_cast<unsigned int>(durationSeconds*intervalSeconds*1000.0f));
+ application.SendNotification();
+ finishCheck.CheckSignalNotReceived();
+
+ application.Render(static_cast<unsigned int>(durationSeconds*intervalSeconds*1000.0f));
+ application.SendNotification();
+ finishCheck.CheckSignalNotReceived(); // we never hit play
+
+ finishCheck.Reset();
+
+
+ END_TEST;
+}
+
+int UtcDaliAnimationSetLoopCountP4(void)
+{
+ TestApplication application;
+
+ //
+ // ..and play again
+ //
+ Actor actor = Actor::New();
+ Stage::GetCurrent().Add(actor);
+
+ // Build the animation
+ float durationSeconds(1.0f);
+ Animation animation = Animation::New(durationSeconds);
+ Vector3 targetPosition(10.0f, 10.0f, 10.0f);
+ animation.AnimateTo(Property(actor, Actor::Property::POSITION), targetPosition, AlphaFunction::LINEAR);
+ animation.SetEndAction(Animation::Bake);
+
+ float intervalSeconds = 3.0f;
+
+ bool signalReceived(false);
+ AnimationFinishCheck finishCheck(signalReceived);
+ animation.FinishedSignal().Connect(&application, finishCheck);
+
+ animation.SetLoopCount(1);
+ animation.Play();
+ DALI_TEST_CHECK(!animation.IsLooping());
+
+ application.SendNotification();
+ finishCheck.CheckSignalNotReceived();
+ application.Render(static_cast<unsigned int>(durationSeconds*intervalSeconds*1000.0f));
+ application.SendNotification();
+ finishCheck.CheckSignalReceived();
+
+ DALI_TEST_EQUALS( actor.GetCurrentPosition(), targetPosition, TEST_LOCATION );
+ actor.SetProperty( Actor::Property::POSITION, Vector3(0.0f, 0.0f, 0.0f) );
+
+ finishCheck.Reset();
+
+ animation.Play(); // again
+ DALI_TEST_CHECK(!animation.IsLooping());
+
+ application.SendNotification();
+ finishCheck.CheckSignalNotReceived();
+ application.Render(static_cast<unsigned int>(durationSeconds*intervalSeconds*1000.0f));
+ application.SendNotification();
+ finishCheck.CheckSignalReceived();
+
+ DALI_TEST_EQUALS( actor.GetCurrentPosition(), targetPosition, TEST_LOCATION );
+
+ END_TEST;
+}
+
+int UtcDaliAnimationGetLoopCountP(void)
+{
+ TestApplication application;
+
+ Actor actor = Actor::New();
+ Stage::GetCurrent().Add(actor);
+
+ // Build the animation
+ float durationSeconds(1.0f);
+ Animation animation = Animation::New(durationSeconds);
+ Vector3 targetPosition(10.0f, 10.0f, 10.0f);
+ animation.AnimateTo(Property(actor, Actor::Property::POSITION), targetPosition, AlphaFunction::LINEAR);
+
+ DALI_TEST_CHECK(1 == animation.GetLoopCount());
+
+ // Start the animation
+ animation.SetLoopCount(3);
+ DALI_TEST_CHECK(animation.IsLooping());
+ DALI_TEST_CHECK(3 == animation.GetLoopCount());
+
+ animation.Play();
+
+ application.Render(0);
+ application.SendNotification();
+
+ // Loop
+ float intervalSeconds = 3.0f;
+
+ application.Render(static_cast<unsigned int>(durationSeconds*intervalSeconds*1000.0f));
+ application.Render(static_cast<unsigned int>(durationSeconds*intervalSeconds*1000.0f));
+
+ application.Render(0);
+ application.SendNotification();
+
+ application.Render(static_cast<unsigned int>(durationSeconds*intervalSeconds*1000.0f));
+ application.SendNotification();
+
+ animation.SetLoopCount(0);
+ DALI_TEST_CHECK(animation.IsLooping());
+ DALI_TEST_CHECK(0 == animation.GetLoopCount());
+
+ animation.SetLoopCount(1);
+ DALI_TEST_CHECK(!animation.IsLooping());
+ DALI_TEST_CHECK(1 == animation.GetLoopCount());
+
+ END_TEST;
+}
+
+
+int UtcDaliAnimationGetCurrentLoopP(void)
+{
+ TestApplication application;
+
+ Actor actor = Actor::New();
+ Stage::GetCurrent().Add(actor);
+
+ // Build the animation
+ float durationSeconds(1.0f);
+ Animation animation = Animation::New(durationSeconds);
+ Vector3 targetPosition(10.0f, 10.0f, 10.0f);
+ animation.AnimateTo(Property(actor, Actor::Property::POSITION), targetPosition, AlphaFunction::LINEAR);
+
+ // Start the animation
+ animation.SetLoopCount(3);
+ DALI_TEST_CHECK(animation.IsLooping());
+ DALI_TEST_CHECK(0 == animation.GetCurrentLoop());
+ animation.Play();
+
+ bool signalReceived(false);
+ AnimationFinishCheck finishCheck(signalReceived);
+ animation.FinishedSignal().Connect(&application, finishCheck);
+
+ application.SendNotification();
+
+ // Loop
+ float intervalSeconds = 3.0f;
+
+ application.Render(static_cast<unsigned int>(durationSeconds*intervalSeconds*1000.0f));
+ application.Render(static_cast<unsigned int>(durationSeconds*intervalSeconds*1000.0f));
+
+ application.SendNotification();
+ finishCheck.CheckSignalNotReceived();
+ DALI_TEST_CHECK(2 == animation.GetCurrentLoop());
+
+ application.Render(static_cast<unsigned int>(durationSeconds*intervalSeconds*1000.0f));
+
+ application.SendNotification();
+ finishCheck.CheckSignalReceived();
+ DALI_TEST_CHECK(3 == animation.GetCurrentLoop());
+ DALI_TEST_CHECK(animation.GetLoopCount() == animation.GetCurrentLoop());
+
+ finishCheck.Reset();
+
+ application.Render(static_cast<unsigned int>(durationSeconds*intervalSeconds*1000.0f));
+ application.SendNotification();
+ finishCheck.CheckSignalNotReceived();
+ DALI_TEST_CHECK(3 == animation.GetCurrentLoop());
+
+ application.Render(static_cast<unsigned int>(durationSeconds*intervalSeconds*1000.0f));
+ application.Render(static_cast<unsigned int>(durationSeconds*intervalSeconds*1000.0f));
+ application.Render(static_cast<unsigned int>(durationSeconds*intervalSeconds*1000.0f));
+ application.Render(static_cast<unsigned int>(durationSeconds*intervalSeconds*1000.0f));
+ application.SendNotification();
+ finishCheck.CheckSignalNotReceived();
+ DALI_TEST_CHECK(3 == animation.GetCurrentLoop());
+
+ END_TEST;
+}
+
int UtcDaliAnimationIsLoopingP(void)
{
TestApplication application;
application.SendNotification();
DALI_TEST_EQUALS( 0.0f, animation.GetCurrentProgress(), TEST_LOCATION );
- animation.SetCurrentProgress( 100.0f);
- application.SendNotification();
- DALI_TEST_EQUALS( 0.0f, animation.GetCurrentProgress(), TEST_LOCATION );
+ animation.SetCurrentProgress( 100.0f);
+ application.SendNotification();
+ DALI_TEST_EQUALS( 0.0f, animation.GetCurrentProgress(), TEST_LOCATION );
+ END_TEST;
+}
+
+int UtcDaliAnimationGetCurrentProgressP(void)
+{
+ TestApplication application;
+
+ Actor actor = Actor::New();
+ Stage::GetCurrent().Add(actor);
+
+ // Build the animation
+ Animation animation = Animation::New(0.0f);
+ animation.Play();
+
+ //Test GetCurrentProgress return 0.0 as the duration is 0.0
+ DALI_TEST_EQUALS( 0.0f, animation.GetCurrentProgress(), TEST_LOCATION );
+
+ animation.SetCurrentProgress( 0.5f );
+ application.SendNotification();
+ application.Render(static_cast<unsigned int>(100.0f));
+
+ //Progress should still be 0.0
+ DALI_TEST_EQUALS( 0.0f, animation.GetCurrentProgress(), TEST_LOCATION );
+
+ //Set duration
+ float durationSeconds(1.0f);
+ animation.SetDuration(durationSeconds);
+ application.SendNotification();
+
+ bool signalReceived(false);
+ AnimationFinishCheck finishCheck(signalReceived);
+ animation.FinishedSignal().Connect(&application, finishCheck);
+ application.SendNotification();
+
+ Vector3 targetPosition(100.0f, 100.0f, 100.0f);
+ animation.AnimateTo(Property(actor, Actor::Property::POSITION), targetPosition, AlphaFunction::LINEAR);
+
+ // Start the animation from 40% progress
+ animation.SetCurrentProgress( 0.4f );
+ animation.Play();
+
+ application.SendNotification();
+ application.Render(static_cast<unsigned int>(durationSeconds*200.0f)/* 60% progress */);
+
+ // We didn't expect the animation to finish yet
+ application.SendNotification();
+ finishCheck.CheckSignalNotReceived();
+ DALI_TEST_EQUALS( 0.6f, animation.GetCurrentProgress(), TEST_LOCATION );
+
+ animation.Play(); // Test that calling play has no effect, when animation is already playing
+ application.SendNotification();
+
+ //Set the progress to 70%
+ animation.SetCurrentProgress( 0.7f );
+ application.SendNotification();
+ application.Render(static_cast<unsigned int>(durationSeconds*100.0f)/* 80% progress */);
+ DALI_TEST_EQUALS( 0.8f, animation.GetCurrentProgress(), TEST_LOCATION );
+
+ application.SendNotification();
+ finishCheck.CheckSignalNotReceived();
+ DALI_TEST_EQUALS( 0.8f, animation.GetCurrentProgress(), TEST_LOCATION );
+
+ application.Render(static_cast<unsigned int>(durationSeconds*200.0f) + 1u/*just beyond the animation duration*/);
+ // We did expect the animation to finish
+ application.SendNotification();
+ finishCheck.CheckSignalReceived();
+ END_TEST;
+}
+
+int UtcDaliAnimationSetSpeedFactorP1(void)
+{
+ TestApplication application;
+
+ tet_printf("Testing that setting a speed factor of 2 takes half the time\n");
+
+ Actor actor = Actor::New();
+ Stage::GetCurrent().Add(actor);
+
+ // Build the animation
+ float durationSeconds(1.0f);
+ Animation animation = Animation::New(durationSeconds);
+
+ const Vector3 initialPosition(0.0f, 0.0f, 0.0f);
+ const Vector3 targetPosition(100.0f, 100.0f, 100.0f);
+
+ KeyFrames keyframes = KeyFrames::New();
+ keyframes.Add( 0.0f, initialPosition);
+ keyframes.Add( 1.0f, targetPosition );
+ animation.AnimateBetween( Property(actor, Actor::Property::POSITION), keyframes, AlphaFunction::LINEAR);
+
+ //Set speed to be x2
+ animation.SetSpeedFactor(2.0f);
+
+ // Start the animation
+ animation.Play();
+
+ bool signalReceived(false);
+ AnimationFinishCheck finishCheck(signalReceived);
+ animation.FinishedSignal().Connect(&application, finishCheck);
+
+ application.SendNotification();
+ application.Render(static_cast<unsigned int>(durationSeconds*200.0f)/* 40% progress */);
+
+ // We didn't expect the animation to finish yet
+ application.SendNotification();
+ finishCheck.CheckSignalNotReceived();
+ DALI_TEST_EQUALS( actor.GetCurrentPosition(), (targetPosition * 0.4f), TEST_LOCATION );
+
+ application.Render(static_cast<unsigned int>(durationSeconds*200.0f)/* 80% progress */);
+
+ // We didn't expect the animation to finish yet
+ application.SendNotification();
+ finishCheck.CheckSignalNotReceived();
+ DALI_TEST_EQUALS( actor.GetCurrentPosition(), (targetPosition * 0.8f), TEST_LOCATION );
+
+ application.Render(static_cast<unsigned int>(durationSeconds*100.0f) + 1u/*just beyond half the duration*/);
+
+ // We did expect the animation to finish
+ application.SendNotification();
+ finishCheck.CheckSignalReceived();
+ DALI_TEST_EQUALS( actor.GetCurrentPosition(), targetPosition, TEST_LOCATION );
+
+ // Check that nothing has changed after a couple of buffer swaps
+ application.Render(0);
+ DALI_TEST_EQUALS( targetPosition, actor.GetCurrentPosition(), TEST_LOCATION );
+ application.Render(0);
+ DALI_TEST_EQUALS( targetPosition, actor.GetCurrentPosition(), TEST_LOCATION );
+
END_TEST;
}
-int UtcDaliAnimationGetCurrentProgressP(void)
+int UtcDaliAnimationSetSpeedFactorP2(void)
{
TestApplication application;
Stage::GetCurrent().Add(actor);
// Build the animation
- Animation animation = Animation::New(0.0f);
- animation.Play();
+ float durationSeconds(1.0f);
+ Animation animation = Animation::New(durationSeconds);
- //Test GetCurrentProgress return 0.0 as the duration is 0.0
- DALI_TEST_EQUALS( 0.0f, animation.GetCurrentProgress(), TEST_LOCATION );
+ const Vector3 initialPosition(0.0f, 0.0f, 0.0f);
+ const Vector3 targetPosition(100.0f, 100.0f, 100.0f);
- animation.SetCurrentProgress( 0.5f );
- application.SendNotification();
- application.Render(static_cast<unsigned int>(100.0f));
+ KeyFrames keyframes = KeyFrames::New();
+ keyframes.Add( 0.0f, initialPosition);
+ keyframes.Add( 1.0f, targetPosition );
+ animation.AnimateBetween( Property(actor, Actor::Property::POSITION), keyframes, AlphaFunction::LINEAR);
- //Progress should still be 0.0
- DALI_TEST_EQUALS( 0.0f, animation.GetCurrentProgress(), TEST_LOCATION );
+ tet_printf("Test -1 speed factor. Animation will play in reverse at normal speed\n");
+ animation.SetSpeedFactor( -1.0f );
- //Set duration
- float durationSeconds(1.0f);
- animation.SetDuration(durationSeconds);
- application.SendNotification();
+ // Start the animation
+ animation.Play();
bool signalReceived(false);
AnimationFinishCheck finishCheck(signalReceived);
animation.FinishedSignal().Connect(&application, finishCheck);
- application.SendNotification();
-
- Vector3 targetPosition(100.0f, 100.0f, 100.0f);
- animation.AnimateTo(Property(actor, Actor::Property::POSITION), targetPosition, AlphaFunction::LINEAR);
- // Start the animation from 40% progress
- animation.SetCurrentProgress( 0.4f );
- animation.Play();
+ application.SendNotification();
+ application.Render(static_cast<unsigned int>(durationSeconds*200.0f)/* 80% progress */);
+ // We didn't expect the animation to finish yet
application.SendNotification();
+ finishCheck.CheckSignalNotReceived();
+ DALI_TEST_EQUALS( actor.GetCurrentPosition(), (targetPosition * 0.8f), TEST_LOCATION );
+
application.Render(static_cast<unsigned int>(durationSeconds*200.0f)/* 60% progress */);
// We didn't expect the animation to finish yet
application.SendNotification();
finishCheck.CheckSignalNotReceived();
- DALI_TEST_EQUALS( 0.6f, animation.GetCurrentProgress(), TEST_LOCATION );
+ DALI_TEST_EQUALS( actor.GetCurrentPosition(), (targetPosition * 0.6f), TEST_LOCATION );
- animation.Play(); // Test that calling play has no effect, when animation is already playing
- application.SendNotification();
+ application.Render(static_cast<unsigned int>(durationSeconds*200.0f)/* 40% progress */);
- //Set the progress to 70%
- animation.SetCurrentProgress( 0.7f );
+ // We didn't expect the animation to finish yet
application.SendNotification();
- application.Render(static_cast<unsigned int>(durationSeconds*100.0f)/* 80% progress */);
- DALI_TEST_EQUALS( 0.8f, animation.GetCurrentProgress(), TEST_LOCATION );
+ finishCheck.CheckSignalNotReceived();
+ DALI_TEST_EQUALS( actor.GetCurrentPosition(), (targetPosition * 0.4f), TEST_LOCATION );
+
+ application.Render(static_cast<unsigned int>(durationSeconds*200.0f)/* 20% progress */);
+ // We didn't expect the animation to finish yet
application.SendNotification();
finishCheck.CheckSignalNotReceived();
- DALI_TEST_EQUALS( 0.8f, animation.GetCurrentProgress(), TEST_LOCATION );
+ DALI_TEST_EQUALS( actor.GetCurrentPosition(), (targetPosition * 0.2f), TEST_LOCATION );
application.Render(static_cast<unsigned int>(durationSeconds*200.0f) + 1u/*just beyond the animation duration*/);
+
// We did expect the animation to finish
application.SendNotification();
finishCheck.CheckSignalReceived();
+ DALI_TEST_EQUALS( actor.GetCurrentPosition(), initialPosition, TEST_LOCATION );
+
+ // Check that nothing has changed after a couple of buffer swaps
+ application.Render(0);
+ DALI_TEST_EQUALS( initialPosition, actor.GetCurrentPosition(), TEST_LOCATION );
+ application.Render(0);
+ DALI_TEST_EQUALS( initialPosition, actor.GetCurrentPosition(), TEST_LOCATION );
+
END_TEST;
}
-int UtcDaliAnimationSetSpeedFactorP(void)
+int UtcDaliAnimationSetSpeedFactorP3(void)
{
TestApplication application;
keyframes.Add( 1.0f, targetPosition );
animation.AnimateBetween( Property(actor, Actor::Property::POSITION), keyframes, AlphaFunction::LINEAR);
- //Set speed to be x2
- animation.SetSpeedFactor(2.0f);
+ bool signalReceived(false);
+ AnimationFinishCheck finishCheck(signalReceived);
+ animation.FinishedSignal().Connect(&application, finishCheck);
+
+ tet_printf("Test half speed factor. Animation will take twice the duration\n");
+
+ //Set speed to be half of normal speed
+ animation.SetSpeedFactor( 0.5f );
// Start the animation
animation.Play();
- bool signalReceived(false);
- AnimationFinishCheck finishCheck(signalReceived);
- animation.FinishedSignal().Connect(&application, finishCheck);
+ application.SendNotification();
+ application.Render(static_cast<unsigned int>(durationSeconds*200.0f)/* 10% progress */);
+ // We didn't expect the animation to finish yet
application.SendNotification();
- application.Render(static_cast<unsigned int>(durationSeconds*200.0f)/* 40% progress */);
+ finishCheck.CheckSignalNotReceived();
+ DALI_TEST_EQUALS( actor.GetCurrentPosition(), (targetPosition * 0.1f), TEST_LOCATION );
+
+ application.Render(static_cast<unsigned int>(durationSeconds*200.0f)/* 20% progress */);
// We didn't expect the animation to finish yet
application.SendNotification();
finishCheck.CheckSignalNotReceived();
- DALI_TEST_EQUALS( actor.GetCurrentPosition(), (targetPosition * 0.4f), TEST_LOCATION );
+ DALI_TEST_EQUALS( actor.GetCurrentPosition(), (targetPosition * 0.2f), TEST_LOCATION );
- application.Render(static_cast<unsigned int>(durationSeconds*200.0f)/* 80% progress */);
+ application.Render(static_cast<unsigned int>(durationSeconds*200.0f)/* 30% progress */);
// We didn't expect the animation to finish yet
application.SendNotification();
finishCheck.CheckSignalNotReceived();
- DALI_TEST_EQUALS( actor.GetCurrentPosition(), (targetPosition * 0.8f), TEST_LOCATION );
+ DALI_TEST_EQUALS( actor.GetCurrentPosition(), (targetPosition * 0.3f), TEST_LOCATION );
- application.Render(static_cast<unsigned int>(durationSeconds*100.0f) + 1u/*just beyond half the duration*/);
+ application.SendNotification();
+ application.Render(static_cast<unsigned int>(durationSeconds*200.0f)/* 40% progress */);
+
+ // We didn't expect the animation to finish yet
+ application.SendNotification();
+ finishCheck.CheckSignalNotReceived();
+ DALI_TEST_EQUALS( actor.GetCurrentPosition(), (targetPosition * 0.4f), TEST_LOCATION );
+
+ application.Render(static_cast<unsigned int>(durationSeconds*1200.0f) + 1u/*just beyond the animation duration*/);
// We did expect the animation to finish
application.SendNotification();
DALI_TEST_EQUALS( targetPosition, actor.GetCurrentPosition(), TEST_LOCATION );
application.Render(0);
DALI_TEST_EQUALS( targetPosition, actor.GetCurrentPosition(), TEST_LOCATION );
+ END_TEST;
+}
- finishCheck.Reset();
- //Test -1 speed factor. Animation will play in reverse at normal speed
- animation.SetSpeedFactor( -1.0f );
+int UtcDaliAnimationSetSpeedFactorP4(void)
+{
+ TestApplication application;
+
+ Actor actor = Actor::New();
+ Stage::GetCurrent().Add(actor);
+
+ // Build the animation
+ float durationSeconds(1.0f);
+ Animation animation = Animation::New(durationSeconds);
+
+ const Vector3 initialPosition(0.0f, 0.0f, 0.0f);
+ const Vector3 targetPosition(100.0f, 100.0f, 100.0f);
+
+ KeyFrames keyframes = KeyFrames::New();
+ keyframes.Add( 0.0f, initialPosition);
+ keyframes.Add( 1.0f, targetPosition );
+ animation.AnimateBetween( Property(actor, Actor::Property::POSITION), keyframes, AlphaFunction::LINEAR);
+
+ bool signalReceived(false);
+ AnimationFinishCheck finishCheck(signalReceived);
+ animation.FinishedSignal().Connect(&application, finishCheck);
+
+ tet_printf("Test half speed factor. Animation will take twice the duration\n");
+
+ tet_printf("Set speed to be half of normal speed\n");
+ tet_printf("SetSpeedFactor(0.5f)\n");
+ animation.SetSpeedFactor( 0.5f );
// Start the animation
animation.Play();
application.SendNotification();
- application.Render(static_cast<unsigned int>(durationSeconds*200.0f)/* 80% progress */);
+ application.Render(static_cast<unsigned int>(durationSeconds*200.0f)/* 10% progress */);
// We didn't expect the animation to finish yet
application.SendNotification();
finishCheck.CheckSignalNotReceived();
- DALI_TEST_EQUALS( actor.GetCurrentPosition(), (targetPosition * 0.8f), TEST_LOCATION );
+ DALI_TEST_EQUALS( actor.GetCurrentPosition(), (targetPosition * 0.1f), TEST_LOCATION );
- application.Render(static_cast<unsigned int>(durationSeconds*200.0f)/* 60% progress */);
+ application.Render(static_cast<unsigned int>(durationSeconds*200.0f)/* 20% progress */);
// We didn't expect the animation to finish yet
application.SendNotification();
finishCheck.CheckSignalNotReceived();
- DALI_TEST_EQUALS( actor.GetCurrentPosition(), (targetPosition * 0.6f), TEST_LOCATION );
+ DALI_TEST_EQUALS( actor.GetCurrentPosition(), (targetPosition * 0.2f), TEST_LOCATION );
- application.Render(static_cast<unsigned int>(durationSeconds*200.0f)/* 40% progress */);
+ application.Render(static_cast<unsigned int>(durationSeconds*200.0f)/* 30% progress */);
// We didn't expect the animation to finish yet
application.SendNotification();
finishCheck.CheckSignalNotReceived();
- DALI_TEST_EQUALS( actor.GetCurrentPosition(), (targetPosition * 0.4f), TEST_LOCATION );
+ DALI_TEST_EQUALS( actor.GetCurrentPosition(), (targetPosition * 0.3f), TEST_LOCATION );
+
+ tet_printf("Reverse direction of animation whilst playing\n");
+ tet_printf("SetSpeedFactor(-0.5f)\n");
+ animation.SetSpeedFactor(-0.5f);
+ application.SendNotification();
application.Render(static_cast<unsigned int>(durationSeconds*200.0f)/* 20% progress */);
// We didn't expect the animation to finish yet
finishCheck.CheckSignalNotReceived();
DALI_TEST_EQUALS( actor.GetCurrentPosition(), (targetPosition * 0.2f), TEST_LOCATION );
+ application.Render(static_cast<unsigned int>(durationSeconds*200.0f)/* 10% progress */);
+
+ // We didn't expect the animation to finish yet
+ application.SendNotification();
+ finishCheck.CheckSignalNotReceived();
+ DALI_TEST_EQUALS( actor.GetCurrentPosition(), (targetPosition * 0.1f), 0.0001, TEST_LOCATION );
+
application.Render(static_cast<unsigned int>(durationSeconds*200.0f) + 1u/*just beyond the animation duration*/);
// We did expect the animation to finish
DALI_TEST_EQUALS( initialPosition, actor.GetCurrentPosition(), TEST_LOCATION );
application.Render(0);
DALI_TEST_EQUALS( initialPosition, actor.GetCurrentPosition(), TEST_LOCATION );
+ END_TEST;
+}
- //Test change speed factor on the fly
- finishCheck.Reset();
+int UtcDaliAnimationSetSpeedFactorAndRange(void)
+{
+ TestApplication application;
- //Set speed to be half of normal speed
+ const unsigned int NUM_FRAMES(15);
+
+ struct TestData
+ {
+ float startTime;
+ float endTime;
+ float startX;
+ float endX;
+ float expected[NUM_FRAMES];
+ };
+
+ TestData testData[] = {
+ // ACTOR 0
+ /*0.0f, 0.1f 0.2f 0.3f 0.4f 0.5f 0.6f 0.7f 0.8f 0.9f 1.0f */
+ /* |----------PlayRange---------------| */
+ /* | reverse */
+ { 0.0f, 1.0f, // TimePeriod
+ 0.0f, 100.0f, // POS
+ {/**/ 30.0f, 40.0f, 50.0f, 60.0f, 70.0f, /* Loop */
+ /**/ 30.0f, 40.0f, 50.0f, 60.0f, /* Reverse direction */
+ /**/ 50.0f,
+ /**/ 40.0f,
+ /**/ 30.0f,
+ /**/ 70.0f,
+ /**/ 60.0f,
+ /**/ 50.0f,
+ /**/
+ }
+ },
+
+ // ACTOR 1 - Across start of range
+ /*0.0f, 0.1f 0.2f 0.3f 0.4f 0.5f 0.6f 0.7f 0.8f 0.9f 1.0f */
+ /* |----------PlayRange---------------| */
+ /* | reverse */
+ { 0.2f, 0.5f, // TimePeriod
+ 20.0f, 50.0f, // POS
+ {/**/ 30.0f, 40.0f, 50.0f, 50.0f, 50.0f, /* Loop */
+ /**/ 30.0f, 40.0f, 50.0f, 50.0f, /* Reverse direction @ frame #9 */
+ /**/ 50.0f,
+ /**/ 40.0f,
+ /**/ 30.0f,
+ /**/ 50.0f,
+ /**/ 50.0f,
+ /**/ 50.0f
+ }
+ },
+
+ // ACTOR 2 - Across end of range
+ /*0.0f, 0.1f 0.2f 0.3f 0.4f 0.5f 0.6f 0.7f 0.8f 0.9f 1.0f */
+ /* |----------PlayRange---------------| */
+ /* | reverse */
+ {/**/ 0.5f, 0.9f, // TimePeriod
+ /**/ 50.0f, 90.0f, // POS
+ { /**/ 50.0f, 50.0f, 50.0f, 60.0f, 70.0f, /* Loop */
+ /**/ 50.0f, 50.0f, 50.0f, 60.0f,/* Reverse direction @ frame #9 */
+ /**/ 50.0f,
+ /**/ 50.0f,
+ /**/ 50.0f, 70.0f,
+ /**/ 60.0f,
+ /**/ 50.0f,
+ }
+ },
+
+ // ACTOR 3 - Before beginning of range
+ /*0.0f, 0.1f 0.2f 0.3f 0.4f 0.5f 0.6f 0.7f 0.8f 0.9f 1.0f */
+ /* |----------PlayRange---------------| */
+ /* | reverse */
+ {/**/ 0.1f, 0.25f, // TimePeriod
+ /**/ 10.0f, 25.0f, // POS
+ { /**/
+ /**/ 25.0f, 25.0f, 25.0f, 25.0f, 25.0f, 25.0f, 25.0f, 25.0f, 25.0f, 25.0f, 25.0f, 25.0f, 25.0f, 25.0f, 25.0f
+ /**/
+ }
+ },
+
+ // ACTOR 4 - After end of range
+ /*0.0f, 0.1f 0.2f 0.3f 0.4f 0.5f 0.6f 0.7f 0.8f 0.9f 1.0f */
+ /* |----------PlayRange---------------| */
+ /* | reverse */
+ {/**/ 0.85f, 1.0f, // TimePeriod
+ /**/ 85.0f, 100.0f, // POS
+ { /**/
+ /**/ 85.0f, 85.0f, 85.0f, 85.0f, 85.0f, 85.0f, 85.0f, 85.0f, 85.0f, 85.0f, 85.0f, 85.0f, 85.0f, 85.0f, 85.0f
+ /**/
+ }
+ },
+ // Actor 5 - Middle of range
+ /*0.0f, 0.1f 0.2f 0.3f 0.4f 0.5f 0.6f 0.7f 0.8f 0.9f 1.0f */
+ /* |----------PlayRange---------------| */
+ /* | reverse */
+ {/**/ 0.4f, 0.65f, // Time Period
+ /**/ 40.0f, 65.0f, // Position
+ { /**/ 40.0f, 40.0f, 50.0f, 60.0f, 65.0f,
+ /**/ 40.0f, 40.0f, 50.0f, 60.0f, // Reverse
+ /**/ 50.0f,
+ /**/ 40.0f,
+ /**/ 40.0f,
+ /**/ 65.0f,
+ /**/ 60.0f,
+ /**/ 50.0f,
+ }
+ }
+ };
+
+ const size_t NUM_ENTRIES(sizeof(testData)/sizeof(TestData));
+
+ // Build the animation
+ float durationSeconds(1.0f);
+ Animation animation = Animation::New(durationSeconds);
+ bool signalReceived(false);
+ AnimationFinishCheck finishCheck(signalReceived);
+ animation.FinishedSignal().Connect(&application, finishCheck);
+
+ std::vector<Dali::Actor> actors;
+
+ for( unsigned int actorIndex = 0; actorIndex < NUM_ENTRIES; ++actorIndex )
+ {
+ Actor actor = Actor::New();
+ actor.SetPosition( Vector3( testData[actorIndex].startX, 0, 0 ) );
+ actors.push_back(actor);
+ Stage::GetCurrent().Add(actor);
+
+ if( actorIndex == 0 || actorIndex == NUM_ENTRIES-1 )
+ {
+ KeyFrames keyframes = KeyFrames::New();
+ keyframes.Add( testData[actorIndex].startTime, Vector3(testData[actorIndex].startX, 0, 0));
+ keyframes.Add( testData[actorIndex].endTime, Vector3(testData[actorIndex].endX, 0, 0));
+ animation.AnimateBetween( Property(actor, Actor::Property::POSITION), keyframes, AlphaFunction::LINEAR);
+ }
+ else
+ {
+ animation.AnimateTo( Property(actor, Actor::Property::POSITION), Vector3( testData[actorIndex].endX, 0, 0 ), TimePeriod( testData[actorIndex].startTime, testData[actorIndex].endTime - testData[actorIndex].startTime) );
+ }
+ }
+
+ tet_printf("Test half speed factor. Animation will take twice the duration\n");
+ tet_printf("Set play range to be 0.3 - 0.8 of the duration\n");
+ tet_printf("SetSpeedFactor(0.5f)\n");
animation.SetSpeedFactor( 0.5f );
+ animation.SetPlayRange( Vector2(0.3f, 0.8f) );
+ animation.SetLooping(true);
// Start the animation
animation.Play();
+ application.SendNotification();
+ application.Render(0); // Frame 0 tests initial values
+
+ for( unsigned int frame = 0; frame < NUM_FRAMES; ++frame )
+ {
+ unsigned int actorIndex = 0u;
+ for( actorIndex = 0u; actorIndex < NUM_ENTRIES; ++actorIndex )
+ {
+ DALI_TEST_EQUALS( actors[actorIndex].GetCurrentPosition().x, testData[actorIndex].expected[frame], 0.001, TEST_LOCATION );
+ if( ! Equals(actors[actorIndex].GetCurrentPosition().x, testData[actorIndex].expected[frame]) )
+ {
+ tet_printf("Failed at frame %u, actorIndex %u\n", frame, actorIndex );
+ }
+ }
+
+ if( frame == 8 )
+ {
+ tet_printf("Reverse direction of animation whilst playing after frame 8\n");
+ tet_printf("SetSpeedFactor(-0.5f)\n");
+ animation.SetSpeedFactor(-0.5f);
+ application.SendNotification();
+ }
+ application.Render(200); // 200 ms at half speed corresponds to 0.1 s
+
+ // We didn't expect the animation to finish yet
+ application.SendNotification();
+ finishCheck.CheckSignalNotReceived();
+ }
+
+ END_TEST;
+}
+
+int UtcDaliAnimationSetSpeedFactorRangeAndLoopCount01(void)
+{
+ TestApplication application;
+
+ const unsigned int NUM_FRAMES(15);
+
+ struct TestData
+ {
+ float startTime;
+ float endTime;
+ float startX;
+ float endX;
+ float expected[NUM_FRAMES];
+ };
+
+ TestData testData =
+ // ACTOR 0
+ /*0.0f, 0.1f 0.2f 0.3f 0.4f 0.5f 0.6f 0.7f 0.8f 0.9f 1.0f */
+ /* |----------PlayRange---------------| */
+ { 0.0f, 1.0f, // TimePeriod
+ 0.0f, 100.0f, // POS
+ {/**/ 30.0f, 40.0f, 50.0f, 60.0f, 70.0f, /* Loop */
+ /**/ 30.0f, 40.0f, 50.0f, 60.0f, 70.0f,
+ /**/ 30.0f, 40.0f, 50.0f, 60.0f, 70.0f,
+ /**/
+ }
+ };
+
+
+ // Build the animation
+ float durationSeconds(1.0f);
+ Animation animation = Animation::New(durationSeconds);
+ bool signalReceived(false);
+ AnimationFinishCheck finishCheck(signalReceived);
+ animation.FinishedSignal().Connect(&application, finishCheck);
+
+ std::vector<Dali::Actor> actors;
+
+ Actor actor = Actor::New();
+ actor.SetPosition( Vector3( testData.startX, 0, 0 ) );
+ actors.push_back(actor);
+ Stage::GetCurrent().Add(actor);
+
+ KeyFrames keyframes = KeyFrames::New();
+ keyframes.Add( testData.startTime, Vector3(testData.startX, 0, 0));
+ keyframes.Add( testData.endTime, Vector3(testData.endX, 0, 0));
+ animation.AnimateBetween( Property(actor, Actor::Property::POSITION), keyframes, AlphaFunction::LINEAR);
+
+ tet_printf("Test half speed factor. Animation will take twice the duration\n");
+ tet_printf("Set play range to be 0.3 - 0.8 of the duration\n");
+ tet_printf("SetSpeedFactor(0.5f)\n");
+ tet_printf("SetLoopCount(3)\n");
+ animation.SetSpeedFactor( 0.5f );
+ animation.SetPlayRange( Vector2(0.3f, 0.8f) );
+ animation.SetLoopCount(3);
+ // Start the animation
+ animation.Play();
application.SendNotification();
- application.Render(static_cast<unsigned int>(durationSeconds*200.0f)/* 10% progress */);
+ application.Render(0); // Frame 0 tests initial values
- // We didn't expect the animation to finish yet
+ for( unsigned int frame = 0; frame < NUM_FRAMES; ++frame )
+ {
+ DALI_TEST_EQUALS( actor.GetCurrentPosition().x, testData.expected[frame], 0.001, TEST_LOCATION );
+
+ application.Render(200); // 200 ms at half speed corresponds to 0.1 s
+
+ if( frame < NUM_FRAMES-1 )
+ {
+ // We didn't expect the animation to finish yet
+ application.SendNotification();
+ finishCheck.CheckSignalNotReceived();
+ }
+ }
+
+ // We did expect the animation to finish
application.SendNotification();
- finishCheck.CheckSignalNotReceived();
- DALI_TEST_EQUALS( actor.GetCurrentPosition(), (targetPosition * 0.1f), TEST_LOCATION );
+ finishCheck.CheckSignalReceived();
+ DALI_TEST_EQUALS( actor.GetCurrentPosition().x, 80.0f, 0.001, TEST_LOCATION );
- application.Render(static_cast<unsigned int>(durationSeconds*200.0f)/* 20% progress */);
+ END_TEST;
+}
+
+int UtcDaliAnimationSetSpeedFactorRangeAndLoopCount02(void)
+{
+ TestApplication application;
+
+ const unsigned int NUM_FRAMES(15);
+
+ struct TestData
+ {
+ float startTime;
+ float endTime;
+ float startX;
+ float endX;
+ float expected[NUM_FRAMES];
+ };
+
+ TestData testData =
+ // ACTOR 0
+ /*0.0f, 0.1f 0.2f 0.3f 0.4f 0.5f 0.6f 0.7f 0.8f 0.9f 1.0f */
+ /* |----------PlayRange---------------| */
+ { 0.0f, 1.0f, // TimePeriod
+ 0.0f, 100.0f, // POS
+ {/**/ 80.0f, 70.0f, 60.0f, 50.0f, 40.0f,
+ /**/ 80.0f, 70.0f, 60.0f, 50.0f, 40.0f,
+ /**/ 80.0f, 70.0f, 60.0f, 50.0f, 40.0f,
+ }
+ };
+
+
+ // Build the animation
+ float durationSeconds(1.0f);
+ Animation animation = Animation::New(durationSeconds);
+ bool signalReceived(false);
+ AnimationFinishCheck finishCheck(signalReceived);
+ animation.FinishedSignal().Connect(&application, finishCheck);
+
+ std::vector<Dali::Actor> actors;
+
+ Actor actor = Actor::New();
+ actor.SetPosition( Vector3( testData.startX, 0, 0 ) );
+ actors.push_back(actor);
+ Stage::GetCurrent().Add(actor);
- // We didn't expect the animation to finish yet
- application.SendNotification();
- finishCheck.CheckSignalNotReceived();
- DALI_TEST_EQUALS( actor.GetCurrentPosition(), (targetPosition * 0.2f), TEST_LOCATION );
+ KeyFrames keyframes = KeyFrames::New();
+ keyframes.Add( testData.startTime, Vector3(testData.startX, 0, 0));
+ keyframes.Add( testData.endTime, Vector3(testData.endX, 0, 0));
+ animation.AnimateBetween( Property(actor, Actor::Property::POSITION), keyframes, AlphaFunction::LINEAR);
- application.Render(static_cast<unsigned int>(durationSeconds*200.0f)/* 30% progress */);
+ tet_printf("Test reverse half speed factor. Animation will take twice the duration\n");
+ tet_printf("Set play range to be 0.3 - 0.8 of the duration\n");
+ tet_printf("SetSpeedFactor(-0.5f)\n");
+ tet_printf("SetLoopCount(3)\n");
+ animation.SetSpeedFactor( -0.5f );
+ animation.SetPlayRange( Vector2(0.3f, 0.8f) );
+ animation.SetLoopCount(3);
- // We didn't expect the animation to finish yet
+ // Start the animation
+ animation.Play();
application.SendNotification();
- finishCheck.CheckSignalNotReceived();
- DALI_TEST_EQUALS( actor.GetCurrentPosition(), (targetPosition * 0.3f), TEST_LOCATION );
+ application.Render(0); // Frame 0 tests initial values
- //Change speed factor while animation still playing.
- animation.SetSpeedFactor(-1.0f);
- application.SendNotification();
- application.Render(static_cast<unsigned int>(durationSeconds*200.0f)/* 10% progress */);
+ for( unsigned int frame = 0; frame < NUM_FRAMES; ++frame )
+ {
+ DALI_TEST_EQUALS( actor.GetCurrentPosition().x, testData.expected[frame], 0.001, TEST_LOCATION );
- // We didn't expect the animation to finish yet
- application.SendNotification();
- finishCheck.CheckSignalNotReceived();
- DALI_TEST_EQUALS( actor.GetCurrentPosition(), (targetPosition * 0.1f), TEST_LOCATION );
+ application.Render(200); // 200 ms at half speed corresponds to 0.1 s
- application.Render(static_cast<unsigned int>(durationSeconds*100.0f) + 1u/*just beyond the animation duration*/);
+ if( frame < NUM_FRAMES-1 )
+ {
+ // We didn't expect the animation to finish yet
+ application.SendNotification();
+ finishCheck.CheckSignalNotReceived();
+ }
+ }
// We did expect the animation to finish
application.SendNotification();
finishCheck.CheckSignalReceived();
- DALI_TEST_EQUALS( actor.GetCurrentPosition(), initialPosition, TEST_LOCATION );
+ DALI_TEST_EQUALS( actor.GetCurrentPosition().x, 30.0f, 0.001, TEST_LOCATION );
- // Check that nothing has changed after a couple of buffer swaps
- application.Render(0);
- DALI_TEST_EQUALS( initialPosition, actor.GetCurrentPosition(), TEST_LOCATION );
- application.Render(0);
- DALI_TEST_EQUALS( initialPosition, actor.GetCurrentPosition(), TEST_LOCATION );
END_TEST;
}
+
int UtcDaliAnimationGetSpeedFactorP(void)
{
TestApplication application;
END_TEST;
}
-int UtcDaliAnimationStoP(void)
+
+int UtcDaliAnimationGetStateP(void)
+{
+ TestApplication application;
+
+ Actor actor = Actor::New();
+ Stage::GetCurrent().Add(actor);
+
+ // Build the animation
+ float durationSeconds(1.0f);
+ Animation animation = Animation::New(durationSeconds);
+ Vector3 targetPosition(100.0f, 100.0f, 100.0f);
+ animation.AnimateTo(Property(actor, Actor::Property::POSITION), targetPosition, AlphaFunction::LINEAR);
+ DALI_TEST_EQUALS( animation.GetState(), Animation::STOPPED, TEST_LOCATION );
+
+ Vector3 fiftyPercentProgress(targetPosition * 0.5f);
+
+ // Start the animation
+ animation.Play();
+
+ DALI_TEST_EQUALS( animation.GetState(), Animation::PLAYING, TEST_LOCATION );
+
+ bool signalReceived(false);
+ AnimationFinishCheck finishCheck(signalReceived);
+ animation.FinishedSignal().Connect(&application, finishCheck);
+
+ application.SendNotification();
+ application.Render(static_cast<unsigned int>(durationSeconds*500.0f)/* 50% progress */);
+
+ // We didn't expect the animation to finish yet
+ application.SendNotification();
+ finishCheck.CheckSignalNotReceived();
+ DALI_TEST_EQUALS( animation.GetState(), Animation::PLAYING, TEST_LOCATION );
+ DALI_TEST_EQUALS( actor.GetCurrentPosition(), fiftyPercentProgress, TEST_LOCATION );
+
+ // Pause the animation
+ animation.Pause();
+ DALI_TEST_EQUALS( animation.GetState(), Animation::PAUSED, TEST_LOCATION );
+ application.SendNotification();
+ application.Render(0.f);
+
+ // Loop 5 times
+ for (int i=0; i<5; ++i)
+ {
+ application.Render(static_cast<unsigned int>(durationSeconds*500.0f));
+
+ // We didn't expect the animation to finish yet
+ application.SendNotification();
+ finishCheck.CheckSignalNotReceived();
+ DALI_TEST_EQUALS( actor.GetCurrentPosition(), fiftyPercentProgress/* Still 50% progress when paused */, TEST_LOCATION );
+ DALI_TEST_EQUALS( animation.GetState(), Animation::PAUSED, TEST_LOCATION );
+ }
+
+ // Keep going
+ finishCheck.Reset();
+ animation.Play();
+ DALI_TEST_EQUALS( animation.GetState(), Animation::PLAYING, TEST_LOCATION );
+ application.SendNotification();
+ application.Render(static_cast<unsigned int>(durationSeconds*490.0f)/*slightly less than the animation duration*/);
+ // We didn't expect the animation to finish yet
+ application.SendNotification();
+ finishCheck.CheckSignalNotReceived();
+ DALI_TEST_EQUALS( animation.GetState(), Animation::PLAYING, TEST_LOCATION );
+
+ application.SendNotification();
+ application.Render(static_cast<unsigned int>(durationSeconds*10.0f) + 1u/*just beyond the animation duration*/);
+
+ // We did expect the animation to finish
+ application.SendNotification();
+ finishCheck.CheckSignalReceived();
+ DALI_TEST_EQUALS( actor.GetCurrentPosition(), targetPosition, TEST_LOCATION );
+ DALI_TEST_EQUALS( animation.GetState(), Animation::STOPPED, TEST_LOCATION );
+
+ // Check that nothing has changed after a couple of buffer swaps
+ application.Render(0);
+ DALI_TEST_EQUALS( targetPosition, actor.GetCurrentPosition(), TEST_LOCATION );
+ application.Render(0);
+ DALI_TEST_EQUALS( targetPosition, actor.GetCurrentPosition(), TEST_LOCATION );
+ DALI_TEST_EQUALS( animation.GetState(), Animation::STOPPED, TEST_LOCATION );
+
+ // re-play
+ finishCheck.Reset();
+ animation.Play();
+ DALI_TEST_EQUALS( animation.GetState(), Animation::PLAYING, TEST_LOCATION );
+ application.SendNotification();
+ application.Render(static_cast<unsigned int>(durationSeconds*490.0f)/*slightly less than the animation duration*/);
+ application.SendNotification();
+ finishCheck.CheckSignalNotReceived();
+ DALI_TEST_EQUALS( animation.GetState(), Animation::PLAYING, TEST_LOCATION );
+
+
+ END_TEST;
+}
+
+int UtcDaliAnimationStopP(void)
{
TestApplication application;
Property::Index index = actor.RegisterProperty( "testProperty", startValue );
Stage::GetCurrent().Add(actor);
DALI_TEST_CHECK( actor.GetProperty<bool>(index) == startValue );
+ DALI_TEST_CHECK( DevelHandle::GetCurrentProperty< bool >( actor, index ) == startValue );
// Build the animation
float durationSeconds(2.0f);
// We didn't expect the animation to finish yet
application.SendNotification();
finishCheck.CheckSignalNotReceived();
- DALI_TEST_CHECK( actor.GetProperty<bool>(index) == startValue );
+ DALI_TEST_CHECK( DevelHandle::GetCurrentProperty< bool >( actor, index ) == startValue );
application.SendNotification();
application.Render(static_cast<unsigned int>(durationSeconds*50.0f) + 1u/*just beyond the animation duration*/);
// We did expect the animation to finish
application.SendNotification();
finishCheck.CheckSignalReceived();
- DALI_TEST_CHECK( actor.GetProperty<bool>(index) == finalValue );
+ DALI_TEST_CHECK( DevelHandle::GetCurrentProperty< bool >( actor, index ) == finalValue );
// Check that nothing has changed after a couple of buffer swaps
application.Render(0);
- DALI_TEST_CHECK( actor.GetProperty<bool>(index) == finalValue );
+ DALI_TEST_CHECK( DevelHandle::GetCurrentProperty< bool >( actor, index ) == finalValue );
application.Render(0);
- DALI_TEST_CHECK( actor.GetProperty<bool>(index) == finalValue );
+ DALI_TEST_CHECK( DevelHandle::GetCurrentProperty< bool >( actor, index ) == finalValue );
// Repeat with relative value "false" - this should be an NOOP
animation = Animation::New(durationSeconds);
// We didn't expect the animation to finish yet
application.SendNotification();
finishCheck.CheckSignalNotReceived();
- DALI_TEST_CHECK( actor.GetProperty<bool>(index) == finalValue );
+ DALI_TEST_CHECK( DevelHandle::GetCurrentProperty< bool >( actor, index ) == finalValue );
application.SendNotification();
application.Render(static_cast<unsigned int>(durationSeconds*50.0f) + 1u/*just beyond the animation duration*/);
// We did expect the animation to finish
application.SendNotification();
finishCheck.CheckSignalReceived();
- DALI_TEST_CHECK( actor.GetProperty<bool>(index) == finalValue );
+ DALI_TEST_CHECK( DevelHandle::GetCurrentProperty< bool >( actor, index ) == finalValue );
// Check that nothing has changed after a couple of buffer swaps
application.Render(0);
- DALI_TEST_CHECK( actor.GetProperty<bool>(index) == finalValue );
+ DALI_TEST_CHECK( DevelHandle::GetCurrentProperty< bool >( actor, index ) == finalValue );
application.Render(0);
- DALI_TEST_CHECK( actor.GetProperty<bool>(index) == finalValue );
+ DALI_TEST_CHECK( DevelHandle::GetCurrentProperty< bool >( actor, index ) == finalValue );
END_TEST;
}
Property::Index index = actor.RegisterProperty( "testProperty", startValue );
Stage::GetCurrent().Add(actor);
DALI_TEST_CHECK( actor.GetProperty<bool>(index) == startValue );
+ DALI_TEST_CHECK( DevelHandle::GetCurrentProperty< bool >( actor, index ) == startValue );
// Build the animation
float durationSeconds(2.0f);
// We didn't expect the animation to finish yet
application.SendNotification();
finishCheck.CheckSignalNotReceived();
- DALI_TEST_CHECK( actor.GetProperty<bool>(index) == startValue );
+ DALI_TEST_CHECK( DevelHandle::GetCurrentProperty< bool >( actor, index ) == startValue );
application.SendNotification();
application.Render(static_cast<unsigned int>(durationSeconds*50.0f) + 1u/*just beyond the animation duration*/);
// We did expect the animation to finish
application.SendNotification();
finishCheck.CheckSignalReceived();
- DALI_TEST_CHECK( actor.GetProperty<bool>(index) == finalValue );
+ DALI_TEST_CHECK( DevelHandle::GetCurrentProperty< bool >( actor, index ) == finalValue );
// Check that nothing has changed after a couple of buffer swaps
application.Render(0);
- DALI_TEST_CHECK( actor.GetProperty<bool>(index) == finalValue );
+ DALI_TEST_CHECK( DevelHandle::GetCurrentProperty< bool >( actor, index ) == finalValue );
application.Render(0);
- DALI_TEST_CHECK( actor.GetProperty<bool>(index) == finalValue );
+ DALI_TEST_CHECK( DevelHandle::GetCurrentProperty< bool >( actor, index ) == finalValue );
// Repeat with relative value "false" - this should be an NOOP
animation = Animation::New(durationSeconds);
// We didn't expect the animation to finish yet
application.SendNotification();
finishCheck.CheckSignalNotReceived();
- DALI_TEST_CHECK( actor.GetProperty<bool>(index) == finalValue );
+ DALI_TEST_CHECK( DevelHandle::GetCurrentProperty< bool >( actor, index ) == finalValue );
application.SendNotification();
application.Render(static_cast<unsigned int>(durationSeconds*50.0f) + 1u/*just beyond the animation duration*/);
// We did expect the animation to finish
application.SendNotification();
finishCheck.CheckSignalReceived();
- DALI_TEST_CHECK( actor.GetProperty<bool>(index) == finalValue );
+ DALI_TEST_CHECK( DevelHandle::GetCurrentProperty< bool >( actor, index ) == finalValue );
END_TEST;
}
Property::Index index = actor.RegisterProperty( "testProperty", startValue );
Stage::GetCurrent().Add(actor);
DALI_TEST_CHECK( actor.GetProperty<bool>(index) == startValue );
+ DALI_TEST_CHECK( DevelHandle::GetCurrentProperty< bool >( actor, index ) == startValue );
// Build the animation
float durationSeconds(2.0f);
// We didn't expect the animation to finish yet
application.SendNotification();
finishCheck.CheckSignalNotReceived();
- DALI_TEST_CHECK( actor.GetProperty<bool>(index) == startValue );
+ DALI_TEST_CHECK( DevelHandle::GetCurrentProperty< bool >( actor, index ) == startValue );
application.SendNotification();
application.Render(static_cast<unsigned int>(animatorDurationSeconds*50.0f) + 1u/*just beyond the animator duration*/);
finishCheck.CheckSignalNotReceived();
// ...however we should have reached the final value
- DALI_TEST_CHECK( actor.GetProperty<bool>(index) == finalValue );
+ DALI_TEST_CHECK( DevelHandle::GetCurrentProperty< bool >( actor, index ) == finalValue );
application.SendNotification();
application.Render(static_cast<unsigned int>(animatorDurationSeconds*1000.0f)/*just beyond the animation duration*/);
// We did expect the animation to finish
application.SendNotification();
finishCheck.CheckSignalReceived();
- DALI_TEST_CHECK( actor.GetProperty<bool>(index) == finalValue );
+ DALI_TEST_CHECK( DevelHandle::GetCurrentProperty< bool >( actor, index ) == finalValue );
// Check that nothing has changed after a couple of buffer swaps
application.Render(0);
- DALI_TEST_CHECK( actor.GetProperty<bool>(index) == finalValue );
+ DALI_TEST_CHECK( DevelHandle::GetCurrentProperty< bool >( actor, index ) == finalValue );
application.Render(0);
- DALI_TEST_CHECK( actor.GetProperty<bool>(index) == finalValue );
+ DALI_TEST_CHECK( DevelHandle::GetCurrentProperty< bool >( actor, index ) == finalValue );
END_TEST;
}
Property::Index index = actor.RegisterProperty( "testProperty", startValue );
Stage::GetCurrent().Add(actor);
DALI_TEST_CHECK( actor.GetProperty<bool>(index) == startValue );
+ DALI_TEST_CHECK( DevelHandle::GetCurrentProperty< bool >( actor, index ) == startValue );
// Build the animation
float durationSeconds(2.0f);
// We didn't expect the animation to finish yet
application.SendNotification();
finishCheck.CheckSignalNotReceived();
- DALI_TEST_CHECK( actor.GetProperty<bool>(index) == startValue );
+ DALI_TEST_CHECK( DevelHandle::GetCurrentProperty< bool >( actor, index ) == startValue );
application.SendNotification();
application.Render(static_cast<unsigned int>(animatorDurationSeconds*50.0f) + 1u/*just beyond the animator duration*/);
finishCheck.CheckSignalNotReceived();
// ...however we should have reached the final value
- DALI_TEST_CHECK( actor.GetProperty<bool>(index) == finalValue );
+ DALI_TEST_CHECK( DevelHandle::GetCurrentProperty< bool >( actor, index ) == finalValue );
application.SendNotification();
application.Render(static_cast<unsigned int>(animatorDurationSeconds*1000.0f)/*just beyond the animation duration*/);
// We did expect the animation to finish
application.SendNotification();
finishCheck.CheckSignalReceived();
- DALI_TEST_CHECK( actor.GetProperty<bool>(index) == finalValue );
+ DALI_TEST_CHECK( DevelHandle::GetCurrentProperty< bool >( actor, index ) == finalValue );
// Check that nothing has changed after a couple of buffer swaps
application.Render(0);
- DALI_TEST_CHECK( actor.GetProperty<bool>(index) == finalValue );
+ DALI_TEST_CHECK( DevelHandle::GetCurrentProperty< bool >( actor, index ) == finalValue );
application.Render(0);
- DALI_TEST_CHECK( actor.GetProperty<bool>(index) == finalValue );
+ DALI_TEST_CHECK( DevelHandle::GetCurrentProperty< bool >( actor, index ) == finalValue );
END_TEST;
}
Property::Index index = actor.RegisterProperty( "testProperty", startValue );
Stage::GetCurrent().Add(actor);
DALI_TEST_EQUALS( actor.GetProperty<float>(index), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, index ), startValue, TEST_LOCATION );
// Build the animation
float durationSeconds(2.0f);
// We didn't expect the animation to finish yet
application.SendNotification();
finishCheck.CheckSignalNotReceived();
- DALI_TEST_EQUALS( actor.GetProperty<float>(index), ninetyFivePercentProgress, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, index ), ninetyFivePercentProgress, TEST_LOCATION );
application.SendNotification();
application.Render(static_cast<unsigned int>(durationSeconds*50.0f) + 1u/*just beyond the animation duration*/);
// We did expect the animation to finish
application.SendNotification();
finishCheck.CheckSignalReceived();
- DALI_TEST_EQUALS( actor.GetProperty<float>(index), targetValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, index ), targetValue, TEST_LOCATION );
// Check that nothing has changed after a couple of buffer swaps
application.Render(0);
- DALI_TEST_EQUALS( actor.GetProperty<float>(index), targetValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, index ), targetValue, TEST_LOCATION );
application.Render(0);
- DALI_TEST_EQUALS( actor.GetProperty<float>(index), targetValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, index ), targetValue, TEST_LOCATION );
END_TEST;
}
Property::Index index = actor.RegisterProperty( "testProperty", startValue );
Stage::GetCurrent().Add(actor);
DALI_TEST_EQUALS( actor.GetProperty<float>(index), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, index ), startValue, TEST_LOCATION );
// Build the animation
float durationSeconds(1.0f);
finishCheck.CheckSignalNotReceived();
// The position should have moved more, than with a linear alpha function
- float current(actor.GetProperty<float>(index));
+ float current( DevelHandle::GetCurrentProperty< float >( actor, index ) );
DALI_TEST_CHECK( current > ninetyFivePercentProgress );
application.SendNotification();
// We did expect the animation to finish
application.SendNotification();
finishCheck.CheckSignalReceived();
- DALI_TEST_EQUALS( actor.GetProperty<float>(index), targetValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, index ), targetValue, TEST_LOCATION );
// Check that nothing has changed after a couple of buffer swaps
application.Render(0);
- DALI_TEST_EQUALS( actor.GetProperty<float>(index), targetValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, index ), targetValue, TEST_LOCATION );
application.Render(0);
- DALI_TEST_EQUALS( actor.GetProperty<float>(index), targetValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, index ), targetValue, TEST_LOCATION );
END_TEST;
}
Property::Index index = actor.RegisterProperty( "testProperty", startValue );
Stage::GetCurrent().Add(actor);
DALI_TEST_EQUALS( actor.GetProperty<float>(index), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, index ), startValue, TEST_LOCATION );
// Build the animation
float durationSeconds(1.0f);
// We didn't expect the animation to finish yet
application.SendNotification();
finishCheck.CheckSignalNotReceived();
- DALI_TEST_EQUALS( actor.GetProperty<float>(index), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, index ), startValue, TEST_LOCATION );
application.SendNotification();
application.Render(static_cast<unsigned int>(durationSeconds*250.0f)/* 75% animation progress, 50% animator progress */);
// We didn't expect the animation to finish yet
application.SendNotification();
finishCheck.CheckSignalNotReceived();
- DALI_TEST_EQUALS( actor.GetProperty<float>(index), startValue+(relativeValue*0.5f), TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, index ), startValue+(relativeValue*0.5f), TEST_LOCATION );
application.SendNotification();
application.Render(static_cast<unsigned int>(durationSeconds*250.0f) + 1u/*just beyond the animation duration*/);
// We did expect the animation to finish
application.SendNotification();
finishCheck.CheckSignalReceived();
- DALI_TEST_EQUALS( actor.GetProperty<float>(index), targetValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, index ), targetValue, TEST_LOCATION );
// Check that nothing has changed after a couple of buffer swaps
application.Render(0);
- DALI_TEST_EQUALS( actor.GetProperty<float>(index), targetValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, index ), targetValue, TEST_LOCATION );
application.Render(0);
- DALI_TEST_EQUALS( actor.GetProperty<float>(index), targetValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, index ), targetValue, TEST_LOCATION );
END_TEST;
}
Property::Index index = actor.RegisterProperty( "testProperty", startValue );
Stage::GetCurrent().Add(actor);
DALI_TEST_EQUALS( actor.GetProperty<float>(index), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, index ), startValue, TEST_LOCATION );
// Build the animation
float durationSeconds(1.0f);
// We didn't expect the animation to finish yet
application.SendNotification();
finishCheck.CheckSignalNotReceived();
- DALI_TEST_EQUALS( actor.GetProperty<float>(index), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, index ), startValue, TEST_LOCATION );
application.SendNotification();
application.Render(static_cast<unsigned int>(durationSeconds*250.0f)/* 75% animation progress, 50% animator progress */);
// We didn't expect the animation to finish yet
application.SendNotification();
finishCheck.CheckSignalNotReceived();
- DALI_TEST_EQUALS( actor.GetProperty<float>(index), startValue+(relativeValue*0.5f), TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, index ), startValue+(relativeValue*0.5f), TEST_LOCATION );
application.SendNotification();
application.Render(static_cast<unsigned int>(durationSeconds*250.0f) + 1u/*just beyond the animation duration*/);
// We did expect the animation to finish
application.SendNotification();
finishCheck.CheckSignalReceived();
- DALI_TEST_EQUALS( actor.GetProperty<float>(index), targetValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, index ), targetValue, TEST_LOCATION );
// Check that nothing has changed after a couple of buffer swaps
application.Render(0);
- DALI_TEST_EQUALS( actor.GetProperty<float>(index), targetValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, index ), targetValue, TEST_LOCATION );
application.Render(0);
- DALI_TEST_EQUALS( actor.GetProperty<float>(index), targetValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, index ), targetValue, TEST_LOCATION );
END_TEST;
}
Property::Index index = actor.RegisterProperty( "testProperty", startValue );
Stage::GetCurrent().Add(actor);
DALI_TEST_EQUALS( actor.GetProperty<int>(index), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< int >( actor, index ), startValue, TEST_LOCATION );
// Build the animation
float durationSeconds(2.0f);
// We didn't expect the animation to finish yet
application.SendNotification();
finishCheck.CheckSignalNotReceived();
- DALI_TEST_EQUALS( actor.GetProperty<int>(index), ninetyFivePercentProgress, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< int >( actor, index ), ninetyFivePercentProgress, TEST_LOCATION );
application.SendNotification();
application.Render(static_cast<unsigned int>(durationSeconds*50.0f) + 1u/*just beyond the animation duration*/);
// We did expect the animation to finish
application.SendNotification();
finishCheck.CheckSignalReceived();
- DALI_TEST_EQUALS( actor.GetProperty<int>(index), targetValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< int >( actor, index ), targetValue, TEST_LOCATION );
// Check that nothing has changed after a couple of buffer swaps
application.Render(0);
- DALI_TEST_EQUALS( actor.GetProperty<int>(index), targetValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< int >( actor, index ), targetValue, TEST_LOCATION );
application.Render(0);
- DALI_TEST_EQUALS( actor.GetProperty<int>(index), targetValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< int >( actor, index ), targetValue, TEST_LOCATION );
END_TEST;
}
Property::Index index = actor.RegisterProperty( "testProperty", startValue );
Stage::GetCurrent().Add(actor);
DALI_TEST_EQUALS( actor.GetProperty<int>(index), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< int >( actor, index ), startValue, TEST_LOCATION );
// Build the animation
float durationSeconds(1.0f);
finishCheck.CheckSignalNotReceived();
// The position should have moved more, than with a linear alpha function
- int current(actor.GetProperty<int>(index));
+ int current( DevelHandle::GetCurrentProperty< int >( actor, index ) );
DALI_TEST_CHECK( current > ninetyFivePercentProgress );
application.SendNotification();
// We did expect the animation to finish
application.SendNotification();
finishCheck.CheckSignalReceived();
- DALI_TEST_EQUALS( actor.GetProperty<int>(index), targetValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< int >( actor, index ), targetValue, TEST_LOCATION );
// Check that nothing has changed after a couple of buffer swaps
application.Render(0);
- DALI_TEST_EQUALS( actor.GetProperty<int>(index), targetValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< int >( actor, index ), targetValue, TEST_LOCATION );
application.Render(0);
- DALI_TEST_EQUALS( actor.GetProperty<int>(index), targetValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< int >( actor, index ), targetValue, TEST_LOCATION );
END_TEST;
}
Property::Index index = actor.RegisterProperty( "testProperty", startValue );
Stage::GetCurrent().Add(actor);
DALI_TEST_EQUALS( actor.GetProperty<int>(index), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< int >( actor, index ), startValue, TEST_LOCATION );
// Build the animation
float durationSeconds(1.0f);
// We didn't expect the animation to finish yet
application.SendNotification();
finishCheck.CheckSignalNotReceived();
- DALI_TEST_EQUALS( actor.GetProperty<int>(index), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< int >( actor, index ), startValue, TEST_LOCATION );
application.SendNotification();
application.Render(static_cast<unsigned int>(durationSeconds*250.0f)/* 75% animation progress, 50% animator progress */);
// We didn't expect the animation to finish yet
application.SendNotification();
finishCheck.CheckSignalNotReceived();
- DALI_TEST_EQUALS( actor.GetProperty<int>(index), static_cast<int>(startValue+(relativeValue*0.5f)+0.5f), TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< int >( actor, index ), static_cast<int>(startValue+(relativeValue*0.5f)+0.5f), TEST_LOCATION );
application.SendNotification();
application.Render(static_cast<unsigned int>(durationSeconds*250.0f) + 1u/*just beyond the animation duration*/);
// We did expect the animation to finish
application.SendNotification();
finishCheck.CheckSignalReceived();
- DALI_TEST_EQUALS( actor.GetProperty<int>(index), targetValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< int >( actor, index ), targetValue, TEST_LOCATION );
// Check that nothing has changed after a couple of buffer swaps
application.Render(0);
- DALI_TEST_EQUALS( actor.GetProperty<int>(index), targetValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< int >( actor, index ), targetValue, TEST_LOCATION );
application.Render(0);
- DALI_TEST_EQUALS( actor.GetProperty<int>(index), targetValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< int >( actor, index ), targetValue, TEST_LOCATION );
END_TEST;
}
Property::Index index = actor.RegisterProperty( "testProperty", startValue );
Stage::GetCurrent().Add(actor);
DALI_TEST_EQUALS( actor.GetProperty<int>(index), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< int >( actor, index ), startValue, TEST_LOCATION );
// Build the animation
float durationSeconds(1.0f);
// We didn't expect the animation to finish yet
application.SendNotification();
finishCheck.CheckSignalNotReceived();
- DALI_TEST_EQUALS( actor.GetProperty<int>(index), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< int >( actor, index ), startValue, TEST_LOCATION );
application.SendNotification();
application.Render(static_cast<unsigned int>(durationSeconds*250.0f)/* 75% animation progress, 50% animator progress */);
// We didn't expect the animation to finish yet
application.SendNotification();
finishCheck.CheckSignalNotReceived();
- DALI_TEST_EQUALS( actor.GetProperty<int>(index), static_cast<int>(startValue+(relativeValue*0.5f)+0.5f), TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< int >( actor, index ), static_cast<int>(startValue+(relativeValue*0.5f)+0.5f), TEST_LOCATION );
application.SendNotification();
application.Render(static_cast<unsigned int>(durationSeconds*250.0f) + 1u/*just beyond the animation duration*/);
// We did expect the animation to finish
application.SendNotification();
finishCheck.CheckSignalReceived();
- DALI_TEST_EQUALS( actor.GetProperty<int>(index), targetValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< int >( actor, index ), targetValue, TEST_LOCATION );
// Check that nothing has changed after a couple of buffer swaps
application.Render(0);
- DALI_TEST_EQUALS( actor.GetProperty<int>(index), targetValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< int >( actor, index ), targetValue, TEST_LOCATION );
application.Render(0);
- DALI_TEST_EQUALS( actor.GetProperty<int>(index), targetValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< int >( actor, index ), targetValue, TEST_LOCATION );
END_TEST;
}
Property::Index index = actor.RegisterProperty( "testProperty", startValue );
Stage::GetCurrent().Add(actor);
DALI_TEST_EQUALS( actor.GetProperty<Vector2>(index), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector2 >( actor, index ), startValue, TEST_LOCATION );
// Build the animation
float durationSeconds(2.0f);
// We didn't expect the animation to finish yet
application.SendNotification();
finishCheck.CheckSignalNotReceived();
- DALI_TEST_EQUALS( actor.GetProperty<Vector2>(index), ninetyFivePercentProgress, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector2 >( actor, index ), ninetyFivePercentProgress, TEST_LOCATION );
application.SendNotification();
application.Render(static_cast<unsigned int>(durationSeconds*50.0f) + 1u/*just beyond the animation duration*/);
// We did expect the animation to finish
application.SendNotification();
finishCheck.CheckSignalReceived();
- DALI_TEST_EQUALS( actor.GetProperty<Vector2>(index), targetValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector2 >( actor, index ), targetValue, TEST_LOCATION );
// Check that nothing has changed after a couple of buffer swaps
application.Render(0);
- DALI_TEST_EQUALS( actor.GetProperty<Vector2>(index), targetValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector2 >( actor, index ), targetValue, TEST_LOCATION );
application.Render(0);
- DALI_TEST_EQUALS( actor.GetProperty<Vector2>(index), targetValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector2 >( actor, index ), targetValue, TEST_LOCATION );
END_TEST;
}
Property::Index index = actor.RegisterProperty( "testProperty", startValue );
Stage::GetCurrent().Add(actor);
DALI_TEST_EQUALS( actor.GetProperty<Vector2>(index), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector2 >( actor, index ), startValue, TEST_LOCATION );
// Build the animation
float durationSeconds(1.0f);
finishCheck.CheckSignalNotReceived();
// The position should have moved more, than with a linear alpha function
- Vector2 current(actor.GetProperty<Vector2>(index));
+ Vector2 current( DevelHandle::GetCurrentProperty< Vector2 >( actor, index ) );
DALI_TEST_CHECK( current.x < ninetyFivePercentProgress.x );
DALI_TEST_CHECK( current.y < ninetyFivePercentProgress.y );
// We did expect the animation to finish
application.SendNotification();
finishCheck.CheckSignalReceived();
- DALI_TEST_EQUALS( actor.GetProperty<Vector2>(index), targetValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector2 >( actor, index ), targetValue, TEST_LOCATION );
// Check that nothing has changed after a couple of buffer swaps
application.Render(0);
- DALI_TEST_EQUALS( actor.GetProperty<Vector2>(index), targetValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector2 >( actor, index ), targetValue, TEST_LOCATION );
application.Render(0);
- DALI_TEST_EQUALS( actor.GetProperty<Vector2>(index), targetValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector2 >( actor, index ), targetValue, TEST_LOCATION );
END_TEST;
}
Property::Index index = actor.RegisterProperty( "testProperty", startValue );
Stage::GetCurrent().Add(actor);
DALI_TEST_EQUALS( actor.GetProperty<Vector2>(index), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector2 >( actor, index ), startValue, TEST_LOCATION );
// Build the animation
float durationSeconds(1.0f);
// We didn't expect the animation to finish yet
application.SendNotification();
finishCheck.CheckSignalNotReceived();
- DALI_TEST_EQUALS( actor.GetProperty<Vector2>(index), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector2 >( actor, index ), startValue, TEST_LOCATION );
application.SendNotification();
application.Render(static_cast<unsigned int>(durationSeconds*250.0f)/* 75% animation progress, 50% animator progress */);
// We didn't expect the animation to finish yet
application.SendNotification();
finishCheck.CheckSignalNotReceived();
- DALI_TEST_EQUALS( actor.GetProperty<Vector2>(index), startValue+(relativeValue*0.5f), TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector2 >( actor, index ), startValue+(relativeValue*0.5f), TEST_LOCATION );
application.SendNotification();
application.Render(static_cast<unsigned int>(durationSeconds*250.0f) + 1u/*just beyond the animation duration*/);
// We did expect the animation to finish
application.SendNotification();
finishCheck.CheckSignalReceived();
- DALI_TEST_EQUALS( actor.GetProperty<Vector2>(index), targetValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector2 >( actor, index ), targetValue, TEST_LOCATION );
// Check that nothing has changed after a couple of buffer swaps
application.Render(0);
- DALI_TEST_EQUALS( actor.GetProperty<Vector2>(index), targetValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector2 >( actor, index ), targetValue, TEST_LOCATION );
application.Render(0);
- DALI_TEST_EQUALS( actor.GetProperty<Vector2>(index), targetValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector2 >( actor, index ), targetValue, TEST_LOCATION );
END_TEST;
}
Property::Index index = actor.RegisterProperty( "testProperty", startValue );
Stage::GetCurrent().Add(actor);
DALI_TEST_EQUALS( actor.GetProperty<Vector2>(index), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector2 >( actor, index ), startValue, TEST_LOCATION );
// Build the animation
float durationSeconds(1.0f);
// We didn't expect the animation to finish yet
application.SendNotification();
finishCheck.CheckSignalNotReceived();
- DALI_TEST_EQUALS( actor.GetProperty<Vector2>(index), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector2 >( actor, index ), startValue, TEST_LOCATION );
application.SendNotification();
application.Render(static_cast<unsigned int>(durationSeconds*250.0f)/* 75% animation progress, 50% animator progress */);
// We didn't expect the animation to finish yet
application.SendNotification();
finishCheck.CheckSignalNotReceived();
- DALI_TEST_EQUALS( actor.GetProperty<Vector2>(index), startValue+(relativeValue*0.5f), TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector2 >( actor, index ), startValue+(relativeValue*0.5f), TEST_LOCATION );
application.SendNotification();
application.Render(static_cast<unsigned int>(durationSeconds*250.0f) + 1u/*just beyond the animation duration*/);
// We did expect the animation to finish
application.SendNotification();
finishCheck.CheckSignalReceived();
- DALI_TEST_EQUALS( actor.GetProperty<Vector2>(index), targetValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector2 >( actor, index ), targetValue, TEST_LOCATION );
// Check that nothing has changed after a couple of buffer swaps
application.Render(0);
- DALI_TEST_EQUALS( actor.GetProperty<Vector2>(index), targetValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector2 >( actor, index ), targetValue, TEST_LOCATION );
application.Render(0);
- DALI_TEST_EQUALS( actor.GetProperty<Vector2>(index), targetValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector2 >( actor, index ), targetValue, TEST_LOCATION );
END_TEST;
}
Property::Index index = actor.RegisterProperty( "testProperty", startValue );
Stage::GetCurrent().Add(actor);
DALI_TEST_EQUALS( actor.GetProperty<Vector3>(index), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector3 >( actor, index ), startValue, TEST_LOCATION );
// Build the animation
float durationSeconds(2.0f);
// We didn't expect the animation to finish yet
application.SendNotification();
finishCheck.CheckSignalNotReceived();
- DALI_TEST_EQUALS( actor.GetProperty<Vector3>(index), ninetyFivePercentProgress, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector3 >( actor, index ), ninetyFivePercentProgress, TEST_LOCATION );
application.SendNotification();
application.Render(static_cast<unsigned int>(durationSeconds*50.0f) + 1u/*just beyond the animation duration*/);
// We did expect the animation to finish
application.SendNotification();
finishCheck.CheckSignalReceived();
- DALI_TEST_EQUALS( actor.GetProperty<Vector3>(index), targetValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector3 >( actor, index ), targetValue, TEST_LOCATION );
// Check that nothing has changed after a couple of buffer swaps
application.Render(0);
- DALI_TEST_EQUALS( actor.GetProperty<Vector3>(index), targetValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector3 >( actor, index ), targetValue, TEST_LOCATION );
application.Render(0);
- DALI_TEST_EQUALS( actor.GetProperty<Vector3>(index), targetValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector3 >( actor, index ), targetValue, TEST_LOCATION );
END_TEST;
}
Property::Index index = actor.RegisterProperty( "testProperty", startValue );
Stage::GetCurrent().Add(actor);
DALI_TEST_EQUALS( actor.GetProperty<Vector3>(index), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector3 >( actor, index ), startValue, TEST_LOCATION );
// Build the animation
float durationSeconds(1.0f);
finishCheck.CheckSignalNotReceived();
// The position should have moved more, than with a linear alpha function
- Vector3 current(actor.GetProperty<Vector3>(index));
+ Vector3 current(DevelHandle::GetCurrentProperty< Vector3 >( actor, index ));
DALI_TEST_CHECK( current.x < ninetyFivePercentProgress.x );
DALI_TEST_CHECK( current.y < ninetyFivePercentProgress.y );
DALI_TEST_CHECK( current.z < ninetyFivePercentProgress.z );
// We did expect the animation to finish
application.SendNotification();
finishCheck.CheckSignalReceived();
- DALI_TEST_EQUALS( actor.GetProperty<Vector3>(index), targetValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector3 >( actor, index ), targetValue, TEST_LOCATION );
// Check that nothing has changed after a couple of buffer swaps
application.Render(0);
- DALI_TEST_EQUALS( actor.GetProperty<Vector3>(index), targetValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector3 >( actor, index ), targetValue, TEST_LOCATION );
application.Render(0);
- DALI_TEST_EQUALS( actor.GetProperty<Vector3>(index), targetValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector3 >( actor, index ), targetValue, TEST_LOCATION );
END_TEST;
}
Property::Index index = actor.RegisterProperty( "testProperty", startValue );
Stage::GetCurrent().Add(actor);
DALI_TEST_EQUALS( actor.GetProperty<Vector3>(index), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector3 >( actor, index ), startValue, TEST_LOCATION );
// Build the animation
float durationSeconds(1.0f);
// We didn't expect the animation to finish yet
application.SendNotification();
finishCheck.CheckSignalNotReceived();
- DALI_TEST_EQUALS( actor.GetProperty<Vector3>(index), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector3 >( actor, index ), startValue, TEST_LOCATION );
application.SendNotification();
application.Render(static_cast<unsigned int>(durationSeconds*250.0f)/* 75% animation progress, 50% animator progress */);
// We didn't expect the animation to finish yet
application.SendNotification();
finishCheck.CheckSignalNotReceived();
- DALI_TEST_EQUALS( actor.GetProperty<Vector3>(index), startValue+(relativeValue*0.5f), TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector3 >( actor, index ), startValue+(relativeValue*0.5f), TEST_LOCATION );
application.SendNotification();
application.Render(static_cast<unsigned int>(durationSeconds*250.0f) + 1u/*just beyond the animation duration*/);
// We did expect the animation to finish
application.SendNotification();
finishCheck.CheckSignalReceived();
- DALI_TEST_EQUALS( actor.GetProperty<Vector3>(index), targetValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector3 >( actor, index ), targetValue, TEST_LOCATION );
// Check that nothing has changed after a couple of buffer swaps
application.Render(0);
- DALI_TEST_EQUALS( actor.GetProperty<Vector3>(index), targetValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector3 >( actor, index ), targetValue, TEST_LOCATION );
application.Render(0);
- DALI_TEST_EQUALS( actor.GetProperty<Vector3>(index), targetValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector3 >( actor, index ), targetValue, TEST_LOCATION );
END_TEST;
}
Property::Index index = actor.RegisterProperty( "testProperty", startValue );
Stage::GetCurrent().Add(actor);
DALI_TEST_EQUALS( actor.GetProperty<Vector3>(index), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector3 >( actor, index ), startValue, TEST_LOCATION );
// Build the animation
float durationSeconds(1.0f);
// We didn't expect the animation to finish yet
application.SendNotification();
finishCheck.CheckSignalNotReceived();
- DALI_TEST_EQUALS( actor.GetProperty<Vector3>(index), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector3 >( actor, index ), startValue, TEST_LOCATION );
application.SendNotification();
application.Render(static_cast<unsigned int>(durationSeconds*250.0f)/* 75% animation progress, 50% animator progress */);
// We didn't expect the animation to finish yet
application.SendNotification();
finishCheck.CheckSignalNotReceived();
- DALI_TEST_EQUALS( actor.GetProperty<Vector3>(index), startValue+(relativeValue*0.5f), TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector3 >( actor, index ), startValue+(relativeValue*0.5f), TEST_LOCATION );
application.SendNotification();
application.Render(static_cast<unsigned int>(durationSeconds*250.0f) + 1u/*just beyond the animation duration*/);
// We did expect the animation to finish
application.SendNotification();
finishCheck.CheckSignalReceived();
- DALI_TEST_EQUALS( actor.GetProperty<Vector3>(index), targetValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector3 >( actor, index ), targetValue, TEST_LOCATION );
// Check that nothing has changed after a couple of buffer swaps
application.Render(0);
- DALI_TEST_EQUALS( actor.GetProperty<Vector3>(index), targetValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector3 >( actor, index ), targetValue, TEST_LOCATION );
application.Render(0);
- DALI_TEST_EQUALS( actor.GetProperty<Vector3>(index), targetValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector3 >( actor, index ), targetValue, TEST_LOCATION );
END_TEST;
}
Property::Index index = actor.RegisterProperty( "testProperty", startValue );
Stage::GetCurrent().Add(actor);
DALI_TEST_EQUALS( actor.GetProperty<Vector4>(index), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector4 >( actor, index ), startValue, TEST_LOCATION );
// Build the animation
float durationSeconds(2.0f);
// We didn't expect the animation to finish yet
application.SendNotification();
finishCheck.CheckSignalNotReceived();
- DALI_TEST_EQUALS( actor.GetProperty<Vector4>(index), ninetyFivePercentProgress, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector4 >( actor, index ), ninetyFivePercentProgress, TEST_LOCATION );
application.SendNotification();
application.Render(static_cast<unsigned int>(durationSeconds*50.0f) + 1u/*just beyond the animation duration*/);
// We did expect the animation to finish
application.SendNotification();
finishCheck.CheckSignalReceived();
- DALI_TEST_EQUALS( actor.GetProperty<Vector4>(index), targetValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector4 >( actor, index ), targetValue, TEST_LOCATION );
// Check that nothing has changed after a couple of buffer swaps
application.Render(0);
- DALI_TEST_EQUALS( actor.GetProperty<Vector4>(index), targetValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector4 >( actor, index ), targetValue, TEST_LOCATION );
application.Render(0);
- DALI_TEST_EQUALS( actor.GetProperty<Vector4>(index), targetValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector4 >( actor, index ), targetValue, TEST_LOCATION );
END_TEST;
}
Property::Index index = actor.RegisterProperty( "testProperty", startValue );
Stage::GetCurrent().Add(actor);
DALI_TEST_EQUALS( actor.GetProperty<Vector4>(index), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector4 >( actor, index ), startValue, TEST_LOCATION );
// Build the animation
float durationSeconds(1.0f);
finishCheck.CheckSignalNotReceived();
// The position should have moved more, than with a linear alpha function
- Vector4 current(actor.GetProperty<Vector4>(index));
+ Vector4 current( DevelHandle::GetCurrentProperty< Vector4 >( actor, index ) );
DALI_TEST_CHECK( current.x < ninetyFivePercentProgress.x );
DALI_TEST_CHECK( current.y < ninetyFivePercentProgress.y );
DALI_TEST_CHECK( current.z < ninetyFivePercentProgress.z );
// We did expect the animation to finish
application.SendNotification();
finishCheck.CheckSignalReceived();
- DALI_TEST_EQUALS( actor.GetProperty<Vector4>(index), targetValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector4 >( actor, index ), targetValue, TEST_LOCATION );
// Check that nothing has changed after a couple of buffer swaps
application.Render(0);
- DALI_TEST_EQUALS( actor.GetProperty<Vector4>(index), targetValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector4 >( actor, index ), targetValue, TEST_LOCATION );
application.Render(0);
- DALI_TEST_EQUALS( actor.GetProperty<Vector4>(index), targetValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector4 >( actor, index ), targetValue, TEST_LOCATION );
END_TEST;
}
Property::Index index = actor.RegisterProperty( "testProperty", startValue );
Stage::GetCurrent().Add(actor);
DALI_TEST_EQUALS( actor.GetProperty<Vector4>(index), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector4 >( actor, index ), startValue, TEST_LOCATION );
// Build the animation
float durationSeconds(1.0f);
// We didn't expect the animation to finish yet
application.SendNotification();
finishCheck.CheckSignalNotReceived();
- DALI_TEST_EQUALS( actor.GetProperty<Vector4>(index), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector4 >( actor, index ), startValue, TEST_LOCATION );
application.SendNotification();
application.Render(static_cast<unsigned int>(durationSeconds*250.0f)/* 75% animation progress, 50% animator progress */);
// We didn't expect the animation to finish yet
application.SendNotification();
finishCheck.CheckSignalNotReceived();
- DALI_TEST_EQUALS( actor.GetProperty<Vector4>(index), startValue+(relativeValue*0.5f), TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector4 >( actor, index ), startValue+(relativeValue*0.5f), TEST_LOCATION );
application.SendNotification();
application.Render(static_cast<unsigned int>(durationSeconds*250.0f) + 1u/*just beyond the animation duration*/);
// We did expect the animation to finish
application.SendNotification();
finishCheck.CheckSignalReceived();
- DALI_TEST_EQUALS( actor.GetProperty<Vector4>(index), targetValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector4 >( actor, index ), targetValue, TEST_LOCATION );
// Check that nothing has changed after a couple of buffer swaps
application.Render(0);
- DALI_TEST_EQUALS( actor.GetProperty<Vector4>(index), targetValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector4 >( actor, index ), targetValue, TEST_LOCATION );
application.Render(0);
- DALI_TEST_EQUALS( actor.GetProperty<Vector4>(index), targetValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector4 >( actor, index ), targetValue, TEST_LOCATION );
END_TEST;
}
Property::Index index = actor.RegisterProperty( "testProperty", startValue );
Stage::GetCurrent().Add(actor);
DALI_TEST_EQUALS( actor.GetProperty<Vector4>(index), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector4 >( actor, index ), startValue, TEST_LOCATION );
// Build the animation
float durationSeconds(1.0f);
// We didn't expect the animation to finish yet
application.SendNotification();
finishCheck.CheckSignalNotReceived();
- DALI_TEST_EQUALS( actor.GetProperty<Vector4>(index), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector4 >( actor, index ), startValue, TEST_LOCATION );
application.SendNotification();
application.Render(static_cast<unsigned int>(durationSeconds*250.0f)/* 75% animation progress, 50% animator progress */);
// We didn't expect the animation to finish yet
application.SendNotification();
finishCheck.CheckSignalNotReceived();
- DALI_TEST_EQUALS( actor.GetProperty<Vector4>(index), startValue+(relativeValue*0.5f), TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector4 >( actor, index ), startValue+(relativeValue*0.5f), TEST_LOCATION );
application.SendNotification();
application.Render(static_cast<unsigned int>(durationSeconds*250.0f) + 1u/*just beyond the animation duration*/);
// We did expect the animation to finish
application.SendNotification();
finishCheck.CheckSignalReceived();
- DALI_TEST_EQUALS( actor.GetProperty<Vector4>(index), targetValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector4 >( actor, index ), targetValue, TEST_LOCATION );
// Check that nothing has changed after a couple of buffer swaps
application.Render(0);
- DALI_TEST_EQUALS( actor.GetProperty<Vector4>(index), targetValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector4 >( actor, index ), targetValue, TEST_LOCATION );
application.Render(0);
- DALI_TEST_EQUALS( actor.GetProperty<Vector4>(index), targetValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector4 >( actor, index ), targetValue, TEST_LOCATION );
END_TEST;
}
END_TEST;
}
-int UtcDaliAnimationAnimateByActorOrientationP(void)
+int UtcDaliAnimationAnimateByActorOrientationP1(void)
{
TestApplication application;
END_TEST;
}
+int UtcDaliAnimationAnimateByActorOrientationP2(void)
+{
+ TestApplication application;
+
+ tet_printf("Testing that rotation angle > 360 performs full rotations\n");
+
+ Actor actor = Actor::New();
+ actor.SetOrientation( Quaternion( Dali::ANGLE_0, Vector3::ZAXIS ) );
+ Stage::GetCurrent().Add(actor);
+ DALI_TEST_EQUALS( actor.GetCurrentOrientation(), Quaternion( Dali::ANGLE_0, Vector3::ZAXIS ), ROTATION_EPSILON, TEST_LOCATION );
+
+ // Build the animation
+ float durationSeconds(1.0f);
+ Animation animation = Animation::New(durationSeconds);
+ Degree relativeRotationDegrees(710.0f);
+ Radian relativeRotationRadians(relativeRotationDegrees);
+
+ animation.AnimateBy( Property( actor, Actor::Property::ORIENTATION ), AngleAxis( relativeRotationRadians, Vector3::ZAXIS ) );
+
+ // Start the animation
+ animation.Play();
+
+ bool signalReceived(false);
+ AnimationFinishCheck finishCheck(signalReceived);
+ animation.FinishedSignal().Connect(&application, finishCheck);
+
+ application.SendNotification();
+ application.Render(static_cast<unsigned int>(durationSeconds*250.0f)/* 25% progress */);
+
+ // We didn't expect the animation to finish yet
+ application.SendNotification();
+ finishCheck.CheckSignalNotReceived();
+ DALI_TEST_EQUALS( actor.GetCurrentOrientation(), Quaternion(relativeRotationRadians * 0.25f, Vector3::ZAXIS), ROTATION_EPSILON, TEST_LOCATION );
+
+ application.SendNotification();
+ application.Render(static_cast<unsigned int>(durationSeconds*250.0f)/* 50% progress */);
+
+ // We didn't expect the animation to finish yet
+ application.SendNotification();
+ finishCheck.CheckSignalNotReceived();
+ DALI_TEST_EQUALS( actor.GetCurrentOrientation(), Quaternion(relativeRotationRadians * 0.5f, Vector3::ZAXIS), ROTATION_EPSILON, TEST_LOCATION );
+
+ application.SendNotification();
+ application.Render(static_cast<unsigned int>(durationSeconds*250.0f)/* 75% progress */);
+
+ // We didn't expect the animation to finish yet
+ application.SendNotification();
+ finishCheck.CheckSignalNotReceived();
+ DALI_TEST_EQUALS( actor.GetCurrentOrientation(), Quaternion(relativeRotationRadians * 0.75f, Vector3::ZAXIS), ROTATION_EPSILON, TEST_LOCATION );
+
+ application.SendNotification();
+ application.Render(static_cast<unsigned int>(durationSeconds*250.0f) + 1u/*just beyond the animation duration*/);
+
+ // We did expect the animation to finish
+ application.SendNotification();
+ finishCheck.CheckSignalReceived();
+ DALI_TEST_EQUALS( actor.GetCurrentOrientation(), Quaternion(relativeRotationRadians, Vector3::ZAXIS), ROTATION_EPSILON, TEST_LOCATION );
+ END_TEST;
+}
+
+
+int UtcDaliAnimationAnimateByActorOrientationP3(void)
+{
+ TestApplication application;
+
+ tet_printf("Testing that rotation angle > 360 performs partial rotations when cast to Quaternion\n");
+
+ Actor actor = Actor::New();
+ actor.SetOrientation( Quaternion( Dali::ANGLE_0, Vector3::ZAXIS ) );
+ Stage::GetCurrent().Add(actor);
+ DALI_TEST_EQUALS( actor.GetCurrentOrientation(), Quaternion( Dali::ANGLE_0, Vector3::ZAXIS ), ROTATION_EPSILON, TEST_LOCATION );
+
+ // Build the animation
+ float durationSeconds(1.0f);
+ Animation animation = Animation::New(durationSeconds);
+ Degree relativeRotationDegrees(730.0f);
+ Radian relativeRotationRadians(relativeRotationDegrees);
+
+ Radian actualRotationRadians( Degree(10.0f) );
+
+ animation.AnimateBy( Property( actor, Actor::Property::ORIENTATION ), Quaternion( relativeRotationRadians, Vector3::ZAXIS ) );
+
+ // Start the animation
+ animation.Play();
+
+ bool signalReceived(false);
+ AnimationFinishCheck finishCheck(signalReceived);
+ animation.FinishedSignal().Connect(&application, finishCheck);
+
+ application.SendNotification();
+ application.Render(static_cast<unsigned int>(durationSeconds*250.0f)/* 25% progress */);
+
+ // We didn't expect the animation to finish yet
+ application.SendNotification();
+ finishCheck.CheckSignalNotReceived();
+ DALI_TEST_EQUALS( actor.GetCurrentOrientation(), Quaternion(actualRotationRadians * 0.25f, Vector3::ZAXIS), ROTATION_EPSILON, TEST_LOCATION );
+
+ application.SendNotification();
+ application.Render(static_cast<unsigned int>(durationSeconds*250.0f)/* 50% progress */);
+
+ // We didn't expect the animation to finish yet
+ application.SendNotification();
+ finishCheck.CheckSignalNotReceived();
+ DALI_TEST_EQUALS( actor.GetCurrentOrientation(), Quaternion(actualRotationRadians * 0.5f, Vector3::ZAXIS), ROTATION_EPSILON, TEST_LOCATION );
+
+ application.SendNotification();
+ application.Render(static_cast<unsigned int>(durationSeconds*250.0f)/* 75% progress */);
+
+ // We didn't expect the animation to finish yet
+ application.SendNotification();
+ finishCheck.CheckSignalNotReceived();
+ DALI_TEST_EQUALS( actor.GetCurrentOrientation(), Quaternion(actualRotationRadians * 0.75f, Vector3::ZAXIS), ROTATION_EPSILON, TEST_LOCATION );
+
+ application.SendNotification();
+ application.Render(static_cast<unsigned int>(durationSeconds*250.0f) + 1u/*just beyond the animation duration*/);
+
+ // We did expect the animation to finish
+ application.SendNotification();
+ finishCheck.CheckSignalReceived();
+ DALI_TEST_EQUALS( actor.GetCurrentOrientation(), Quaternion(actualRotationRadians, Vector3::ZAXIS), ROTATION_EPSILON, TEST_LOCATION );
+ DALI_TEST_EQUALS( actor.GetCurrentOrientation(), Quaternion(relativeRotationRadians, Vector3::ZAXIS), ROTATION_EPSILON, TEST_LOCATION );
+ END_TEST;
+}
+
+
int UtcDaliAnimationAnimateByActorOrientationAlphaFunctionP(void)
{
TestApplication application;
Property::Index index = actor.RegisterProperty( "testProperty", startValue );
Stage::GetCurrent().Add(actor);
DALI_TEST_CHECK( actor.GetProperty<bool>(index) == startValue );
+ DALI_TEST_CHECK( DevelHandle::GetCurrentProperty< bool >( actor, index ) == startValue );
// Build the animation
float durationSeconds(2.0f);
// We didn't expect the animation to finish yet
application.SendNotification();
finishCheck.CheckSignalNotReceived();
- DALI_TEST_CHECK( actor.GetProperty<bool>(index) == startValue );
+ DALI_TEST_CHECK( DevelHandle::GetCurrentProperty< bool >( actor, index ) == startValue );
application.SendNotification();
application.Render(static_cast<unsigned int>(durationSeconds*50.0f) + 1u/*just beyond the animation duration*/);
// We did expect the animation to finish
application.SendNotification();
finishCheck.CheckSignalReceived();
- DALI_TEST_CHECK( actor.GetProperty<bool>(index) == targetValue );
+ DALI_TEST_CHECK( DevelHandle::GetCurrentProperty< bool >( actor, index ) == targetValue );
// Check that nothing has changed after a couple of buffer swaps
application.Render(0);
- DALI_TEST_CHECK( actor.GetProperty<bool>(index) == targetValue );
+ DALI_TEST_CHECK( DevelHandle::GetCurrentProperty< bool >( actor, index ) == targetValue );
application.Render(0);
- DALI_TEST_CHECK( actor.GetProperty<bool>(index) == targetValue );
+ DALI_TEST_CHECK( DevelHandle::GetCurrentProperty< bool >( actor, index ) == targetValue );
// Repeat with target value "false"
animation = Animation::New(durationSeconds);
// We didn't expect the animation to finish yet
application.SendNotification();
finishCheck.CheckSignalNotReceived();
- DALI_TEST_CHECK( actor.GetProperty<bool>(index) == targetValue );
+ DALI_TEST_CHECK( DevelHandle::GetCurrentProperty< bool >( actor, index ) == targetValue );
application.SendNotification();
application.Render(static_cast<unsigned int>(durationSeconds*50.0f) + 1u/*just beyond the animation duration*/);
// We did expect the animation to finish
application.SendNotification();
finishCheck.CheckSignalReceived();
- DALI_TEST_CHECK( actor.GetProperty<bool>(index) == finalValue );
+ DALI_TEST_CHECK( DevelHandle::GetCurrentProperty< bool >( actor, index ) == finalValue );
// Check that nothing has changed after a couple of buffer swaps
application.Render(0);
- DALI_TEST_CHECK( actor.GetProperty<bool>(index) == finalValue );
+ DALI_TEST_CHECK( DevelHandle::GetCurrentProperty< bool >( actor, index ) == finalValue );
application.Render(0);
- DALI_TEST_CHECK( actor.GetProperty<bool>(index) == finalValue );
+ DALI_TEST_CHECK( DevelHandle::GetCurrentProperty< bool >( actor, index ) == finalValue );
END_TEST;
}
Property::Index index = actor.RegisterProperty( "testProperty", startValue );
Stage::GetCurrent().Add(actor);
DALI_TEST_CHECK( actor.GetProperty<bool>(index) == startValue );
+ DALI_TEST_CHECK( DevelHandle::GetCurrentProperty< bool >( actor, index ) == startValue );
// Build the animation
float durationSeconds(2.0f);
// We didn't expect the animation to finish yet
application.SendNotification();
finishCheck.CheckSignalNotReceived();
- DALI_TEST_CHECK( actor.GetProperty<bool>(index) == startValue );
+ DALI_TEST_CHECK( DevelHandle::GetCurrentProperty< bool >( actor, index ) == startValue );
application.SendNotification();
application.Render(static_cast<unsigned int>(durationSeconds*50.0f) + 1u/*just beyond the animation duration*/);
// We did expect the animation to finish
application.SendNotification();
finishCheck.CheckSignalReceived();
- DALI_TEST_CHECK( actor.GetProperty<bool>(index) == targetValue );
+ DALI_TEST_CHECK( DevelHandle::GetCurrentProperty< bool >( actor, index ) == targetValue );
// Check that nothing has changed after a couple of buffer swaps
application.Render(0);
- DALI_TEST_CHECK( actor.GetProperty<bool>(index) == targetValue );
+ DALI_TEST_CHECK( DevelHandle::GetCurrentProperty< bool >( actor, index ) == targetValue );
application.Render(0);
- DALI_TEST_CHECK( actor.GetProperty<bool>(index) == targetValue );
+ DALI_TEST_CHECK( DevelHandle::GetCurrentProperty< bool >( actor, index ) == targetValue );
// Repeat with target value "false"
animation = Animation::New(durationSeconds);
// We didn't expect the animation to finish yet
application.SendNotification();
finishCheck.CheckSignalNotReceived();
- DALI_TEST_CHECK( actor.GetProperty<bool>(index) == targetValue );
+ DALI_TEST_CHECK( DevelHandle::GetCurrentProperty< bool >( actor, index ) == targetValue );
application.SendNotification();
application.Render(static_cast<unsigned int>(durationSeconds*50.0f) + 1u/*just beyond the animation duration*/);
// We did expect the animation to finish
application.SendNotification();
finishCheck.CheckSignalReceived();
- DALI_TEST_CHECK( actor.GetProperty<bool>(index) == finalValue );
+ DALI_TEST_CHECK( DevelHandle::GetCurrentProperty< bool >( actor, index ) == finalValue );
// Check that nothing has changed after a couple of buffer swaps
application.Render(0);
- DALI_TEST_CHECK( actor.GetProperty<bool>(index) == finalValue );
+ DALI_TEST_CHECK( DevelHandle::GetCurrentProperty< bool >( actor, index ) == finalValue );
application.Render(0);
- DALI_TEST_CHECK( actor.GetProperty<bool>(index) == finalValue );
+ DALI_TEST_CHECK( DevelHandle::GetCurrentProperty< bool >( actor, index ) == finalValue );
END_TEST;
}
Property::Index index = actor.RegisterProperty( "testProperty", startValue );
Stage::GetCurrent().Add(actor);
DALI_TEST_CHECK( actor.GetProperty<bool>(index) == startValue );
+ DALI_TEST_CHECK( DevelHandle::GetCurrentProperty< bool >( actor, index ) == startValue );
// Build the animation
float durationSeconds(2.0f);
// We didn't expect the animation to finish yet
application.SendNotification();
finishCheck.CheckSignalNotReceived();
- DALI_TEST_CHECK( actor.GetProperty<bool>(index) == startValue );
+ DALI_TEST_CHECK( DevelHandle::GetCurrentProperty< bool >( actor, index ) == startValue );
application.SendNotification();
application.Render(static_cast<unsigned int>(animatorDurationSeconds*50.0f) + 1u/*just beyond the animator duration*/);
finishCheck.CheckSignalNotReceived();
// ...however we should have reached the final value
- DALI_TEST_CHECK( actor.GetProperty<bool>(index) == finalValue );
+ DALI_TEST_CHECK( DevelHandle::GetCurrentProperty< bool >( actor, index ) == finalValue );
application.SendNotification();
application.Render(static_cast<unsigned int>(animatorDurationSeconds*1000.0f)/*just beyond the animation duration*/);
// We did expect the animation to finish
application.SendNotification();
finishCheck.CheckSignalReceived();
- DALI_TEST_CHECK( actor.GetProperty<bool>(index) == finalValue );
+ DALI_TEST_CHECK( DevelHandle::GetCurrentProperty< bool >( actor, index ) == finalValue );
// Check that nothing has changed after a couple of buffer swaps
application.Render(0);
- DALI_TEST_CHECK( actor.GetProperty<bool>(index) == finalValue );
+ DALI_TEST_CHECK( DevelHandle::GetCurrentProperty< bool >( actor, index ) == finalValue );
application.Render(0);
- DALI_TEST_CHECK( actor.GetProperty<bool>(index) == finalValue );
+ DALI_TEST_CHECK( DevelHandle::GetCurrentProperty< bool >( actor, index ) == finalValue );
END_TEST;
}
Property::Index index = actor.RegisterProperty( "testProperty", startValue );
Stage::GetCurrent().Add(actor);
DALI_TEST_CHECK( actor.GetProperty<bool>(index) == startValue );
+ DALI_TEST_CHECK( DevelHandle::GetCurrentProperty< bool >( actor, index ) == startValue );
// Build the animation
float durationSeconds(2.0f);
// We didn't expect the animation to finish yet
application.SendNotification();
finishCheck.CheckSignalNotReceived();
- DALI_TEST_CHECK( actor.GetProperty<bool>(index) == startValue );
+ DALI_TEST_CHECK( DevelHandle::GetCurrentProperty< bool >( actor, index ) == startValue );
application.SendNotification();
application.Render(static_cast<unsigned int>(animatorDurationSeconds*50.0f) + 1u/*just beyond the animator duration*/);
finishCheck.CheckSignalNotReceived();
// ...however we should have reached the final value
- DALI_TEST_CHECK( actor.GetProperty<bool>(index) == finalValue );
+ DALI_TEST_CHECK( DevelHandle::GetCurrentProperty< bool >( actor, index ) == finalValue );
application.SendNotification();
application.Render(static_cast<unsigned int>(animatorDurationSeconds*1000.0f)/*just beyond the animation duration*/);
// We did expect the animation to finish
application.SendNotification();
finishCheck.CheckSignalReceived();
- DALI_TEST_CHECK( actor.GetProperty<bool>(index) == finalValue );
+ DALI_TEST_CHECK( DevelHandle::GetCurrentProperty< bool >( actor, index ) == finalValue );
// Check that nothing has changed after a couple of buffer swaps
application.Render(0);
- DALI_TEST_CHECK( actor.GetProperty<bool>(index) == finalValue );
+ DALI_TEST_CHECK( DevelHandle::GetCurrentProperty< bool >( actor, index ) == finalValue );
application.Render(0);
- DALI_TEST_CHECK( actor.GetProperty<bool>(index) == finalValue );
+ DALI_TEST_CHECK( DevelHandle::GetCurrentProperty< bool >( actor, index ) == finalValue );
END_TEST;
}
Property::Index index = actor.RegisterProperty( "testProperty", startValue );
Stage::GetCurrent().Add(actor);
DALI_TEST_EQUALS( actor.GetProperty<float>(index), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, index ), startValue, TEST_LOCATION );
// Build the animation
float durationSeconds(2.0f);
// We didn't expect the animation to finish yet
application.SendNotification();
finishCheck.CheckSignalNotReceived();
- DALI_TEST_EQUALS( actor.GetProperty<float>(index), ninetyFivePercentProgress, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, index ), ninetyFivePercentProgress, TEST_LOCATION );
application.SendNotification();
application.Render(static_cast<unsigned int>(durationSeconds*50.0f) + 1u/*just beyond the animation duration*/);
// We did expect the animation to finish
application.SendNotification();
finishCheck.CheckSignalReceived();
- DALI_TEST_EQUALS( actor.GetProperty<float>(index), targetValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, index ), targetValue, TEST_LOCATION );
END_TEST;
}
Property::Index index = actor.RegisterProperty( "testProperty", startValue );
Stage::GetCurrent().Add(actor);
DALI_TEST_EQUALS( actor.GetProperty<float>(index), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, index ), startValue, TEST_LOCATION );
// Build the animation
float durationSeconds(1.0f);
finishCheck.CheckSignalNotReceived();
// The position should have moved more, than with a linear alpha function
- float current(actor.GetProperty<float>(index));
+ float current( DevelHandle::GetCurrentProperty< float >( actor, index ) );
DALI_TEST_CHECK( current > ninetyFivePercentProgress );
application.SendNotification();
// We did expect the animation to finish
application.SendNotification();
finishCheck.CheckSignalReceived();
- DALI_TEST_EQUALS( actor.GetProperty<float>(index), targetValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, index ), targetValue, TEST_LOCATION );
END_TEST;
}
Property::Index index = actor.RegisterProperty( "testProperty", startValue );
Stage::GetCurrent().Add(actor);
DALI_TEST_EQUALS( actor.GetProperty<float>(index), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, index ), startValue, TEST_LOCATION );
// Build the animation
float durationSeconds(1.0f);
// We didn't expect the animation to finish yet
application.SendNotification();
finishCheck.CheckSignalNotReceived();
- DALI_TEST_EQUALS( actor.GetProperty<float>(index), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, index ), startValue, TEST_LOCATION );
application.SendNotification();
application.Render(static_cast<unsigned int>(durationSeconds*250.0f)/* 75% animation progress, 50% animator progress */);
// We didn't expect the animation to finish yet
application.SendNotification();
finishCheck.CheckSignalNotReceived();
- DALI_TEST_EQUALS( actor.GetProperty<float>(index), startValue+(relativeValue*0.5f), TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, index ), startValue+(relativeValue*0.5f), TEST_LOCATION );
application.SendNotification();
application.Render(static_cast<unsigned int>(durationSeconds*250.0f) + 1u/*just beyond the animation duration*/);
// We did expect the animation to finish
application.SendNotification();
finishCheck.CheckSignalReceived();
- DALI_TEST_EQUALS( actor.GetProperty<float>(index), targetValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, index ), targetValue, TEST_LOCATION );
END_TEST;
}
Property::Index index = actor.RegisterProperty( "testProperty", startValue );
Stage::GetCurrent().Add(actor);
DALI_TEST_EQUALS( actor.GetProperty<float>(index), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, index ), startValue, TEST_LOCATION );
// Build the animation
float durationSeconds(1.0f);
// We didn't expect the animation to finish yet
application.SendNotification();
finishCheck.CheckSignalNotReceived();
- DALI_TEST_EQUALS( actor.GetProperty<float>(index), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, index ), startValue, TEST_LOCATION );
application.SendNotification();
application.Render(static_cast<unsigned int>(durationSeconds*250.0f)/* 75% animation progress, 50% animator progress */);
// We didn't expect the animation to finish yet
application.SendNotification();
finishCheck.CheckSignalNotReceived();
- DALI_TEST_EQUALS( actor.GetProperty<float>(index), startValue+(relativeValue*0.5f), TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, index ), startValue+(relativeValue*0.5f), TEST_LOCATION );
application.SendNotification();
application.Render(static_cast<unsigned int>(durationSeconds*250.0f) + 1u/*just beyond the animation duration*/);
// We did expect the animation to finish
application.SendNotification();
finishCheck.CheckSignalReceived();
- DALI_TEST_EQUALS( actor.GetProperty<float>(index), targetValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, index ), targetValue, TEST_LOCATION );
END_TEST;
}
Property::Index index = actor.RegisterProperty( "testProperty", startValue );
Stage::GetCurrent().Add(actor);
DALI_TEST_EQUALS( actor.GetProperty<int>(index), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< int >( actor, index ), startValue, TEST_LOCATION );
// Build the animation
float durationSeconds(2.0f);
// We didn't expect the animation to finish yet
application.SendNotification();
finishCheck.CheckSignalNotReceived();
- DALI_TEST_EQUALS( actor.GetProperty<int>(index), ninetyFivePercentProgress, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< int >( actor, index ), ninetyFivePercentProgress, TEST_LOCATION );
application.SendNotification();
application.Render(static_cast<unsigned int>(durationSeconds*50.0f) + 1u/*just beyond the animation duration*/);
// We did expect the animation to finish
application.SendNotification();
finishCheck.CheckSignalReceived();
- DALI_TEST_EQUALS( actor.GetProperty<int>(index), targetValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< int >( actor, index ), targetValue, TEST_LOCATION );
END_TEST;
}
Property::Index index = actor.RegisterProperty( "testProperty", startValue );
Stage::GetCurrent().Add(actor);
DALI_TEST_EQUALS( actor.GetProperty<int>(index), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< int >( actor, index ), startValue, TEST_LOCATION );
// Build the animation
float durationSeconds(1.0f);
finishCheck.CheckSignalNotReceived();
// The position should have moved more, than with a linear alpha function
- int current(actor.GetProperty<int>(index));
+ int current( DevelHandle::GetCurrentProperty< int >( actor, index ) );
DALI_TEST_CHECK( current > ninetyFivePercentProgress );
application.SendNotification();
// We did expect the animation to finish
application.SendNotification();
finishCheck.CheckSignalReceived();
- DALI_TEST_EQUALS( actor.GetProperty<int>(index), targetValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< int >( actor, index ), targetValue, TEST_LOCATION );
END_TEST;
}
Property::Index index = actor.RegisterProperty( "testProperty", startValue );
Stage::GetCurrent().Add(actor);
DALI_TEST_EQUALS( actor.GetProperty<int>(index), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< int >( actor, index ), startValue, TEST_LOCATION );
// Build the animation
float durationSeconds(1.0f);
// We didn't expect the animation to finish yet
application.SendNotification();
finishCheck.CheckSignalNotReceived();
- DALI_TEST_EQUALS( actor.GetProperty<int>(index), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< int >( actor, index ), startValue, TEST_LOCATION );
application.SendNotification();
application.Render(static_cast<unsigned int>(durationSeconds*250.0f)/* 75% animation progress, 50% animator progress */);
// We didn't expect the animation to finish yet
application.SendNotification();
finishCheck.CheckSignalNotReceived();
- DALI_TEST_EQUALS( actor.GetProperty<int>(index), static_cast<int>(startValue+(relativeValue*0.5f)+0.5f), TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< int >( actor, index ), static_cast<int>(startValue+(relativeValue*0.5f)+0.5f), TEST_LOCATION );
application.SendNotification();
application.Render(static_cast<unsigned int>(durationSeconds*250.0f) + 1u/*just beyond the animation duration*/);
// We did expect the animation to finish
application.SendNotification();
finishCheck.CheckSignalReceived();
- DALI_TEST_EQUALS( actor.GetProperty<int>(index), targetValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< int >( actor, index ), targetValue, TEST_LOCATION );
END_TEST;
}
Property::Index index = actor.RegisterProperty( "testProperty", startValue );
Stage::GetCurrent().Add(actor);
DALI_TEST_EQUALS( actor.GetProperty<int>(index), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< int >( actor, index ), startValue, TEST_LOCATION );
// Build the animation
float durationSeconds(1.0f);
// We didn't expect the animation to finish yet
application.SendNotification();
finishCheck.CheckSignalNotReceived();
- DALI_TEST_EQUALS( actor.GetProperty<int>(index), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< int >( actor, index ), startValue, TEST_LOCATION );
application.SendNotification();
application.Render(static_cast<unsigned int>(durationSeconds*250.0f)/* 75% animation progress, 50% animator progress */);
// We didn't expect the animation to finish yet
application.SendNotification();
finishCheck.CheckSignalNotReceived();
- DALI_TEST_EQUALS( actor.GetProperty<int>(index), static_cast<int>(startValue+(relativeValue*0.5f)+0.5f), TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< int >( actor, index ), static_cast<int>(startValue+(relativeValue*0.5f)+0.5f), TEST_LOCATION );
application.SendNotification();
application.Render(static_cast<unsigned int>(durationSeconds*250.0f) + 1u/*just beyond the animation duration*/);
// We did expect the animation to finish
application.SendNotification();
finishCheck.CheckSignalReceived();
- DALI_TEST_EQUALS( actor.GetProperty<int>(index), targetValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< int >( actor, index ), targetValue, TEST_LOCATION );
END_TEST;
}
Vector2 startValue(-50.0f, -50.0f);
Property::Index index = actor.RegisterProperty( "testProperty", startValue );
Stage::GetCurrent().Add(actor);
- DALI_TEST_EQUALS( actor.GetProperty<Vector2>(index), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( actor.GetProperty< Vector2 >( index ), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector2 >( actor, index ), startValue, TEST_LOCATION );
// Build the animation
float durationSeconds(2.0f);
// We didn't expect the animation to finish yet
application.SendNotification();
finishCheck.CheckSignalNotReceived();
- DALI_TEST_EQUALS( actor.GetProperty<Vector2>(index), ninetyFivePercentProgress, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector2 >( actor, index ), ninetyFivePercentProgress, TEST_LOCATION );
application.SendNotification();
application.Render(static_cast<unsigned int>(durationSeconds*50.0f) + 1u/*just beyond the animation duration*/);
// We did expect the animation to finish
application.SendNotification();
finishCheck.CheckSignalReceived();
- DALI_TEST_EQUALS( actor.GetProperty<Vector2>(index), targetValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector2 >( actor, index ), targetValue, TEST_LOCATION );
END_TEST;
}
Vector2 startValue(1000.0f, 1000.0f);
Property::Index index = actor.RegisterProperty( "testProperty", startValue );
Stage::GetCurrent().Add(actor);
- DALI_TEST_EQUALS( actor.GetProperty<Vector2>(index), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( actor.GetProperty< Vector2 >( index ), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector2 >( actor, index ), startValue, TEST_LOCATION );
// Build the animation
float durationSeconds(1.0f);
finishCheck.CheckSignalNotReceived();
// The position should have moved more, than with a linear alpha function
- Vector2 current(actor.GetProperty<Vector2>(index));
+ Vector2 current( DevelHandle::GetCurrentProperty< Vector2 >( actor, index ) );
DALI_TEST_CHECK( current.x > ninetyFivePercentProgress.x );
DALI_TEST_CHECK( current.y > ninetyFivePercentProgress.y );
// We did expect the animation to finish
application.SendNotification();
finishCheck.CheckSignalReceived();
- DALI_TEST_EQUALS( actor.GetProperty<Vector2>(index), targetValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector2 >( actor, index ), targetValue, TEST_LOCATION );
END_TEST;
}
Vector2 startValue(10.0f, 10.0f);
Property::Index index = actor.RegisterProperty( "testProperty", startValue );
Stage::GetCurrent().Add(actor);
- DALI_TEST_EQUALS( actor.GetProperty<Vector2>(index), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( actor.GetProperty< Vector2 >( index ), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector2 >( actor, index ), startValue, TEST_LOCATION );
// Build the animation
float durationSeconds(1.0f);
// We didn't expect the animation to finish yet
application.SendNotification();
finishCheck.CheckSignalNotReceived();
- DALI_TEST_EQUALS( actor.GetProperty<Vector2>(index), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector2 >( actor, index ), startValue, TEST_LOCATION );
application.SendNotification();
application.Render(static_cast<unsigned int>(durationSeconds*250.0f)/* 75% animation progress, 50% animator progress */);
// We didn't expect the animation to finish yet
application.SendNotification();
finishCheck.CheckSignalNotReceived();
- DALI_TEST_EQUALS( actor.GetProperty<Vector2>(index), startValue+(relativeValue*0.5f), TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector2 >( actor, index ), startValue+(relativeValue*0.5f), TEST_LOCATION );
application.SendNotification();
application.Render(static_cast<unsigned int>(durationSeconds*250.0f) + 1u/*just beyond the animation duration*/);
// We did expect the animation to finish
application.SendNotification();
finishCheck.CheckSignalReceived();
- DALI_TEST_EQUALS( actor.GetProperty<Vector2>(index), targetValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector2 >( actor, index ), targetValue, TEST_LOCATION );
END_TEST;
}
Vector2 startValue(10.0f, 10.0f);
Property::Index index = actor.RegisterProperty( "testProperty", startValue );
Stage::GetCurrent().Add(actor);
- DALI_TEST_EQUALS( actor.GetProperty<Vector2>(index), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( actor.GetProperty< Vector2 >( index ), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector2 >( actor, index ), startValue, TEST_LOCATION );
// Build the animation
float durationSeconds(1.0f);
// We didn't expect the animation to finish yet
application.SendNotification();
finishCheck.CheckSignalNotReceived();
- DALI_TEST_EQUALS( actor.GetProperty<Vector2>(index), startValue+(relativeValue*0.5f), TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector2 >( actor, index ), startValue+(relativeValue*0.5f), TEST_LOCATION );
application.SendNotification();
application.Render(static_cast<unsigned int>(durationSeconds*250.0f) + 1u/*just beyond the animation duration*/);
// We did expect the animation to finish
application.SendNotification();
finishCheck.CheckSignalReceived();
- DALI_TEST_EQUALS( actor.GetProperty<Vector2>(index), targetValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector2 >( actor, index ), targetValue, TEST_LOCATION );
END_TEST;
}
Vector3 startValue(-50.0f, -50.0f, -50.0f);
Property::Index index = actor.RegisterProperty( "testProperty", startValue );
Stage::GetCurrent().Add(actor);
- DALI_TEST_EQUALS( actor.GetProperty<Vector3>(index), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( actor.GetProperty<Vector3>( index ), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector3 >( actor, index ), startValue, TEST_LOCATION );
// Build the animation
float durationSeconds(2.0f);
// We didn't expect the animation to finish yet
application.SendNotification();
finishCheck.CheckSignalNotReceived();
- DALI_TEST_EQUALS( actor.GetProperty<Vector3>(index), ninetyFivePercentProgress, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector3 >( actor, index ), ninetyFivePercentProgress, TEST_LOCATION );
application.SendNotification();
application.Render(static_cast<unsigned int>(durationSeconds*50.0f) + 1u/*just beyond the animation duration*/);
// We did expect the animation to finish
application.SendNotification();
finishCheck.CheckSignalReceived();
- DALI_TEST_EQUALS( actor.GetProperty<Vector3>(index), targetValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector3 >( actor, index ), targetValue, TEST_LOCATION );
END_TEST;
}
Property::Index index = actor.RegisterProperty( "testProperty", startValue );
Stage::GetCurrent().Add(actor);
DALI_TEST_EQUALS( actor.GetProperty<Vector3>(index), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector3 >( actor, index ), startValue, TEST_LOCATION );
// Build the animation
float durationSeconds(1.0f);
finishCheck.CheckSignalNotReceived();
// The position should have moved more, than with a linear alpha function
- Vector3 current(actor.GetProperty<Vector3>(index));
+ Vector3 current( DevelHandle::GetCurrentProperty< Vector3 >( actor, index ) );
DALI_TEST_CHECK( current.x > ninetyFivePercentProgress.x );
DALI_TEST_CHECK( current.y > ninetyFivePercentProgress.y );
DALI_TEST_CHECK( current.z > ninetyFivePercentProgress.z );
// We did expect the animation to finish
application.SendNotification();
finishCheck.CheckSignalReceived();
- DALI_TEST_EQUALS( actor.GetProperty<Vector3>(index), targetValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector3 >( actor, index ), targetValue, TEST_LOCATION );
END_TEST;
}
Property::Index index = actor.RegisterProperty( "testProperty", startValue );
Stage::GetCurrent().Add(actor);
DALI_TEST_EQUALS( actor.GetProperty<Vector3>(index), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector3 >( actor, index ), startValue, TEST_LOCATION );
// Build the animation
float durationSeconds(1.0f);
// We didn't expect the animation to finish yet
application.SendNotification();
finishCheck.CheckSignalNotReceived();
- DALI_TEST_EQUALS( actor.GetProperty<Vector3>(index), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector3 >( actor, index ), startValue, TEST_LOCATION );
application.SendNotification();
application.Render(static_cast<unsigned int>(durationSeconds*250.0f)/* 75% animation progress, 50% animator progress */);
// We didn't expect the animation to finish yet
application.SendNotification();
finishCheck.CheckSignalNotReceived();
- DALI_TEST_EQUALS( actor.GetProperty<Vector3>(index), startValue+(relativeValue*0.5f), TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector3 >( actor, index ), startValue+(relativeValue*0.5f), TEST_LOCATION );
application.SendNotification();
application.Render(static_cast<unsigned int>(durationSeconds*250.0f) + 1u/*just beyond the animation duration*/);
// We did expect the animation to finish
application.SendNotification();
finishCheck.CheckSignalReceived();
- DALI_TEST_EQUALS( actor.GetProperty<Vector3>(index), targetValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector3 >( actor, index ), targetValue, TEST_LOCATION );
END_TEST;
}
Property::Index index = actor.RegisterProperty( "testProperty", startValue );
Stage::GetCurrent().Add(actor);
DALI_TEST_EQUALS( actor.GetProperty<Vector3>(index), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector3 >( actor, index ), startValue, TEST_LOCATION );
// Build the animation
float durationSeconds(1.0f);
// We didn't expect the animation to finish yet
application.SendNotification();
finishCheck.CheckSignalNotReceived();
- DALI_TEST_EQUALS( actor.GetProperty<Vector3>(index), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector3 >( actor, index ), startValue, TEST_LOCATION );
application.SendNotification();
application.Render(static_cast<unsigned int>(durationSeconds*250.0f)/* 75% animation progress, 50% animator progress */);
// We didn't expect the animation to finish yet
application.SendNotification();
finishCheck.CheckSignalNotReceived();
- DALI_TEST_EQUALS( actor.GetProperty<Vector3>(index), startValue+(relativeValue*0.5f), TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector3 >( actor, index ), startValue+(relativeValue*0.5f), TEST_LOCATION );
application.SendNotification();
application.Render(static_cast<unsigned int>(durationSeconds*250.0f) + 1u/*just beyond the animation duration*/);
// We did expect the animation to finish
application.SendNotification();
finishCheck.CheckSignalReceived();
- DALI_TEST_EQUALS( actor.GetProperty<Vector3>(index), targetValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector3 >( actor, index ), targetValue, TEST_LOCATION );
END_TEST;
}
Property::Index index = actor.RegisterProperty( "testProperty", startValue );
Stage::GetCurrent().Add(actor);
DALI_TEST_EQUALS( actor.GetProperty<Vector3>(index), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector3 >( actor, index ), startValue, TEST_LOCATION );
// Build the animation
float durationSeconds(1.0f);
// We didn't expect the animation to finish yet
application.SendNotification();
finishCheck.CheckSignalNotReceived();
- DALI_TEST_EQUALS( actor.GetProperty<Vector3>(index), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector3 >( actor, index ), startValue, TEST_LOCATION );
application.SendNotification();
application.Render(static_cast<unsigned int>(durationSeconds*250.0f)/* 75% animation progress, 50% animator progress */);
// We didn't expect the animation to finish yet
application.SendNotification();
finishCheck.CheckSignalNotReceived();
- DALI_TEST_EQUALS( actor.GetProperty<Vector3>(index), startValue+(relativeValue*0.5f), TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector3 >( actor, index ), startValue+(relativeValue*0.5f), TEST_LOCATION );
application.SendNotification();
application.Render(static_cast<unsigned int>(durationSeconds*250.0f) + 1u/*just beyond the animation duration*/);
// We did expect the animation to finish
application.SendNotification();
finishCheck.CheckSignalReceived();
- DALI_TEST_EQUALS( actor.GetProperty<Vector3>(index), targetValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector3 >( actor, index ), targetValue, TEST_LOCATION );
END_TEST;
}
Property::Index index = actor.RegisterProperty( "testProperty", startValue );
Stage::GetCurrent().Add(actor);
DALI_TEST_EQUALS( actor.GetProperty<Vector4>(index), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector4 >( actor, index ), startValue, TEST_LOCATION );
// Build the animation
float durationSeconds(2.0f);
// We didn't expect the animation to finish yet
application.SendNotification();
finishCheck.CheckSignalNotReceived();
- DALI_TEST_EQUALS( actor.GetProperty<Vector4>(index), ninetyFivePercentProgress, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector4 >( actor, index ), ninetyFivePercentProgress, TEST_LOCATION );
application.SendNotification();
application.Render(static_cast<unsigned int>(durationSeconds*50.0f) + 1u/*just beyond the animation duration*/);
// We did expect the animation to finish
application.SendNotification();
finishCheck.CheckSignalReceived();
- DALI_TEST_EQUALS( actor.GetProperty<Vector4>(index), targetValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector4 >( actor, index ), targetValue, TEST_LOCATION );
END_TEST;
}
Property::Index index = actor.RegisterProperty( "testProperty", startValue );
Stage::GetCurrent().Add(actor);
DALI_TEST_EQUALS( actor.GetProperty<Vector4>(index), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector4 >( actor, index ), startValue, TEST_LOCATION );
// Build the animation
float durationSeconds(1.0f);
finishCheck.CheckSignalNotReceived();
// The position should have moved more, than with a linear alpha function
- Vector4 current(actor.GetProperty<Vector4>(index));
+ Vector4 current( DevelHandle::GetCurrentProperty< Vector4 >( actor, index ) );
DALI_TEST_CHECK( current.x > ninetyFivePercentProgress.x );
DALI_TEST_CHECK( current.y > ninetyFivePercentProgress.y );
DALI_TEST_CHECK( current.z > ninetyFivePercentProgress.z );
// We did expect the animation to finish
application.SendNotification();
finishCheck.CheckSignalReceived();
- DALI_TEST_EQUALS( actor.GetProperty<Vector4>(index), targetValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector4 >( actor, index ), targetValue, TEST_LOCATION );
END_TEST;
}
Vector4 startValue(10.0f, 10.0f, 10.0f, 10.0f);
Property::Index index = actor.RegisterProperty( "testProperty", startValue );
Stage::GetCurrent().Add(actor);
- DALI_TEST_EQUALS( actor.GetProperty<Vector4>(index), startValue, VECTOR4_EPSILON, TEST_LOCATION );
+ DALI_TEST_EQUALS( actor.GetProperty<Vector4>(index), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector4 >( actor, index ), startValue, VECTOR4_EPSILON, TEST_LOCATION );
// Build the animation
float durationSeconds(1.0f);
// We didn't expect the animation to finish yet
application.SendNotification();
finishCheck.CheckSignalNotReceived();
- DALI_TEST_EQUALS( actor.GetProperty<Vector4>(index), startValue, VECTOR4_EPSILON, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector4 >( actor, index ), startValue, VECTOR4_EPSILON, TEST_LOCATION );
application.SendNotification();
application.Render(static_cast<unsigned int>(durationSeconds*250.0f)/* 75% animation progress, 50% animator progress */);
// We didn't expect the animation to finish yet
application.SendNotification();
finishCheck.CheckSignalNotReceived();
- DALI_TEST_EQUALS( actor.GetProperty<Vector4>(index), startValue+(relativeValue*0.5f), VECTOR4_EPSILON, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector4 >( actor, index ), startValue+(relativeValue*0.5f), VECTOR4_EPSILON, TEST_LOCATION );
application.SendNotification();
application.Render(static_cast<unsigned int>(durationSeconds*250.0f) + 1u/*just beyond the animation duration*/);
// We did expect the animation to finish
application.SendNotification();
finishCheck.CheckSignalReceived();
- DALI_TEST_EQUALS( actor.GetProperty<Vector4>(index), targetValue, VECTOR4_EPSILON, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector4 >( actor, index ), targetValue, VECTOR4_EPSILON, TEST_LOCATION );
END_TEST;
}
Property::Index index = actor.RegisterProperty( "testProperty", startValue );
Stage::GetCurrent().Add(actor);
DALI_TEST_EQUALS( actor.GetProperty<Vector4>(index), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector4 >( actor, index ), startValue, TEST_LOCATION );
// Build the animation
float durationSeconds(1.0f);
// We didn't expect the animation to finish yet
application.SendNotification();
finishCheck.CheckSignalNotReceived();
- DALI_TEST_EQUALS( actor.GetProperty<Vector4>(index), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector4 >( actor, index ), startValue, TEST_LOCATION );
application.SendNotification();
application.Render(static_cast<unsigned int>(durationSeconds*250.0f)/* 75% animation progress, 50% animator progress */);
// We didn't expect the animation to finish yet
application.SendNotification();
finishCheck.CheckSignalNotReceived();
- DALI_TEST_EQUALS( actor.GetProperty<Vector4>(index), startValue+(relativeValue*0.5f), TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector4 >( actor, index ), startValue+(relativeValue*0.5f), TEST_LOCATION );
application.SendNotification();
application.Render(static_cast<unsigned int>(durationSeconds*250.0f) + 1u/*just beyond the animation duration*/);
// We did expect the animation to finish
application.SendNotification();
finishCheck.CheckSignalReceived();
- DALI_TEST_EQUALS( actor.GetProperty<Vector4>(index), targetValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< Vector4 >( actor, index ), targetValue, TEST_LOCATION );
END_TEST;
}
DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::SCALE_X), startValue, TEST_LOCATION );
DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::SCALE_Y), startValue, TEST_LOCATION );
DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::SCALE_Z), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::SCALE_X ), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::SCALE_Y ), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::SCALE_Z ), startValue, TEST_LOCATION );
// Build the animation
float durationSeconds(1.0f);
application.SendNotification();
finishCheck.CheckSignalNotReceived();
DALI_TEST_EQUALS( actor.GetCurrentScale().x, fiftyPercentProgress, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::SCALE_X), fiftyPercentProgress, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::SCALE_Y), startValue, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::SCALE_Z), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::SCALE_X ), fiftyPercentProgress, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::SCALE_Y ), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::SCALE_Z ), startValue, TEST_LOCATION );
application.SendNotification();
application.Render(static_cast<unsigned int>(durationSeconds*500.0f) + 1u/*just beyond the animation duration*/);
application.SendNotification();
finishCheck.CheckSignalReceived();
DALI_TEST_EQUALS( actor.GetCurrentScale().x, targetX, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::SCALE_X), targetX, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::SCALE_Y), startValue, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::SCALE_Z), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::SCALE_X ), targetX, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::SCALE_Y ), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::SCALE_Z ), startValue, TEST_LOCATION );
END_TEST;
}
DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::SCALE_X), startValue, TEST_LOCATION );
DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::SCALE_Y), startValue, TEST_LOCATION );
DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::SCALE_Z), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::SCALE_X ), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::SCALE_Y ), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::SCALE_Z ), startValue, TEST_LOCATION );
// Build the animation
float durationSeconds(1.0f);
application.SendNotification();
finishCheck.CheckSignalNotReceived();
DALI_TEST_EQUALS( actor.GetCurrentScale().y, fiftyPercentProgress, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::SCALE_X), startValue, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::SCALE_Y), fiftyPercentProgress, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::SCALE_Z), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::SCALE_X ), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::SCALE_Y ), fiftyPercentProgress, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::SCALE_Z ), startValue, TEST_LOCATION );
application.SendNotification();
application.Render(static_cast<unsigned int>(durationSeconds*500.0f) + 1u/*just beyond the animation duration*/);
application.SendNotification();
finishCheck.CheckSignalReceived();
DALI_TEST_EQUALS( actor.GetCurrentScale().y, targetY, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::SCALE_X), startValue, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::SCALE_Y), targetY, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::SCALE_Z), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::SCALE_X ), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::SCALE_Y ), targetY, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::SCALE_Z ), startValue, TEST_LOCATION );
END_TEST;
}
DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::SCALE_X), startValue, TEST_LOCATION );
DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::SCALE_Y), startValue, TEST_LOCATION );
DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::SCALE_Z), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::SCALE_X ), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::SCALE_Y ), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::SCALE_Z ), startValue, TEST_LOCATION );
// Build the animation
float durationSeconds(1.0f);
// We didn't expect the animation to finish yet
application.SendNotification();
finishCheck.CheckSignalNotReceived();
- DALI_TEST_EQUALS( actor.GetCurrentScale().z, fiftyPercentProgress, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::SCALE_X), startValue, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::SCALE_Y), startValue, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::SCALE_Z), fiftyPercentProgress, TEST_LOCATION );
+ DALI_TEST_EQUALS( actor.GetCurrentScale().z, fiftyPercentProgress, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::SCALE_X ), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::SCALE_Y ), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::SCALE_Z ), fiftyPercentProgress, TEST_LOCATION );
application.SendNotification();
application.Render(static_cast<unsigned int>(durationSeconds*500.0f) + 1u/*just beyond the animation duration*/);
application.SendNotification();
finishCheck.CheckSignalReceived();
DALI_TEST_EQUALS( actor.GetCurrentScale().z, targetZ, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::SCALE_X), startValue, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::SCALE_Y), startValue, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::SCALE_Z), targetZ, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::SCALE_X ), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::SCALE_Y ), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::SCALE_Z ), targetZ, TEST_LOCATION );
END_TEST;
}
DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_GREEN), startValue, TEST_LOCATION );
DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_BLUE), startValue, TEST_LOCATION );
DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_ALPHA), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_RED ), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_GREEN ), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_BLUE ), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_ALPHA ), startValue, TEST_LOCATION );
// Build the animation
float durationSeconds(1.0f);
application.SendNotification();
finishCheck.CheckSignalNotReceived();
DALI_TEST_EQUALS( actor.GetCurrentColor().r, fiftyPercentProgress, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_RED), fiftyPercentProgress, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_GREEN), startValue, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_BLUE), startValue, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_ALPHA), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_RED), fiftyPercentProgress, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_GREEN), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_BLUE), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_ALPHA), startValue, TEST_LOCATION );
application.SendNotification();
application.Render(static_cast<unsigned int>(durationSeconds*500.0f) + 1u/*just beyond the animation duration*/);
application.SendNotification();
finishCheck.CheckSignalReceived();
DALI_TEST_EQUALS( actor.GetCurrentColor().r, targetRed, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_RED), targetRed, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_GREEN), startValue, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_BLUE), startValue, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_ALPHA), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_RED), targetRed, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_GREEN), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_BLUE), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_ALPHA), startValue, TEST_LOCATION );
END_TEST;
}
DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_GREEN), startValue, TEST_LOCATION );
DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_BLUE), startValue, TEST_LOCATION );
DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_ALPHA), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_RED ), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_GREEN ), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_BLUE ), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_ALPHA ), startValue, TEST_LOCATION );
// Build the animation
float durationSeconds(1.0f);
application.SendNotification();
finishCheck.CheckSignalNotReceived();
DALI_TEST_EQUALS( actor.GetCurrentColor().g, fiftyPercentProgress, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_RED), startValue, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_GREEN), fiftyPercentProgress, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_BLUE), startValue, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_ALPHA), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_RED), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_GREEN), fiftyPercentProgress, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_BLUE), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_ALPHA), startValue, TEST_LOCATION );
application.SendNotification();
application.Render(static_cast<unsigned int>(durationSeconds*500.0f) + 1u/*just beyond the animation duration*/);
application.SendNotification();
finishCheck.CheckSignalReceived();
DALI_TEST_EQUALS( actor.GetCurrentColor().g, targetGreen, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_RED), startValue, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_GREEN), targetGreen, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_BLUE), startValue, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_ALPHA), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_RED), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_GREEN), targetGreen, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_BLUE), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_ALPHA), startValue, TEST_LOCATION );
END_TEST;
}
DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_GREEN), startValue, TEST_LOCATION );
DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_BLUE), startValue, TEST_LOCATION );
DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_ALPHA), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_RED ), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_GREEN ), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_BLUE ), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_ALPHA ), startValue, TEST_LOCATION );
// Build the animation
float durationSeconds(1.0f);
application.SendNotification();
finishCheck.CheckSignalNotReceived();
DALI_TEST_EQUALS( actor.GetCurrentColor().b, fiftyPercentProgress, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_RED), startValue, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_GREEN), startValue, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_BLUE), fiftyPercentProgress, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_ALPHA), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_RED ), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_GREEN ), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_BLUE ), fiftyPercentProgress, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_ALPHA ), startValue, TEST_LOCATION );
application.SendNotification();
application.Render(static_cast<unsigned int>(durationSeconds*500.0f) + 1u/*just beyond the animation duration*/);
application.SendNotification();
finishCheck.CheckSignalReceived();
DALI_TEST_EQUALS( actor.GetCurrentColor().b, targetBlue, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_RED), startValue, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_GREEN), startValue, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_BLUE), targetBlue, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_ALPHA), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_RED ), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_GREEN ), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_BLUE ), targetBlue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_ALPHA ), startValue, TEST_LOCATION );
END_TEST;
}
DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_GREEN), startValue, TEST_LOCATION );
DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_BLUE), startValue, TEST_LOCATION );
DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_ALPHA), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_RED ), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_GREEN ), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_BLUE ), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_ALPHA ), startValue, TEST_LOCATION );
// Build the animation
float durationSeconds(1.0f);
application.SendNotification();
finishCheck.CheckSignalNotReceived();
DALI_TEST_EQUALS( actor.GetCurrentColor().a, fiftyPercentProgress, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_RED), startValue, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_GREEN), startValue, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_BLUE), startValue, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_ALPHA), fiftyPercentProgress, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_RED ), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_GREEN ), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_BLUE ), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_ALPHA ), fiftyPercentProgress, TEST_LOCATION );
application.SendNotification();
application.Render(static_cast<unsigned int>(durationSeconds*500.0f) + 1u/*just beyond the animation duration*/);
application.SendNotification();
finishCheck.CheckSignalReceived();
DALI_TEST_EQUALS( actor.GetCurrentColor().a, targetAlpha, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_RED), startValue, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_GREEN), startValue, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_BLUE), startValue, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_ALPHA), targetAlpha, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_RED ), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_GREEN ), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_BLUE ), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_ALPHA ), targetAlpha, TEST_LOCATION );
END_TEST;
}
DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_GREEN), startValue, TEST_LOCATION );
DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_BLUE), startValue, TEST_LOCATION );
DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_ALPHA), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_RED ), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_GREEN ), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_BLUE ), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_ALPHA ), startValue, TEST_LOCATION );
// Build the animation
float durationSeconds(1.0f);
application.Render(static_cast<unsigned int>(durationSeconds*100.0f)/* 10% progress */);
application.SendNotification();
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_RED), startValue, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_GREEN), startValue, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_BLUE), startValue, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_ALPHA), 0.3f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_RED), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_GREEN), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_BLUE), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_ALPHA), 0.3f, 0.01f, TEST_LOCATION );
DALI_TEST_EQUALS( actor.GetCurrentColor().a, 0.3f, 0.01f, TEST_LOCATION );
application.Render(static_cast<unsigned int>(durationSeconds*200.0f)/* 30% progress */);
application.SendNotification();
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_RED), startValue, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_GREEN), startValue, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_BLUE), startValue, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_ALPHA), 0.25f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_RED), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_GREEN), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_BLUE), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_ALPHA), 0.25f, 0.01f, TEST_LOCATION );
DALI_TEST_EQUALS( actor.GetCurrentColor().a, 0.25f, 0.01f, TEST_LOCATION );
application.Render(static_cast<unsigned int>(durationSeconds*100.0f)/* 40% progress */);
application.SendNotification();
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_RED), startValue, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_GREEN), startValue, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_BLUE), startValue, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_ALPHA), 0.0f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_RED), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_GREEN), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_BLUE), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_ALPHA), 0.0f, 0.01f, TEST_LOCATION );
DALI_TEST_EQUALS( actor.GetCurrentColor().a, 0.0f, 0.01f, TEST_LOCATION );
application.Render(static_cast<unsigned int>(durationSeconds*400.0f)/* 80% progress */);
application.SendNotification();
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_RED), startValue, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_GREEN), startValue, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_BLUE), startValue, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_ALPHA), 0.7f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_RED), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_GREEN), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_BLUE), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_ALPHA), 0.7f, 0.01f, TEST_LOCATION );
DALI_TEST_EQUALS( actor.GetCurrentColor().a, 0.7f, 0.01f, TEST_LOCATION );
application.Render(static_cast<unsigned int>(durationSeconds*100.0f)/* 90% progress */);
application.SendNotification();
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_RED), startValue, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_GREEN), startValue, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_BLUE), startValue, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_ALPHA), 0.8f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_RED), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_GREEN), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_BLUE), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_ALPHA), 0.8f, 0.01f, TEST_LOCATION );
DALI_TEST_EQUALS( actor.GetCurrentColor().a, 0.8f, 0.01f, TEST_LOCATION );
application.Render(static_cast<unsigned int>(durationSeconds*100.0f)+1/* 100% progress */);
application.SendNotification();
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_RED), startValue, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_GREEN), startValue, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_BLUE), startValue, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_ALPHA), 0.9f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_RED), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_GREEN), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_BLUE), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_ALPHA), 0.9f, 0.01f, TEST_LOCATION );
DALI_TEST_EQUALS( actor.GetCurrentColor().a, 0.9f, 0.01f, TEST_LOCATION );
// We did expect the animation to finish
DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_GREEN), startValue, TEST_LOCATION );
DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_BLUE), startValue, TEST_LOCATION );
DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_ALPHA), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_RED ), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_GREEN ), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_BLUE ), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_ALPHA ), startValue, TEST_LOCATION );
// Build the animation
float durationSeconds(1.0f);
application.Render(static_cast<unsigned int>(durationSeconds*100.0f)/* 10% progress */);
application.SendNotification();
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_RED), startValue, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_GREEN), startValue, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_BLUE), startValue, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_ALPHA), 0.36f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_RED ), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_GREEN ), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_BLUE ), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_ALPHA ), 0.36f, 0.01f, TEST_LOCATION );
DALI_TEST_EQUALS( actor.GetCurrentColor().a, 0.36f, 0.01f, TEST_LOCATION );
application.Render(static_cast<unsigned int>(durationSeconds*200.0f)/* 30% progress */);
application.SendNotification();
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_RED), startValue, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_GREEN), startValue, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_BLUE), startValue, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_ALPHA), 0.21f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_RED ), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_GREEN ), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_BLUE ), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_ALPHA ), 0.21f, 0.01f, TEST_LOCATION );
DALI_TEST_EQUALS( actor.GetCurrentColor().a, 0.21f, 0.01f, TEST_LOCATION );
application.Render(static_cast<unsigned int>(durationSeconds*100.0f)/* 40% progress */);
application.SendNotification();
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_RED), startValue, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_GREEN), startValue, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_BLUE), startValue, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_ALPHA), 0.0f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_RED ), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_GREEN ), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_BLUE ), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_ALPHA ), 0.0f, 0.01f, TEST_LOCATION );
DALI_TEST_EQUALS( actor.GetCurrentColor().a, 0.0f, 0.01f, TEST_LOCATION );
application.Render(static_cast<unsigned int>(durationSeconds*400.0f)/* 80% progress */);
application.SendNotification();
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_RED), startValue, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_GREEN), startValue, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_BLUE), startValue, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_ALPHA), 0.7f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_RED ), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_GREEN ), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_BLUE ), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_ALPHA ), 0.7f, 0.01f, TEST_LOCATION );
DALI_TEST_EQUALS( actor.GetCurrentColor().a, 0.7f, 0.01f, TEST_LOCATION );
application.Render(static_cast<unsigned int>(durationSeconds*100.0f)/* 90% progress */);
application.SendNotification();
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_RED), startValue, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_GREEN), startValue, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_BLUE), startValue, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_ALPHA), 0.76f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_RED ), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_GREEN ), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_BLUE ), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_ALPHA ), 0.76f, 0.01f, TEST_LOCATION );
DALI_TEST_EQUALS( actor.GetCurrentColor().a, 0.76f, 0.01f, TEST_LOCATION );
application.Render(static_cast<unsigned int>(durationSeconds*100.0f)+1/* 100% progress */);
application.SendNotification();
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_RED), startValue, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_GREEN), startValue, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_BLUE), startValue, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_ALPHA), 0.9f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_RED ), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_GREEN ), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_BLUE ), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_ALPHA ), 0.9f, 0.01f, TEST_LOCATION );
DALI_TEST_EQUALS( actor.GetCurrentColor().a, 0.9f, 0.01f, TEST_LOCATION );
// We did expect the animation to finish
DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_GREEN), startValue, TEST_LOCATION );
DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_BLUE), startValue, TEST_LOCATION );
DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_ALPHA), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_RED ), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_GREEN ), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_BLUE ), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_ALPHA ), startValue, TEST_LOCATION );
// Build the animation
float durationSeconds(1.0f);
application.Render(0);
application.SendNotification();
finishCheck.CheckSignalNotReceived();
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_RED), 0.1f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_GREEN), 0.2f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_BLUE), 0.3f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_ALPHA), 0.4f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_RED ), 0.1f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_GREEN ), 0.2f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_BLUE ), 0.3f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_ALPHA ), 0.4f, 0.01f, TEST_LOCATION );
application.Render(static_cast<unsigned int>(durationSeconds*250.0f)/* 25% progress */);
application.SendNotification();
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_RED), 0.5f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_GREEN), 0.5f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_BLUE), 0.5f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_ALPHA), 0.5f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_RED ), 0.5f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_GREEN ), 0.5f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_BLUE ), 0.5f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_ALPHA ), 0.5f, 0.01f, TEST_LOCATION );
application.Render(static_cast<unsigned int>(durationSeconds*250.0f)/* 50% progress */);
application.SendNotification();
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_RED), 0.9f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_GREEN), 0.8f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_BLUE), 0.7f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_ALPHA), 0.6f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_RED ), 0.9f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_GREEN ), 0.8f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_BLUE ), 0.7f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_ALPHA ), 0.6f, 0.01f, TEST_LOCATION );
application.Render(static_cast<unsigned int>(durationSeconds*250.0f)/* 75% progress */);
application.SendNotification();
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_RED), 0.95f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_GREEN), 0.90f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_BLUE), 0.85f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_ALPHA), 0.80f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_RED ), 0.95f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_GREEN ), 0.90f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_BLUE ), 0.85f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_ALPHA ), 0.80f, 0.01f, TEST_LOCATION );
application.Render(static_cast<unsigned int>(durationSeconds*250.0f)+1/* 100% progress */);
application.SendNotification();
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_RED), 1.0f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_GREEN), 1.0f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_BLUE), 1.0f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_ALPHA), 1.0f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_RED ), 1.0f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_GREEN ), 1.0f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_BLUE ), 1.0f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_ALPHA ), 1.0f, 0.01f, TEST_LOCATION );
// We did expect the animation to finish
DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_GREEN), startValue, TEST_LOCATION );
DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_BLUE), startValue, TEST_LOCATION );
DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_ALPHA), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_RED ), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_GREEN ), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_BLUE ), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_ALPHA ), startValue, TEST_LOCATION );
// Build the animation
float durationSeconds(1.0f);
application.Render(0);
application.SendNotification();
finishCheck.CheckSignalNotReceived();
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_RED), 0.1f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_GREEN), 0.2f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_BLUE), 0.3f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_ALPHA), 0.4f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_RED ), 0.1f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_GREEN ), 0.2f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_BLUE ), 0.3f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_ALPHA ), 0.4f, 0.01f, TEST_LOCATION );
application.Render(static_cast<unsigned int>(durationSeconds*250.0f)/* 25% progress */);
application.SendNotification();
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_RED), 0.55f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_GREEN), 0.525f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_BLUE), 0.506f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_ALPHA), 0.4875f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_RED ), 0.55f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_GREEN ), 0.525f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_BLUE ), 0.506f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_ALPHA ), 0.4875f, 0.01f, TEST_LOCATION );
application.Render(static_cast<unsigned int>(durationSeconds*250.0f)/* 50% progress */);
application.SendNotification();
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_RED), 0.9f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_GREEN), 0.8f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_BLUE), 0.7f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_ALPHA), 0.6f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_RED ), 0.9f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_GREEN ), 0.8f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_BLUE ), 0.7f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_ALPHA ), 0.6f, 0.01f, TEST_LOCATION );
application.Render(static_cast<unsigned int>(durationSeconds*250.0f)/* 75% progress */);
application.SendNotification();
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_RED), 0.99375f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_GREEN), 0.925f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_BLUE), 0.85625f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_ALPHA), 0.7875f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_RED ), 0.99375f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_GREEN ), 0.925f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_BLUE ), 0.85625f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_ALPHA ), 0.7875f, 0.01f, TEST_LOCATION );
application.Render(static_cast<unsigned int>(durationSeconds*250.0f)+1/* 100% progress */);
application.SendNotification();
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_RED), 1.0f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_GREEN), 1.0f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_BLUE), 1.0f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_ALPHA), 1.0f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_RED ), 1.0f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_GREEN ), 1.0f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_BLUE ), 1.0f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_ALPHA ), 1.0f, 0.01f, TEST_LOCATION );
// We did expect the animation to finish
DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_GREEN), startValue, TEST_LOCATION );
DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_BLUE), startValue, TEST_LOCATION );
DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_ALPHA), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_RED ), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_GREEN ), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_BLUE ), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_ALPHA ), startValue, TEST_LOCATION );
// Build the animation
float durationSeconds(1.0f);
application.Render(0);
application.SendNotification();
finishCheck.CheckSignalNotReceived();
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_RED), 0.1f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_GREEN), 0.2f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_BLUE), 0.3f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_ALPHA), 0.4f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_RED ), 0.1f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_GREEN ), 0.2f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_BLUE ), 0.3f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_ALPHA ), 0.4f, 0.01f, TEST_LOCATION );
application.Render(static_cast<unsigned int>(durationSeconds*250.0f)/* 25% progress */);
application.SendNotification();
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_RED), 0.5f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_GREEN), 0.5f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_BLUE), 0.5f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_ALPHA), 0.5f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_RED ), 0.5f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_GREEN ), 0.5f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_BLUE ), 0.5f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_ALPHA ), 0.5f, 0.01f, TEST_LOCATION );
application.Render(static_cast<unsigned int>(durationSeconds*250.0f)/* 50% progress */);
application.SendNotification();
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_RED), 0.9f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_GREEN), 0.8f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_BLUE), 0.7f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_ALPHA), 0.6f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_RED ), 0.9f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_GREEN ), 0.8f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_BLUE ), 0.7f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_ALPHA ), 0.6f, 0.01f, TEST_LOCATION );
application.Render(static_cast<unsigned int>(durationSeconds*250.0f)/* 75% progress */);
application.SendNotification();
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_RED), 0.95f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_GREEN), 0.90f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_BLUE), 0.85f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_ALPHA), 0.80f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_RED ), 0.95f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_GREEN ), 0.90f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_BLUE ), 0.85f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_ALPHA ), 0.80f, 0.01f, TEST_LOCATION );
application.Render(static_cast<unsigned int>(durationSeconds*250.0f)+1/* 100% progress */);
application.SendNotification();
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_RED), 1.0f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_GREEN), 1.0f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_BLUE), 1.0f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_ALPHA), 1.0f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_RED ), 1.0f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_GREEN ), 1.0f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_BLUE ), 1.0f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_ALPHA ), 1.0f, 0.01f, TEST_LOCATION );
// We did expect the animation to finish
DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_GREEN), startValue, TEST_LOCATION );
DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_BLUE), startValue, TEST_LOCATION );
DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_ALPHA), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_RED ), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_GREEN ), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_BLUE ), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_ALPHA ), startValue, TEST_LOCATION );
// Build the animation
float durationSeconds(1.0f);
application.Render(0);
application.SendNotification();
finishCheck.CheckSignalNotReceived();
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_RED), 0.1f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_GREEN), 0.2f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_BLUE), 0.3f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_ALPHA), 0.4f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_RED ), 0.1f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_GREEN ), 0.2f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_BLUE ), 0.3f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_ALPHA ), 0.4f, 0.01f, TEST_LOCATION );
application.Render(static_cast<unsigned int>(durationSeconds*250.0f)/* 25% progress */);
application.SendNotification();
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_RED), 0.55f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_GREEN), 0.525f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_BLUE), 0.506f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_ALPHA), 0.4875f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_RED ), 0.55f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_GREEN ), 0.525f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_BLUE ), 0.506f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_ALPHA ), 0.4875f, 0.01f, TEST_LOCATION );
application.Render(static_cast<unsigned int>(durationSeconds*250.0f)/* 50% progress */);
application.SendNotification();
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_RED), 0.9f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_GREEN), 0.8f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_BLUE), 0.7f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_ALPHA), 0.6f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_RED ), 0.9f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_GREEN ), 0.8f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_BLUE ), 0.7f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_ALPHA ), 0.6f, 0.01f, TEST_LOCATION );
application.Render(static_cast<unsigned int>(durationSeconds*250.0f)/* 75% progress */);
application.SendNotification();
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_RED), 0.99375f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_GREEN), 0.925f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_BLUE), 0.85625f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_ALPHA), 0.7875f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_RED ), 0.99375f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_GREEN ), 0.925f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_BLUE ), 0.85625f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_ALPHA ), 0.7875f, 0.01f, TEST_LOCATION );
application.Render(static_cast<unsigned int>(durationSeconds*250.0f)+1/* 100% progress */);
application.SendNotification();
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_RED), 1.0f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_GREEN), 1.0f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_BLUE), 1.0f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_ALPHA), 1.0f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_RED ), 1.0f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_GREEN ), 1.0f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_BLUE ), 1.0f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_ALPHA ), 1.0f, 0.01f, TEST_LOCATION );
// We did expect the animation to finish
DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_GREEN), startValue, TEST_LOCATION );
DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_BLUE), startValue, TEST_LOCATION );
DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_ALPHA), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_RED ), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_GREEN ), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_BLUE ), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_ALPHA ), startValue, TEST_LOCATION );
// Build the animation
float durationSeconds(1.0f);
application.Render(static_cast<unsigned int>(delay*1000.0f)/* 0% progress */);
application.SendNotification();
finishCheck.CheckSignalNotReceived();
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_RED), 0.1f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_GREEN), 0.2f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_BLUE), 0.3f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_ALPHA), 0.4f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_RED ), 0.1f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_GREEN ), 0.2f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_BLUE ), 0.3f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_ALPHA ), 0.4f, 0.01f, TEST_LOCATION );
application.Render(static_cast<unsigned int>((durationSeconds - delay)*250.0f)/* 25% progress */);
application.SendNotification();
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_RED), 0.5f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_GREEN), 0.5f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_BLUE), 0.5f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_ALPHA), 0.5f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_RED ), 0.5f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_GREEN ), 0.5f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_BLUE ), 0.5f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_ALPHA ), 0.5f, 0.01f, TEST_LOCATION );
application.Render(static_cast<unsigned int>((durationSeconds - delay)*250.0f)/* 50% progress */);
application.SendNotification();
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_RED), 0.9f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_GREEN), 0.8f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_BLUE), 0.7f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_ALPHA), 0.6f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_RED ), 0.9f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_GREEN ), 0.8f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_BLUE ), 0.7f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_ALPHA ), 0.6f, 0.01f, TEST_LOCATION );
application.Render(static_cast<unsigned int>((durationSeconds - delay)*250.0f)/* 75% progress */);
application.SendNotification();
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_RED), 0.95f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_GREEN), 0.90f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_BLUE), 0.85f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_ALPHA), 0.80f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_RED ), 0.95f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_GREEN ), 0.90f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_BLUE ), 0.85f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_ALPHA ), 0.80f, 0.01f, TEST_LOCATION );
application.Render(static_cast<unsigned int>((durationSeconds - delay)*250.0f)+1/* 100% progress */);
application.SendNotification();
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_RED), 1.0f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_GREEN), 1.0f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_BLUE), 1.0f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_ALPHA), 1.0f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_RED ), 1.0f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_GREEN ), 1.0f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_BLUE ), 1.0f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_ALPHA ), 1.0f, 0.01f, TEST_LOCATION );
// We did expect the animation to finish
DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_GREEN), startValue, TEST_LOCATION );
DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_BLUE), startValue, TEST_LOCATION );
DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_ALPHA), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_RED ), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_GREEN ), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_BLUE ), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_ALPHA ), startValue, TEST_LOCATION );
// Build the animation
float durationSeconds(1.0f);
application.Render(static_cast<unsigned int>(delay*1000.0f)/* 0% progress */);
application.SendNotification();
finishCheck.CheckSignalNotReceived();
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_RED), 0.1f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_GREEN), 0.2f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_BLUE), 0.3f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_ALPHA), 0.4f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_RED ), 0.1f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_GREEN ), 0.2f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_BLUE ), 0.3f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_ALPHA ), 0.4f, 0.01f, TEST_LOCATION );
application.Render(static_cast<unsigned int>((durationSeconds - delay)*250.0f)/* 25% progress */);
application.SendNotification();
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_RED), 0.55f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_GREEN), 0.525f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_BLUE), 0.506f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_ALPHA), 0.4875f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_RED ), 0.55f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_GREEN ), 0.525f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_BLUE ), 0.506f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_ALPHA ), 0.4875f, 0.01f, TEST_LOCATION );
application.Render(static_cast<unsigned int>((durationSeconds - delay)*250.0f)/* 50% progress */);
application.SendNotification();
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_RED), 0.9f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_GREEN), 0.8f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_BLUE), 0.7f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_ALPHA), 0.6f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_RED ), 0.9f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_GREEN), 0.8f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_BLUE ), 0.7f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_ALPHA ), 0.6f, 0.01f, TEST_LOCATION );
application.Render(static_cast<unsigned int>((durationSeconds - delay)*250.0f)/* 75% progress */);
application.SendNotification();
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_RED), 0.99375f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_GREEN), 0.925f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_BLUE), 0.85625f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_ALPHA), 0.7875f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_RED ), 0.99375f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_GREEN ), 0.925f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_BLUE ), 0.85625f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_ALPHA ), 0.7875f, 0.01f, TEST_LOCATION );
application.Render(static_cast<unsigned int>((durationSeconds - delay)*250.0f)+1/* 100% progress */);
application.SendNotification();
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_RED), 1.0f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_GREEN), 1.0f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_BLUE), 1.0f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_ALPHA), 1.0f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_RED ), 1.0f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_GREEN ), 1.0f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_BLUE ), 1.0f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_ALPHA ), 1.0f, 0.01f, TEST_LOCATION );
// We did expect the animation to finish
DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_GREEN), startValue, TEST_LOCATION );
DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_BLUE), startValue, TEST_LOCATION );
DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_ALPHA), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_RED ), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_GREEN ), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_BLUE ), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_ALPHA ), startValue, TEST_LOCATION );
// Build the animation
float durationSeconds(1.0f);
application.Render(static_cast<unsigned int>(delay*1000.0f)/* 0% progress */);
application.SendNotification();
finishCheck.CheckSignalNotReceived();
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_RED), 0.1f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_GREEN), 0.2f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_BLUE), 0.3f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_ALPHA), 0.4f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_RED ), 0.1f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_GREEN ), 0.2f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_BLUE ), 0.3f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_ALPHA ), 0.4f, 0.01f, TEST_LOCATION );
application.Render(static_cast<unsigned int>((durationSeconds - delay)*250.0f)/* 25% progress */);
application.SendNotification();
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_RED), 0.5f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_GREEN), 0.5f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_BLUE), 0.5f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_ALPHA), 0.5f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_RED ), 0.5f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_GREEN ), 0.5f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_BLUE ), 0.5f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_ALPHA ), 0.5f, 0.01f, TEST_LOCATION );
application.Render(static_cast<unsigned int>((durationSeconds - delay)*250.0f)/* 50% progress */);
application.SendNotification();
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_RED), 0.9f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_GREEN), 0.8f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_BLUE), 0.7f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_ALPHA), 0.6f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_RED ), 0.9f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_GREEN ), 0.8f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_BLUE ), 0.7f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_ALPHA ), 0.6f, 0.01f, TEST_LOCATION );
application.Render(static_cast<unsigned int>((durationSeconds - delay)*250.0f)/* 75% progress */);
application.SendNotification();
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_RED), 0.95f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_GREEN), 0.90f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_BLUE), 0.85f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_ALPHA), 0.80f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_RED ), 0.95f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_GREEN ), 0.90f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_BLUE ), 0.85f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_ALPHA ), 0.80f, 0.01f, TEST_LOCATION );
application.Render(static_cast<unsigned int>((durationSeconds - delay)*250.0f)+1/* 100% progress */);
application.SendNotification();
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_RED), 1.0f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_GREEN), 1.0f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_BLUE), 1.0f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_ALPHA), 1.0f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_RED ), 1.0f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_GREEN ), 1.0f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_BLUE ), 1.0f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_ALPHA ), 1.0f, 0.01f, TEST_LOCATION );
// We did expect the animation to finish
END_TEST;
}
-int P(void)
+int UtcDaliAnimationAnimateBetweenActorColorCubicWithDelayP(void)
{
TestApplication application;
DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_GREEN), startValue, TEST_LOCATION );
DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_BLUE), startValue, TEST_LOCATION );
DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_ALPHA), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_RED ), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_GREEN ), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_BLUE ), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_ALPHA ), startValue, TEST_LOCATION );
+
// Build the animation
float durationSeconds(1.0f);
application.Render(static_cast<unsigned int>(delay*1000.0f)/* 0% progress */);
application.SendNotification();
finishCheck.CheckSignalNotReceived();
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_RED), 0.1f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_GREEN), 0.2f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_BLUE), 0.3f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_ALPHA), 0.4f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_RED ), 0.1f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_GREEN ), 0.2f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_BLUE ), 0.3f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_ALPHA ), 0.4f, 0.01f, TEST_LOCATION );
application.Render(static_cast<unsigned int>((durationSeconds - delay)*250.0f)/* 25% progress */);
application.SendNotification();
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_RED), 0.55f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_GREEN), 0.525f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_BLUE), 0.506f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_ALPHA), 0.4875f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_RED ), 0.55f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_GREEN ), 0.525f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_BLUE ), 0.506f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_ALPHA ), 0.4875f, 0.01f, TEST_LOCATION );
application.Render(static_cast<unsigned int>((durationSeconds - delay)*250.0f)/* 50% progress */);
application.SendNotification();
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_RED), 0.9f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_GREEN), 0.8f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_BLUE), 0.7f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_ALPHA), 0.6f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_RED ), 0.9f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_GREEN ), 0.8f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_BLUE ), 0.7f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_ALPHA ), 0.6f, 0.01f, TEST_LOCATION );
application.Render(static_cast<unsigned int>((durationSeconds - delay)*250.0f)/* 75% progress */);
application.SendNotification();
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_RED), 0.99375f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_GREEN), 0.925f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_BLUE), 0.85625f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_ALPHA), 0.7875f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_RED ), 0.99375f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_GREEN ), 0.925f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_BLUE ), 0.85625f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_ALPHA ), 0.7875f, 0.01f, TEST_LOCATION );
application.Render(static_cast<unsigned int>((durationSeconds - delay)*250.0f)+1/* 100% progress */);
application.SendNotification();
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_RED), 1.0f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_GREEN), 1.0f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_BLUE), 1.0f, 0.01f, TEST_LOCATION );
- DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_ALPHA), 1.0f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_RED ), 1.0f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_GREEN ), 1.0f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_BLUE ), 1.0f, 0.01f, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, Actor::Property::COLOR_ALPHA ), 1.0f, 0.01f, TEST_LOCATION );
// We did expect the animation to finish
// Apply animation to actor
animation.AnimateTo( Property(actor, Actor::Property::POSITION), Vector3( 100.f, 90.f, 80.f ), AlphaFunction::LINEAR );
+ animation.AnimateTo( Property(actor, DevelActor::Property::OPACITY), 0.3f, AlphaFunction::LINEAR );
animation.Play();
Property::Index index = actor.RegisterProperty( "testProperty", startValue );
Stage::GetCurrent().Add(actor);
DALI_TEST_EQUALS( actor.GetProperty<float>(index), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, index ), startValue, TEST_LOCATION );
// Build the animation
float initialDurationSeconds(1.0f);
// We didn't expect the animation to finish yet
application.SendNotification();
finishCheck.CheckSignalNotReceived();
- DALI_TEST_EQUALS( actor.GetProperty<float>(index), startValue+(relativeValue*0.5f), TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, index ), startValue+(relativeValue*0.5f), TEST_LOCATION );
application.SendNotification();
application.Render(static_cast<unsigned int>(extendedDurationSeconds*250.0f) + 1u/*just beyond the animation duration*/);
// We did expect the animation to finish
application.SendNotification();
finishCheck.CheckSignalReceived();
- DALI_TEST_EQUALS( actor.GetProperty<float>(index), targetValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< float >( actor, index ), targetValue, TEST_LOCATION );
END_TEST;
}
int startValue(0u);
Property::Index index = actor.RegisterProperty("anIndex", startValue);
- DALI_TEST_EQUALS( actor.GetProperty<int>(index), startValue, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< int >( actor, index ), startValue, TEST_LOCATION );
// Build the animation
float durationSeconds(1.0f);
// We didn't expect the animation to finish yet
application.SendNotification();
finishCheck.CheckSignalNotReceived();
- DALI_TEST_EQUALS( actor.GetProperty<int>(index), 10, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< int >( actor, index ), 10, TEST_LOCATION );
application.SendNotification();
application.Render(static_cast<unsigned int>(durationSeconds*500.0f) + 1u/*just beyond the animation duration*/);
// We did expect the animation to finish
application.SendNotification();
finishCheck.CheckSignalReceived();
- DALI_TEST_EQUALS( actor.GetProperty<int>(index), 20, TEST_LOCATION );
+ DALI_TEST_EQUALS( DevelHandle::GetCurrentProperty< int >( actor, index ), 20, TEST_LOCATION );
+ END_TEST;
+}
+
+int UtcDaliAnimationDuration(void)
+{
+ TestApplication application;
+
+ Actor actor = Actor::New();
+ Stage::GetCurrent().Add(actor);
+
+ Animation animation = Animation::New( 0.0f );
+ DALI_TEST_EQUALS( 0.0f, animation.GetDuration(), TEST_LOCATION );
+
+ // The animation duration should automatically increase depending on the animator time period
+
+ animation.AnimateTo( Property( actor, Actor::Property::POSITION_X ), 100.0f, TimePeriod( 0.0f, 1.0f ) );
+ DALI_TEST_EQUALS( 1.0f, animation.GetDuration(), TEST_LOCATION );
+
+ animation.AnimateTo( Property( actor, Actor::Property::POSITION_Y ), 200.0f, TimePeriod( 10.0f, 1.0f ) );
+ DALI_TEST_EQUALS( 11.0f, animation.GetDuration(), TEST_LOCATION );
+
+ END_TEST;
+}
+
+int UtcDaliAnimationAnimateByNonAnimateableTypeN(void)
+{
+ TestApplication application;
+
+ Actor actor = Actor::New();
+
+ // Register an integer property
+ int startValue(1);
+ Property::Index index = actor.RegisterProperty( "testProperty", startValue );
+ Stage::GetCurrent().Add(actor);
+ DALI_TEST_EQUALS( actor.GetProperty<int>(index), startValue, TEST_LOCATION );
+
+ try
+ {
+ // Build the animation
+ Animation animation = Animation::New( 2.0f );
+ std::string relativeValue = "relative string";
+ animation.AnimateBy( Property(actor, index), relativeValue );
+ tet_result(TET_FAIL);
+ }
+ catch ( Dali::DaliException& e )
+ {
+ DALI_TEST_ASSERT( e, "Animated value and Property type don't match", TEST_LOCATION );
+ }
+
+
+ END_TEST;
+}
+
+
+int UtcDaliAnimationAnimateToNonAnimateableTypeN(void)
+{
+ TestApplication application;
+
+ Actor actor = Actor::New();
+
+ // Register an integer property
+ int startValue(1);
+ Property::Index index = actor.RegisterProperty( "testProperty", startValue );
+ Stage::GetCurrent().Add(actor);
+ DALI_TEST_EQUALS( actor.GetProperty<int>(index), startValue, TEST_LOCATION );
+
+ try
+ {
+ // Build the animation
+ Animation animation = Animation::New( 2.0f );
+ std::string relativeValue = "relative string";
+ animation.AnimateTo( Property(actor, index), relativeValue );
+
+ tet_result(TET_FAIL);
+ }
+ catch ( Dali::DaliException& e )
+ {
+ DALI_TEST_ASSERT( e, "Animated value and Property type don't match", TEST_LOCATION );
+ }
+
+ END_TEST;
+}
+
+int UtcDaliAnimationAnimateBetweenNonAnimateableTypeN(void)
+{
+ TestApplication application;
+
+ Actor actor = Actor::New();
+
+ // Register an integer property
+ int startValue(1);
+ Property::Index index = actor.RegisterProperty( "testProperty", startValue );
+ Stage::GetCurrent().Add(actor);
+ DALI_TEST_EQUALS( actor.GetProperty<int>(index), startValue, TEST_LOCATION );
+
+ try
+ {
+ // Build the animation
+ KeyFrames keyFrames = KeyFrames::New();
+ keyFrames.Add( 0.0f, std::string("relative string1") );
+ keyFrames.Add( 1.0f, std::string("relative string2") );
+ // no need to really create the animation as keyframes do the check
+
+ tet_result(TET_FAIL);
+ }
+ catch ( Dali::DaliException& e )
+ {
+ DALI_TEST_ASSERT( e, "Type not animateable", TEST_LOCATION );
+ }
+
END_TEST;
}
+int UtcDaliAnimationSetAndGetTargetBeforePlayP(void)
+{
+ tet_infoline("Setting up an animation should not effect it's position property until the animation plays");
+
+ TestApplication application;
+
+ tet_infoline("Set initial position and set up animation to re-position actor");
+
+ Actor actor = Actor::New();
+ Stage::GetCurrent().Add(actor);
+ Vector3 initialPosition(0.0f, 0.0f, 0.0f);
+ actor.SetProperty( Actor::Property::POSITION, initialPosition );
+
+ // Build the animation
+ Animation animation = Animation::New(2.0f);
+
+ //Test GetCurrentProgress return 0.0 as the duration is 0.0
+ DALI_TEST_EQUALS( 0.0f, animation.GetCurrentProgress(), TEST_LOCATION );
+ DALI_TEST_EQUALS( Vector3( 0.0f, 0.0f, 0.0f ), actor.GetCurrentPosition(), TEST_LOCATION );
+
+ tet_infoline("Set target position in animation without intiating play");
+
+ Vector3 targetPosition(100.0f, 100.0f, 100.0f);
+ animation.AnimateTo(Property(actor, Actor::Property::POSITION), targetPosition, AlphaFunction::LINEAR);
+
+ application.SendNotification();
+ application.Render();
+
+ tet_infoline("Ensure position of actor is still at intial value");
+
+ DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::POSITION_X), initialPosition.x, TEST_LOCATION );
+ DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::POSITION_Y), initialPosition.y, TEST_LOCATION );
+ DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::POSITION_Z), initialPosition.z, TEST_LOCATION );
+
+ tet_infoline("Play animation and ensure actor position is now target");
+
+ animation.Play();
+ application.SendNotification();
+ application.Render(1000u);
+
+ tet_infoline("Ensure position of actor is at target value when aninmation half way");
+
+ DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::POSITION_X), targetPosition.x, TEST_LOCATION );
+ DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::POSITION_Y), targetPosition.y, TEST_LOCATION );
+ DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::POSITION_Z), targetPosition.z, TEST_LOCATION );
+
+ tet_printf( "x position at half way point(%f)\n", actor.GetCurrentPosition().x );
+
+ application.Render(2000u);
+
+ tet_infoline("Ensure position of actor is still at target value when aninmation complete");
+
+ DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::POSITION_X), targetPosition.x, TEST_LOCATION );
+ DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::POSITION_Y), targetPosition.y, TEST_LOCATION );
+ DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::POSITION_Z), targetPosition.z, TEST_LOCATION );
+
+ END_TEST;
+}
+
+int UtcDaliAnimationSetAndGetTargetBeforePlayMulitpleAnimatorsPositionP(void)
+{
+ tet_infoline("Setting up an animation should not effect it's position property until the animation plays even with mulitple animators");
+
+ TestApplication application;
+
+ std::vector<Vector3> targetPositions;
+
+ targetPositions.push_back( Vector3( 100.0f, 100.0f, 100.0f ) );
+ targetPositions.push_back( Vector3( 200.0f, 1.0f, 100.0f ) );
+ targetPositions.push_back( Vector3( 50.0f, 10.0f, 100.0f ) );
+
+ tet_infoline("Set initial position and set up animation to re-position actor");
+
+ Actor actor = Actor::New();
+ Stage::GetCurrent().Add(actor);
+ Vector3 initialPosition(0.0f, 0.0f, 0.0f);
+ actor.SetProperty( Actor::Property::POSITION, initialPosition );
+
+ // Build the animation
+ Animation animation = Animation::New(2.0f);
+
+ //Test GetCurrentProgress return 0.0 as the duration is 0.0
+ DALI_TEST_EQUALS( 0.0f, animation.GetCurrentProgress(), TEST_LOCATION );
+ DALI_TEST_EQUALS( Vector3( 0.0f, 0.0f, 0.0f ), actor.GetCurrentPosition(), TEST_LOCATION );
+
+ tet_infoline("Set target position in animation without intiating play");
+
+ for ( unsigned int i = 0; i < targetPositions.size(); i++ )
+ {
+ animation.AnimateTo(Property(actor, Actor::Property::POSITION), targetPositions[i], AlphaFunction::LINEAR);
+ }
+
+ application.SendNotification();
+ application.Render();
+
+ tet_infoline("Ensure position of actor is still at intial value");
+
+ DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::POSITION_X), initialPosition.x, TEST_LOCATION );
+ DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::POSITION_Y), initialPosition.y, TEST_LOCATION );
+ DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::POSITION_Z), initialPosition.z, TEST_LOCATION );
+
+ tet_infoline("Play animation and ensure actor position is now target");
+
+ animation.Play();
+ application.SendNotification();
+ application.Render(1000u);
+
+ tet_infoline("Ensure position of actor is at target value when aninmation half way");
+
+ DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::POSITION_X), targetPositions[2].x, TEST_LOCATION );
+ DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::POSITION_Y), targetPositions[2].y, TEST_LOCATION );
+ DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::POSITION_Z), targetPositions[2].z, TEST_LOCATION );
+
+ tet_printf( "x position at half way point(%f)\n", actor.GetCurrentPosition().x );
+
+ application.Render(2000u);
+
+ tet_infoline("Ensure position of actor is still at target value when aninmation complete");
+
+ DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::POSITION_X), targetPositions[2].x, TEST_LOCATION );
+ DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::POSITION_Y), targetPositions[2].y, TEST_LOCATION );
+ DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::POSITION_Z), targetPositions[2].z, TEST_LOCATION );
+
+ END_TEST;
+}
+
+int UtcDaliAnimationSetAndGetTargetBeforePlayMulitpleAnimatorsSizeAndPositionP(void)
+{
+ tet_infoline("Setting up an animation should not effect it's size property until the animation plays even with mulitple animators of different Property Indexes");
+
+ TestApplication application;
+
+ std::vector<Vector3> targetSizes;
+ std::vector<Vector3> targetPositions;
+
+ targetSizes.push_back( Vector3( 100.0f, 100.0f, 100.0f ) );
+ targetSizes.push_back( Vector3( 50.0f, 10.0f, 100.0f ) );
+
+ targetPositions.push_back( Vector3( 200.0f, 1.0f, 100.0f ) );
+
+ tet_infoline("Set initial position and set up animation to re-position actor");
+
+ Actor actor = Actor::New();
+ Stage::GetCurrent().Add(actor);
+ Vector3 initialSize( 10.0f, 10.0f, 10.0f);
+ Vector3 initialPosition(10.0f, 10.0f, 10.0f);
+
+ actor.SetProperty( Actor::Property::SIZE, initialSize );
+ actor.SetProperty( Actor::Property::POSITION, initialPosition );
+
+ // Build the animation
+ Animation animation = Animation::New(2.0f);
+
+ tet_infoline("Set target size in animation without intiating play");
+ animation.AnimateTo(Property(actor, Actor::Property::SIZE), targetSizes[0], AlphaFunction::LINEAR);
+ tet_infoline("Set target position in animation without intiating play");
+ animation.AnimateTo(Property(actor, Actor::Property::POSITION), targetPositions[0], AlphaFunction::LINEAR);
+ animation.AnimateTo(Property(actor, Actor::Property::SIZE), targetSizes[1], AlphaFunction::LINEAR);
+
+ application.SendNotification();
+ application.Render();
+
+ tet_infoline("Ensure position of actor is still at intial size and position");
+
+ DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::SIZE_WIDTH), initialSize.x, TEST_LOCATION );
+ DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::SIZE_HEIGHT), initialSize.y, TEST_LOCATION );
+ DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::SIZE_DEPTH), initialSize.z, TEST_LOCATION );
+
+ DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::SIZE_WIDTH), initialPosition.x, TEST_LOCATION );
+ DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::SIZE_HEIGHT), initialPosition.y, TEST_LOCATION );
+ DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::SIZE_DEPTH), initialPosition.z, TEST_LOCATION );
+
+ tet_infoline("Play animation and ensure actor position and size is now matches targets");
+
+ animation.Play();
+ application.SendNotification();
+ application.Render(2000u);
+
+ tet_infoline("Ensure position and size of actor is at target value when aninmation playing");
+
+ DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::SIZE_WIDTH), targetSizes[1].x, TEST_LOCATION );
+ DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::SIZE_HEIGHT), targetSizes[1].y, TEST_LOCATION );
+ DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::SIZE_DEPTH), targetSizes[1].z, TEST_LOCATION );
+
+ DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::POSITION_X), targetPositions[0].x, TEST_LOCATION );
+ DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::POSITION_Y), targetPositions[0].y, TEST_LOCATION );
+ DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::POSITION_Z), targetPositions[0].z, TEST_LOCATION );
+
+ END_TEST;
+}
+
+int UtcDaliAnimationSetAndGetTargetBeforePlayMulitpleAnimatorsSizeAndPositionColourP(void)
+{
+ tet_infoline("Setting up an animation should not effect it's size property until the animation plays even if other Properties animated");
+
+ TestApplication application;
+
+ std::vector<Vector3> targetSizes;
+ std::vector<float> targetColors;
+
+ targetSizes.push_back( Vector3( 100.0f, 100.0f, 100.0f ) );
+ targetSizes.push_back( Vector3( 50.0f, 10.0f, 150.0f ) );
+
+ targetColors.push_back( 1.0f );
+
+ tet_infoline("Set initial position and set up animation to re-position actor");
+
+ Actor actor = Actor::New();
+ Stage::GetCurrent().Add(actor);
+ Vector3 initialSize( 10.0f, 5.0f, 10.0f);
+
+ actor.SetProperty( Actor::Property::SIZE, initialSize );
+
+ // Build the animation
+ Animation animation = Animation::New(2.0f);
+
+ tet_infoline("Set target size in animation without intiating play");
+ animation.AnimateTo(Property(actor, Actor::Property::SIZE), targetSizes[0], AlphaFunction::LINEAR);
+ tet_infoline("Set target position in animation without intiating play");
+ animation.AnimateTo(Property(actor, Actor::Property::COLOR_RED), targetColors[0], AlphaFunction::LINEAR);
+ animation.AnimateTo(Property(actor, Actor::Property::SIZE), targetSizes[1], AlphaFunction::LINEAR);
+
+ application.SendNotification();
+ application.Render();
+
+ tet_infoline("Ensure position of actor is still at intial size and position");
+
+ DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::SIZE_WIDTH), initialSize.x, TEST_LOCATION );
+ DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::SIZE_HEIGHT), initialSize.y, TEST_LOCATION );
+ DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::SIZE_DEPTH), initialSize.z, TEST_LOCATION );
+
+ tet_infoline("Play animation and ensure actor position and size is now matches targets");
+
+ animation.Play();
+ application.SendNotification();
+ application.Render(2000u);
+
+ tet_infoline("Ensure position and size of actor is at target value when aninmation playing");
+
+ DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::SIZE_WIDTH), targetSizes[1].x, TEST_LOCATION );
+ DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::SIZE_HEIGHT), targetSizes[1].y, TEST_LOCATION );
+ DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::SIZE_DEPTH), targetSizes[1].z, TEST_LOCATION );
+
+ DALI_TEST_EQUALS( actor.GetProperty<float>(Actor::Property::COLOR_RED), targetColors[0], TEST_LOCATION );
+
+ END_TEST;
+}