+ if( animator.propertyKey.type == Property::Key::INDEX )
+ {
+ map.Add( animator.propertyKey.indexKey, animator.targetValue );
+ }
+ else
+ {
+ map.Add( animator.propertyKey.stringKey, animator.targetValue );
+ }
+
+ mImpl->mTransform.UpdatePropertyMap( map );
+ }
+
+ SetupTransition( transition, animator, index, animator.initialValue, animator.targetValue );
+ }
+}
+
+void Visual::Base::AnimateMixColorProperty(
+ Dali::Animation& transition,
+ Internal::TransitionData::Animator& animator )
+{
+ Property::Index index = mImpl->mMixColorIndex;
+ bool animateOpacity = false;
+
+ Property::Value initialOpacity;
+ Property::Value targetOpacity;
+ Property::Value initialMixColor;
+ Property::Value targetMixColor;
+
+ if( index != Property::INVALID_INDEX )
+ {
+ Vector4 initialColor;
+ if( animator.initialValue.Get(initialColor) )
+ {
+ if( animator.initialValue.GetType() == Property::VECTOR4 )
+ {
+ // if there is an initial color specifying alpha, test it
+ initialOpacity = initialColor.a;
+ }
+ initialMixColor = Vector3( initialColor );
+ }
+
+ // Set target value into data store
+ if( animator.targetValue.GetType() != Property::NONE )
+ {
+ Vector4 mixColor;
+ animator.targetValue.Get(mixColor);
+ if( animator.targetValue.GetType() == Property::VECTOR4 )
+ {
+ mImpl->mMixColor.a = mixColor.a;
+ targetOpacity = mixColor.a;
+ animateOpacity = true;
+ }
+
+ mImpl->mMixColor.r = mixColor.r;
+ mImpl->mMixColor.g = mixColor.g;
+ mImpl->mMixColor.b = mixColor.b;
+ targetMixColor = Vector3(mixColor);
+ }
+
+ SetupTransition( transition, animator, index, initialMixColor, targetMixColor );
+ if( animateOpacity )
+ {
+ SetupTransition( transition, animator, DevelRenderer::Property::OPACITY, initialOpacity, targetOpacity );
+ }
+ }
+}
+
+Dali::Property Visual::Base::GetPropertyObject(Dali::Property::Key key)
+{
+ if(!mImpl->mRenderer)
+ {
+ Handle handle;
+ return Dali::Property(handle, Property::INVALID_INDEX);
+ }
+
+ // Mix color or opacity cases
+ if(key.type == Property::Key::INDEX)
+ {
+ if(key.indexKey == Toolkit::Visual::Property::MIX_COLOR || (mImpl->mType == Toolkit::Visual::COLOR && key.indexKey == ColorVisual::Property::MIX_COLOR) || (mImpl->mType == Toolkit::Visual::PRIMITIVE && key.indexKey == PrimitiveVisual::Property::MIX_COLOR))
+ {
+ return Dali::Property(mImpl->mRenderer, mImpl->mMixColorIndex);
+ }
+ else if(key.indexKey == Toolkit::Visual::Property::OPACITY)
+ {
+ return Dali::Property(mImpl->mRenderer, DevelRenderer::Property::OPACITY);