X-Git-Url: http://review.tizen.org/git/?a=blobdiff_plain;f=dali-toolkit%2Finternal%2Fvisuals%2Fvisual-base-impl.cpp;h=f0a7af4537ba3ccba64f204ca617eea7758f2a89;hb=refs%2Fchanges%2F46%2F265846%2F1;hp=443c51ccfa28b915c59e9c6fcb6ff66133b0e361;hpb=a7947e5dc3202ed5da5414b8a8db685c8d422a7b;p=platform%2Fcore%2Fuifw%2Fdali-toolkit.git diff --git a/dali-toolkit/internal/visuals/visual-base-impl.cpp b/dali-toolkit/internal/visuals/visual-base-impl.cpp index 443c51c..f0a7af4 100644 --- a/dali-toolkit/internal/visuals/visual-base-impl.cpp +++ b/dali-toolkit/internal/visuals/visual-base-impl.cpp @@ -25,6 +25,7 @@ #include //INTERNAL HEARDER +#include #include #include #include @@ -294,6 +295,11 @@ void Visual::Base::SetProperties(const Property::Map& propertyMap) { mImpl->mBorderlineWidth = width; } + + if(mImpl->mBorderlineWidthIndex != Property::INVALID_INDEX) + { + mImpl->mRenderer.SetProperty(mImpl->mBorderlineWidthIndex, mImpl->mBorderlineWidth); + } break; } case Toolkit::DevelVisual::Property::BORDERLINE_COLOR: @@ -303,6 +309,11 @@ void Visual::Base::SetProperties(const Property::Map& propertyMap) { mImpl->mBorderlineColor = color; } + + if(mImpl->mBorderlineColorIndex != Property::INVALID_INDEX) + { + mImpl->mRenderer.SetProperty(mImpl->mBorderlineColorIndex, mImpl->mBorderlineColor); + } break; } case Toolkit::DevelVisual::Property::BORDERLINE_OFFSET: @@ -312,6 +323,11 @@ void Visual::Base::SetProperties(const Property::Map& propertyMap) { mImpl->mBorderlineOffset = offset; } + + if(mImpl->mBorderlineOffsetIndex != Property::INVALID_INDEX) + { + mImpl->mRenderer.SetProperty(mImpl->mBorderlineOffsetIndex, mImpl->mBorderlineOffset); + } break; } case Toolkit::DevelVisual::Property::CORNER_RADIUS: @@ -337,6 +353,11 @@ void Visual::Base::SetProperties(const Property::Map& propertyMap) mImpl->mCornerRadius = Vector4(radius, radius, radius, radius); } } + + if(mImpl->mCornerRadiusIndex != Property::INVALID_INDEX) + { + mImpl->mRenderer.SetProperty(mImpl->mCornerRadiusIndex, mImpl->mCornerRadius); + } break; } case Toolkit::DevelVisual::Property::CORNER_RADIUS_POLICY: @@ -423,6 +444,20 @@ void Visual::Base::GetNaturalSize(Vector2& naturalSize) void Visual::Base::DoAction(const Property::Index actionId, const Property::Value attributes) { OnDoAction(actionId, attributes); + + // Check if action is valid for this visual type and perform action if possible + switch(actionId) + { + case DevelVisual::Action::UPDATE_PROPERTY: + { + const Property::Map* map = attributes.GetMap(); + if(map) + { + SetProperties(*map); + } + break; + } + } } void Visual::Base::SetDepthIndex(int index)