Further Setter/Getter public API removal from Dali::Actor
[platform/core/uifw/dali-demo.git] / examples / styling / styling-application.cpp
index 4a6c8ea..b386432 100644 (file)
@@ -23,8 +23,8 @@
 #include "styling-application.h"
 
 // External includes
+#include <dali/devel-api/actors/actor-devel.h>
 #include <dali-toolkit/dali-toolkit.h>
-//#include <dali-toolkit/devel-api/controls/slider/slider.h>
 #include <dali-toolkit/devel-api/controls/popup/popup.h>
 #include "image-channel-control.h"
 #include <cstdio>
@@ -113,14 +113,14 @@ void StylingApplication::Create( Application& application )
 
   mContentPane = CreateContentPane();
   stage.Add( mContentPane );
-  mContentPane.SetSize( stage.GetSize() );
+  mContentPane.SetProperty( Actor::Property::SIZE, stage.GetSize() );
 
   // Content panes:
   TableView contentLayout = TableView::New( 5, 1 );
-  contentLayout.SetName("ContentLayout");
+  contentLayout.SetProperty( Dali::Actor::Property::NAME,"ContentLayout");
   contentLayout.SetResizePolicy( ResizePolicy::FILL_TO_PARENT, Dimension::ALL_DIMENSIONS );
-  contentLayout.SetAnchorPoint( AnchorPoint::TOP_LEFT );
-  contentLayout.SetParentOrigin( ParentOrigin::TOP_LEFT );
+  contentLayout.SetProperty( Actor::Property::ANCHOR_POINT, AnchorPoint::TOP_LEFT );
+  contentLayout.SetProperty( Actor::Property::PARENT_ORIGIN, ParentOrigin::TOP_LEFT );
   contentLayout.SetCellPadding( Size( MARGIN_SIZE, MARGIN_SIZE ) );
 
   // Assign all rows the size negotiation property of fitting to children
@@ -135,10 +135,10 @@ void StylingApplication::Create( Application& application )
   mContentPane.Add( contentLayout );
 
   mTitle = TextLabel::New( "Styling Example" );
-  mTitle.SetName( "Title" );
+  mTitle.SetProperty( Dali::Actor::Property::NAME, "Title" );
   mTitle.SetStyleName("Title");
-  mTitle.SetAnchorPoint( AnchorPoint::TOP_CENTER );
-  mTitle.SetParentOrigin( ParentOrigin::TOP_CENTER );
+  mTitle.SetProperty( Actor::Property::ANCHOR_POINT, AnchorPoint::TOP_CENTER );
+  mTitle.SetProperty( Actor::Property::PARENT_ORIGIN, ParentOrigin::TOP_CENTER );
   mTitle.SetResizePolicy( ResizePolicy::FILL_TO_PARENT, Dimension::WIDTH );
   mTitle.SetResizePolicy( ResizePolicy::USE_NATURAL_SIZE, Dimension::HEIGHT );
   mTitle.SetProperty( TextLabel::Property::HORIZONTAL_ALIGNMENT, "CENTER" );
@@ -147,12 +147,12 @@ void StylingApplication::Create( Application& application )
   // Buttons:
 
   TableView imageSelectLayout = TableView::New( 1, 2 );
-  imageSelectLayout.SetName("ImageSelectLayout");
+  imageSelectLayout.SetProperty( Dali::Actor::Property::NAME,"ImageSelectLayout");
 
   imageSelectLayout.SetResizePolicy( ResizePolicy::FILL_TO_PARENT, Dimension::WIDTH );
   imageSelectLayout.SetResizePolicy( ResizePolicy::FILL_TO_PARENT, Dimension::HEIGHT );
-  imageSelectLayout.SetAnchorPoint( AnchorPoint::CENTER );
-  imageSelectLayout.SetParentOrigin( ParentOrigin::CENTER );
+  imageSelectLayout.SetProperty( Actor::Property::ANCHOR_POINT, AnchorPoint::CENTER );
+  imageSelectLayout.SetProperty( Actor::Property::PARENT_ORIGIN, ParentOrigin::CENTER );
   imageSelectLayout.SetCellPadding( Size( MARGIN_SIZE, MARGIN_SIZE ) );
 
   // Fit radio button column to child width, leave image to fill remainder
@@ -161,7 +161,7 @@ void StylingApplication::Create( Application& application )
   contentLayout.Add( imageSelectLayout );
 
   TableView radioButtonsLayout = TableView::New( 3, 2 );
-  radioButtonsLayout.SetName("RadioButtonsLayout");
+  radioButtonsLayout.SetProperty( Dali::Actor::Property::NAME,"RadioButtonsLayout");
   radioButtonsLayout.SetResizePolicy( ResizePolicy::FILL_TO_PARENT, Dimension::HEIGHT );
   // Leave each row to fill to parent height
   // Set each column to fit to child width
@@ -177,17 +177,17 @@ void StylingApplication::Create( Application& application )
   for( int i=0; i<3; ++i )
   {
     std::ostringstream thumbnailName; thumbnailName << "thumbnail" << i+1;
-    ImageView image = ImageView::New( ResourceImage::New( images[i] ) );
-    image.SetName( thumbnailName.str() );
-    image.SetSize( DP(RADIO_LABEL_THUMBNAIL_SIZE), DP(RADIO_LABEL_THUMBNAIL_SIZE) );
+    ImageView image = ImageView::New( images[i] );
+    image.SetProperty( Dali::Actor::Property::NAME, thumbnailName.str() );
+    image.SetProperty( Actor::Property::SIZE, Vector2( DP(RADIO_LABEL_THUMBNAIL_SIZE), DP(RADIO_LABEL_THUMBNAIL_SIZE) ) );
 
     std::ostringstream label; label << (i+1);
     std::ostringstream radioButtonStyleName;
     radioButtonStyleName << "imageSelectButton" << i+1;
     mRadioButtons[i] = RadioButton::New( label.str() );
-    mRadioButtons[i].SetName( radioButtonStyleName.str() );
-    mRadioButtons[i].SetParentOrigin( ParentOrigin::TOP_LEFT );
-    mRadioButtons[i].SetAnchorPoint( AnchorPoint::TOP_LEFT );
+    mRadioButtons[i].SetProperty( Dali::Actor::Property::NAME, radioButtonStyleName.str() );
+    mRadioButtons[i].SetProperty( Actor::Property::PARENT_ORIGIN, ParentOrigin::TOP_LEFT );
+    mRadioButtons[i].SetProperty( Actor::Property::ANCHOR_POINT, AnchorPoint::TOP_LEFT );
     mRadioButtons[i].SetProperty( Button::Property::SELECTED, false );
     mRadioButtons[i].StateChangedSignal().Connect( this, &StylingApplication::OnButtonStateChange );
 
@@ -200,35 +200,35 @@ void StylingApplication::Create( Application& application )
   mRadioButtons[0].SetProperty( Button::Property::SELECTED, true );
 
   mImagePlacement = Actor::New();
-  mImagePlacement.SetParentOrigin( ParentOrigin::CENTER );
-  mImagePlacement.SetAnchorPoint( AnchorPoint::CENTER );
+  mImagePlacement.SetProperty( Actor::Property::PARENT_ORIGIN, ParentOrigin::CENTER );
+  mImagePlacement.SetProperty( Actor::Property::ANCHOR_POINT, AnchorPoint::CENTER );
   mImagePlacement.SetResizePolicy( ResizePolicy::FILL_TO_PARENT, Dimension::ALL_DIMENSIONS );
   imageSelectLayout.AddChild( mImagePlacement, TableView::CellPosition( 0, 1 ) );
   imageSelectLayout.SetCellAlignment( TableView::CellPosition( 0, 1 ), HorizontalAlignment::RIGHT, VerticalAlignment::CENTER );
 
   mIcc1 = ImageChannelControl::New( BIG_IMAGE_1 );
-  mIcc1.SetName("ICC1");
+  mIcc1.SetProperty( Dali::Actor::Property::NAME,"ICC1");
   mIcc1.SetResizePolicy( ResizePolicy::FILL_TO_PARENT , Dimension::ALL_DIMENSIONS );
-  mIcc1.SetSizeScalePolicy( SizeScalePolicy::FIT_WITH_ASPECT_RATIO );
-  mIcc1.SetParentOrigin( ParentOrigin::CENTER );
+  mIcc1.SetProperty( Actor::Property::SIZE_SCALE_POLICY, SizeScalePolicy::FIT_WITH_ASPECT_RATIO );
+  mIcc1.SetProperty( Actor::Property::PARENT_ORIGIN, ParentOrigin::CENTER );
   mIcc1.SetVisibility( true );
-  
+
   mImagePlacement.Add( mIcc1 );
 
   mIcc2 = ImageChannelControl::New( BIG_IMAGE_2 );
-  mIcc2.SetName("ICC2");
+  mIcc2.SetProperty( Dali::Actor::Property::NAME,"ICC2");
   mIcc2.SetResizePolicy( ResizePolicy::FILL_TO_PARENT , Dimension::ALL_DIMENSIONS );
-  mIcc2.SetSizeScalePolicy( SizeScalePolicy::FIT_WITH_ASPECT_RATIO );
-  mIcc2.SetParentOrigin( ParentOrigin::CENTER );
+  mIcc2.SetProperty( Actor::Property::SIZE_SCALE_POLICY, SizeScalePolicy::FIT_WITH_ASPECT_RATIO );
+  mIcc2.SetProperty( Actor::Property::PARENT_ORIGIN, ParentOrigin::CENTER );
   mIcc2.SetVisibility( false );
 
   mImagePlacement.Add( mIcc2 );
 
   mIcc3 = ImageChannelControl::New( BIG_IMAGE_3 );
-  mIcc3.SetName("ICC3");
+  mIcc3.SetProperty( Dali::Actor::Property::NAME,"ICC3");
   mIcc3.SetResizePolicy( ResizePolicy::FILL_TO_PARENT , Dimension::ALL_DIMENSIONS );
-  mIcc3.SetSizeScalePolicy( SizeScalePolicy::FIT_WITH_ASPECT_RATIO );
-  mIcc3.SetParentOrigin( ParentOrigin::CENTER );
+  mIcc3.SetProperty( Actor::Property::SIZE_SCALE_POLICY, SizeScalePolicy::FIT_WITH_ASPECT_RATIO );
+  mIcc3.SetProperty( Actor::Property::PARENT_ORIGIN, ParentOrigin::CENTER );
   mIcc3.SetVisibility( false );
 
   mImagePlacement.Add( mIcc3 );
@@ -236,13 +236,13 @@ void StylingApplication::Create( Application& application )
   mImageChannelControl = mIcc1;
 
   TableView channelSliderLayout = TableView::New( 3, 3 );
-  channelSliderLayout.SetName("ChannelSliderLayout");
+  channelSliderLayout.SetProperty( Dali::Actor::Property::NAME,"ChannelSliderLayout");
 
   // Contains a column of check buttons and a column of sliders for R/G/B
   channelSliderLayout.SetResizePolicy( ResizePolicy::FILL_TO_PARENT, Dimension::WIDTH );
   channelSliderLayout.SetResizePolicy( ResizePolicy::USE_NATURAL_SIZE, Dimension::HEIGHT );
-  channelSliderLayout.SetAnchorPoint( AnchorPoint::CENTER );
-  channelSliderLayout.SetParentOrigin( ParentOrigin::CENTER );
+  channelSliderLayout.SetProperty( Actor::Property::ANCHOR_POINT, AnchorPoint::CENTER );
+  channelSliderLayout.SetProperty( Actor::Property::PARENT_ORIGIN, ParentOrigin::CENTER );
   channelSliderLayout.SetCellPadding( Size( MARGIN_SIZE, MARGIN_SIZE ) );
 
   // Set each row to fit to child height
@@ -262,9 +262,9 @@ void StylingApplication::Create( Application& application )
     std::ostringstream checkBoxStyleName;
     checkBoxStyleName << "channelActiveCheckBox" << i+1;
     mCheckButtons[i] = CheckBoxButton::New();
-    mCheckButtons[i].SetName( checkBoxStyleName.str() );
-    mCheckButtons[i].SetParentOrigin( ParentOrigin::CENTER );
-    mCheckButtons[i].SetAnchorPoint( AnchorPoint::CENTER );
+    mCheckButtons[i].SetProperty( Dali::Actor::Property::NAME, checkBoxStyleName.str() );
+    mCheckButtons[i].SetProperty( Actor::Property::PARENT_ORIGIN, ParentOrigin::CENTER );
+    mCheckButtons[i].SetProperty( Actor::Property::ANCHOR_POINT, AnchorPoint::CENTER );
     mCheckButtons[i].SetProperty( Button::Property::SELECTED, true );
 
     mCheckButtons[i].StateChangedSignal().Connect( this, &StylingApplication::OnCheckButtonChange );
@@ -275,10 +275,10 @@ void StylingApplication::Create( Application& application )
 
     TextLabel label = TextLabel::New( checkboxLabels[i] );
     std::ostringstream labelStyleName; labelStyleName << "ColorLabel" << i+1;
-    label.SetName( labelStyleName.str() );
+    label.SetProperty( Dali::Actor::Property::NAME, labelStyleName.str() );
     label.SetStyleName( labelStyleName.str() );
-    label.SetParentOrigin( ParentOrigin::CENTER );
-    label.SetAnchorPoint ( AnchorPoint::CENTER );
+    label.SetProperty( Actor::Property::PARENT_ORIGIN, ParentOrigin::CENTER );
+    label.SetProperty( Actor::Property::ANCHOR_POINT, AnchorPoint::CENTER );
     label.SetResizePolicy( ResizePolicy::USE_NATURAL_SIZE, Dimension::WIDTH );
     label.SetResizePolicy( ResizePolicy::USE_NATURAL_SIZE, Dimension::HEIGHT );
 
@@ -287,10 +287,10 @@ void StylingApplication::Create( Application& application )
 
     mChannelSliders[i] = Slider::New();
     std::ostringstream sliderStyleName; sliderStyleName << "ColorSlider" << i+1;
-    mChannelSliders[i].SetName( sliderStyleName.str() );
+    mChannelSliders[i].SetProperty( Dali::Actor::Property::NAME, sliderStyleName.str() );
     mChannelSliders[i].SetStyleName( sliderStyleName.str() );
-    mChannelSliders[i].SetParentOrigin( ParentOrigin::CENTER );
-    mChannelSliders[i].SetAnchorPoint ( AnchorPoint::CENTER );
+    mChannelSliders[i].SetProperty( Actor::Property::PARENT_ORIGIN, ParentOrigin::CENTER );
+    mChannelSliders[i].SetProperty( Actor::Property::ANCHOR_POINT, AnchorPoint::CENTER );
     mChannelSliders[i].SetResizePolicy( ResizePolicy::FILL_TO_PARENT, Dimension::WIDTH );
     mChannelSliders[i].SetResizePolicy( ResizePolicy::FIT_TO_CHILDREN , Dimension::HEIGHT );
     mChannelSliders[i].SetProperty( Slider::Property::LOWER_BOUND, 0.0f );
@@ -309,8 +309,8 @@ void StylingApplication::Create( Application& application )
   }
 
   mResetButton = PushButton::New();
-  mResetButton.SetLabelText( "Reset" );
-  mResetButton.SetName("ResetButton");
+  mResetButton.SetProperty( Toolkit::Button::Property::LABEL, "Reset" );
+  mResetButton.SetProperty( Dali::Actor::Property::NAME,"ResetButton");
   mResetButton.SetResizePolicy( ResizePolicy::USE_NATURAL_SIZE, Dimension::ALL_DIMENSIONS );
   mResetButton.ClickedSignal().Connect( this, &StylingApplication::OnResetClicked );
 
@@ -318,11 +318,11 @@ void StylingApplication::Create( Application& application )
   contentLayout.SetCellAlignment( TableView::CellPosition( 3, 0 ), HorizontalAlignment::CENTER, VerticalAlignment::CENTER );
 
   TableView themeButtonLayout = TableView::New( 1, 4 );
-  themeButtonLayout.SetName("ThemeButtonsLayout");
+  themeButtonLayout.SetProperty( Dali::Actor::Property::NAME,"ThemeButtonsLayout");
   themeButtonLayout.SetCellPadding( Vector2( 6.0f, 0.0f ) );
 
-  themeButtonLayout.SetAnchorPoint( AnchorPoint::CENTER );
-  themeButtonLayout.SetParentOrigin( ParentOrigin::CENTER );
+  themeButtonLayout.SetProperty( Actor::Property::ANCHOR_POINT, AnchorPoint::CENTER );
+  themeButtonLayout.SetProperty( Actor::Property::PARENT_ORIGIN, ParentOrigin::CENTER );
   themeButtonLayout.SetResizePolicy( ResizePolicy::FILL_TO_PARENT, Dimension::WIDTH );
   themeButtonLayout.SetResizePolicy( ResizePolicy::FIT_TO_CHILDREN, Dimension::HEIGHT );
   themeButtonLayout.SetCellPadding( Size( MARGIN_SIZE, MARGIN_SIZE ) );
@@ -331,27 +331,27 @@ void StylingApplication::Create( Application& application )
   TextLabel label = TextLabel::New( "Theme: ");
   label.SetResizePolicy( ResizePolicy::USE_NATURAL_SIZE, Dimension::ALL_DIMENSIONS );
   label.SetStyleName("ThemeLabel");
-  label.SetAnchorPoint( AnchorPoint::TOP_CENTER );
-  label.SetParentOrigin( ParentOrigin::TOP_CENTER );
+  label.SetProperty( Actor::Property::ANCHOR_POINT, AnchorPoint::TOP_CENTER );
+  label.SetProperty( Actor::Property::PARENT_ORIGIN, ParentOrigin::TOP_CENTER );
   themeButtonLayout.AddChild( label, TableView::CellPosition( 0, 0 ) );
   themeButtonLayout.SetCellAlignment( TableView::CellPosition( 0, 0 ), HorizontalAlignment::LEFT, VerticalAlignment::CENTER );
 
   for( int i=0; i<3; ++i )
   {
     mThemeButtons[i] = PushButton::New();
-    mThemeButtons[i].SetName("ThemeButton");
+    mThemeButtons[i].SetProperty( Dali::Actor::Property::NAME,"ThemeButton");
     mThemeButtons[i].SetStyleName("ThemeButton");
-    mThemeButtons[i].SetParentOrigin( ParentOrigin::CENTER );
-    mThemeButtons[i].SetAnchorPoint( ParentOrigin::CENTER );
+    mThemeButtons[i].SetProperty( Actor::Property::PARENT_ORIGIN, ParentOrigin::CENTER );
+    mThemeButtons[i].SetProperty( Actor::Property::ANCHOR_POINT, ParentOrigin::CENTER );
     mThemeButtons[i].SetResizePolicy( ResizePolicy::FILL_TO_PARENT, Dimension::WIDTH );
     mThemeButtons[i].SetResizePolicy( ResizePolicy::USE_NATURAL_SIZE, Dimension::HEIGHT );
     mThemeButtons[i].RegisterProperty( "theme", i, Property::READ_WRITE );
     mThemeButtons[i].ClickedSignal().Connect( this, &StylingApplication::OnThemeButtonClicked );
     themeButtonLayout.AddChild( mThemeButtons[i], TableView::CellPosition( 0, 1+i ) );
   }
-  mThemeButtons[0].SetLabelText( "Lite" ); // Lightweight changes on top of Dali
-  mThemeButtons[1].SetLabelText( "App1" ); // Different application style
-  mThemeButtons[2].SetLabelText( "App2" );
+  mThemeButtons[0].SetProperty( Toolkit::Button::Property::LABEL, "Lite" ); // Lightweight changes on top of Dali
+  mThemeButtons[1].SetProperty( Toolkit::Button::Property::LABEL, "App1" ); // Different application style
+  mThemeButtons[2].SetProperty( Toolkit::Button::Property::LABEL, "App2" );
 
   contentLayout.Add( themeButtonLayout );
 }
@@ -359,33 +359,33 @@ void StylingApplication::Create( Application& application )
 Actor StylingApplication::CreateContentPane()
 {
   Toolkit::ImageView contentPane = Toolkit::ImageView::New( BORDER_IMAGE );
-  contentPane.SetName("ContentPane");
-  contentPane.SetParentOrigin( ParentOrigin::CENTER );
-  contentPane.SetAnchorPoint( AnchorPoint::CENTER );
-  contentPane.SetPadding( Padding( BORDER_WIDTH, BORDER_WIDTH, BORDER_WIDTH, BORDER_WIDTH ) );
+  contentPane.SetProperty( Dali::Actor::Property::NAME,"ContentPane");
+  contentPane.SetProperty( Actor::Property::PARENT_ORIGIN, ParentOrigin::CENTER );
+  contentPane.SetProperty( Actor::Property::ANCHOR_POINT, AnchorPoint::CENTER );
+  contentPane.SetProperty( Actor::Property::PADDING, Padding( BORDER_WIDTH, BORDER_WIDTH, BORDER_WIDTH, BORDER_WIDTH ) );
   return contentPane;
 }
 
 Actor StylingApplication::CreateResizableContentPane()
 {
   Toolkit::ImageView contentPane = Toolkit::ImageView::New( BORDER_IMAGE );
-  contentPane.SetName("ContentPane");
-  contentPane.SetParentOrigin( ParentOrigin::CENTER );
-  contentPane.SetAnchorPoint( AnchorPoint::CENTER );
-  contentPane.SetPadding( Padding( BORDER_WIDTH, BORDER_WIDTH, BORDER_WIDTH, BORDER_WIDTH ) );
+  contentPane.SetProperty( Dali::Actor::Property::NAME,"ContentPane");
+  contentPane.SetProperty( Actor::Property::PARENT_ORIGIN, ParentOrigin::CENTER );
+  contentPane.SetProperty( Actor::Property::ANCHOR_POINT, AnchorPoint::CENTER );
+  contentPane.SetProperty( Actor::Property::PADDING, Padding( BORDER_WIDTH, BORDER_WIDTH, BORDER_WIDTH, BORDER_WIDTH ) );
 
   Toolkit::ImageView grabHandle = Toolkit::ImageView::New( RESIZE_HANDLE_IMAGE );
-  grabHandle.SetName("GrabHandle");
+  grabHandle.SetProperty( Dali::Actor::Property::NAME,"GrabHandle");
   grabHandle.SetResizePolicy( ResizePolicy::USE_NATURAL_SIZE, Dimension::ALL_DIMENSIONS );
-  grabHandle.SetParentOrigin( ParentOrigin::BOTTOM_RIGHT );
-  grabHandle.SetAnchorPoint( AnchorPoint::BOTTOM_RIGHT );
-  grabHandle.SetPosition( -BORDER_WIDTH, -BORDER_WIDTH );
-  grabHandle.SetOpacity( 0.6f );
+  grabHandle.SetProperty( Actor::Property::PARENT_ORIGIN, ParentOrigin::BOTTOM_RIGHT );
+  grabHandle.SetProperty( Actor::Property::ANCHOR_POINT, AnchorPoint::BOTTOM_RIGHT );
+  grabHandle.SetProperty( Actor::Property::POSITION, Vector2( -BORDER_WIDTH, -BORDER_WIDTH ));
+  grabHandle.SetProperty( DevelActor::Property::OPACITY, 0.6f );
 
   Layer grabCornerLayer = Layer::New();
-  grabCornerLayer.SetName("GrabCornerLayer");
-  grabCornerLayer.SetParentOrigin( ParentOrigin::BOTTOM_RIGHT );
-  grabCornerLayer.SetAnchorPoint( AnchorPoint::BOTTOM_RIGHT );
+  grabCornerLayer.SetProperty( Dali::Actor::Property::NAME,"GrabCornerLayer");
+  grabCornerLayer.SetProperty( Actor::Property::PARENT_ORIGIN, ParentOrigin::BOTTOM_RIGHT );
+  grabCornerLayer.SetProperty( Actor::Property::ANCHOR_POINT, AnchorPoint::BOTTOM_RIGHT );
   grabCornerLayer.Add( grabHandle );
   contentPane.Add( grabCornerLayer );
 
@@ -401,11 +401,11 @@ Popup StylingApplication::CreateResetPopup()
   Stage stage = Stage::GetCurrent();
 
   Popup popup= Popup::New();
-  popup.SetName("ResetPopup");
+  popup.SetProperty( Dali::Actor::Property::NAME,"ResetPopup");
   popup.SetStyleName("ResetPopup");
-  popup.SetParentOrigin( ParentOrigin::CENTER );
-  popup.SetAnchorPoint( AnchorPoint::CENTER );
-  popup.SetSize( stage.GetSize().width * 0.75f, 0.0f );
+  popup.SetProperty( Actor::Property::PARENT_ORIGIN, ParentOrigin::CENTER );
+  popup.SetProperty( Actor::Property::ANCHOR_POINT, AnchorPoint::CENTER );
+  popup.SetProperty( Actor::Property::SIZE, Vector2( stage.GetSize().width * 0.75f, 0.0f ) );
   popup.SetProperty( Popup::Property::TAIL_VISIBILITY, false );
   popup.OutsideTouchedSignal().Connect( this, &StylingApplication::HidePopup );
   popup.HiddenSignal().Connect( this, &StylingApplication::PopupHidden );
@@ -413,47 +413,47 @@ Popup StylingApplication::CreateResetPopup()
   popup.SetTitle( CreateTitle( "Reset channels" ) );
 
   TextLabel text = TextLabel::New( "This will reset the channel data to full value. Are you sure?" );
-  text.SetName( "PopupContentText" );
+  text.SetProperty( Dali::Actor::Property::NAME, "PopupContentText" );
   text.SetStyleName( "PopupBody" );
   text.SetResizePolicy( ResizePolicy::FILL_TO_PARENT, Dimension::WIDTH );
   text.SetResizePolicy( ResizePolicy::DIMENSION_DEPENDENCY, Dimension::HEIGHT );
   text.SetProperty( TextLabel::Property::MULTI_LINE, true );
-  text.SetPadding( Padding( 10.0f, 10.0f, 20.0f, 0.0f ) );
+  text.SetProperty( Actor::Property::PADDING, Padding( 10.0f, 10.0f, 20.0f, 0.0f ) );
   popup.SetContent( text );
 
   ImageView footer = ImageView::New( DEFAULT_CONTROL_AREA_IMAGE_PATH );
-  footer.SetName( "PopupFooter" );
+  footer.SetProperty( Dali::Actor::Property::NAME, "PopupFooter" );
   footer.SetStyleName( "PopupFooter" );
   footer.SetResizePolicy( ResizePolicy::FILL_TO_PARENT, Dimension::WIDTH );
   footer.SetResizePolicy( ResizePolicy::FIXED, Dimension::HEIGHT );
-  footer.SetSize( 0.0f, 80.0f );
-  footer.SetAnchorPoint( AnchorPoint::CENTER );
-  footer.SetParentOrigin( ParentOrigin::CENTER );
+  footer.SetProperty( Actor::Property::SIZE, Vector2( 0.0f, 80.0f ) );
+  footer.SetProperty( Actor::Property::ANCHOR_POINT, AnchorPoint::CENTER );
+  footer.SetProperty( Actor::Property::PARENT_ORIGIN, ParentOrigin::CENTER );
 
   TableView footerLayout = TableView::New( 1, 2 );
-  footerLayout.SetParentOrigin( ParentOrigin::CENTER );
-  footerLayout.SetAnchorPoint ( AnchorPoint::CENTER );
+  footerLayout.SetProperty( Actor::Property::PARENT_ORIGIN, ParentOrigin::CENTER );
+  footerLayout.SetProperty( Actor::Property::ANCHOR_POINT, AnchorPoint::CENTER );
   footerLayout.SetResizePolicy( ResizePolicy::FILL_TO_PARENT, Dimension::ALL_DIMENSIONS );
 
   PushButton okayButton = PushButton::New();
-  okayButton.SetName( POPUP_CONTROL_OK_NAME );
+  okayButton.SetProperty( Dali::Actor::Property::NAME, POPUP_CONTROL_OK_NAME );
   okayButton.SetStyleName( POPUP_CONTROL_OK_NAME );
-  okayButton.SetLabelText( "Ok!" );
+  okayButton.SetProperty( Toolkit::Button::Property::LABEL, "Ok!" );
   okayButton.ClickedSignal().Connect( this, &StylingApplication::OnReset );
-  okayButton.SetParentOrigin( ParentOrigin::CENTER );
-  okayButton.SetAnchorPoint( AnchorPoint::CENTER );
+  okayButton.SetProperty( Actor::Property::PARENT_ORIGIN, ParentOrigin::CENTER );
+  okayButton.SetProperty( Actor::Property::ANCHOR_POINT, AnchorPoint::CENTER );
   okayButton.SetResizePolicy( ResizePolicy::SIZE_FIXED_OFFSET_FROM_PARENT, Dimension::ALL_DIMENSIONS );
-  okayButton.SetSizeModeFactor( Vector3( -20.0f, -20.0f, 0.0f ) );
+  okayButton.SetProperty( Actor::Property::SIZE_MODE_FACTOR, Vector3( -20.0f, -20.0f, 0.0f ) );
 
   PushButton cancelButton = PushButton::New();
-  cancelButton.SetName( POPUP_CONTROL_CANCEL_NAME );
+  cancelButton.SetProperty( Dali::Actor::Property::NAME, POPUP_CONTROL_CANCEL_NAME );
   cancelButton.SetStyleName( POPUP_CONTROL_CANCEL_NAME );
-  cancelButton.SetLabelText( "Cancel" );
+  cancelButton.SetProperty( Toolkit::Button::Property::LABEL, "Cancel" );
   cancelButton.ClickedSignal().Connect( this, &StylingApplication::OnResetCancelled );
-  cancelButton.SetParentOrigin( ParentOrigin::CENTER );
-  cancelButton.SetAnchorPoint( AnchorPoint::CENTER );
+  cancelButton.SetProperty( Actor::Property::PARENT_ORIGIN, ParentOrigin::CENTER );
+  cancelButton.SetProperty( Actor::Property::ANCHOR_POINT, AnchorPoint::CENTER );
   cancelButton.SetResizePolicy( ResizePolicy::SIZE_FIXED_OFFSET_FROM_PARENT, Dimension::ALL_DIMENSIONS );
-  cancelButton.SetSizeModeFactor( Vector3( -20.0f, -20.0f, 0.0f ) );
+  cancelButton.SetProperty( Actor::Property::SIZE_MODE_FACTOR, Vector3( -20.0f, -20.0f, 0.0f ) );
 
   footerLayout.SetCellAlignment( TableView::CellPosition( 0, 0 ), HorizontalAlignment::CENTER, VerticalAlignment::CENTER );
   footerLayout.SetCellAlignment( TableView::CellPosition( 0, 1 ), HorizontalAlignment::CENTER, VerticalAlignment::CENTER );
@@ -469,7 +469,7 @@ Popup StylingApplication::CreateResetPopup()
 TextLabel StylingApplication::CreateTitle( std::string title )
 {
   TextLabel titleActor = TextLabel::New( title );
-  titleActor.SetName( "titleActor" );
+  titleActor.SetProperty( Dali::Actor::Property::NAME, "titleActor" );
   titleActor.SetStyleName( "PopupTitle" );
   titleActor.SetProperty( TextLabel::Property::HORIZONTAL_ALIGNMENT, "CENTER" );
   titleActor.SetProperty( TextLabel::Property::MULTI_LINE, false );
@@ -484,20 +484,20 @@ bool StylingApplication::OnButtonStateChange( Button button )
 
 // Todo: save / restore slider states per image
 
-  if( button.GetProperty( Toolkit::Button::Property::SELECTED ).Get<bool>() )
+  if( button.GetProperty<bool>(Button::Property::SELECTED) )
   {
 
     ImageChannelControl prevIcc = mImageChannelControl;
 
-    if( mRadioButtons[0].GetProperty( Toolkit::Button::Property::SELECTED ).Get<bool>() )
+    if( mRadioButtons[0].GetProperty<bool>(Button::Property::SELECTED) )
     {
       mImageChannelControl = mIcc1;
     }
-    else if( mRadioButtons[1].GetProperty( Toolkit::Button::Property::SELECTED ).Get<bool>() )
+    else if( mRadioButtons[1].GetProperty<bool>(Button::Property::SELECTED) )
     {
       mImageChannelControl = mIcc2;
     }
-    else if( mRadioButtons[2].GetProperty( Toolkit::Button::Property::SELECTED ).Get<bool>() )
+    else if( mRadioButtons[2].GetProperty<bool>(Button::Property::SELECTED) )
     {
       mImageChannelControl = mIcc3;
     }
@@ -523,7 +523,7 @@ bool StylingApplication::OnCheckButtonChange( Button button )
   {
     int channel = button.GetProperty<int>( index );
     float value = mChannelSliders[channel].GetProperty<float>( Slider::Property::VALUE );
-    if( !button.IsSelected() )
+    if( !button.GetProperty<bool>(Button::Property::SELECTED) )
     {
       // "Turn off" the channel's contribution
       value = 0.0f;
@@ -600,7 +600,7 @@ bool StylingApplication::OnSliderChanged( Slider slider, float value )
   if( index != Property::INVALID_INDEX )
   {
     int channel = slider.GetProperty<int>( index );
-    if( mCheckButtons[channel].IsSelected() )
+    if( mCheckButtons[channel].GetProperty<bool>(Button::Property::SELECTED) )
     {
       Property::Index channelIndex = GetChannelProperty( channel );
       mImageChannelControl.SetProperty(channelIndex, value/100.0f);
@@ -630,7 +630,7 @@ void StylingApplication::PopupHidden()
 void StylingApplication::OnPan( Actor actor, const PanGesture& gesture )
 {
   Vector3 size = mContentPane.GetTargetSize();
-  mContentPane.SetSize( size.GetVectorXY() + gesture.displacement * 2.0f );
+  mContentPane.SetProperty( Actor::Property::SIZE, Vector2( size.GetVectorXY() + gesture.displacement * 2.0f ) );
 }
 
 void StylingApplication::OnKeyEvent( const KeyEvent& keyEvent )