Const correctness improvements for Property::Value. 78/244978/3
authorGyörgy Straub <g.straub@partner.samsung.com>
Mon, 28 Sep 2020 13:14:48 +0000 (14:14 +0100)
committerGyörgy Straub <g.straub@partner.samsung.com>
Mon, 28 Sep 2020 13:42:00 +0000 (14:42 +0100)
Change-Id: Ie802f27afba4069d87b52ba7256410c4f3cec4ab
Signed-off-by: György Straub <g.straub@partner.samsung.com>
examples/simple-visuals-control/my-control-impl.cpp
examples/styling/image-channel-control-impl.cpp
examples/transitions/shadow-button-impl.cpp
examples/visual-transitions/beat-control-impl.cpp

index 6e2b6ed..9074a89 100644 (file)
@@ -88,7 +88,7 @@ void MyControl::SetProperty(BaseObject* object, Property::Index index, const Pro
       {
         Toolkit::Visual::Base  iconVisual;
         Toolkit::VisualFactory visualFactory = Toolkit::VisualFactory::Get();
-        Property::Map*         map           = value.GetMap();
+        const Property::Map*   map           = value.GetMap();
         if(map && !map->Empty())
         {
           iconVisual = visualFactory.CreateVisual(*map);
index fc20650..5b64dd6 100644 (file)
@@ -228,7 +228,7 @@ void ImageChannelControl::SetProperty(BaseObject* object, Property::Index index,
       }
       case Demo::ImageChannelControl::Property::IMAGE_VISUAL:
       {
-        Property::Map* map = value.GetMap();
+        const Property::Map* map = value.GetMap();
         if(map)
         {
           impl.mVisual = Toolkit::VisualFactory::Get().CreateVisual(*map);
index 1b1ece8..17cd0f4 100644 (file)
@@ -336,7 +336,7 @@ void ShadowButton::ResetVisual(
     // we are replacing an existing visual, so force relayout
     RelayoutRequest();
   }
-  Property::Map* map = value.GetMap();
+  const Property::Map* map = value.GetMap();
   if(map)
   {
     visual = Toolkit::VisualFactory::Get().CreateVisual(*map);
index 770b4c6..9dc35f4 100644 (file)
@@ -249,7 +249,7 @@ void BeatControl::SetProperty(BaseObject* object, Property::Index index, const P
 
         // Determine if a transform.size property exists in the map, and
         // save it.
-        Property::Map* map = value.GetMap();
+        const Property::Map* map = value.GetMap();
         if(map)
         {
           Property::Value* value = map->Find(Visual::Property::TRANSFORM, "transform");