Commit a79f0d43e94c3b5e9f50f209ea66ee4b2c6b0e89

Authored by Richard Huang
2 parents ee35102c c27ee116

[dali_1.0.50] Merge branch 'devel/master'

Change-Id: Ie3455de5c35e480ca9aae279d17e9fca8ce0b964
demo/dali-table-view.cpp
@@ -88,10 +88,10 @@ const float BUBBLE_MAX_Z = 0.0f; @@ -88,10 +88,10 @@ const float BUBBLE_MAX_Z = 0.0f;
88 /** 88 /**
89 * Creates the background image 89 * Creates the background image
90 */ 90 */
91 -ImageActor CreateBackground( std::string imagePath ) 91 +ImageView CreateBackground( std::string imagePath )
92 { 92 {
93 Image image = ResourceImage::New( imagePath ); 93 Image image = ResourceImage::New( imagePath );
94 - ImageActor background = ImageActor::New( image ); 94 + ImageView background = ImageView::New( image );
95 background.SetName( "BACKGROUND" ); 95 background.SetName( "BACKGROUND" );
96 background.SetAnchorPoint( AnchorPoint::CENTER ); 96 background.SetAnchorPoint( AnchorPoint::CENTER );
97 background.SetParentOrigin( ParentOrigin::CENTER ); 97 background.SetParentOrigin( ParentOrigin::CENTER );
@@ -153,7 +153,6 @@ DaliTableView::DaliTableView( Application& application ) @@ -153,7 +153,6 @@ DaliTableView::DaliTableView( Application& application )
153 mBackgroundLayer(), 153 mBackgroundLayer(),
154 mRootActor(), 154 mRootActor(),
155 mRotateAnimation(), 155 mRotateAnimation(),
156 - mBackground(),  
157 mPressedAnimation(), 156 mPressedAnimation(),
158 mScrollViewLayer(), 157 mScrollViewLayer(),
159 mScrollView(), 158 mScrollView(),
@@ -209,7 +208,7 @@ void DaliTableView::Initialize( Application& application ) @@ -209,7 +208,7 @@ void DaliTableView::Initialize( Application& application )
209 const Vector2 stageSize = Stage::GetCurrent().GetSize(); 208 const Vector2 stageSize = Stage::GetCurrent().GetSize();
210 209
211 // Background 210 // Background
212 - Actor background = CreateBackground( mBackgroundImagePath ); 211 + ImageView background = CreateBackground( mBackgroundImagePath );
213 Stage::GetCurrent().Add( background ); 212 Stage::GetCurrent().Add( background );
214 213
215 // Render entire content as overlays, as is all on same 2D plane. 214 // Render entire content as overlays, as is all on same 2D plane.
@@ -230,7 +229,7 @@ void DaliTableView::Initialize( Application& application ) @@ -230,7 +229,7 @@ void DaliTableView::Initialize( Application& application )
230 mRootActor.SetFitHeight( 0 ); 229 mRootActor.SetFitHeight( 0 );
231 230
232 // Add logo 231 // Add logo
233 - Dali::ImageActor logo = CreateLogo( LOGO_PATH ); 232 + ImageView logo = CreateLogo( LOGO_PATH );
234 logo.SetName( "LOGO_IMAGE" ); 233 logo.SetName( "LOGO_IMAGE" );
235 logo.SetResizePolicy( ResizePolicy::USE_NATURAL_SIZE, Dimension::ALL_DIMENSIONS ); 234 logo.SetResizePolicy( ResizePolicy::USE_NATURAL_SIZE, Dimension::ALL_DIMENSIONS );
236 const float paddingHeight = ( ( 1.f-TABLE_RELATIVE_SIZE.y ) * stageSize.y ); 235 const float paddingHeight = ( ( 1.f-TABLE_RELATIVE_SIZE.y ) * stageSize.y );
@@ -848,10 +847,10 @@ void DaliTableView::GenerateCircle( const Size& size, std::vector< unsigned char @@ -848,10 +847,10 @@ void DaliTableView::GenerateCircle( const Size& size, std::vector< unsigned char
848 } 847 }
849 } 848 }
850 849
851 -ImageActor DaliTableView::CreateLogo( std::string imagePath ) 850 +ImageView DaliTableView::CreateLogo( std::string imagePath )
852 { 851 {
853 Image image = ResourceImage::New( imagePath ); 852 Image image = ResourceImage::New( imagePath );
854 - ImageActor logo = ImageActor::New( image ); 853 + ImageView logo = ImageView::New( image );
855 854
856 logo.SetAnchorPoint( AnchorPoint::CENTER ); 855 logo.SetAnchorPoint( AnchorPoint::CENTER );
857 logo.SetParentOrigin( ParentOrigin::CENTER ); 856 logo.SetParentOrigin( ParentOrigin::CENTER );
demo/dali-table-view.h
@@ -318,7 +318,7 @@ private: // Application callbacks & implementation @@ -318,7 +318,7 @@ private: // Application callbacks & implementation
318 * 318 *
319 * @return The created image actor 319 * @return The created image actor
320 */ 320 */
321 - Dali::ImageActor CreateLogo( std::string imagePath ); 321 + Dali::Toolkit::ImageView CreateLogo( std::string imagePath );
322 322
323 /** 323 /**
324 * Timer handler for ending background animation 324 * Timer handler for ending background animation
@@ -392,7 +392,6 @@ private: @@ -392,7 +392,6 @@ private:
392 Dali::Layer mBackgroundLayer; ///< Background resides on a separate layer. 392 Dali::Layer mBackgroundLayer; ///< Background resides on a separate layer.
393 Dali::Toolkit::TableView mRootActor; ///< All content (excluding background is anchored to this Actor) 393 Dali::Toolkit::TableView mRootActor; ///< All content (excluding background is anchored to this Actor)
394 Dali::Animation mRotateAnimation; ///< Animation to rotate and resize mRootActor. 394 Dali::Animation mRotateAnimation; ///< Animation to rotate and resize mRootActor.
395 - Dali::ImageActor mBackground; ///< Background's static image.  
396 Dali::Animation mPressedAnimation; ///< Button press scaling animation. 395 Dali::Animation mPressedAnimation; ///< Button press scaling animation.
397 Dali::Layer mScrollViewLayer; ///< ScrollView resides on a separate layer. 396 Dali::Layer mScrollViewLayer; ///< ScrollView resides on a separate layer.
398 Dali::Toolkit::ScrollView mScrollView; ///< ScrollView container (for all Examples) 397 Dali::Toolkit::ScrollView mScrollView; ///< ScrollView container (for all Examples)
examples/atlas/atlas-example.cpp
@@ -72,8 +72,8 @@ public: @@ -72,8 +72,8 @@ public:
72 "Atlas" ); 72 "Atlas" );
73 73
74 mLoseContextButton = Toolkit::PushButton::New(); 74 mLoseContextButton = Toolkit::PushButton::New();
75 - mLoseContextButton.SetButtonImage( ResourceImage::New( LOSE_CONTEXT_IMAGE ) );  
76 - mLoseContextButton.SetSelectedImage( ResourceImage::New( LOSE_CONTEXT_IMAGE_SELECTED ) ); 75 + mLoseContextButton.SetUnselectedImage( LOSE_CONTEXT_IMAGE );
  76 + mLoseContextButton.SetSelectedImage( LOSE_CONTEXT_IMAGE_SELECTED );
77 mLoseContextButton.ClickedSignal().Connect( this, &AtlasController::OnLoseContextButtonClicked ); 77 mLoseContextButton.ClickedSignal().Connect( this, &AtlasController::OnLoseContextButtonClicked );
78 mToolBar.AddControl( mLoseContextButton, DemoHelper::DEFAULT_VIEW_STYLE.mToolBarButtonPercentage, Toolkit::Alignment::HorizontalRight, DemoHelper::DEFAULT_MODE_SWITCH_PADDING ); 78 mToolBar.AddControl( mLoseContextButton, DemoHelper::DEFAULT_VIEW_STYLE.mToolBarButtonPercentage, Toolkit::Alignment::HorizontalRight, DemoHelper::DEFAULT_MODE_SWITCH_PADDING );
79 79
@@ -90,7 +90,7 @@ public: @@ -90,7 +90,7 @@ public:
90 mAtlas.Upload( DALI_IMAGE_DIR "icon-item-view-layout-spiral.png", 250, 130 ); 90 mAtlas.Upload( DALI_IMAGE_DIR "icon-item-view-layout-spiral.png", 250, 130 );
91 UploadBufferImages(); 91 UploadBufferImages();
92 92
93 - ImageActor imageActor1 = ImageActor::New( mAtlas ); 93 + Toolkit::ImageView imageActor1 = Toolkit::ImageView::New( mAtlas );
94 imageActor1.SetY(-170.f); 94 imageActor1.SetY(-170.f);
95 imageActor1.SetParentOrigin(ParentOrigin::CENTER); 95 imageActor1.SetParentOrigin(ParentOrigin::CENTER);
96 mContentLayer.Add( imageActor1 ); 96 mContentLayer.Add( imageActor1 );
@@ -109,19 +109,20 @@ public: @@ -109,19 +109,20 @@ public:
109 atlas2.Upload( DALI_IMAGE_DIR "gallery-small-7.jpg", 268, 268 ); 109 atlas2.Upload( DALI_IMAGE_DIR "gallery-small-7.jpg", 268, 268 );
110 110
111 111
112 - ImageActor imageActor2 = ImageActor::New( atlas2 );  
113 - imageActor2.SetY(200.f);  
114 - imageActor2.SetZ(-1.f);  
115 - imageActor2.SetParentOrigin(ParentOrigin::CENTER);  
116 - mContentLayer.Add( imageActor2 ); 112 + Toolkit::ImageView imageView = Toolkit::ImageView::New( DALI_IMAGE_DIR "gallery-small-1.jpg" );
  113 +
  114 + imageView.SetY(200.f);
  115 + imageView.SetZ(-1.f);
  116 + imageView.SetParentOrigin(ParentOrigin::CENTER);
  117 + mContentLayer.Add( imageView );
117 118
118 mPanGestureDetector = PanGestureDetector::New(); 119 mPanGestureDetector = PanGestureDetector::New();
119 - mPanGestureDetector.DetectedSignal().Connect(this, &AtlasController::OnPanGesture);  
120 - mPanGestureDetector.Attach(imageActor1);  
121 - mPanGestureDetector.Attach(imageActor2); 120 + mPanGestureDetector.DetectedSignal().Connect( this, &AtlasController::OnPanGesture );
  121 + mPanGestureDetector.Attach( imageActor1 );
  122 + mPanGestureDetector.Attach( imageView );
122 123
123 - stage.ContextLostSignal().Connect(this, &AtlasController::OnContextLost);  
124 - stage.ContextRegainedSignal().Connect(this, &AtlasController::OnContextRegained); 124 + stage.ContextLostSignal().Connect( this, &AtlasController::OnContextLost );
  125 + stage.ContextRegainedSignal().Connect( this, &AtlasController::OnContextRegained );
125 } 126 }
126 127
127 void UploadBufferImages() 128 void UploadBufferImages()
examples/blocks/blocks-example.cpp
@@ -523,7 +523,7 @@ private: @@ -523,7 +523,7 @@ private:
523 const Vector2 brickSize(BRICK_SIZE * Vector2(stageSize.x, stageSize.x)); 523 const Vector2 brickSize(BRICK_SIZE * Vector2(stageSize.x, stageSize.x));
524 524
525 Image img = ResourceImage::New( BRICK_IMAGE_PATH[type], Dali::ImageDimensions( 128, 64 ), Dali::FittingMode::SCALE_TO_FILL, Dali::SamplingMode::BOX_THEN_LINEAR ); 525 Image img = ResourceImage::New( BRICK_IMAGE_PATH[type], Dali::ImageDimensions( 128, 64 ), Dali::FittingMode::SCALE_TO_FILL, Dali::SamplingMode::BOX_THEN_LINEAR );
526 - ImageActor brick = ImageActor::New(img); 526 + ImageView brick = ImageView::New(img);
527 brick.SetParentOrigin(ParentOrigin::TOP_LEFT); 527 brick.SetParentOrigin(ParentOrigin::TOP_LEFT);
528 brick.SetAnchorPoint(AnchorPoint::CENTER); 528 brick.SetAnchorPoint(AnchorPoint::CENTER);
529 brick.SetSize( brickSize ); 529 brick.SetSize( brickSize );
@@ -551,10 +551,9 @@ private: @@ -551,10 +551,9 @@ private:
551 * 551 *
552 * @param[in] filename the path of the image. 552 * @param[in] filename the path of the image.
553 */ 553 */
554 - ImageActor CreateImage(const std::string& filename) 554 + ImageView CreateImage(const std::string& filename)
555 { 555 {
556 - Image img = ResourceImage::New(filename);  
557 - ImageActor actor = ImageActor::New(img); 556 + ImageView actor = ImageView::New(filename);
558 actor.SetParentOrigin(ParentOrigin::TOP_LEFT); 557 actor.SetParentOrigin(ParentOrigin::TOP_LEFT);
559 actor.SetAnchorPoint(AnchorPoint::CENTER); 558 actor.SetAnchorPoint(AnchorPoint::CENTER);
560 return actor; 559 return actor;
@@ -806,13 +805,13 @@ private: @@ -806,13 +805,13 @@ private:
806 Application& mApplication; ///< Application instance 805 Application& mApplication; ///< Application instance
807 Toolkit::Control mView; ///< The View instance. 806 Toolkit::Control mView; ///< The View instance.
808 Layer mContentLayer; ///< The content layer (contains game actors) 807 Layer mContentLayer; ///< The content layer (contains game actors)
809 - ImageActor mBall; ///< The Moving ball image. 808 + ImageView mBall; ///< The Moving ball image.
810 Vector3 mBallStartPosition; ///< Ball Start position 809 Vector3 mBallStartPosition; ///< Ball Start position
811 Vector3 mBallVelocity; ///< Ball's current direction. 810 Vector3 mBallVelocity; ///< Ball's current direction.
812 Animation mBallAnimation; ///< Ball's animation 811 Animation mBallAnimation; ///< Ball's animation
813 Actor mPaddle; ///< The paddle including hit area. 812 Actor mPaddle; ///< The paddle including hit area.
814 - ImageActor mPaddleImage; ///< The paddle's image.  
815 - ImageActor mPaddleHandle; ///< The paddle's handle (where the user touches) 813 + ImageView mPaddleImage; ///< The paddle's image.
  814 + ImageView mPaddleHandle; ///< The paddle's handle (where the user touches)
816 Vector2 mPaddleHitMargin; ///< The paddle hit margin. 815 Vector2 mPaddleHitMargin; ///< The paddle hit margin.
817 Animation mWobbleAnimation; ///< Paddle's animation when hit (wobbles) 816 Animation mWobbleAnimation; ///< Paddle's animation when hit (wobbles)
818 Property::Index mWobbleProperty; ///< The wobble property (generated from animation) 817 Property::Index mWobbleProperty; ///< The wobble property (generated from animation)
examples/bubble-effect/bubble-effect-example.cpp
@@ -111,8 +111,8 @@ private: @@ -111,8 +111,8 @@ private:
111 111
112 // Add a button to change background. (right of toolbar) 112 // Add a button to change background. (right of toolbar)
113 mChangeBackgroundButton = Toolkit::PushButton::New(); 113 mChangeBackgroundButton = Toolkit::PushButton::New();
114 - mChangeBackgroundButton.SetButtonImage( ResourceImage::New( CHANGE_BACKGROUND_ICON ) );  
115 - mChangeBackgroundButton.SetSelectedImage( ResourceImage::New( CHANGE_BACKGROUND_ICON_SELECTED ) ); 114 + mChangeBackgroundButton.SetUnselectedImage( CHANGE_BACKGROUND_ICON );
  115 + mChangeBackgroundButton.SetSelectedImage( CHANGE_BACKGROUND_ICON_SELECTED );
116 mChangeBackgroundButton.ClickedSignal().Connect( this, &BubbleEffectExample::OnChangeIconClicked ); 116 mChangeBackgroundButton.ClickedSignal().Connect( this, &BubbleEffectExample::OnChangeIconClicked );
117 toolBar.AddControl( mChangeBackgroundButton, 117 toolBar.AddControl( mChangeBackgroundButton,
118 DemoHelper::DEFAULT_VIEW_STYLE.mToolBarButtonPercentage, 118 DemoHelper::DEFAULT_VIEW_STYLE.mToolBarButtonPercentage,
@@ -120,8 +120,8 @@ private: @@ -120,8 +120,8 @@ private:
120 DemoHelper::DEFAULT_MODE_SWITCH_PADDING ); 120 DemoHelper::DEFAULT_MODE_SWITCH_PADDING );
121 // Add a button to change bubble shape. ( left of bar ) 121 // Add a button to change bubble shape. ( left of bar )
122 mChangeBubbleShapeButton = Toolkit::PushButton::New(); 122 mChangeBubbleShapeButton = Toolkit::PushButton::New();
123 - mChangeBubbleShapeButton.SetButtonImage( ResourceImage::New( CHANGE_BUBBLE_SHAPE_ICON ) );  
124 - mChangeBubbleShapeButton.SetSelectedImage( ResourceImage::New( CHANGE_BUBBLE_SHAPE_ICON_SELECTED ) ); 123 + mChangeBubbleShapeButton.SetUnselectedImage( CHANGE_BUBBLE_SHAPE_ICON );
  124 + mChangeBubbleShapeButton.SetSelectedImage( CHANGE_BUBBLE_SHAPE_ICON_SELECTED );
125 mChangeBubbleShapeButton.ClickedSignal().Connect( this, &BubbleEffectExample::OnChangeIconClicked ); 125 mChangeBubbleShapeButton.ClickedSignal().Connect( this, &BubbleEffectExample::OnChangeIconClicked );
126 toolBar.AddControl( mChangeBubbleShapeButton, 126 toolBar.AddControl( mChangeBubbleShapeButton,
127 DemoHelper::DEFAULT_VIEW_STYLE.mToolBarButtonPercentage, 127 DemoHelper::DEFAULT_VIEW_STYLE.mToolBarButtonPercentage,
examples/builder/examples.cpp
@@ -513,8 +513,8 @@ public: @@ -513,8 +513,8 @@ public:
513 513
514 // Create an edit mode button. (left of toolbar) 514 // Create an edit mode button. (left of toolbar)
515 Toolkit::PushButton editButton = Toolkit::PushButton::New(); 515 Toolkit::PushButton editButton = Toolkit::PushButton::New();
516 - editButton.SetButtonImage( ResourceImage::New( EDIT_IMAGE ) );  
517 - editButton.SetSelectedImage( ResourceImage::New( EDIT_IMAGE_SELECTED ) ); 516 + editButton.SetUnselectedImage( EDIT_IMAGE );
  517 + editButton.SetSelectedImage( EDIT_IMAGE_SELECTED );
518 editButton.ClickedSignal().Connect( this, &ExampleApp::OnToolSelectLayout); 518 editButton.ClickedSignal().Connect( this, &ExampleApp::OnToolSelectLayout);
519 editButton.SetLeaveRequired( true ); 519 editButton.SetLeaveRequired( true );
520 mToolBar.AddControl( editButton, DemoHelper::DEFAULT_VIEW_STYLE.mToolBarButtonPercentage, Toolkit::Alignment::HorizontalLeft, DemoHelper::DEFAULT_MODE_SWITCH_PADDING ); 520 mToolBar.AddControl( editButton, DemoHelper::DEFAULT_VIEW_STYLE.mToolBarButtonPercentage, Toolkit::Alignment::HorizontalLeft, DemoHelper::DEFAULT_MODE_SWITCH_PADDING );
examples/buttons/buttons-example.cpp
@@ -49,6 +49,7 @@ const Vector4 BACKGROUND_COLOUR( 1.0f, 1.0f, 1.0f, 0.15f ); @@ -49,6 +49,7 @@ const Vector4 BACKGROUND_COLOUR( 1.0f, 1.0f, 1.0f, 0.15f );
49 49
50 // Layout sizes 50 // Layout sizes
51 const int RADIO_LABEL_THUMBNAIL_SIZE = 60; 51 const int RADIO_LABEL_THUMBNAIL_SIZE = 60;
  52 +const int RADIO_LABEL_THUMBNAIL_SIZE_SMALL = 40;
52 const int RADIO_IMAGE_SPACING = 8; 53 const int RADIO_IMAGE_SPACING = 8;
53 const int BUTTON_HEIGHT = 48; 54 const int BUTTON_HEIGHT = 48;
54 55
@@ -141,54 +142,71 @@ class ButtonsController: public ConnectionTracker @@ -141,54 +142,71 @@ class ButtonsController: public ConnectionTracker
141 142
142 radioGroup2Background.AddChild( radioButtonsGroup2, Toolkit::TableView::CellPosition( 0, 0 ) ); 143 radioGroup2Background.AddChild( radioButtonsGroup2, Toolkit::TableView::CellPosition( 0, 0 ) );
143 144
  145 + // TableView to lay out 3x Radio buttons on the left, and 3x Image thumbnails on the right.
  146 + Toolkit::TableView imageSelectTableView = Toolkit::TableView::New( 3, 2 );
  147 + imageSelectTableView.SetResizePolicy( ResizePolicy::USE_NATURAL_SIZE, Dimension::ALL_DIMENSIONS );
  148 + imageSelectTableView.SetFitHeight( 0 );
  149 + imageSelectTableView.SetFitHeight( 1 );
  150 + imageSelectTableView.SetFitHeight( 2 );
  151 + imageSelectTableView.SetFitWidth( 0 );
  152 + imageSelectTableView.SetFitWidth( 1 );
  153 + imageSelectTableView.SetCellPadding( Vector2( 6.0f, 0.0f ) );
  154 +
  155 + radioButtonsGroup2.Add( imageSelectTableView );
  156 +
144 int radioY = 0; 157 int radioY = 0;
145 158
146 // Radio 1 159 // Radio 1
147 { 160 {
148 - ImageActor imageActor = ImageActor::New( ResourceImage::New( SMALL_IMAGE_1 ) );  
149 - imageActor.SetSize( DP(RADIO_LABEL_THUMBNAIL_SIZE), DP(RADIO_LABEL_THUMBNAIL_SIZE) );  
150 - mRadioButtonImage1 = Dali::Toolkit::RadioButton::New( imageActor ); 161 + ImageActor image = ImageActor::New( ResourceImage::New( SMALL_IMAGE_1 ) );
  162 + image.SetSize( DP(RADIO_LABEL_THUMBNAIL_SIZE), DP(RADIO_LABEL_THUMBNAIL_SIZE) );
  163 +
  164 + mRadioButtonImage1 = Dali::Toolkit::RadioButton::New( "1" );
151 mRadioButtonImage1.SetParentOrigin( ParentOrigin::TOP_LEFT ); 165 mRadioButtonImage1.SetParentOrigin( ParentOrigin::TOP_LEFT );
152 mRadioButtonImage1.SetAnchorPoint( AnchorPoint::TOP_LEFT ); 166 mRadioButtonImage1.SetAnchorPoint( AnchorPoint::TOP_LEFT );
153 mRadioButtonImage1.SetPosition( 0, DP(radioY) ); 167 mRadioButtonImage1.SetPosition( 0, DP(radioY) );
154 mRadioButtonImage1.SetSelected( true ); 168 mRadioButtonImage1.SetSelected( true );
155 169
156 - radioButtonsGroup2.Add( mRadioButtonImage1 ); 170 + imageSelectTableView.AddChild( mRadioButtonImage1, Toolkit::TableView::CellPosition( 0, 0 ) );
  171 + imageSelectTableView.AddChild( image, Toolkit::TableView::CellPosition( 0, 1 ) );
157 } 172 }
158 173
159 // Radio 2 174 // Radio 2
160 { 175 {
161 radioY += RADIO_LABEL_THUMBNAIL_SIZE + RADIO_IMAGE_SPACING; 176 radioY += RADIO_LABEL_THUMBNAIL_SIZE + RADIO_IMAGE_SPACING;
162 177
163 - ImageActor imageActor = ImageActor::New( ResourceImage::New( SMALL_IMAGE_2 ) );  
164 - imageActor.SetSize( DP(RADIO_LABEL_THUMBNAIL_SIZE), DP(RADIO_LABEL_THUMBNAIL_SIZE) ); 178 + ImageActor image = ImageActor::New( ResourceImage::New( SMALL_IMAGE_2 ) );
  179 + image.SetSize( DP(RADIO_LABEL_THUMBNAIL_SIZE), DP(RADIO_LABEL_THUMBNAIL_SIZE) );
165 180
166 - mRadioButtonImage2 = Dali::Toolkit::RadioButton::New( imageActor ); 181 + mRadioButtonImage2 = Dali::Toolkit::RadioButton::New( "2" );
167 mRadioButtonImage2.SetParentOrigin( ParentOrigin::TOP_LEFT ); 182 mRadioButtonImage2.SetParentOrigin( ParentOrigin::TOP_LEFT );
168 mRadioButtonImage2.SetAnchorPoint( AnchorPoint::TOP_LEFT ); 183 mRadioButtonImage2.SetAnchorPoint( AnchorPoint::TOP_LEFT );
169 mRadioButtonImage2.SetPosition( 0, DP(radioY) ); 184 mRadioButtonImage2.SetPosition( 0, DP(radioY) );
170 185
171 - radioButtonsGroup2.Add( mRadioButtonImage2 ); 186 + imageSelectTableView.AddChild( mRadioButtonImage2, Toolkit::TableView::CellPosition( 1, 0 ) );
  187 + imageSelectTableView.AddChild( image, Toolkit::TableView::CellPosition( 1, 1 ) );
172 } 188 }
173 189
174 // Radio 3 190 // Radio 3
175 { 191 {
176 radioY += RADIO_LABEL_THUMBNAIL_SIZE + RADIO_IMAGE_SPACING; 192 radioY += RADIO_LABEL_THUMBNAIL_SIZE + RADIO_IMAGE_SPACING;
177 193
178 - ImageActor imageActor = ImageActor::New( ResourceImage::New( SMALL_IMAGE_3 ) );  
179 - imageActor.SetSize( DP(RADIO_LABEL_THUMBNAIL_SIZE), DP(RADIO_LABEL_THUMBNAIL_SIZE) ); 194 + ImageActor image = ImageActor::New( ResourceImage::New( SMALL_IMAGE_3 ) );
  195 + image.SetSize( DP(RADIO_LABEL_THUMBNAIL_SIZE), DP(RADIO_LABEL_THUMBNAIL_SIZE) );
180 196
181 - mRadioButtonImage3 = Dali::Toolkit::RadioButton::New( imageActor ); 197 + mRadioButtonImage3 = Dali::Toolkit::RadioButton::New( "3" );
182 mRadioButtonImage3.SetParentOrigin( ParentOrigin::TOP_LEFT ); 198 mRadioButtonImage3.SetParentOrigin( ParentOrigin::TOP_LEFT );
183 mRadioButtonImage3.SetAnchorPoint( AnchorPoint::TOP_LEFT ); 199 mRadioButtonImage3.SetAnchorPoint( AnchorPoint::TOP_LEFT );
184 mRadioButtonImage3.SetPosition( 0, DP(radioY) ); 200 mRadioButtonImage3.SetPosition( 0, DP(radioY) );
185 201
186 - radioButtonsGroup2.Add( mRadioButtonImage3 ); 202 + imageSelectTableView.AddChild( mRadioButtonImage3, Toolkit::TableView::CellPosition( 2, 0 ) );
  203 + imageSelectTableView.AddChild( image, Toolkit::TableView::CellPosition( 2, 1 ) );
187 } 204 }
188 205
189 // Create select button 206 // Create select button
190 mUpdateButton = Toolkit::PushButton::New(); 207 mUpdateButton = Toolkit::PushButton::New();
191 - mUpdateButton.SetLabel( "Select" ); 208 + mUpdateButton.SetLabelText( "Select" );
  209 + mUpdateButton.SetName( "select-button" );
192 mUpdateButton.SetResizePolicy( ResizePolicy::USE_NATURAL_SIZE, Dimension::ALL_DIMENSIONS ); 210 mUpdateButton.SetResizePolicy( ResizePolicy::USE_NATURAL_SIZE, Dimension::ALL_DIMENSIONS );
193 211
194 mUpdateButton.ClickedSignal().Connect( this, &ButtonsController::OnButtonClicked ); 212 mUpdateButton.ClickedSignal().Connect( this, &ButtonsController::OnButtonClicked );
@@ -227,26 +245,29 @@ class ButtonsController: public ConnectionTracker @@ -227,26 +245,29 @@ class ButtonsController: public ConnectionTracker
227 245
228 radioGroup1Background.Add( radioButtonsGroup1 ); 246 radioGroup1Background.Add( radioButtonsGroup1 );
229 247
  248 + // TableView to lay out 2x Radio buttons on the left, and 1x Tick image on the right.
  249 + Toolkit::TableView tableView = Toolkit::TableView::New( 2, 2 );
  250 + tableView.SetResizePolicy( ResizePolicy::USE_NATURAL_SIZE, Dimension::ALL_DIMENSIONS );
  251 + tableView.SetFitHeight( 0 );
  252 + tableView.SetFitHeight( 1 );
  253 + tableView.SetFitWidth( 0 );
  254 + tableView.SetFitWidth( 1 );
  255 +
  256 + Toolkit::TextLabel textLabel = Toolkit::TextLabel::New( "Select enabled" );
  257 + textLabel.SetResizePolicy( ResizePolicy::USE_NATURAL_SIZE, Dimension::WIDTH );
  258 + textLabel.SetResizePolicy( ResizePolicy::FILL_TO_PARENT, Dimension::HEIGHT );
  259 + textLabel.SetProperty( Toolkit::TextLabel::Property::VERTICAL_ALIGNMENT, "CENTER" );
  260 +
  261 + ImageActor imageActor = ImageActor::New( ResourceImage::New( ENABLED_IMAGE ) );
  262 + imageActor.SetSize( DP(RADIO_LABEL_THUMBNAIL_SIZE), DP(RADIO_LABEL_THUMBNAIL_SIZE) );
  263 + imageActor.SetPadding( Padding( DP(20.0f), 0.0f, 0.0f, 0.0f ) );
  264 + tableView.AddChild( imageActor, Toolkit::TableView::CellPosition( 0, 1 ) );
  265 +
  266 + radioButtonsGroup1.Add( tableView );
  267 +
230 // First radio button 268 // First radio button
231 { 269 {
232 - Toolkit::TableView tableView = Toolkit::TableView::New( 1, 2 );  
233 - tableView.SetResizePolicy( ResizePolicy::USE_NATURAL_SIZE, Dimension::ALL_DIMENSIONS );  
234 - tableView.SetFitHeight( 0 );  
235 - tableView.SetFitWidth( 0 );  
236 - tableView.SetFitWidth( 1 );  
237 -  
238 - Toolkit::TextLabel textLabel = Toolkit::TextLabel::New( "Select enabled" );  
239 - textLabel.SetResizePolicy( ResizePolicy::USE_NATURAL_SIZE, Dimension::WIDTH );  
240 - textLabel.SetResizePolicy( ResizePolicy::FILL_TO_PARENT, Dimension::HEIGHT );  
241 - textLabel.SetProperty( Toolkit::TextLabel::Property::VERTICAL_ALIGNMENT, "CENTER" );  
242 - tableView.AddChild( textLabel, Toolkit::TableView::CellPosition( 0, 0 ) );  
243 -  
244 - ImageActor imageActor = ImageActor::New( ResourceImage::New( ENABLED_IMAGE ) );  
245 - imageActor.SetSize( DP(RADIO_LABEL_THUMBNAIL_SIZE), DP(RADIO_LABEL_THUMBNAIL_SIZE) );  
246 - imageActor.SetPadding( Padding( DP(20.0f), 0.0f, 0.0f, 0.0f ) );  
247 - tableView.AddChild( imageActor, Toolkit::TableView::CellPosition( 0, 1 ) );  
248 -  
249 - Toolkit::RadioButton radioButton = Dali::Toolkit::RadioButton::New( tableView ); 270 + Toolkit::RadioButton radioButton = Dali::Toolkit::RadioButton::New( "Select enabled" );
250 radioButton.SetName( "radio-select-enable" ); 271 radioButton.SetName( "radio-select-enable" );
251 radioButton.SetParentOrigin( ParentOrigin::TOP_LEFT ); 272 radioButton.SetParentOrigin( ParentOrigin::TOP_LEFT );
252 radioButton.SetAnchorPoint( AnchorPoint::TOP_LEFT ); 273 radioButton.SetAnchorPoint( AnchorPoint::TOP_LEFT );
@@ -255,7 +276,7 @@ class ButtonsController: public ConnectionTracker @@ -255,7 +276,7 @@ class ButtonsController: public ConnectionTracker
255 276
256 radioButton.StateChangedSignal().Connect( this, &ButtonsController::EnableSelectButton ); 277 radioButton.StateChangedSignal().Connect( this, &ButtonsController::EnableSelectButton );
257 278
258 - radioButtonsGroup1.Add( radioButton ); 279 + tableView.AddChild( radioButton, Toolkit::TableView::CellPosition( 0, 0 ) );
259 } 280 }
260 281
261 // Second radio button 282 // Second radio button
@@ -268,7 +289,7 @@ class ButtonsController: public ConnectionTracker @@ -268,7 +289,7 @@ class ButtonsController: public ConnectionTracker
268 289
269 radioButton.StateChangedSignal().Connect( this, &ButtonsController::EnableSelectButton ); 290 radioButton.StateChangedSignal().Connect( this, &ButtonsController::EnableSelectButton );
270 291
271 - radioButtonsGroup1.Add( radioButton ); 292 + tableView.AddChild( radioButton, Toolkit::TableView::CellPosition( 1, 0 ) );
272 } 293 }
273 294
274 // CheckBoxes 295 // CheckBoxes
@@ -276,7 +297,7 @@ class ButtonsController: public ConnectionTracker @@ -276,7 +297,7 @@ class ButtonsController: public ConnectionTracker
276 checkBoxBackground.SetResizePolicy( ResizePolicy::FILL_TO_PARENT, Dimension::WIDTH ); 297 checkBoxBackground.SetResizePolicy( ResizePolicy::FILL_TO_PARENT, Dimension::WIDTH );
277 checkBoxBackground.SetResizePolicy( ResizePolicy::USE_NATURAL_SIZE, Dimension::HEIGHT ); 298 checkBoxBackground.SetResizePolicy( ResizePolicy::USE_NATURAL_SIZE, Dimension::HEIGHT );
278 checkBoxBackground.SetBackgroundColor( BACKGROUND_COLOUR ); 299 checkBoxBackground.SetBackgroundColor( BACKGROUND_COLOUR );
279 - checkBoxBackground.SetCellPadding( Size( MARGIN_SIZE, MARGIN_SIZE ) ); 300 + checkBoxBackground.SetCellPadding( Size( MARGIN_SIZE / 2.0f, MARGIN_SIZE / 2.0f ) );
280 301
281 for( unsigned int i = 0; i < checkBoxBackground.GetRows(); ++i ) 302 for( unsigned int i = 0; i < checkBoxBackground.GetRows(); ++i )
282 { 303 {
@@ -288,7 +309,7 @@ class ButtonsController: public ConnectionTracker @@ -288,7 +309,7 @@ class ButtonsController: public ConnectionTracker
288 { 309 {
289 mCheckboxButton1 = Toolkit::CheckBoxButton::New(); 310 mCheckboxButton1 = Toolkit::CheckBoxButton::New();
290 mCheckboxButton1.SetName( "checkbox1" ); 311 mCheckboxButton1.SetName( "checkbox1" );
291 - mCheckboxButton1.SetLabel( "CheckBox1 is unselected" ); 312 + mCheckboxButton1.SetLabelText( "CheckBox1 is unselected" );
292 mCheckboxButton1.StateChangedSignal().Connect( this, &ButtonsController::OnCheckBoxesSelected ); 313 mCheckboxButton1.StateChangedSignal().Connect( this, &ButtonsController::OnCheckBoxesSelected );
293 314
294 checkBoxBackground.Add( mCheckboxButton1 ); 315 checkBoxBackground.Add( mCheckboxButton1 );
@@ -297,7 +318,7 @@ class ButtonsController: public ConnectionTracker @@ -297,7 +318,7 @@ class ButtonsController: public ConnectionTracker
297 { 318 {
298 mCheckboxButton2 = Toolkit::CheckBoxButton::New(); 319 mCheckboxButton2 = Toolkit::CheckBoxButton::New();
299 mCheckboxButton2.SetName( "checkbox2" ); 320 mCheckboxButton2.SetName( "checkbox2" );
300 - mCheckboxButton2.SetLabel( "CheckBox2 is selected" ); 321 + mCheckboxButton2.SetLabelText( "CheckBox2 is selected" );
301 mCheckboxButton2.SetSelected( true ); 322 mCheckboxButton2.SetSelected( true );
302 mCheckboxButton2.StateChangedSignal().Connect( this, &ButtonsController::OnCheckBoxesSelected ); 323 mCheckboxButton2.StateChangedSignal().Connect( this, &ButtonsController::OnCheckBoxesSelected );
303 324
@@ -307,7 +328,7 @@ class ButtonsController: public ConnectionTracker @@ -307,7 +328,7 @@ class ButtonsController: public ConnectionTracker
307 { 328 {
308 mCheckboxButton3 = Toolkit::CheckBoxButton::New(); 329 mCheckboxButton3 = Toolkit::CheckBoxButton::New();
309 mCheckboxButton3.SetName( "checkbox3" ); 330 mCheckboxButton3.SetName( "checkbox3" );
310 - mCheckboxButton3.SetLabel( "CheckBox3 is unselected" ); 331 + mCheckboxButton3.SetLabelText( "CheckBox3 is unselected" );
311 mCheckboxButton3.StateChangedSignal().Connect( this, &ButtonsController::OnCheckBoxesSelected ); 332 mCheckboxButton3.StateChangedSignal().Connect( this, &ButtonsController::OnCheckBoxesSelected );
312 333
313 checkBoxBackground.Add( mCheckboxButton3 ); 334 checkBoxBackground.Add( mCheckboxButton3 );
@@ -329,7 +350,7 @@ class ButtonsController: public ConnectionTracker @@ -329,7 +350,7 @@ class ButtonsController: public ConnectionTracker
329 350
330 mToggleButton = Toolkit::PushButton::New(); 351 mToggleButton = Toolkit::PushButton::New();
331 mToggleButton.SetTogglableButton( true ); 352 mToggleButton.SetTogglableButton( true );
332 - mToggleButton.SetLabel( "Unselected" ); 353 + mToggleButton.SetLabelText( "Unselected" );
333 mToggleButton.SetResizePolicy( ResizePolicy::FILL_TO_PARENT, Dimension::WIDTH ); 354 mToggleButton.SetResizePolicy( ResizePolicy::FILL_TO_PARENT, Dimension::WIDTH );
334 mToggleButton.SetResizePolicy( ResizePolicy::USE_NATURAL_SIZE, Dimension::HEIGHT ); 355 mToggleButton.SetResizePolicy( ResizePolicy::USE_NATURAL_SIZE, Dimension::HEIGHT );
335 mToggleButton.StateChangedSignal().Connect( this, &ButtonsController::OnButtonSelected ); 356 mToggleButton.StateChangedSignal().Connect( this, &ButtonsController::OnButtonSelected );
@@ -356,11 +377,11 @@ class ButtonsController: public ConnectionTracker @@ -356,11 +377,11 @@ class ButtonsController: public ConnectionTracker
356 { 377 {
357 if( button.IsSelected() ) 378 if( button.IsSelected() )
358 { 379 {
359 - pushButton.SetLabel( "Selected" ); 380 + pushButton.SetLabelText( "Selected" );
360 } 381 }
361 else 382 else
362 { 383 {
363 - pushButton.SetLabel( "Unselected" ); 384 + pushButton.SetLabelText( "Unselected" );
364 } 385 }
365 } 386 }
366 387
@@ -424,11 +445,11 @@ class ButtonsController: public ConnectionTracker @@ -424,11 +445,11 @@ class ButtonsController: public ConnectionTracker
424 { 445 {
425 if( button.IsSelected() ) 446 if( button.IsSelected() )
426 { 447 {
427 - button.SetLabel("CheckBox1 is selected"); 448 + button.SetLabelText("CheckBox1 is selected");
428 } 449 }
429 else 450 else
430 { 451 {
431 - button.SetLabel("CheckBox1 is unselected"); 452 + button.SetLabelText("CheckBox1 is unselected");
432 } 453 }
433 } 454 }
434 455
@@ -436,11 +457,11 @@ class ButtonsController: public ConnectionTracker @@ -436,11 +457,11 @@ class ButtonsController: public ConnectionTracker
436 { 457 {
437 if( button.IsSelected() ) 458 if( button.IsSelected() )
438 { 459 {
439 - button.SetLabel("CheckBox2 is selected"); 460 + button.SetLabelText("CheckBox2 is selected");
440 } 461 }
441 else 462 else
442 { 463 {
443 - button.SetLabel("CheckBox2 is unselected"); 464 + button.SetLabelText("CheckBox2 is unselected");
444 } 465 }
445 } 466 }
446 467
@@ -448,11 +469,11 @@ class ButtonsController: public ConnectionTracker @@ -448,11 +469,11 @@ class ButtonsController: public ConnectionTracker
448 { 469 {
449 if( button.IsSelected() ) 470 if( button.IsSelected() )
450 { 471 {
451 - button.SetLabel("CheckBox3 is selected"); 472 + button.SetLabelText("CheckBox3 is selected");
452 } 473 }
453 else 474 else
454 { 475 {
455 - button.SetLabel("CheckBox3 is unselected"); 476 + button.SetLabelText("CheckBox3 is unselected");
456 } 477 }
457 } 478 }
458 479
examples/cluster/cluster-example.cpp
@@ -325,8 +325,8 @@ struct ShrinkConstraint @@ -325,8 +325,8 @@ struct ShrinkConstraint
325 325
326 struct ButtonImages 326 struct ButtonImages
327 { 327 {
328 - Image mButtonImage;  
329 - Image mSelectedImage; 328 + std::string mButtonImage;
  329 + std::string mSelectedImage;
330 }; 330 };
331 331
332 332
@@ -390,14 +390,14 @@ public: @@ -390,14 +390,14 @@ public:
390 mContentLayer.SetProperty(Layer::Property::BEHAVIOR, "Dali::Layer::LAYER_3D"); 390 mContentLayer.SetProperty(Layer::Property::BEHAVIOR, "Dali::Layer::LAYER_3D");
391 391
392 // Create a effect toggle button. (right of toolbar) 392 // Create a effect toggle button. (right of toolbar)
393 - mLayoutButtonImages[ NO_EFFECT ].mButtonImage = ResourceImage::New( LAYOUT_NONE_IMAGE );  
394 - mLayoutButtonImages[ NO_EFFECT ].mSelectedImage = ResourceImage::New( LAYOUT_NONE_IMAGE_SELECTED );  
395 - mLayoutButtonImages[ MOTION_BLUR_EFFECT ].mButtonImage = ResourceImage::New( LAYOUT_MOTION_BLUR_IMAGE );  
396 - mLayoutButtonImages[ MOTION_BLUR_EFFECT ].mSelectedImage = ResourceImage::New( LAYOUT_MOTION_BLUR_IMAGE_SELECTED );  
397 - mLayoutButtonImages[ CAROUSEL_EFFECT ].mButtonImage = ResourceImage::New( LAYOUT_CAROUSEL_IMAGE );  
398 - mLayoutButtonImages[ CAROUSEL_EFFECT ].mSelectedImage = ResourceImage::New( LAYOUT_CAROUSEL_IMAGE_SELECTED );  
399 - mLayoutButtonImages[ SPHERE_EFFECT ].mButtonImage = ResourceImage::New( LAYOUT_SPHERE_IMAGE );  
400 - mLayoutButtonImages[ SPHERE_EFFECT ].mSelectedImage = ResourceImage::New( LAYOUT_SPHERE_IMAGE_SELECTED ); 393 + mLayoutButtonImages[ NO_EFFECT ].mButtonImage = LAYOUT_NONE_IMAGE;
  394 + mLayoutButtonImages[ NO_EFFECT ].mSelectedImage = LAYOUT_NONE_IMAGE_SELECTED;
  395 + mLayoutButtonImages[ MOTION_BLUR_EFFECT ].mButtonImage = LAYOUT_MOTION_BLUR_IMAGE;
  396 + mLayoutButtonImages[ MOTION_BLUR_EFFECT ].mSelectedImage = LAYOUT_MOTION_BLUR_IMAGE_SELECTED;
  397 + mLayoutButtonImages[ CAROUSEL_EFFECT ].mButtonImage = LAYOUT_CAROUSEL_IMAGE;
  398 + mLayoutButtonImages[ CAROUSEL_EFFECT ].mSelectedImage = LAYOUT_CAROUSEL_IMAGE_SELECTED;
  399 + mLayoutButtonImages[ SPHERE_EFFECT ].mButtonImage = LAYOUT_SPHERE_IMAGE;
  400 + mLayoutButtonImages[ SPHERE_EFFECT ].mSelectedImage = LAYOUT_SPHERE_IMAGE_SELECTED;
401 401
402 mLayoutButton = Toolkit::PushButton::New(); 402 mLayoutButton = Toolkit::PushButton::New();
403 mLayoutButton.ClickedSignal().Connect( this, &ClusterController::OnEffectTouched ); 403 mLayoutButton.ClickedSignal().Connect( this, &ClusterController::OnEffectTouched );
@@ -631,7 +631,7 @@ public: @@ -631,7 +631,7 @@ public:
631 // Remove all shader-effects from mScrollView and it's children (the clusters) 631 // Remove all shader-effects from mScrollView and it's children (the clusters)
632 mScrollView.SetPosition(Vector3::ZERO); 632 mScrollView.SetPosition(Vector3::ZERO);
633 633
634 - mLayoutButton.SetButtonImage( mLayoutButtonImages[ type ].mButtonImage ); 634 + mLayoutButton.SetUnselectedImage( mLayoutButtonImages[ type ].mButtonImage );
635 mLayoutButton.SetSelectedImage( mLayoutButtonImages[ type ].mSelectedImage ); 635 mLayoutButton.SetSelectedImage( mLayoutButtonImages[ type ].mSelectedImage );
636 636
637 for( std::vector<ClusterInfo>::iterator i = mClusterInfo.begin(); i != mClusterInfo.end(); ++i ) 637 for( std::vector<ClusterInfo>::iterator i = mClusterInfo.begin(); i != mClusterInfo.end(); ++i )
examples/cube-transition-effect/cube-transition-effect-example.cpp
@@ -201,20 +201,10 @@ private: @@ -201,20 +201,10 @@ private:
201 bool mSlideshow; 201 bool mSlideshow;
202 Timer mViewTimer; 202 Timer mViewTimer;
203 Toolkit::PushButton mSlideshowButton; 203 Toolkit::PushButton mSlideshowButton;
204 - Image mIconSlideshowStart;  
205 - Image mIconSlideshowStartSelected;  
206 - Image mIconSlideshowStop;  
207 - Image mIconSlideshowStopSelected;  
208 204
209 Vector2 mPanPosition; 205 Vector2 mPanPosition;
210 Vector2 mPanDisplacement; 206 Vector2 mPanDisplacement;
211 207
212 - Image mImageWave;  
213 - Image mImageWaveSelected;  
214 - Image mImageCross;  
215 - Image mImageCrossSelected;  
216 - Image mImageFold;  
217 - Image mImageFoldSelected;  
218 Toolkit::PushButton mEffectChangeButton; 208 Toolkit::PushButton mEffectChangeButton;
219 }; 209 };
220 210
@@ -241,15 +231,9 @@ void CubeTransitionApp::OnInit( Application&amp; application ) @@ -241,15 +231,9 @@ void CubeTransitionApp::OnInit( Application&amp; application )
241 mContent.SetBehavior( Layer::LAYER_3D ); 231 mContent.SetBehavior( Layer::LAYER_3D );
242 232
243 // Add an effect-changing button on the right of the tool bar. 233 // Add an effect-changing button on the right of the tool bar.
244 - mImageWave = ResourceImage::New( EFFECT_WAVE_IMAGE );  
245 - mImageWaveSelected = ResourceImage::New( EFFECT_WAVE_IMAGE_SELECTED );  
246 - mImageCross = ResourceImage::New( EFFECT_CROSS_IMAGE );  
247 - mImageCrossSelected = ResourceImage::New( EFFECT_CROSS_IMAGE_SELECTED );  
248 - mImageFold = ResourceImage::New( EFFECT_FOLD_IMAGE );  
249 - mImageFoldSelected = ResourceImage::New( EFFECT_FOLD_IMAGE_SELECTED );  
250 mEffectChangeButton = Toolkit::PushButton::New(); 234 mEffectChangeButton = Toolkit::PushButton::New();
251 - mEffectChangeButton.SetButtonImage( mImageWave );  
252 - mEffectChangeButton.SetSelectedImage( mImageWaveSelected ); 235 + mEffectChangeButton.SetUnselectedImage( EFFECT_WAVE_IMAGE );
  236 + mEffectChangeButton.SetSelectedImage( EFFECT_WAVE_IMAGE_SELECTED );
253 mEffectChangeButton.ClickedSignal().Connect( this, &CubeTransitionApp::OnEffectButtonClicked ); 237 mEffectChangeButton.ClickedSignal().Connect( this, &CubeTransitionApp::OnEffectButtonClicked );
254 mToolBar.AddControl( mEffectChangeButton, DemoHelper::DEFAULT_VIEW_STYLE.mToolBarButtonPercentage, Toolkit::Alignment::HorizontalRight, DemoHelper::DEFAULT_MODE_SWITCH_PADDING ); 238 mToolBar.AddControl( mEffectChangeButton, DemoHelper::DEFAULT_VIEW_STYLE.mToolBarButtonPercentage, Toolkit::Alignment::HorizontalRight, DemoHelper::DEFAULT_MODE_SWITCH_PADDING );
255 239
@@ -258,13 +242,9 @@ void CubeTransitionApp::OnInit( Application&amp; application ) @@ -258,13 +242,9 @@ void CubeTransitionApp::OnInit( Application&amp; application )
258 mToolBar.AddControl( mTitleActor, DemoHelper::DEFAULT_VIEW_STYLE.mToolBarTitlePercentage, Toolkit::Alignment::HorizontalCenter ); 242 mToolBar.AddControl( mTitleActor, DemoHelper::DEFAULT_VIEW_STYLE.mToolBarTitlePercentage, Toolkit::Alignment::HorizontalCenter );
259 243
260 //Add an slideshow icon on the right of the title 244 //Add an slideshow icon on the right of the title
261 - mIconSlideshowStart = ResourceImage::New( SLIDE_SHOW_START_ICON );  
262 - mIconSlideshowStartSelected = ResourceImage::New( SLIDE_SHOW_START_ICON_SELECTED );  
263 - mIconSlideshowStop = ResourceImage::New( SLIDE_SHOW_STOP_ICON );  
264 - mIconSlideshowStopSelected = ResourceImage::New( SLIDE_SHOW_STOP_ICON_SELECTED );  
265 mSlideshowButton = Toolkit::PushButton::New(); 245 mSlideshowButton = Toolkit::PushButton::New();
266 - mSlideshowButton.SetButtonImage( mIconSlideshowStart );  
267 - mSlideshowButton.SetSelectedImage( mIconSlideshowStartSelected ); 246 + mSlideshowButton.SetUnselectedImage( SLIDE_SHOW_START_ICON );
  247 + mSlideshowButton.SetSelectedImage( SLIDE_SHOW_START_ICON_SELECTED );
268 mSlideshowButton.ClickedSignal().Connect( this, &CubeTransitionApp::OnSildeshowButtonClicked ); 248 mSlideshowButton.ClickedSignal().Connect( this, &CubeTransitionApp::OnSildeshowButtonClicked );
269 mToolBar.AddControl( mSlideshowButton, DemoHelper::DEFAULT_VIEW_STYLE.mToolBarButtonPercentage, Toolkit::Alignment::HorizontalCenter, DemoHelper::DEFAULT_PLAY_PADDING ); 249 mToolBar.AddControl( mSlideshowButton, DemoHelper::DEFAULT_VIEW_STYLE.mToolBarButtonPercentage, Toolkit::Alignment::HorizontalCenter, DemoHelper::DEFAULT_PLAY_PADDING );
270 250
@@ -375,23 +355,23 @@ bool CubeTransitionApp::OnEffectButtonClicked( Toolkit::Button button ) @@ -375,23 +355,23 @@ bool CubeTransitionApp::OnEffectButtonClicked( Toolkit::Button button )
375 { 355 {
376 mCurrentEffect = mCubeCrossEffect; 356 mCurrentEffect = mCubeCrossEffect;
377 mTitleActor.SetProperty( TextLabel::Property::TEXT, std::string(APPLICATION_TITLE_CROSS) ); 357 mTitleActor.SetProperty( TextLabel::Property::TEXT, std::string(APPLICATION_TITLE_CROSS) );
378 - mEffectChangeButton.SetButtonImage( mImageCross );  
379 - mEffectChangeButton.SetSelectedImage( mImageCrossSelected ); 358 + mEffectChangeButton.SetUnselectedImage( EFFECT_CROSS_IMAGE );
  359 + mEffectChangeButton.SetSelectedImage( EFFECT_CROSS_IMAGE_SELECTED );
380 360
381 } 361 }
382 else if(mCurrentEffect == mCubeCrossEffect) 362 else if(mCurrentEffect == mCubeCrossEffect)
383 { 363 {
384 mCurrentEffect = mCubeFoldEffect; 364 mCurrentEffect = mCubeFoldEffect;
385 mTitleActor.SetProperty( TextLabel::Property::TEXT, std::string(APPLICATION_TITLE_FOLD) ); 365 mTitleActor.SetProperty( TextLabel::Property::TEXT, std::string(APPLICATION_TITLE_FOLD) );
386 - mEffectChangeButton.SetButtonImage( mImageFold );  
387 - mEffectChangeButton.SetSelectedImage( mImageFoldSelected ); 366 + mEffectChangeButton.SetUnselectedImage( EFFECT_FOLD_IMAGE );
  367 + mEffectChangeButton.SetSelectedImage( EFFECT_FOLD_IMAGE_SELECTED );
388 } 368 }
389 else 369 else
390 { 370 {
391 mCurrentEffect = mCubeWaveEffect; 371 mCurrentEffect = mCubeWaveEffect;
392 mTitleActor.SetProperty( TextLabel::Property::TEXT, std::string(APPLICATION_TITLE_WAVE) ); 372 mTitleActor.SetProperty( TextLabel::Property::TEXT, std::string(APPLICATION_TITLE_WAVE) );
393 - mEffectChangeButton.SetButtonImage( mImageWave );  
394 - mEffectChangeButton.SetSelectedImage( mImageWaveSelected ); 373 + mEffectChangeButton.SetUnselectedImage( EFFECT_WAVE_IMAGE );
  374 + mEffectChangeButton.SetSelectedImage( EFFECT_WAVE_IMAGE_SELECTED );
395 } 375 }
396 376
397 // Set the current image to cube transition effect 377 // Set the current image to cube transition effect
@@ -406,8 +386,8 @@ bool CubeTransitionApp::OnSildeshowButtonClicked( Toolkit::Button button ) @@ -406,8 +386,8 @@ bool CubeTransitionApp::OnSildeshowButtonClicked( Toolkit::Button button )
406 if( mSlideshow ) 386 if( mSlideshow )
407 { 387 {
408 mPanGestureDetector.Detach( mParent ); 388 mPanGestureDetector.Detach( mParent );
409 - mSlideshowButton.SetButtonImage( mIconSlideshowStop );  
410 - mSlideshowButton.SetSelectedImage( mIconSlideshowStopSelected ); 389 + mSlideshowButton.SetUnselectedImage( SLIDE_SHOW_STOP_ICON );
  390 + mSlideshowButton.SetSelectedImage( SLIDE_SHOW_STOP_ICON_SELECTED );
411 mPanPosition = Vector2( mViewSize.width, mViewSize.height*0.5f ); 391 mPanPosition = Vector2( mViewSize.width, mViewSize.height*0.5f );
412 mPanDisplacement = Vector2( -10.f, 0.f ); 392 mPanDisplacement = Vector2( -10.f, 0.f );
413 mViewTimer.Start(); 393 mViewTimer.Start();
@@ -415,8 +395,8 @@ bool CubeTransitionApp::OnSildeshowButtonClicked( Toolkit::Button button ) @@ -415,8 +395,8 @@ bool CubeTransitionApp::OnSildeshowButtonClicked( Toolkit::Button button )
415 else 395 else
416 { 396 {
417 mPanGestureDetector.Attach( mParent ); 397 mPanGestureDetector.Attach( mParent );
418 - mSlideshowButton.SetButtonImage( mIconSlideshowStart );  
419 - mSlideshowButton.SetSelectedImage( mIconSlideshowStartSelected ); 398 + mSlideshowButton.SetUnselectedImage( SLIDE_SHOW_START_ICON );
  399 + mSlideshowButton.SetSelectedImage( SLIDE_SHOW_START_ICON_SELECTED );
420 mViewTimer.Stop(); 400 mViewTimer.Stop();
421 } 401 }
422 return true; 402 return true;
examples/dissolve-effect/dissolve-effect-example.cpp
@@ -180,16 +180,8 @@ private: @@ -180,16 +180,8 @@ private:
180 bool mTimerReady; 180 bool mTimerReady;
181 unsigned int mCentralLineIndex; 181 unsigned int mCentralLineIndex;
182 182
183 - Image mIconPlay;  
184 - Image mIconPlaySelected;  
185 - Image mIconStop;  
186 - Image mIconStopSelected;  
187 Toolkit::PushButton mPlayStopButton; 183 Toolkit::PushButton mPlayStopButton;
188 184
189 - Image mIconHighP;  
190 - Image mIconHighPSelected;  
191 - Image mIconMediumP;  
192 - Image mIconMediumPSelected;  
193 Toolkit::PushButton mEffectChangeButton; 185 Toolkit::PushButton mEffectChangeButton;
194 }; 186 };
195 187
@@ -218,13 +210,9 @@ void DissolveEffectApp::OnInit( Application&amp; application ) @@ -218,13 +210,9 @@ void DissolveEffectApp::OnInit( Application&amp; application )
218 mContent = DemoHelper::CreateView( application, mView,mToolBar, "", TOOLBAR_IMAGE, "" ); 210 mContent = DemoHelper::CreateView( application, mView,mToolBar, "", TOOLBAR_IMAGE, "" );
219 211
220 // Add an effect-changing button on the right of the tool bar. 212 // Add an effect-changing button on the right of the tool bar.
221 - mIconHighP = ResourceImage::New( EFFECT_HIGHP_IMAGE );  
222 - mIconHighPSelected = ResourceImage::New( EFFECT_HIGHP_IMAGE_SELECTED );  
223 - mIconMediumP = ResourceImage::New( EFFECT_MEDIUMP_IMAGE );  
224 - mIconMediumPSelected = ResourceImage::New( EFFECT_MEDIUMP_IMAGE_SELECTED );  
225 mEffectChangeButton = Toolkit::PushButton::New(); 213 mEffectChangeButton = Toolkit::PushButton::New();
226 - mEffectChangeButton.SetButtonImage( mIconHighP );  
227 - mEffectChangeButton.SetSelectedImage( mIconHighPSelected ); 214 + mEffectChangeButton.SetUnselectedImage( EFFECT_HIGHP_IMAGE );
  215 + mEffectChangeButton.SetSelectedImage( EFFECT_HIGHP_IMAGE_SELECTED );
228 mEffectChangeButton.ClickedSignal().Connect( this, &DissolveEffectApp::OnEffectButtonClicked ); 216 mEffectChangeButton.ClickedSignal().Connect( this, &DissolveEffectApp::OnEffectButtonClicked );
229 mToolBar.AddControl( mEffectChangeButton, DemoHelper::DEFAULT_VIEW_STYLE.mToolBarButtonPercentage, Toolkit::Alignment::HorizontalRight, DemoHelper::DEFAULT_MODE_SWITCH_PADDING ); 217 mToolBar.AddControl( mEffectChangeButton, DemoHelper::DEFAULT_VIEW_STYLE.mToolBarButtonPercentage, Toolkit::Alignment::HorizontalRight, DemoHelper::DEFAULT_MODE_SWITCH_PADDING );
230 218
@@ -233,13 +221,9 @@ void DissolveEffectApp::OnInit( Application&amp; application ) @@ -233,13 +221,9 @@ void DissolveEffectApp::OnInit( Application&amp; application )
233 mToolBar.AddControl( mTitleActor, DemoHelper::DEFAULT_VIEW_STYLE.mToolBarTitlePercentage, Toolkit::Alignment::HorizontalCenter ); 221 mToolBar.AddControl( mTitleActor, DemoHelper::DEFAULT_VIEW_STYLE.mToolBarTitlePercentage, Toolkit::Alignment::HorizontalCenter );
234 222
235 // Add an slide-show button on the right of the title 223 // Add an slide-show button on the right of the title
236 - mIconPlay = ResourceImage::New( PLAY_ICON );  
237 - mIconPlaySelected = ResourceImage::New( PLAY_ICON_SELECTED );  
238 - mIconStop = ResourceImage::New( STOP_ICON );  
239 - mIconStopSelected = ResourceImage::New( STOP_ICON_SELECTED );  
240 mPlayStopButton = Toolkit::PushButton::New(); 224 mPlayStopButton = Toolkit::PushButton::New();
241 - mPlayStopButton.SetButtonImage( mIconPlay );  
242 - mPlayStopButton.SetSelectedImage( mIconPlaySelected ); 225 + mPlayStopButton.SetUnselectedImage( PLAY_ICON );
  226 + mPlayStopButton.SetSelectedImage( PLAY_ICON_SELECTED );
243 mPlayStopButton.ClickedSignal().Connect( this, &DissolveEffectApp::OnSildeshowButtonClicked ); 227 mPlayStopButton.ClickedSignal().Connect( this, &DissolveEffectApp::OnSildeshowButtonClicked );
244 mToolBar.AddControl( mPlayStopButton, DemoHelper::DEFAULT_VIEW_STYLE.mToolBarButtonPercentage, Toolkit::Alignment::HorizontalCenter, DemoHelper::DEFAULT_PLAY_PADDING ); 228 mToolBar.AddControl( mPlayStopButton, DemoHelper::DEFAULT_VIEW_STYLE.mToolBarButtonPercentage, Toolkit::Alignment::HorizontalCenter, DemoHelper::DEFAULT_PLAY_PADDING );
245 229
@@ -350,14 +334,14 @@ bool DissolveEffectApp::OnEffectButtonClicked( Toolkit::Button button ) @@ -350,14 +334,14 @@ bool DissolveEffectApp::OnEffectButtonClicked( Toolkit::Button button )
350 if(mUseHighPrecision) 334 if(mUseHighPrecision)
351 { 335 {
352 mTitleActor.SetProperty( TextLabel::Property::TEXT, std::string(APPLICATION_TITLE_HIGHP) ); 336 mTitleActor.SetProperty( TextLabel::Property::TEXT, std::string(APPLICATION_TITLE_HIGHP) );
353 - mEffectChangeButton.SetButtonImage( mIconHighP );  
354 - mEffectChangeButton.SetSelectedImage( mIconHighPSelected ); 337 + mEffectChangeButton.SetUnselectedImage( EFFECT_HIGHP_IMAGE );
  338 + mEffectChangeButton.SetSelectedImage( EFFECT_HIGHP_IMAGE_SELECTED );
355 } 339 }
356 else 340 else
357 { 341 {
358 mTitleActor.SetProperty( TextLabel::Property::TEXT, std::string(APPLICATION_TITLE_MEDIUMP) ); 342 mTitleActor.SetProperty( TextLabel::Property::TEXT, std::string(APPLICATION_TITLE_MEDIUMP) );
359 - mEffectChangeButton.SetButtonImage( mIconMediumP );  
360 - mEffectChangeButton.SetSelectedImage( mIconMediumPSelected ); 343 + mEffectChangeButton.SetUnselectedImage( EFFECT_MEDIUMP_IMAGE );
  344 + mEffectChangeButton.SetSelectedImage( EFFECT_MEDIUMP_IMAGE_SELECTED );
361 } 345 }
362 346
363 return true; 347 return true;
@@ -368,16 +352,16 @@ bool DissolveEffectApp::OnSildeshowButtonClicked( Toolkit::Button button ) @@ -368,16 +352,16 @@ bool DissolveEffectApp::OnSildeshowButtonClicked( Toolkit::Button button )
368 mSlideshow = !mSlideshow; 352 mSlideshow = !mSlideshow;
369 if( mSlideshow ) 353 if( mSlideshow )
370 { 354 {
371 - mPlayStopButton.SetButtonImage( mIconStop );  
372 - mPlayStopButton.SetSelectedImage( mIconStopSelected ); 355 + mPlayStopButton.SetUnselectedImage( STOP_ICON );
  356 + mPlayStopButton.SetSelectedImage( STOP_ICON_SELECTED );
373 mPanGestureDetector.Detach( mParent ); 357 mPanGestureDetector.Detach( mParent );
374 mViewTimer.Start(); 358 mViewTimer.Start();
375 mTimerReady = false; 359 mTimerReady = false;
376 } 360 }
377 else 361 else
378 { 362 {
379 - mPlayStopButton.SetButtonImage( mIconPlay );  
380 - mPlayStopButton.SetSelectedImage( mIconPlaySelected ); 363 + mPlayStopButton.SetUnselectedImage( PLAY_ICON );
  364 + mPlayStopButton.SetSelectedImage( PLAY_ICON_SELECTED );
381 mTimerReady = true; 365 mTimerReady = true;
382 mPanGestureDetector.Attach( mParent ); 366 mPanGestureDetector.Attach( mParent );
383 } 367 }
examples/image-scaling-and-filtering/image-scaling-and-filtering-example.cpp
@@ -171,7 +171,7 @@ public: @@ -171,7 +171,7 @@ public:
171 171
172 // Background image: 172 // Background image:
173 ResourceImage backgroundImage = ResourceImage::New( BACKGROUND_IMAGE, ImageDimensions( stage.GetSize().width, stage.GetSize().height ), FittingMode::SCALE_TO_FILL, SamplingMode::BOX_THEN_LINEAR ); 173 ResourceImage backgroundImage = ResourceImage::New( BACKGROUND_IMAGE, ImageDimensions( stage.GetSize().width, stage.GetSize().height ), FittingMode::SCALE_TO_FILL, SamplingMode::BOX_THEN_LINEAR );
174 - ImageActor background = ImageActor::New( backgroundImage ); 174 + Toolkit::ImageView background = Toolkit::ImageView::New( backgroundImage );
175 background.SetZ( -2.0f ); 175 background.SetZ( -2.0f );
176 background.SetAnchorPoint( AnchorPoint::TOP_LEFT ); 176 background.SetAnchorPoint( AnchorPoint::TOP_LEFT );
177 background.SetSize( stage.GetSize() ); 177 background.SetSize( stage.GetSize() );
@@ -192,34 +192,34 @@ public: @@ -192,34 +192,34 @@ public:
192 widthPixel[1] = 0x4f; 192 widthPixel[1] = 0x4f;
193 widthPixel[2] = 0x4f; 193 widthPixel[2] = 0x4f;
194 194
195 - mHeightBox = ImageActor::New( heightBackground ); 195 + mHeightBox = Toolkit::ImageView::New( heightBackground );
196 mHeightBox.SetOpacity( 0.2f ); 196 mHeightBox.SetOpacity( 0.2f );
197 stage.Add( mHeightBox ); 197 stage.Add( mHeightBox );
198 198
199 - mWidthBox = ImageActor::New( widthBackground ); 199 + mWidthBox = Toolkit::ImageView::New( widthBackground );
200 mWidthBox.SetOpacity( 0.2f ); 200 mWidthBox.SetOpacity( 0.2f );
201 stage.Add( mWidthBox ); 201 stage.Add( mWidthBox );
202 202
203 - mDesiredBox = ImageActor::New( desiredBackground ); 203 + mDesiredBox = Toolkit::ImageView::New( desiredBackground );
204 stage.Add( mDesiredBox ); 204 stage.Add( mDesiredBox );
205 205
206 mDesiredBox.SetSize( stage.GetSize() * mImageStageScale ); 206 mDesiredBox.SetSize( stage.GetSize() * mImageStageScale );
207 mDesiredBox.SetParentOrigin( ParentOrigin::CENTER ); 207 mDesiredBox.SetParentOrigin( ParentOrigin::CENTER );
208 mDesiredBox.SetAnchorPoint( AnchorPoint::CENTER ); 208 mDesiredBox.SetAnchorPoint( AnchorPoint::CENTER );
209 mDesiredBox.SetPosition( 0, 0, -1 ); 209 mDesiredBox.SetPosition( 0, 0, -1 );
210 - mDesiredBox.SetSortModifier(4.f); 210 + //mDesiredBox.SetSortModifier(4.f);
211 211
212 mHeightBox.SetSize( stage.GetSize().width, (stage.GetSize() * mImageStageScale).height ); 212 mHeightBox.SetSize( stage.GetSize().width, (stage.GetSize() * mImageStageScale).height );
213 mHeightBox.SetParentOrigin( ParentOrigin::CENTER ); 213 mHeightBox.SetParentOrigin( ParentOrigin::CENTER );
214 mHeightBox.SetAnchorPoint( AnchorPoint::CENTER ); 214 mHeightBox.SetAnchorPoint( AnchorPoint::CENTER );
215 mHeightBox.SetPosition( 0, 0, -1 ); 215 mHeightBox.SetPosition( 0, 0, -1 );
216 - mHeightBox.SetSortModifier(3.f); 216 + //mHeightBox.SetSortModifier(3.f);
217 217
218 mWidthBox.SetSize( (stage.GetSize() * mImageStageScale).width, stage.GetSize().height ); 218 mWidthBox.SetSize( (stage.GetSize() * mImageStageScale).width, stage.GetSize().height );
219 mWidthBox.SetParentOrigin( ParentOrigin::CENTER ); 219 mWidthBox.SetParentOrigin( ParentOrigin::CENTER );
220 mWidthBox.SetAnchorPoint( AnchorPoint::CENTER ); 220 mWidthBox.SetAnchorPoint( AnchorPoint::CENTER );
221 mWidthBox.SetPosition( 0, 0, -1 ); 221 mWidthBox.SetPosition( 0, 0, -1 );
222 - mWidthBox.SetSortModifier(2.f); 222 + //mWidthBox.SetSortModifier(2.f);
223 223
224 // Make a grab-handle for resizing the image: 224 // Make a grab-handle for resizing the image:
225 mGrabCorner = Toolkit::PushButton::New(); 225 mGrabCorner = Toolkit::PushButton::New();
@@ -284,7 +284,7 @@ public: @@ -284,7 +284,7 @@ public:
284 // Back and next image buttons in corners of stage: 284 // Back and next image buttons in corners of stage:
285 unsigned int playWidth = std::min( stage.GetSize().x * (1 / 5.0f), 58.0f ); 285 unsigned int playWidth = std::min( stage.GetSize().x * (1 / 5.0f), 58.0f );
286 Image playImage = ResourceImage::New( DALI_ICON_PLAY, ImageDimensions( playWidth, playWidth ), FittingMode::SHRINK_TO_FIT, SamplingMode::BOX_THEN_LINEAR ); 286 Image playImage = ResourceImage::New( DALI_ICON_PLAY, ImageDimensions( playWidth, playWidth ), FittingMode::SHRINK_TO_FIT, SamplingMode::BOX_THEN_LINEAR );
287 - Actor imagePrevious = ImageActor::New( playImage ); 287 + Toolkit::ImageView imagePrevious = Toolkit::ImageView::New( playImage );
288 288
289 // Last image button: 289 // Last image button:
290 imagePrevious.SetAnchorPoint( AnchorPoint::TOP_LEFT ); 290 imagePrevious.SetAnchorPoint( AnchorPoint::TOP_LEFT );
@@ -297,7 +297,7 @@ public: @@ -297,7 +297,7 @@ public:
297 imagePrevious.TouchedSignal().Connect( this, &ImageScalingAndFilteringController::OnControlTouched ); 297 imagePrevious.TouchedSignal().Connect( this, &ImageScalingAndFilteringController::OnControlTouched );
298 298
299 // Next image button: 299 // Next image button:
300 - Actor imageNext = ImageActor::New( playImage ); 300 + Toolkit::ImageView imageNext = Toolkit::ImageView::New( playImage );
301 imageNext.SetAnchorPoint( AnchorPoint::TOP_RIGHT ); 301 imageNext.SetAnchorPoint( AnchorPoint::TOP_RIGHT );
302 imageNext.SetY( playWidth * 0.5f ); 302 imageNext.SetY( playWidth * 0.5f );
303 imageNext.SetX( stage.GetSize().x - playWidth * 0.5f ); 303 imageNext.SetX( stage.GetSize().x - playWidth * 0.5f );
@@ -337,7 +337,6 @@ public: @@ -337,7 +337,6 @@ public:
337 fittingModeGroup.Add( label ); 337 fittingModeGroup.Add( label );
338 338
339 Toolkit::PushButton button = CreateButton( FITTING_BUTTON_ID, StringFromScalingMode( mFittingMode ) ); 339 Toolkit::PushButton button = CreateButton( FITTING_BUTTON_ID, StringFromScalingMode( mFittingMode ) );
340 - button.GetLabel().SetProperty( Toolkit::Control::Property::STYLE_NAME, STYLE_BUTTON_TEXT );  
341 fittingModeGroup.Add( button ); 340 fittingModeGroup.Add( button );
342 mFittingModeButton = button; 341 mFittingModeButton = button;
343 342
@@ -359,7 +358,6 @@ public: @@ -359,7 +358,6 @@ public:
359 samplingModeGroup.Add( label ); 358 samplingModeGroup.Add( label );
360 359
361 Toolkit::PushButton button = CreateButton( SAMPLING_BUTTON_ID, StringFromFilterMode( mSamplingMode ) ); 360 Toolkit::PushButton button = CreateButton( SAMPLING_BUTTON_ID, StringFromFilterMode( mSamplingMode ) );
362 - button.GetLabel().SetProperty( Toolkit::Control::Property::STYLE_NAME, STYLE_BUTTON_TEXT );  
363 samplingModeGroup.Add( button ); 361 samplingModeGroup.Add( button );
364 mSamplingModeButton = button; 362 mSamplingModeButton = button;
365 363
@@ -372,7 +370,7 @@ public: @@ -372,7 +370,7 @@ public:
372 Toolkit::PushButton button = Toolkit::PushButton::New(); 370 Toolkit::PushButton button = Toolkit::PushButton::New();
373 button.SetProperty( Toolkit::Control::Property::STYLE_NAME, STYLE_BUTTON_TEXT ); 371 button.SetProperty( Toolkit::Control::Property::STYLE_NAME, STYLE_BUTTON_TEXT );
374 button.SetName( id ); 372 button.SetName( id );
375 - button.SetLabel( label ); 373 + button.SetLabelText( label );
376 button.SetResizePolicy( ResizePolicy::FILL_TO_PARENT, Dimension::WIDTH ); 374 button.SetResizePolicy( ResizePolicy::FILL_TO_PARENT, Dimension::WIDTH );
377 button.SetResizePolicy( ResizePolicy::USE_NATURAL_SIZE, Dimension::HEIGHT ); 375 button.SetResizePolicy( ResizePolicy::USE_NATURAL_SIZE, Dimension::HEIGHT );
378 button.ClickedSignal().Connect( this, &ImageScalingAndFilteringController::OnButtonClicked ); 376 button.ClickedSignal().Connect( this, &ImageScalingAndFilteringController::OnButtonClicked );
@@ -401,9 +399,7 @@ public: @@ -401,9 +399,7 @@ public:
401 { 399 {
402 Toolkit::PushButton button = Toolkit::PushButton::New(); 400 Toolkit::PushButton button = Toolkit::PushButton::New();
403 button.SetName( id ); 401 button.SetName( id );
404 - button.SetLabel( id );  
405 - Toolkit::TextLabel textLabel = Toolkit::TextLabel::DownCast( button.GetLabel() );  
406 - textLabel.SetProperty( TextLabel::Property::POINT_SIZE, 12.0f ); 402 + button.SetLabelText( id );
407 403
408 button.SetAnchorPoint( AnchorPoint::TOP_LEFT ); 404 button.SetAnchorPoint( AnchorPoint::TOP_LEFT );
409 button.SetParentOrigin( ParentOrigin::BOTTOM_LEFT ); 405 button.SetParentOrigin( ParentOrigin::BOTTOM_LEFT );
@@ -492,8 +488,7 @@ public: @@ -492,8 +488,7 @@ public:
492 if( button.GetName() == modeName ) 488 if( button.GetName() == modeName )
493 { 489 {
494 mFittingMode = mode; 490 mFittingMode = mode;
495 - mFittingModeButton.SetLabel( modeName );  
496 - mFittingModeButton.GetLabel().SetProperty( Toolkit::Control::Property::STYLE_NAME, STYLE_BUTTON_TEXT ); 491 + mFittingModeButton.SetLabelText( modeName );
497 ResizeImage(); 492 ResizeImage();
498 mPopup.Hide(); 493 mPopup.Hide();
499 mPopup.Reset(); 494 mPopup.Reset();
@@ -508,8 +503,7 @@ public: @@ -508,8 +503,7 @@ public:
508 if( button.GetName() == modeName ) 503 if( button.GetName() == modeName )
509 { 504 {
510 mSamplingMode = mode; 505 mSamplingMode = mode;
511 - mSamplingModeButton.SetLabel( modeName );  
512 - mSamplingModeButton.GetLabel().SetProperty( Toolkit::Control::Property::STYLE_NAME, STYLE_BUTTON_TEXT ); 506 + mSamplingModeButton.SetLabelText( modeName );
513 ResizeImage(); 507 ResizeImage();
514 mPopup.Hide(); 508 mPopup.Hide();
515 mPopup.Reset(); 509 mPopup.Reset();
@@ -657,15 +651,13 @@ public: @@ -657,15 +651,13 @@ public:
657 else if ( event.keyPressedName == "f" ) 651 else if ( event.keyPressedName == "f" )
658 { 652 {
659 mSamplingMode = NextFilterMode( mSamplingMode ); 653 mSamplingMode = NextFilterMode( mSamplingMode );
660 - mSamplingModeButton.SetLabel( StringFromFilterMode( mSamplingMode ) );  
661 - mSamplingModeButton.GetLabel().SetProperty( Toolkit::Control::Property::STYLE_NAME, STYLE_BUTTON_TEXT ); 654 + mSamplingModeButton.SetLabelText( StringFromFilterMode( mSamplingMode ) );
662 } 655 }
663 // Cycle filter and scaling modes: 656 // Cycle filter and scaling modes:
664 else if ( event.keyPressedName == "s" ) 657 else if ( event.keyPressedName == "s" )
665 { 658 {
666 mFittingMode = NextScalingMode( mFittingMode ); 659 mFittingMode = NextScalingMode( mFittingMode );
667 - mFittingModeButton.SetLabel( StringFromScalingMode( mFittingMode ) );  
668 - mFittingModeButton.GetLabel().SetProperty( Toolkit::Control::Property::STYLE_NAME, STYLE_BUTTON_TEXT ); 660 + mFittingModeButton.SetLabelText( StringFromScalingMode( mFittingMode ) );
669 } 661 }
670 else 662 else
671 { 663 {
@@ -697,9 +689,9 @@ private: @@ -697,9 +689,9 @@ private:
697 689
698 private: 690 private:
699 Application& mApplication; 691 Application& mApplication;
700 - ImageActor mDesiredBox; //< Background rectangle to show requested image size.  
701 - ImageActor mHeightBox; //< Background horizontal stripe to show requested image height.  
702 - ImageActor mWidthBox; //< Background vertical stripe to show requested image width. 692 + Toolkit::ImageView mDesiredBox; //< Background rectangle to show requested image size.
  693 + Toolkit::ImageView mHeightBox; //< Background horizontal stripe to show requested image height.
  694 + Toolkit::ImageView mWidthBox; //< Background vertical stripe to show requested image width.
703 Toolkit::PushButton mFittingModeButton; 695 Toolkit::PushButton mFittingModeButton;
704 Toolkit::PushButton mSamplingModeButton; 696 Toolkit::PushButton mSamplingModeButton;
705 Toolkit::Popup mPopup; 697 Toolkit::Popup mPopup;
examples/image-scaling-irregular-grid/image-scaling-irregular-grid-example.cpp
@@ -24,7 +24,7 @@ @@ -24,7 +24,7 @@
24 * reduce the image to save memory, improve performance, and potentially display 24 * reduce the image to save memory, improve performance, and potentially display
25 * a better small version of the image than if the default size were loaded. 25 * a better small version of the image than if the default size were loaded.
26 * 26 *
27 - * The functions CreateImage and CreateImageActor below show how to build an 27 + * The functions CreateImage and CreateImageView below show how to build an
28 * image using a scaling mode to have %Dali resize it during loading. 28 * image using a scaling mode to have %Dali resize it during loading.
29 * 29 *
30 * This demo defaults to the SCALE_TO_FILL mode of ImageAttributes which makes 30 * This demo defaults to the SCALE_TO_FILL mode of ImageAttributes which makes
@@ -38,7 +38,7 @@ @@ -38,7 +38,7 @@
38 * grid using the button in the top-right of the toolbar. 38 * grid using the button in the top-right of the toolbar.
39 * A single image can be cycled by clicking the image directly. 39 * A single image can be cycled by clicking the image directly.
40 * 40 *
41 - * @see CreateImage CreateImageActor 41 + * @see CreateImage CreateImageView
42 */ 42 */
43 43
44 // EXTERNAL INCLUDES 44 // EXTERNAL INCLUDES
@@ -186,17 +186,17 @@ Image CreateImage(const std::string&amp; filename, unsigned int width, unsigned int @@ -186,17 +186,17 @@ Image CreateImage(const std::string&amp; filename, unsigned int width, unsigned int
186 } 186 }
187 187
188 /** 188 /**
189 - * Creates an ImageActor 189 + * Creates an ImageView
190 * 190 *
191 * @param[in] filename The path of the image. 191 * @param[in] filename The path of the image.
192 * @param[in] width The width of the image in pixels. 192 * @param[in] width The width of the image in pixels.
193 * @param[in] height The height of the image in pixels. 193 * @param[in] height The height of the image in pixels.
194 * @param[in] fittingMode The mode to use when scaling the image to fit the desired dimensions. 194 * @param[in] fittingMode The mode to use when scaling the image to fit the desired dimensions.
195 */ 195 */
196 -ImageActor CreateImageActor(const std::string& filename, unsigned int width, unsigned int height, Dali::FittingMode::Type fittingMode ) 196 +ImageView CreateImageView(const std::string& filename, unsigned int width, unsigned int height, Dali::FittingMode::Type fittingMode )
197 { 197 {
198 Image img = CreateImage( filename, width, height, fittingMode ); 198 Image img = CreateImage( filename, width, height, fittingMode );
199 - ImageActor actor = ImageActor::New( img ); 199 + ImageView actor = ImageView::New( img );
200 actor.SetName( filename ); 200 actor.SetName( filename );
201 actor.SetParentOrigin(ParentOrigin::CENTER); 201 actor.SetParentOrigin(ParentOrigin::CENTER);
202 actor.SetAnchorPoint(AnchorPoint::CENTER); 202 actor.SetAnchorPoint(AnchorPoint::CENTER);
@@ -306,11 +306,9 @@ public: @@ -306,11 +306,9 @@ public:
306 "" ); 306 "" );
307 307
308 // Create an image scaling toggle button. (right of toolbar) 308 // Create an image scaling toggle button. (right of toolbar)
309 - Image toggleScalingImage = ResourceImage::New( TOGGLE_SCALING_IMAGE );  
310 - Image toggleScalingImageSelected = ResourceImage::New( TOGGLE_SCALING_IMAGE_SELECTED );  
311 Toolkit::PushButton toggleScalingButton = Toolkit::PushButton::New(); 309 Toolkit::PushButton toggleScalingButton = Toolkit::PushButton::New();
312 - toggleScalingButton.SetButtonImage( toggleScalingImage );  
313 - toggleScalingButton.SetSelectedImage( toggleScalingImageSelected ); 310 + toggleScalingButton.SetUnselectedImage( TOGGLE_SCALING_IMAGE );
  311 + toggleScalingButton.SetSelectedImage( TOGGLE_SCALING_IMAGE_SELECTED );
314 toggleScalingButton.ClickedSignal().Connect( this, &ImageScalingIrregularGridController::OnToggleScalingTouched ); 312 toggleScalingButton.ClickedSignal().Connect( this, &ImageScalingIrregularGridController::OnToggleScalingTouched );
315 mToolBar.AddControl( toggleScalingButton, DemoHelper::DEFAULT_VIEW_STYLE.mToolBarButtonPercentage, Toolkit::Alignment::HorizontalRight, DemoHelper::DEFAULT_MODE_SWITCH_PADDING ); 313 mToolBar.AddControl( toggleScalingButton, DemoHelper::DEFAULT_VIEW_STYLE.mToolBarButtonPercentage, Toolkit::Alignment::HorizontalRight, DemoHelper::DEFAULT_MODE_SWITCH_PADDING );
316 314
@@ -460,7 +458,7 @@ public: @@ -460,7 +458,7 @@ public:
460 const Vector2 imageRegionCorner = gridOrigin + cellSize * Vector2( imageSource.cellX, imageSource.cellY ); 458 const Vector2 imageRegionCorner = gridOrigin + cellSize * Vector2( imageSource.cellX, imageSource.cellY );
461 const Vector2 imagePosition = imageRegionCorner + Vector2( GRID_CELL_PADDING , GRID_CELL_PADDING ) + imageSize * 0.5f; 459 const Vector2 imagePosition = imageRegionCorner + Vector2( GRID_CELL_PADDING , GRID_CELL_PADDING ) + imageSize * 0.5f;
462 460
463 - ImageActor image = CreateImageActor( imageSource.configuration.path, imageSize.x, imageSize.y, fittingMode ); 461 + ImageView image = CreateImageView( imageSource.configuration.path, imageSize.x, imageSize.y, fittingMode );
464 image.SetPosition( Vector3( imagePosition.x, imagePosition.y, 0 ) ); 462 image.SetPosition( Vector3( imagePosition.x, imagePosition.y, 0 ) );
465 image.SetSize( imageSize ); 463 image.SetSize( imageSize );
466 image.TouchedSignal().Connect( this, &ImageScalingIrregularGridController::OnTouchImage ); 464 image.TouchedSignal().Connect( this, &ImageScalingIrregularGridController::OnTouchImage );
@@ -495,10 +493,10 @@ public: @@ -495,10 +493,10 @@ public:
495 Dali::FittingMode::Type newMode = NextMode( mFittingModes[id] ); 493 Dali::FittingMode::Type newMode = NextMode( mFittingModes[id] );
496 const Vector2 imageSize = mSizes[actor.GetId()]; 494 const Vector2 imageSize = mSizes[actor.GetId()];
497 495
498 - ImageActor imageActor = ImageActor::DownCast( actor );  
499 - Image oldImage = imageActor.GetImage(); 496 + ImageView imageView = ImageView::DownCast( actor );
  497 + Image oldImage = imageView.GetImage();
500 Image newImage = CreateImage( ResourceImage::DownCast(oldImage).GetUrl(), imageSize.width + 0.5f, imageSize.height + 0.5f, newMode ); 498 Image newImage = CreateImage( ResourceImage::DownCast(oldImage).GetUrl(), imageSize.width + 0.5f, imageSize.height + 0.5f, newMode );
501 - imageActor.SetImage( newImage ); 499 + imageView.SetImage( newImage );
502 mFittingModes[id] = newMode; 500 mFittingModes[id] = newMode;
503 } 501 }
504 } 502 }
@@ -532,17 +530,17 @@ public: @@ -532,17 +530,17 @@ public:
532 530
533 for( unsigned i = 0; i < numChildren; ++i ) 531 for( unsigned i = 0; i < numChildren; ++i )
534 { 532 {
535 - ImageActor gridImageActor = ImageActor::DownCast( mGridActor.GetChildAt( i ) );  
536 - if( gridImageActor ) 533 + ImageView gridImageView = ImageView::DownCast( mGridActor.GetChildAt( i ) );
  534 + if( gridImageView )
537 { 535 {
538 // Cycle the scaling mode options: 536 // Cycle the scaling mode options:
539 - const Vector2 imageSize = mSizes[gridImageActor.GetId()];  
540 - Dali::FittingMode::Type newMode = NextMode( mFittingModes[gridImageActor.GetId()] );  
541 - Image oldImage = gridImageActor.GetImage(); 537 + const Vector2 imageSize = mSizes[gridImageView.GetId()];
  538 + Dali::FittingMode::Type newMode = NextMode( mFittingModes[gridImageView.GetId()] );
  539 + Image oldImage = gridImageView.GetImage();
542 Image newImage = CreateImage(ResourceImage::DownCast(oldImage).GetUrl(), imageSize.width, imageSize.height, newMode ); 540 Image newImage = CreateImage(ResourceImage::DownCast(oldImage).GetUrl(), imageSize.width, imageSize.height, newMode );
543 - gridImageActor.SetImage( newImage ); 541 + gridImageView.SetImage( newImage );
544 542
545 - mFittingModes[gridImageActor.GetId()] = newMode; 543 + mFittingModes[gridImageView.GetId()] = newMode;
546 544
547 SetTitle( std::string( newMode == FittingMode::SHRINK_TO_FIT ? "SHRINK_TO_FIT" : newMode == FittingMode::SCALE_TO_FILL ? "SCALE_TO_FILL" : newMode == FittingMode::FIT_WIDTH ? "FIT_WIDTH" : "FIT_HEIGHT" ) ); 545 SetTitle( std::string( newMode == FittingMode::SHRINK_TO_FIT ? "SHRINK_TO_FIT" : newMode == FittingMode::SCALE_TO_FILL ? "SCALE_TO_FILL" : newMode == FittingMode::FIT_WIDTH ? "FIT_WIDTH" : "FIT_HEIGHT" ) );
548 } 546 }
examples/item-view/item-view-example.cpp
@@ -231,16 +231,16 @@ public: @@ -231,16 +231,16 @@ public:
231 231
232 // Create an edit mode button. (left of toolbar) 232 // Create an edit mode button. (left of toolbar)
233 Toolkit::PushButton editButton = Toolkit::PushButton::New(); 233 Toolkit::PushButton editButton = Toolkit::PushButton::New();
234 - editButton.SetButtonImage( ResourceImage::New( EDIT_IMAGE ) );  
235 - editButton.SetSelectedImage( ResourceImage::New( EDIT_IMAGE_SELECTED ) ); 234 + editButton.SetUnselectedImage( EDIT_IMAGE );
  235 + editButton.SetSelectedImage( EDIT_IMAGE_SELECTED );
236 editButton.ClickedSignal().Connect( this, &ItemViewExample::OnModeButtonClicked); 236 editButton.ClickedSignal().Connect( this, &ItemViewExample::OnModeButtonClicked);
237 editButton.SetLeaveRequired( true ); 237 editButton.SetLeaveRequired( true );
238 mToolBar.AddControl( editButton, DemoHelper::DEFAULT_VIEW_STYLE.mToolBarButtonPercentage, Toolkit::Alignment::HorizontalLeft, DemoHelper::DEFAULT_MODE_SWITCH_PADDING ); 238 mToolBar.AddControl( editButton, DemoHelper::DEFAULT_VIEW_STYLE.mToolBarButtonPercentage, Toolkit::Alignment::HorizontalLeft, DemoHelper::DEFAULT_MODE_SWITCH_PADDING );
239 239
240 // Create a layout toggle button. (right of toolbar) 240 // Create a layout toggle button. (right of toolbar)
241 mLayoutButton = Toolkit::PushButton::New(); 241 mLayoutButton = Toolkit::PushButton::New();
242 - mLayoutButton.SetButtonImage( ResourceImage::New( SPIRAL_LAYOUT_IMAGE ) );  
243 - mLayoutButton.SetSelectedImage( ResourceImage::New( SPIRAL_LAYOUT_IMAGE_SELECTED ) ); 242 + mLayoutButton.SetUnselectedImage( SPIRAL_LAYOUT_IMAGE );
  243 + mLayoutButton.SetSelectedImage(SPIRAL_LAYOUT_IMAGE_SELECTED );
244 mLayoutButton.ClickedSignal().Connect( this, &ItemViewExample::OnLayoutButtonClicked); 244 mLayoutButton.ClickedSignal().Connect( this, &ItemViewExample::OnLayoutButtonClicked);
245 mLayoutButton.SetLeaveRequired( true ); 245 mLayoutButton.SetLeaveRequired( true );
246 mToolBar.AddControl( mLayoutButton, DemoHelper::DEFAULT_VIEW_STYLE.mToolBarButtonPercentage, Toolkit::Alignment::HorizontalRight, DemoHelper::DEFAULT_MODE_SWITCH_PADDING ); 246 mToolBar.AddControl( mLayoutButton, DemoHelper::DEFAULT_VIEW_STYLE.mToolBarButtonPercentage, Toolkit::Alignment::HorizontalRight, DemoHelper::DEFAULT_MODE_SWITCH_PADDING );
@@ -251,9 +251,9 @@ public: @@ -251,9 +251,9 @@ public:
251 mDeleteButton.SetAnchorPoint(AnchorPoint::BOTTOM_RIGHT); 251 mDeleteButton.SetAnchorPoint(AnchorPoint::BOTTOM_RIGHT);
252 mDeleteButton.SetPosition( BUTTON_BORDER, BUTTON_BORDER ); 252 mDeleteButton.SetPosition( BUTTON_BORDER, BUTTON_BORDER );
253 mDeleteButton.SetDrawMode( DrawMode::OVERLAY_2D ); 253 mDeleteButton.SetDrawMode( DrawMode::OVERLAY_2D );
254 - mDeleteButton.SetButtonImage( ResourceImage::New( DELETE_IMAGE ) );  
255 - mDeleteButton.SetSelectedImage( ResourceImage::New( DELETE_IMAGE_SELECTED ) );  
256 - mDeleteButton.SetBackgroundImage( ResourceImage::New( TOOLBAR_IMAGE ) ); 254 + mDeleteButton.SetUnselectedImage( DELETE_IMAGE );
  255 + mDeleteButton.SetSelectedImage( DELETE_IMAGE_SELECTED );
  256 + mDeleteButton.SetBackgroundImage( TOOLBAR_IMAGE );
257 mDeleteButton.SetSize( Vector2( stageSize.width * 0.15f, stageSize.width * 0.15f ) ); 257 mDeleteButton.SetSize( Vector2( stageSize.width * 0.15f, stageSize.width * 0.15f ) );
258 mDeleteButton.ClickedSignal().Connect( this, &ItemViewExample::OnDeleteButtonClicked); 258 mDeleteButton.ClickedSignal().Connect( this, &ItemViewExample::OnDeleteButtonClicked);
259 mDeleteButton.SetLeaveRequired( true ); 259 mDeleteButton.SetLeaveRequired( true );
@@ -266,9 +266,9 @@ public: @@ -266,9 +266,9 @@ public:
266 mInsertButton.SetAnchorPoint(AnchorPoint::BOTTOM_RIGHT); 266 mInsertButton.SetAnchorPoint(AnchorPoint::BOTTOM_RIGHT);
267 mInsertButton.SetPosition( BUTTON_BORDER, BUTTON_BORDER ); 267 mInsertButton.SetPosition( BUTTON_BORDER, BUTTON_BORDER );
268 mInsertButton.SetDrawMode( DrawMode::OVERLAY_2D ); 268 mInsertButton.SetDrawMode( DrawMode::OVERLAY_2D );
269 - mInsertButton.SetButtonImage( ResourceImage::New( INSERT_IMAGE ) );  
270 - mInsertButton.SetSelectedImage( ResourceImage::New( INSERT_IMAGE_SELECTED ) );  
271 - mInsertButton.SetBackgroundImage( ResourceImage::New( TOOLBAR_IMAGE ) ); 269 + mInsertButton.SetUnselectedImage( INSERT_IMAGE );
  270 + mInsertButton.SetSelectedImage( INSERT_IMAGE_SELECTED );
  271 + mInsertButton.SetBackgroundImage( TOOLBAR_IMAGE );
272 mInsertButton.SetSize( stageSize.width * 0.15f, stageSize.width * 0.15f ); 272 mInsertButton.SetSize( stageSize.width * 0.15f, stageSize.width * 0.15f );
273 mInsertButton.ClickedSignal().Connect( this, &ItemViewExample::OnInsertButtonClicked); 273 mInsertButton.ClickedSignal().Connect( this, &ItemViewExample::OnInsertButtonClicked);
274 mInsertButton.SetLeaveRequired( true ); 274 mInsertButton.SetLeaveRequired( true );
@@ -281,9 +281,9 @@ public: @@ -281,9 +281,9 @@ public:
281 mReplaceButton.SetAnchorPoint(AnchorPoint::BOTTOM_RIGHT); 281 mReplaceButton.SetAnchorPoint(AnchorPoint::BOTTOM_RIGHT);
282 mReplaceButton.SetPosition( BUTTON_BORDER, BUTTON_BORDER ); 282 mReplaceButton.SetPosition( BUTTON_BORDER, BUTTON_BORDER );
283 mReplaceButton.SetDrawMode( DrawMode::OVERLAY_2D ); 283 mReplaceButton.SetDrawMode( DrawMode::OVERLAY_2D );
284 - mReplaceButton.SetButtonImage( ResourceImage::New( REPLACE_IMAGE ) );  
285 - mReplaceButton.SetSelectedImage( ResourceImage::New( REPLACE_IMAGE_SELECTED ) );  
286 - mReplaceButton.SetBackgroundImage( ResourceImage::New( TOOLBAR_IMAGE ) ); 284 + mReplaceButton.SetUnselectedImage( REPLACE_IMAGE );
  285 + mReplaceButton.SetSelectedImage( REPLACE_IMAGE_SELECTED );
  286 + mReplaceButton.SetBackgroundImage( TOOLBAR_IMAGE );
287 mReplaceButton.SetSize( stageSize.width * 0.15f, stageSize.width * 0.15f ); 287 mReplaceButton.SetSize( stageSize.width * 0.15f, stageSize.width * 0.15f );
288 mReplaceButton.ClickedSignal().Connect( this, &ItemViewExample::OnReplaceButtonClicked); 288 mReplaceButton.ClickedSignal().Connect( this, &ItemViewExample::OnReplaceButtonClicked);
289 mReplaceButton.SetLeaveRequired( true ); 289 mReplaceButton.SetLeaveRequired( true );
@@ -812,22 +812,22 @@ public: @@ -812,22 +812,22 @@ public:
812 { 812 {
813 case SPIRAL_LAYOUT: 813 case SPIRAL_LAYOUT:
814 { 814 {
815 - mLayoutButton.SetButtonImage( ResourceImage::New( SPIRAL_LAYOUT_IMAGE ) );  
816 - mLayoutButton.SetSelectedImage( ResourceImage::New( SPIRAL_LAYOUT_IMAGE_SELECTED ) ); 815 + mLayoutButton.SetUnselectedImage( SPIRAL_LAYOUT_IMAGE );
  816 + mLayoutButton.SetSelectedImage( SPIRAL_LAYOUT_IMAGE_SELECTED );
817 break; 817 break;
818 } 818 }
819 819
820 case GRID_LAYOUT: 820 case GRID_LAYOUT:
821 { 821 {
822 - mLayoutButton.SetButtonImage( ResourceImage::New( GRID_LAYOUT_IMAGE ) );  
823 - mLayoutButton.SetSelectedImage( ResourceImage::New( GRID_LAYOUT_IMAGE_SELECTED ) ); 822 + mLayoutButton.SetUnselectedImage( GRID_LAYOUT_IMAGE );
  823 + mLayoutButton.SetSelectedImage( GRID_LAYOUT_IMAGE_SELECTED );
824 break; 824 break;
825 } 825 }
826 826
827 case DEPTH_LAYOUT: 827 case DEPTH_LAYOUT:
828 { 828 {
829 - mLayoutButton.SetButtonImage( ResourceImage::New( DEPTH_LAYOUT_IMAGE ) );  
830 - mLayoutButton.SetSelectedImage( ResourceImage::New( DEPTH_LAYOUT_IMAGE_SELECTED ) ); 829 + mLayoutButton.SetUnselectedImage( DEPTH_LAYOUT_IMAGE );
  830 + mLayoutButton.SetSelectedImage( DEPTH_LAYOUT_IMAGE_SELECTED );
831 break; 831 break;
832 } 832 }
833 833
examples/logging/logging-example.cpp
@@ -285,7 +285,7 @@ class LoggingController: public ConnectionTracker @@ -285,7 +285,7 @@ class LoggingController: public ConnectionTracker
285 { 285 {
286 Toolkit::PushButton button = Toolkit::PushButton::New(); 286 Toolkit::PushButton button = Toolkit::PushButton::New();
287 button.SetName( CREATE_BUTTON_ID ); 287 button.SetName( CREATE_BUTTON_ID );
288 - button.SetLabel( CREATE_BUTTON_TEXT ); 288 + button.SetLabelText( CREATE_BUTTON_TEXT );
289 button.SetResizePolicy( ResizePolicy::FILL_TO_PARENT, Dimension::WIDTH ); 289 button.SetResizePolicy( ResizePolicy::FILL_TO_PARENT, Dimension::WIDTH );
290 button.SetResizePolicy( ResizePolicy::USE_NATURAL_SIZE, Dimension::HEIGHT ); 290 button.SetResizePolicy( ResizePolicy::USE_NATURAL_SIZE, Dimension::HEIGHT );
291 button.ClickedSignal().Connect( this, &LoggingController::OnButtonClicked ); 291 button.ClickedSignal().Connect( this, &LoggingController::OnButtonClicked );
@@ -296,7 +296,7 @@ class LoggingController: public ConnectionTracker @@ -296,7 +296,7 @@ class LoggingController: public ConnectionTracker
296 { 296 {
297 Toolkit::PushButton button = Toolkit::PushButton::New(); 297 Toolkit::PushButton button = Toolkit::PushButton::New();
298 button.SetName( DELETE_BUTTON_ID ); 298 button.SetName( DELETE_BUTTON_ID );
299 - button.SetLabel( DELETE_BUTTON_TEXT ); 299 + button.SetLabelText( DELETE_BUTTON_TEXT );
300 button.SetResizePolicy( ResizePolicy::FILL_TO_PARENT, Dimension::WIDTH ); 300 button.SetResizePolicy( ResizePolicy::FILL_TO_PARENT, Dimension::WIDTH );
301 button.SetResizePolicy( ResizePolicy::USE_NATURAL_SIZE, Dimension::HEIGHT ); 301 button.SetResizePolicy( ResizePolicy::USE_NATURAL_SIZE, Dimension::HEIGHT );
302 button.ClickedSignal().Connect( this, &LoggingController::OnButtonClicked ); 302 button.ClickedSignal().Connect( this, &LoggingController::OnButtonClicked );
@@ -318,7 +318,7 @@ class LoggingController: public ConnectionTracker @@ -318,7 +318,7 @@ class LoggingController: public ConnectionTracker
318 { 318 {
319 Toolkit::PushButton button = Toolkit::PushButton::New(); 319 Toolkit::PushButton button = Toolkit::PushButton::New();
320 button.SetName( START_BUTTON_ID ); 320 button.SetName( START_BUTTON_ID );
321 - button.SetLabel( START_BUTTON_TEXT ); 321 + button.SetLabelText( START_BUTTON_TEXT );
322 button.SetResizePolicy( ResizePolicy::FILL_TO_PARENT, Dimension::WIDTH ); 322 button.SetResizePolicy( ResizePolicy::FILL_TO_PARENT, Dimension::WIDTH );
323 button.SetResizePolicy( ResizePolicy::USE_NATURAL_SIZE, Dimension::HEIGHT ); 323 button.SetResizePolicy( ResizePolicy::USE_NATURAL_SIZE, Dimension::HEIGHT );
324 button.ClickedSignal().Connect( this, &LoggingController::OnButtonClicked ); 324 button.ClickedSignal().Connect( this, &LoggingController::OnButtonClicked );
@@ -329,7 +329,7 @@ class LoggingController: public ConnectionTracker @@ -329,7 +329,7 @@ class LoggingController: public ConnectionTracker
329 { 329 {
330 Toolkit::PushButton button = Toolkit::PushButton::New(); 330 Toolkit::PushButton button = Toolkit::PushButton::New();
331 button.SetName( STOP_BUTTON_ID ); 331 button.SetName( STOP_BUTTON_ID );
332 - button.SetLabel( STOP_BUTTON_TEXT ); 332 + button.SetLabelText( STOP_BUTTON_TEXT );
333 button.SetResizePolicy( ResizePolicy::FILL_TO_PARENT, Dimension::WIDTH ); 333 button.SetResizePolicy( ResizePolicy::FILL_TO_PARENT, Dimension::WIDTH );
334 button.SetResizePolicy( ResizePolicy::USE_NATURAL_SIZE, Dimension::HEIGHT ); 334 button.SetResizePolicy( ResizePolicy::USE_NATURAL_SIZE, Dimension::HEIGHT );
335 button.ClickedSignal().Connect( this, &LoggingController::OnButtonClicked ); 335 button.ClickedSignal().Connect( this, &LoggingController::OnButtonClicked );
@@ -350,7 +350,7 @@ class LoggingController: public ConnectionTracker @@ -350,7 +350,7 @@ class LoggingController: public ConnectionTracker
350 { 350 {
351 Toolkit::PushButton button = Toolkit::PushButton::New(); 351 Toolkit::PushButton button = Toolkit::PushButton::New();
352 button.SetName( ENABLE_BUTTON_ID ); 352 button.SetName( ENABLE_BUTTON_ID );
353 - button.SetLabel( ENABLE_BUTTON_TEXT ); 353 + button.SetLabelText( ENABLE_BUTTON_TEXT );
354 button.SetResizePolicy( ResizePolicy::FILL_TO_PARENT, Dimension::WIDTH ); 354 button.SetResizePolicy( ResizePolicy::FILL_TO_PARENT, Dimension::WIDTH );
355 button.SetResizePolicy( ResizePolicy::USE_NATURAL_SIZE, Dimension::HEIGHT ); 355 button.SetResizePolicy( ResizePolicy::USE_NATURAL_SIZE, Dimension::HEIGHT );
356 button.ClickedSignal().Connect( this, &LoggingController::OnButtonClicked ); 356 button.ClickedSignal().Connect( this, &LoggingController::OnButtonClicked );
@@ -361,7 +361,7 @@ class LoggingController: public ConnectionTracker @@ -361,7 +361,7 @@ class LoggingController: public ConnectionTracker
361 { 361 {
362 Toolkit::PushButton button = Toolkit::PushButton::New(); 362 Toolkit::PushButton button = Toolkit::PushButton::New();
363 button.SetName( DISABLE_BUTTON_ID ); 363 button.SetName( DISABLE_BUTTON_ID );
364 - button.SetLabel( DISABLE_BUTTON_TEXT ); 364 + button.SetLabelText( DISABLE_BUTTON_TEXT );
365 button.SetResizePolicy( ResizePolicy::FILL_TO_PARENT, Dimension::WIDTH ); 365 button.SetResizePolicy( ResizePolicy::FILL_TO_PARENT, Dimension::WIDTH );
366 button.SetResizePolicy( ResizePolicy::USE_NATURAL_SIZE, Dimension::HEIGHT ); 366 button.SetResizePolicy( ResizePolicy::USE_NATURAL_SIZE, Dimension::HEIGHT );
367 button.ClickedSignal().Connect( this, &LoggingController::OnButtonClicked ); 367 button.ClickedSignal().Connect( this, &LoggingController::OnButtonClicked );
@@ -444,7 +444,7 @@ class LoggingController: public ConnectionTracker @@ -444,7 +444,7 @@ class LoggingController: public ConnectionTracker
444 { 444 {
445 Toolkit::PushButton button = Toolkit::PushButton::New(); 445 Toolkit::PushButton button = Toolkit::PushButton::New();
446 button.SetName( VSYNC_BUTTON_ID ); 446 button.SetName( VSYNC_BUTTON_ID );
447 - button.SetLabel( VSYNC_BUTTON_TEXT ); 447 + button.SetLabelText( VSYNC_BUTTON_TEXT );
448 button.SetResizePolicy( ResizePolicy::FILL_TO_PARENT, Dimension::WIDTH ); 448 button.SetResizePolicy( ResizePolicy::FILL_TO_PARENT, Dimension::WIDTH );
449 button.SetResizePolicy( ResizePolicy::USE_NATURAL_SIZE, Dimension::HEIGHT ); 449 button.SetResizePolicy( ResizePolicy::USE_NATURAL_SIZE, Dimension::HEIGHT );
450 button.ClickedSignal().Connect( this, &LoggingController::OnButtonClicked ); 450 button.ClickedSignal().Connect( this, &LoggingController::OnButtonClicked );
@@ -464,9 +464,7 @@ class LoggingController: public ConnectionTracker @@ -464,9 +464,7 @@ class LoggingController: public ConnectionTracker
464 << ", " << ((mLoggerStates[i].isTiming) ? "Started" : "Stopped") 464 << ", " << ((mLoggerStates[i].isTiming) ? "Started" : "Stopped")
465 << ", " << ((mLoggerStates[i].isEnabled) ? "Enabled" : "Disabled"); 465 << ", " << ((mLoggerStates[i].isEnabled) ? "Enabled" : "Disabled");
466 466
467 - Toolkit::TextLabel textLabel = Toolkit::TextLabel::New( ss.str() );  
468 -  
469 - mLogRadioButtons[i].SetLabel( textLabel ); 467 + mLogRadioButtons[i].SetLabelText( ss.str() );
470 } 468 }
471 } 469 }
472 470
examples/motion-blur/motion-blur-example.cpp
@@ -166,23 +166,17 @@ public: @@ -166,23 +166,17 @@ public:
166 APPLICATION_TITLE ); 166 APPLICATION_TITLE );
167 167
168 //Add an effects icon on the right of the title 168 //Add an effects icon on the right of the title
169 - mIconEffectsOff = ResourceImage::New( EFFECTS_OFF_ICON );  
170 - mIconEffectsOffSelected = ResourceImage::New( EFFECTS_OFF_ICON_SELECTED );  
171 - mIconEffectsOn = ResourceImage::New( EFFECTS_ON_ICON );  
172 - mIconEffectsOnSelected = ResourceImage::New( EFFECTS_ON_ICON_SELECTED );  
173 mActorEffectsButton = Toolkit::PushButton::New(); 169 mActorEffectsButton = Toolkit::PushButton::New();
174 - mActorEffectsButton.SetButtonImage( mIconEffectsOff );  
175 - mActorEffectsButton.SetSelectedImage( mIconEffectsOffSelected ); 170 + mActorEffectsButton.SetUnselectedImage( EFFECTS_OFF_ICON );
  171 + mActorEffectsButton.SetSelectedImage( EFFECTS_OFF_ICON_SELECTED );
176 mActorEffectsButton.ClickedSignal().Connect( this, &MotionBlurExampleApp::OnEffectButtonClicked ); 172 mActorEffectsButton.ClickedSignal().Connect( this, &MotionBlurExampleApp::OnEffectButtonClicked );
177 mToolBar.AddControl( mActorEffectsButton, DemoHelper::DEFAULT_VIEW_STYLE.mToolBarButtonPercentage, Toolkit::Alignment::HorizontalCenter, DemoHelper::DEFAULT_PLAY_PADDING ); 173 mToolBar.AddControl( mActorEffectsButton, DemoHelper::DEFAULT_VIEW_STYLE.mToolBarButtonPercentage, Toolkit::Alignment::HorizontalCenter, DemoHelper::DEFAULT_PLAY_PADDING );
178 174
179 // Creates a mode button. 175 // Creates a mode button.
180 // Create a effect toggle button. (right of toolbar) 176 // Create a effect toggle button. (right of toolbar)
181 - Image imageLayout = ResourceImage::New( LAYOUT_IMAGE );  
182 - Image imageLayoutSelected = ResourceImage::New( LAYOUT_IMAGE_SELECTED );  
183 Toolkit::PushButton layoutButton = Toolkit::PushButton::New(); 177 Toolkit::PushButton layoutButton = Toolkit::PushButton::New();
184 - layoutButton.SetButtonImage( imageLayout );  
185 - layoutButton.SetSelectedImage( imageLayoutSelected ); 178 + layoutButton.SetUnselectedImage( LAYOUT_IMAGE );
  179 + layoutButton.SetSelectedImage( LAYOUT_IMAGE_SELECTED );
186 layoutButton.ClickedSignal().Connect( this, &MotionBlurExampleApp::OnLayoutButtonClicked); 180 layoutButton.ClickedSignal().Connect( this, &MotionBlurExampleApp::OnLayoutButtonClicked);
187 layoutButton.SetLeaveRequired( true ); 181 layoutButton.SetLeaveRequired( true );
188 mToolBar.AddControl( layoutButton, DemoHelper::DEFAULT_VIEW_STYLE.mToolBarButtonPercentage, Toolkit::Alignment::HorizontalRight, DemoHelper::DEFAULT_MODE_SWITCH_PADDING ); 182 mToolBar.AddControl( layoutButton, DemoHelper::DEFAULT_VIEW_STYLE.mToolBarButtonPercentage, Toolkit::Alignment::HorizontalRight, DemoHelper::DEFAULT_MODE_SWITCH_PADDING );
@@ -455,14 +449,14 @@ public: @@ -455,14 +449,14 @@ public:
455 if(!mActorEffectsEnabled) 449 if(!mActorEffectsEnabled)
456 { 450 {
457 mActorEffectsEnabled = true; 451 mActorEffectsEnabled = true;
458 - mActorEffectsButton.SetButtonImage( mIconEffectsOn );  
459 - mActorEffectsButton.SetSelectedImage( mIconEffectsOnSelected ); 452 + mActorEffectsButton.SetUnselectedImage( EFFECTS_ON_ICON );
  453 + mActorEffectsButton.SetSelectedImage( EFFECTS_ON_ICON_SELECTED );
460 } 454 }
461 else 455 else
462 { 456 {
463 mActorEffectsEnabled = false; 457 mActorEffectsEnabled = false;
464 - mActorEffectsButton.SetButtonImage( mIconEffectsOff );  
465 - mActorEffectsButton.SetSelectedImage( mIconEffectsOffSelected ); 458 + mActorEffectsButton.SetUnselectedImage( EFFECTS_OFF_ICON );
  459 + mActorEffectsButton.SetSelectedImage( EFFECTS_OFF_ICON_SELECTED );
466 } 460 }
467 } 461 }
468 462
@@ -522,10 +516,6 @@ private: @@ -522,10 +516,6 @@ private:
522 Application& mApplication; ///< Application instance 516 Application& mApplication; ///< Application instance
523 Toolkit::Control mView; 517 Toolkit::Control mView;
524 Toolkit::ToolBar mToolBar; 518 Toolkit::ToolBar mToolBar;
525 - Image mIconEffectsOff;  
526 - Image mIconEffectsOffSelected;  
527 - Image mIconEffectsOn;  
528 - Image mIconEffectsOnSelected;  
529 519
530 Layer mContentLayer; ///< Content layer (contains actor for this blur demo) 520 Layer mContentLayer; ///< Content layer (contains actor for this blur demo)
531 521
examples/motion-stretch/motion-stretch-example.cpp
@@ -140,23 +140,17 @@ public: @@ -140,23 +140,17 @@ public:
140 APPLICATION_TITLE ); 140 APPLICATION_TITLE );
141 141
142 //Add an slideshow icon on the right of the title 142 //Add an slideshow icon on the right of the title
143 - mIconEffectsOff = ResourceImage::New( EFFECTS_OFF_ICON );  
144 - mIconEffectsOffSelected = ResourceImage::New( EFFECTS_OFF_ICON_SELECTED );  
145 - mIconEffectsOn = ResourceImage::New( EFFECTS_ON_ICON );  
146 - mIconEffectsOnSelected = ResourceImage::New( EFFECTS_ON_ICON_SELECTED );  
147 mActorEffectsButton = Toolkit::PushButton::New(); 143 mActorEffectsButton = Toolkit::PushButton::New();
148 - mActorEffectsButton.SetButtonImage( mIconEffectsOff );  
149 - mActorEffectsButton.SetSelectedImage( mIconEffectsOffSelected ); 144 + mActorEffectsButton.SetUnselectedImage( EFFECTS_OFF_ICON );
  145 + mActorEffectsButton.SetSelectedImage( EFFECTS_OFF_ICON_SELECTED );
150 mActorEffectsButton.ClickedSignal().Connect( this, &MotionStretchExampleApp::OnEffectButtonClicked ); 146 mActorEffectsButton.ClickedSignal().Connect( this, &MotionStretchExampleApp::OnEffectButtonClicked );
151 mToolBar.AddControl( mActorEffectsButton, DemoHelper::DEFAULT_VIEW_STYLE.mToolBarButtonPercentage, Toolkit::Alignment::HorizontalCenter, DemoHelper::DEFAULT_PLAY_PADDING ); 147 mToolBar.AddControl( mActorEffectsButton, DemoHelper::DEFAULT_VIEW_STYLE.mToolBarButtonPercentage, Toolkit::Alignment::HorizontalCenter, DemoHelper::DEFAULT_PLAY_PADDING );
152 148
153 // Creates a mode button. 149 // Creates a mode button.
154 // Create a effect toggle button. (right of toolbar) 150 // Create a effect toggle button. (right of toolbar)
155 - Image imageLayout = ResourceImage::New( LAYOUT_IMAGE );  
156 - Image imageLayoutSelected = ResourceImage::New( LAYOUT_IMAGE_SELECTED );  
157 Toolkit::PushButton layoutButton = Toolkit::PushButton::New(); 151 Toolkit::PushButton layoutButton = Toolkit::PushButton::New();
158 - layoutButton.SetButtonImage( imageLayout );  
159 - layoutButton.SetSelectedImage( imageLayoutSelected ); 152 + layoutButton.SetUnselectedImage( LAYOUT_IMAGE );
  153 + layoutButton.SetSelectedImage( LAYOUT_IMAGE_SELECTED );
160 layoutButton.ClickedSignal().Connect( this, &MotionStretchExampleApp::OnLayoutButtonClicked); 154 layoutButton.ClickedSignal().Connect( this, &MotionStretchExampleApp::OnLayoutButtonClicked);
161 layoutButton.SetLeaveRequired( true ); 155 layoutButton.SetLeaveRequired( true );
162 mToolBar.AddControl( layoutButton, DemoHelper::DEFAULT_VIEW_STYLE.mToolBarButtonPercentage, Toolkit::Alignment::HorizontalRight, DemoHelper::DEFAULT_MODE_SWITCH_PADDING ); 156 mToolBar.AddControl( layoutButton, DemoHelper::DEFAULT_VIEW_STYLE.mToolBarButtonPercentage, Toolkit::Alignment::HorizontalRight, DemoHelper::DEFAULT_MODE_SWITCH_PADDING );
@@ -349,14 +343,14 @@ public: @@ -349,14 +343,14 @@ public:
349 if(!mActorEffectsEnabled) 343 if(!mActorEffectsEnabled)
350 { 344 {
351 mActorEffectsEnabled = true; 345 mActorEffectsEnabled = true;
352 - mActorEffectsButton.SetButtonImage( mIconEffectsOn );  
353 - mActorEffectsButton.SetSelectedImage( mIconEffectsOnSelected ); 346 + mActorEffectsButton.SetUnselectedImage( EFFECTS_ON_ICON );
  347 + mActorEffectsButton.SetSelectedImage( EFFECTS_ON_ICON_SELECTED );
354 } 348 }
355 else 349 else
356 { 350 {
357 mActorEffectsEnabled = false; 351 mActorEffectsEnabled = false;
358 - mActorEffectsButton.SetButtonImage( mIconEffectsOff );  
359 - mActorEffectsButton.SetSelectedImage( mIconEffectsOffSelected ); 352 + mActorEffectsButton.SetUnselectedImage( EFFECTS_OFF_ICON );
  353 + mActorEffectsButton.SetSelectedImage( EFFECTS_OFF_ICON_SELECTED );
360 } 354 }
361 } 355 }
362 356
@@ -416,10 +410,6 @@ private: @@ -416,10 +410,6 @@ private:
416 Application& mApplication; ///< Application instance 410 Application& mApplication; ///< Application instance
417 Toolkit::Control mView; 411 Toolkit::Control mView;
418 Toolkit::ToolBar mToolBar; 412 Toolkit::ToolBar mToolBar;
419 - Image mIconEffectsOff;  
420 - Image mIconEffectsOffSelected;  
421 - Image mIconEffectsOn;  
422 - Image mIconEffectsOnSelected;  
423 Layer mContentLayer; ///< Content layer (contains actor for this stretch demo) 413 Layer mContentLayer; ///< Content layer (contains actor for this stretch demo)
424 414
425 PushButton mActorEffectsButton; ///< The actor effects toggling Button. 415 PushButton mActorEffectsButton; ///< The actor effects toggling Button.
examples/new-window/new-window-example.cpp
@@ -124,7 +124,7 @@ public: @@ -124,7 +124,7 @@ public:
124 void AddBlendingImageActor(); 124 void AddBlendingImageActor();
125 void AddTextLabel(); 125 void AddTextLabel();
126 126
127 - ImageActor CreateBlurredMirrorImage(const char* imageName); 127 + ImageView CreateBlurredMirrorImage(const char* imageName);
128 FrameBufferImage CreateFrameBufferForImage(const char* imageName, Image image, ShaderEffect shaderEffect); 128 FrameBufferImage CreateFrameBufferForImage(const char* imageName, Image image, ShaderEffect shaderEffect);
129 void SetUpBubbleEmission( const Vector2& emitPosition, const Vector2& direction ); 129 void SetUpBubbleEmission( const Vector2& emitPosition, const Vector2& direction );
130 Geometry CreateMeshGeometry(); 130 Geometry CreateMeshGeometry();
@@ -199,8 +199,8 @@ void NewWindowController::Create( Application&amp; app ) @@ -199,8 +199,8 @@ void NewWindowController::Create( Application&amp; app )
199 } 199 }
200 200
201 mLoseContextButton = Toolkit::PushButton::New(); 201 mLoseContextButton = Toolkit::PushButton::New();
202 - mLoseContextButton.SetButtonImage( ResourceImage::New( LOSE_CONTEXT_IMAGE ) );  
203 - mLoseContextButton.SetSelectedImage( ResourceImage::New( LOSE_CONTEXT_IMAGE_SELECTED ) ); 202 + mLoseContextButton.SetUnselectedImage( LOSE_CONTEXT_IMAGE );
  203 + mLoseContextButton.SetSelectedImage( LOSE_CONTEXT_IMAGE_SELECTED );
204 mLoseContextButton.ClickedSignal().Connect( this, &NewWindowController::OnLoseContextButtonClicked ); 204 mLoseContextButton.ClickedSignal().Connect( this, &NewWindowController::OnLoseContextButtonClicked );
205 mToolBar.AddControl( mLoseContextButton, DemoHelper::DEFAULT_VIEW_STYLE.mToolBarButtonPercentage, Toolkit::Alignment::HorizontalRight, DemoHelper::DEFAULT_MODE_SWITCH_PADDING ); 205 mToolBar.AddControl( mLoseContextButton, DemoHelper::DEFAULT_VIEW_STYLE.mToolBarButtonPercentage, Toolkit::Alignment::HorizontalRight, DemoHelper::DEFAULT_MODE_SWITCH_PADDING );
206 206
@@ -211,16 +211,16 @@ void NewWindowController::Create( Application&amp; app ) @@ -211,16 +211,16 @@ void NewWindowController::Create( Application&amp; app )
211 mContentLayer.Add(logoLayoutActor); 211 mContentLayer.Add(logoLayoutActor);
212 212
213 Image image = ResourceImage::New(LOGO_IMAGE); 213 Image image = ResourceImage::New(LOGO_IMAGE);
214 - ImageActor imageActor = ImageActor::New(image);  
215 - imageActor.SetName("dali-logo");  
216 - imageActor.SetParentOrigin(ParentOrigin::CENTER);  
217 - imageActor.SetAnchorPoint(AnchorPoint::BOTTOM_CENTER);  
218 - logoLayoutActor.Add(imageActor); 214 + ImageView imageView = ImageView::New(image);
  215 + imageView.SetName("dali-logo");
  216 + imageView.SetParentOrigin(ParentOrigin::CENTER);
  217 + imageView.SetAnchorPoint(AnchorPoint::BOTTOM_CENTER);
  218 + logoLayoutActor.Add(imageView);
219 219
220 - ImageActor mirrorImageActor = CreateBlurredMirrorImage(LOGO_IMAGE);  
221 - mirrorImageActor.SetParentOrigin(ParentOrigin::CENTER);  
222 - mirrorImageActor.SetAnchorPoint(AnchorPoint::TOP_CENTER);  
223 - logoLayoutActor.Add(mirrorImageActor); 220 + ImageView mirrorImageView = CreateBlurredMirrorImage(LOGO_IMAGE);
  221 + mirrorImageView.SetParentOrigin(ParentOrigin::CENTER);
  222 + mirrorImageView.SetAnchorPoint(AnchorPoint::TOP_CENTER);
  223 + logoLayoutActor.Add(mirrorImageView);
224 224
225 AddBubbles(stage.GetSize()); 225 AddBubbles(stage.GetSize());
226 AddMeshActor(); 226 AddMeshActor();
@@ -300,7 +300,7 @@ void NewWindowController::AddBlendingImageActor() @@ -300,7 +300,7 @@ void NewWindowController::AddBlendingImageActor()
300 Image effectImage = ResourceImage::New(EFFECT_IMAGE); 300 Image effectImage = ResourceImage::New(EFFECT_IMAGE);
301 FrameBufferImage fb2 = CreateFrameBufferForImage( EFFECT_IMAGE, effectImage, colorModifier ); 301 FrameBufferImage fb2 = CreateFrameBufferForImage( EFFECT_IMAGE, effectImage, colorModifier );
302 302
303 - ImageActor tmpActor = ImageActor::New(fb2); 303 + ImageView tmpActor = ImageView::New(fb2);
304 mContentLayer.Add(tmpActor); 304 mContentLayer.Add(tmpActor);
305 tmpActor.SetParentOrigin(ParentOrigin::CENTER_RIGHT); 305 tmpActor.SetParentOrigin(ParentOrigin::CENTER_RIGHT);
306 tmpActor.SetAnchorPoint(AnchorPoint::TOP_RIGHT); 306 tmpActor.SetAnchorPoint(AnchorPoint::TOP_RIGHT);
@@ -331,7 +331,7 @@ void NewWindowController::AddTextLabel() @@ -331,7 +331,7 @@ void NewWindowController::AddTextLabel()
331 mContentLayer.Add( mTextActor ); 331 mContentLayer.Add( mTextActor );
332 } 332 }
333 333
334 -ImageActor NewWindowController::CreateBlurredMirrorImage(const char* imageName) 334 +ImageView NewWindowController::CreateBlurredMirrorImage(const char* imageName)
335 { 335 {
336 Image image = ResourceImage::New(imageName); 336 Image image = ResourceImage::New(imageName);
337 337
@@ -346,7 +346,7 @@ ImageActor NewWindowController::CreateBlurredMirrorImage(const char* imageName) @@ -346,7 +346,7 @@ ImageActor NewWindowController::CreateBlurredMirrorImage(const char* imageName)
346 Stage::GetCurrent().Add(gbv); 346 Stage::GetCurrent().Add(gbv);
347 gbv.ActivateOnce(); 347 gbv.ActivateOnce();
348 348
349 - ImageActor blurredActor = ImageActor::New(fbo); 349 + ImageView blurredActor = ImageView::New(fbo);
350 blurredActor.SetSize(FBOSize); 350 blurredActor.SetSize(FBOSize);
351 blurredActor.SetScale(1.0f, -1.0f, 1.0f); 351 blurredActor.SetScale(1.0f, -1.0f, 1.0f);
352 return blurredActor; 352 return blurredActor;
examples/radial-menu/radial-menu-example.cpp
@@ -104,16 +104,12 @@ private: // Member variables @@ -104,16 +104,12 @@ private: // Member variables
104 Application mApplication; ///< The application handle 104 Application mApplication; ///< The application handle
105 Toolkit::Control mView; ///< The toolbar view 105 Toolkit::Control mView; ///< The toolbar view
106 Layer mContents; ///< The toolbar contents pane 106 Layer mContents; ///< The toolbar contents pane
107 - ImageActor mImageActor; ///< Image actor shown by stencil mask 107 + ImageView mImageView; ///< Image view shown by stencil mask
108 Animation mAnimation; 108 Animation mAnimation;
109 AnimState mAnimationState; 109 AnimState mAnimationState;
110 110
111 - Image mIconPlay;  
112 - Image mIconPlaySelected;  
113 - Image mIconStop;  
114 - Image mIconStopSelected;  
115 Toolkit::PushButton mPlayStopButton; 111 Toolkit::PushButton mPlayStopButton;
116 - ImageActor mDialActor; 112 + ImageView mDialView;
117 RadialSweepView mRadialSweepView1; 113 RadialSweepView mRadialSweepView1;
118 RadialSweepView mRadialSweepView2; 114 RadialSweepView mRadialSweepView2;
119 RadialSweepView mRadialSweepView3; 115 RadialSweepView mRadialSweepView3;
@@ -148,13 +144,9 @@ void RadialMenuExample::OnInit(Application&amp; app) @@ -148,13 +144,9 @@ void RadialMenuExample::OnInit(Application&amp; app)
148 TOOLBAR_IMAGE, 144 TOOLBAR_IMAGE,
149 APPLICATION_TITLE ); 145 APPLICATION_TITLE );
150 146
151 - mIconPlay = ResourceImage::New( PLAY_ICON );  
152 - mIconPlaySelected = ResourceImage::New( PLAY_ICON_SELECTED );  
153 - mIconStop = ResourceImage::New( STOP_ICON );  
154 - mIconStopSelected = ResourceImage::New( STOP_ICON_SELECTED );  
155 mPlayStopButton = Toolkit::PushButton::New(); 147 mPlayStopButton = Toolkit::PushButton::New();
156 - mPlayStopButton.SetButtonImage( mIconStop );  
157 - mPlayStopButton.SetSelectedImage( mIconStopSelected ); 148 + mPlayStopButton.SetUnselectedImage( STOP_ICON );
  149 + mPlayStopButton.SetSelectedImage( STOP_ICON_SELECTED );
158 150
159 mPlayStopButton.ClickedSignal().Connect( this, &RadialMenuExample::OnButtonClicked ); 151 mPlayStopButton.ClickedSignal().Connect( this, &RadialMenuExample::OnButtonClicked );
160 152
@@ -181,13 +173,13 @@ void RadialMenuExample::OnInit(Application&amp; app) @@ -181,13 +173,13 @@ void RadialMenuExample::OnInit(Application&amp; app)
181 mRadialSweepView3.SetFinalActorAngle(Degree(0)); 173 mRadialSweepView3.SetFinalActorAngle(Degree(0));
182 174
183 Image dial = ResourceImage::New( TEST_DIAL_FILENAME ); 175 Image dial = ResourceImage::New( TEST_DIAL_FILENAME );
184 - mDialActor = ImageActor::New( dial );  
185 - mDialActor.SetResizePolicy( ResizePolicy::USE_NATURAL_SIZE, Dimension::ALL_DIMENSIONS );  
186 - mDialActor.SetPositionInheritanceMode(USE_PARENT_POSITION);  
187 - mDialActor.SetScale(scale); 176 + mDialView = ImageView::New( dial );
  177 + mDialView.SetResizePolicy( ResizePolicy::USE_NATURAL_SIZE, Dimension::ALL_DIMENSIONS );
  178 + mDialView.SetPositionInheritanceMode(USE_PARENT_POSITION);
  179 + mDialView.SetScale(scale);
188 Layer dialLayer = Layer::New(); 180 Layer dialLayer = Layer::New();
189 181
190 - dialLayer.Add(mDialActor); 182 + dialLayer.Add( mDialView );
191 dialLayer.SetPositionInheritanceMode(USE_PARENT_POSITION); 183 dialLayer.SetPositionInheritanceMode(USE_PARENT_POSITION);
192 dialLayer.SetSize(stage.GetSize()); 184 dialLayer.SetSize(stage.GetSize());
193 mContents.Add(dialLayer); 185 mContents.Add(dialLayer);
@@ -201,13 +193,13 @@ void RadialMenuExample::OnInit(Application&amp; app) @@ -201,13 +193,13 @@ void RadialMenuExample::OnInit(Application&amp; app)
201 193
202 void RadialMenuExample::StartAnimation() 194 void RadialMenuExample::StartAnimation()
203 { 195 {
204 - mDialActor.SetOpacity(0.0f); 196 + mDialView.SetOpacity(0.0f);
205 mRadialSweepView1.SetOpacity(0.0f); 197 mRadialSweepView1.SetOpacity(0.0f);
206 mAnimation = Animation::New(6.0f); 198 mAnimation = Animation::New(6.0f);
207 mRadialSweepView1.Activate(mAnimation, 0.0f, 3.0f); 199 mRadialSweepView1.Activate(mAnimation, 0.0f, 3.0f);
208 mRadialSweepView2.Activate(mAnimation, 1.5f, 3.0f); 200 mRadialSweepView2.Activate(mAnimation, 1.5f, 3.0f);
209 mRadialSweepView3.Activate(mAnimation, 3.0f, 3.0f); 201 mRadialSweepView3.Activate(mAnimation, 3.0f, 3.0f);
210 - mAnimation.AnimateTo( Property( mDialActor, Actor::Property::COLOR_ALPHA ), 1.0f, AlphaFunction::EASE_IN, TimePeriod( 0.0f, 0.8f ) ); 202 + mAnimation.AnimateTo( Property( mDialView, Actor::Property::COLOR_ALPHA ), 1.0f, AlphaFunction::EASE_IN, TimePeriod( 0.0f, 0.8f ) );
211 mAnimation.AnimateTo( Property( mRadialSweepView1, Actor::Property::COLOR_ALPHA ), 1.0f, AlphaFunction::EASE_IN, TimePeriod( 0.0f, 0.5f ) ); 203 mAnimation.AnimateTo( Property( mRadialSweepView1, Actor::Property::COLOR_ALPHA ), 1.0f, AlphaFunction::EASE_IN, TimePeriod( 0.0f, 0.5f ) );
212 mAnimation.FinishedSignal().Connect( this, &RadialMenuExample::OnAnimationFinished ); 204 mAnimation.FinishedSignal().Connect( this, &RadialMenuExample::OnAnimationFinished );
213 205
@@ -223,8 +215,8 @@ bool RadialMenuExample::OnButtonClicked( Toolkit::Button button ) @@ -223,8 +215,8 @@ bool RadialMenuExample::OnButtonClicked( Toolkit::Button button )
223 { 215 {
224 mAnimation.Pause(); 216 mAnimation.Pause();
225 mAnimationState = PAUSED; 217 mAnimationState = PAUSED;
226 - mPlayStopButton.SetButtonImage( mIconPlay );  
227 - mPlayStopButton.SetSelectedImage( mIconPlaySelected ); 218 + mPlayStopButton.SetUnselectedImage( PLAY_ICON );
  219 + mPlayStopButton.SetSelectedImage( PLAY_ICON_SELECTED );
228 } 220 }
229 break; 221 break;
230 222
@@ -232,15 +224,15 @@ bool RadialMenuExample::OnButtonClicked( Toolkit::Button button ) @@ -232,15 +224,15 @@ bool RadialMenuExample::OnButtonClicked( Toolkit::Button button )
232 { 224 {
233 mAnimation.Play(); 225 mAnimation.Play();
234 mAnimationState = PLAYING; 226 mAnimationState = PLAYING;
235 - mPlayStopButton.SetButtonImage( mIconStop );  
236 - mPlayStopButton.SetSelectedImage( mIconStopSelected ); 227 + mPlayStopButton.SetUnselectedImage( STOP_ICON );
  228 + mPlayStopButton.SetSelectedImage( STOP_ICON_SELECTED );
237 } 229 }
238 break; 230 break;
239 231
240 case STOPPED: 232 case STOPPED:
241 { 233 {
242 - mPlayStopButton.SetButtonImage( mIconStop );  
243 - mPlayStopButton.SetSelectedImage( mIconStopSelected ); 234 + mPlayStopButton.SetUnselectedImage( STOP_ICON );
  235 + mPlayStopButton.SetSelectedImage( STOP_ICON_SELECTED );
244 mRadialSweepView1.Deactivate(); 236 mRadialSweepView1.Deactivate();
245 mRadialSweepView2.Deactivate(); 237 mRadialSweepView2.Deactivate();
246 mRadialSweepView3.Deactivate(); 238 mRadialSweepView3.Deactivate();
@@ -253,8 +245,8 @@ bool RadialMenuExample::OnButtonClicked( Toolkit::Button button ) @@ -253,8 +245,8 @@ bool RadialMenuExample::OnButtonClicked( Toolkit::Button button )
253 void RadialMenuExample::OnAnimationFinished( Animation& source ) 245 void RadialMenuExample::OnAnimationFinished( Animation& source )
254 { 246 {
255 mAnimationState = STOPPED; 247 mAnimationState = STOPPED;
256 - mPlayStopButton.SetButtonImage( mIconPlay );  
257 - mPlayStopButton.SetSelectedImage( mIconPlaySelected ); 248 + mPlayStopButton.SetUnselectedImage( PLAY_ICON );
  249 + mPlayStopButton.SetSelectedImage( PLAY_ICON_SELECTED );
258 } 250 }
259 251
260 RadialSweepView RadialMenuExample::CreateSweepView( std::string imageName, 252 RadialSweepView RadialMenuExample::CreateSweepView( std::string imageName,
@@ -263,10 +255,10 @@ RadialSweepView RadialMenuExample::CreateSweepView( std::string imageName, @@ -263,10 +255,10 @@ RadialSweepView RadialMenuExample::CreateSweepView( std::string imageName,
263 { 255 {
264 // Create the image 256 // Create the image
265 Image image = ResourceImage::New(imageName); 257 Image image = ResourceImage::New(imageName);
266 - mImageActor = ImageActor::New(image);  
267 - mImageActor.SetParentOrigin(ParentOrigin::CENTER);  
268 - mImageActor.SetAnchorPoint(AnchorPoint::CENTER);  
269 - mImageActor.SetResizePolicy( ResizePolicy::USE_NATURAL_SIZE, Dimension::ALL_DIMENSIONS ); 258 + mImageView = ImageView::New(image);
  259 + mImageView.SetParentOrigin(ParentOrigin::CENTER);
  260 + mImageView.SetAnchorPoint(AnchorPoint::CENTER);
  261 + mImageView.SetResizePolicy( ResizePolicy::USE_NATURAL_SIZE, Dimension::ALL_DIMENSIONS );
270 262
271 // Create the stencil 263 // Create the stencil
272 const ImageDimensions imageSize = ResourceImage::GetImageSize(imageName); 264 const ImageDimensions imageSize = ResourceImage::GetImageSize(imageName);
@@ -281,8 +273,8 @@ RadialSweepView RadialMenuExample::CreateSweepView( std::string imageName, @@ -281,8 +273,8 @@ RadialSweepView RadialMenuExample::CreateSweepView( std::string imageName,
281 radialSweepView.SetEasingFunction( Dali::AlphaFunction::EASE_IN_OUT ); 273 radialSweepView.SetEasingFunction( Dali::AlphaFunction::EASE_IN_OUT );
282 radialSweepView.SetPositionInheritanceMode(USE_PARENT_POSITION); 274 radialSweepView.SetPositionInheritanceMode(USE_PARENT_POSITION);
283 mContents.Add(radialSweepView); 275 mContents.Add(radialSweepView);
284 - radialSweepView.Add( mImageActor );  
285 - mImageActor.SetPositionInheritanceMode(USE_PARENT_POSITION); 276 + radialSweepView.Add( mImageView );
  277 + mImageView.SetPositionInheritanceMode(USE_PARENT_POSITION);
286 278
287 return radialSweepView; 279 return radialSweepView;
288 } 280 }
examples/refraction-effect/refraction-effect-example.cpp
@@ -257,8 +257,8 @@ private: @@ -257,8 +257,8 @@ private:
257 257
258 // Add a button to change background. (right of toolbar) 258 // Add a button to change background. (right of toolbar)
259 mChangeTextureButton = Toolkit::PushButton::New(); 259 mChangeTextureButton = Toolkit::PushButton::New();
260 - mChangeTextureButton.SetButtonImage( ResourceImage::New( CHANGE_TEXTURE_ICON ) );  
261 - mChangeTextureButton.SetSelectedImage( ResourceImage::New( CHANGE_TEXTURE_ICON_SELECTED ) ); 260 + mChangeTextureButton.SetUnselectedImage( CHANGE_TEXTURE_ICON );
  261 + mChangeTextureButton.SetSelectedImage( CHANGE_TEXTURE_ICON_SELECTED );
262 mChangeTextureButton.ClickedSignal().Connect( this, &RefractionEffectExample::OnChangeTexture ); 262 mChangeTextureButton.ClickedSignal().Connect( this, &RefractionEffectExample::OnChangeTexture );
263 toolBar.AddControl( mChangeTextureButton, 263 toolBar.AddControl( mChangeTextureButton,
264 DemoHelper::DEFAULT_VIEW_STYLE.mToolBarButtonPercentage, 264 DemoHelper::DEFAULT_VIEW_STYLE.mToolBarButtonPercentage,
@@ -266,8 +266,8 @@ private: @@ -266,8 +266,8 @@ private:
266 DemoHelper::DEFAULT_MODE_SWITCH_PADDING ); 266 DemoHelper::DEFAULT_MODE_SWITCH_PADDING );
267 // Add a button to change mesh pattern. ( left of bar ) 267 // Add a button to change mesh pattern. ( left of bar )
268 mChangeMeshButton = Toolkit::PushButton::New(); 268 mChangeMeshButton = Toolkit::PushButton::New();
269 - mChangeMeshButton.SetButtonImage( ResourceImage::New( CHANGE_MESH_ICON ) );  
270 - mChangeMeshButton.SetSelectedImage( ResourceImage::New( CHANGE_MESH_ICON_SELECTED ) ); 269 + mChangeMeshButton.SetUnselectedImage( CHANGE_MESH_ICON );
  270 + mChangeMeshButton.SetSelectedImage( CHANGE_MESH_ICON_SELECTED );
271 mChangeMeshButton.ClickedSignal().Connect( this, &RefractionEffectExample::OnChangeMesh ); 271 mChangeMeshButton.ClickedSignal().Connect( this, &RefractionEffectExample::OnChangeMesh );
272 toolBar.AddControl( mChangeMeshButton, 272 toolBar.AddControl( mChangeMeshButton,
273 DemoHelper::DEFAULT_VIEW_STYLE.mToolBarButtonPercentage, 273 DemoHelper::DEFAULT_VIEW_STYLE.mToolBarButtonPercentage,
examples/scroll-view/scroll-view-example.cpp
@@ -173,14 +173,14 @@ public: @@ -173,14 +173,14 @@ public:
173 TOOLBAR_IMAGE, 173 TOOLBAR_IMAGE,
174 "" ); 174 "" );
175 175
176 - mEffectIcon[ PageCarouselEffect ] = ResourceImage::New( EFFECT_CAROUSEL_IMAGE );  
177 - mEffectIconSelected[ PageCarouselEffect ] = ResourceImage::New( EFFECT_CAROUSEL_IMAGE_SELECTED );  
178 - mEffectIcon[ PageCubeEffect ] = ResourceImage::New( EFFECT_CAROUSEL_IMAGE );  
179 - mEffectIconSelected[ PageCubeEffect ] = ResourceImage::New( EFFECT_CAROUSEL_IMAGE_SELECTED );  
180 - mEffectIcon[ PageSpiralEffect ] = ResourceImage::New( EFFECT_CAROUSEL_IMAGE );  
181 - mEffectIconSelected[ PageSpiralEffect ] = ResourceImage::New( EFFECT_CAROUSEL_IMAGE_SELECTED );  
182 - mEffectIcon[ PageWaveEffect ] = ResourceImage::New( EFFECT_CAROUSEL_IMAGE );  
183 - mEffectIconSelected[ PageWaveEffect ] = ResourceImage::New( EFFECT_CAROUSEL_IMAGE_SELECTED ); 176 + mEffectIcon[ PageCarouselEffect ] = EFFECT_CAROUSEL_IMAGE;
  177 + mEffectIconSelected[ PageCarouselEffect ] = EFFECT_CAROUSEL_IMAGE_SELECTED;
  178 + mEffectIcon[ PageCubeEffect ] = EFFECT_CAROUSEL_IMAGE;
  179 + mEffectIconSelected[ PageCubeEffect ] = EFFECT_CAROUSEL_IMAGE_SELECTED;
  180 + mEffectIcon[ PageSpiralEffect ] = EFFECT_CAROUSEL_IMAGE;
  181 + mEffectIconSelected[ PageSpiralEffect ] = EFFECT_CAROUSEL_IMAGE_SELECTED;
  182 + mEffectIcon[ PageWaveEffect ] = EFFECT_CAROUSEL_IMAGE;
  183 + mEffectIconSelected[ PageWaveEffect ] = EFFECT_CAROUSEL_IMAGE_SELECTED;
184 184
185 // Create a effect change button. (right of toolbar) 185 // Create a effect change button. (right of toolbar)
186 mEffectChangeButton = Toolkit::PushButton::New(); 186 mEffectChangeButton = Toolkit::PushButton::New();
@@ -244,7 +244,7 @@ private: @@ -244,7 +244,7 @@ private:
244 ss << APPLICATION_TITLE << ": " << EFFECT_MODE_NAME[mEffectMode]; 244 ss << APPLICATION_TITLE << ": " << EFFECT_MODE_NAME[mEffectMode];
245 SetTitle(ss.str()); 245 SetTitle(ss.str());
246 246
247 - mEffectChangeButton.SetButtonImage( mEffectIcon[ mEffectMode ] ); 247 + mEffectChangeButton.SetUnselectedImage( mEffectIcon[ mEffectMode ] );
248 mEffectChangeButton.SetSelectedImage( mEffectIconSelected[ mEffectMode ] ); 248 mEffectChangeButton.SetSelectedImage( mEffectIconSelected[ mEffectMode ] );
249 249
250 // remove old Effect if exists. 250 // remove old Effect if exists.
@@ -286,7 +286,7 @@ private: @@ -286,7 +286,7 @@ private:
286 { 286 {
287 for(int column = 0;column<imageColumns;column++) 287 for(int column = 0;column<imageColumns;column++)
288 { 288 {
289 - ImageActor image = CreateImage( GetNextImagePath(), imageSize.x, imageSize.y ); 289 + ImageView image = CreateImage( GetNextImagePath(), imageSize.x, imageSize.y );
290 290
291 image.SetParentOrigin( ParentOrigin::CENTER ); 291 image.SetParentOrigin( ParentOrigin::CENTER );
292 image.SetAnchorPoint( AnchorPoint::CENTER ); 292 image.SetAnchorPoint( AnchorPoint::CENTER );
@@ -458,11 +458,11 @@ private: @@ -458,11 +458,11 @@ private:
458 * @param[in] width the width of the image in texels 458 * @param[in] width the width of the image in texels
459 * @param[in] height the height of the image in texels. 459 * @param[in] height the height of the image in texels.
460 */ 460 */
461 - ImageActor CreateImage( const std::string& filename, unsigned int width = IMAGE_THUMBNAIL_WIDTH, unsigned int height = IMAGE_THUMBNAIL_HEIGHT ) 461 + ImageView CreateImage( const std::string& filename, unsigned int width = IMAGE_THUMBNAIL_WIDTH, unsigned int height = IMAGE_THUMBNAIL_HEIGHT )
462 { 462 {
463 Image img = ResourceImage::New(filename, ImageDimensions( width, height ), Dali::FittingMode::SCALE_TO_FILL, Dali::SamplingMode::BOX_THEN_LINEAR ); 463 Image img = ResourceImage::New(filename, ImageDimensions( width, height ), Dali::FittingMode::SCALE_TO_FILL, Dali::SamplingMode::BOX_THEN_LINEAR );
464 464
465 - ImageActor actor = ImageActor::New(img); 465 + ImageView actor = ImageView::New(img);
466 actor.SetName( filename ); 466 actor.SetName( filename );
467 actor.SetParentOrigin(ParentOrigin::CENTER); 467 actor.SetParentOrigin(ParentOrigin::CENTER);
468 actor.SetAnchorPoint(AnchorPoint::CENTER); 468 actor.SetAnchorPoint(AnchorPoint::CENTER);
@@ -582,8 +582,8 @@ private: @@ -582,8 +582,8 @@ private:
582 582
583 EffectMode mEffectMode; ///< Current Effect mode 583 EffectMode mEffectMode; ///< Current Effect mode
584 584
585 - Image mEffectIcon[Total]; ///< Icons for the effect button  
586 - Image mEffectIconSelected[Total]; ///< Icons for the effect button when its selected 585 + std::string mEffectIcon[Total]; ///< Icons for the effect button
  586 + std::string mEffectIconSelected[Total]; ///< Icons for the effect button when its selected
587 Toolkit::PushButton mEffectChangeButton; ///< Effect Change Button 587 Toolkit::PushButton mEffectChangeButton; ///< Effect Change Button
588 }; 588 };
589 589
examples/shadow-bone-lighting/shadow-bone-lighting-example.cpp
@@ -146,11 +146,9 @@ public: @@ -146,11 +146,9 @@ public:
146 "" ); 146 "" );
147 147
148 // Add an effect-changing button on the right of the tool bar. 148 // Add an effect-changing button on the right of the tool bar.
149 - Image imageChangeEffect = ResourceImage::New( CHANGE_EFFECT_IMAGE );  
150 - Image imageChangeEffectSelected = ResourceImage::New( CHANGE_EFFECT_IMAGE_SELECTED );  
151 Toolkit::PushButton effectChangeButton = Toolkit::PushButton::New(); 149 Toolkit::PushButton effectChangeButton = Toolkit::PushButton::New();
152 - effectChangeButton.SetButtonImage( imageChangeEffect );  
153 - effectChangeButton.SetSelectedImage( imageChangeEffectSelected ); 150 + effectChangeButton.SetUnselectedImage( CHANGE_EFFECT_IMAGE );
  151 + effectChangeButton.SetSelectedImage( CHANGE_EFFECT_IMAGE_SELECTED );
154 effectChangeButton.ClickedSignal().Connect( this, &TestApp::OnEffectButtonClicked ); 152 effectChangeButton.ClickedSignal().Connect( this, &TestApp::OnEffectButtonClicked );
155 toolBar.AddControl( effectChangeButton, DemoHelper::DEFAULT_VIEW_STYLE.mToolBarButtonPercentage, Toolkit::Alignment::HorizontalRight, DemoHelper::DEFAULT_MODE_SWITCH_PADDING ); 153 toolBar.AddControl( effectChangeButton, DemoHelper::DEFAULT_VIEW_STYLE.mToolBarButtonPercentage, Toolkit::Alignment::HorizontalRight, DemoHelper::DEFAULT_MODE_SWITCH_PADDING );
156 154
@@ -162,11 +160,9 @@ public: @@ -162,11 +160,9 @@ public:
162 mTitleActor.SetProperty( TextLabel::Property::TEXT, std::string(APPLICATION_TITLE_PAN_SCENE) ); 160 mTitleActor.SetProperty( TextLabel::Property::TEXT, std::string(APPLICATION_TITLE_PAN_SCENE) );
163 161
164 //Add a reset button 162 //Add a reset button
165 - Image resetImage = ResourceImage::New( RESET_ICON );  
166 - Image resetImageSelected = ResourceImage::New( RESET_ICON_SELECTED );  
167 Toolkit::PushButton resetButton = Toolkit::PushButton::New(); 163 Toolkit::PushButton resetButton = Toolkit::PushButton::New();
168 - resetButton.SetButtonImage( resetImage );  
169 - resetButton.SetSelectedImage( resetImageSelected ); 164 + resetButton.SetUnselectedImage( RESET_ICON );
  165 + resetButton.SetSelectedImage( RESET_ICON_SELECTED );
170 resetButton.ClickedSignal().Connect( this, &TestApp::OnResetPressed ); 166 resetButton.ClickedSignal().Connect( this, &TestApp::OnResetPressed );
171 toolBar.AddControl( resetButton, DemoHelper::DEFAULT_VIEW_STYLE.mToolBarButtonPercentage, Toolkit::Alignment::HorizontalCenter, DemoHelper::DEFAULT_PLAY_PADDING ); 167 toolBar.AddControl( resetButton, DemoHelper::DEFAULT_VIEW_STYLE.mToolBarButtonPercentage, Toolkit::Alignment::HorizontalCenter, DemoHelper::DEFAULT_PLAY_PADDING );
172 168
examples/size-negotiation/size-negotiation-example.cpp
@@ -176,8 +176,8 @@ public: @@ -176,8 +176,8 @@ public:
176 176
177 // Create menu button 177 // Create menu button
178 Toolkit::PushButton viewButton = Toolkit::PushButton::New(); 178 Toolkit::PushButton viewButton = Toolkit::PushButton::New();
179 - viewButton.SetButtonImage( ResourceImage::New( MENU_ICON_IMAGE ) );  
180 - viewButton.SetSelectedImage( ResourceImage::New( MENU_ICON_IMAGE_SELECTED ) ); 179 + viewButton.SetUnselectedImage( MENU_ICON_IMAGE );
  180 + viewButton.SetSelectedImage( MENU_ICON_IMAGE_SELECTED );
181 viewButton.ClickedSignal().Connect( this, &SizeNegotiationController::OnMenu ); 181 viewButton.ClickedSignal().Connect( this, &SizeNegotiationController::OnMenu );
182 mToolBar.AddControl( viewButton, DemoHelper::DEFAULT_VIEW_STYLE.mToolBarButtonPercentage, Toolkit::Alignment::HorizontalLeft, DemoHelper::DEFAULT_MODE_SWITCH_PADDING ); 182 mToolBar.AddControl( viewButton, DemoHelper::DEFAULT_VIEW_STYLE.mToolBarButtonPercentage, Toolkit::Alignment::HorizontalLeft, DemoHelper::DEFAULT_MODE_SWITCH_PADDING );
183 183
@@ -259,9 +259,9 @@ public: @@ -259,9 +259,9 @@ public:
259 { 259 {
260 Toolkit::PushButton menuButton = Toolkit::PushButton::New(); 260 Toolkit::PushButton menuButton = Toolkit::PushButton::New();
261 menuButton.SetName( MENU_ITEMS[ i ].name ); 261 menuButton.SetName( MENU_ITEMS[ i ].name );
262 - menuButton.SetLabel( MENU_ITEMS[ i ].text );  
263 - menuButton.SetButtonImage( Actor() );  
264 - menuButton.SetSelectedImage( Actor() ); 262 + menuButton.SetLabelText( MENU_ITEMS[ i ].text );
  263 + menuButton.SetUnselectedImage( "" );
  264 + menuButton.SetSelectedImage( "" );
265 menuButton.ClickedSignal().Connect( this, &SizeNegotiationController::OnMenuSelect ); 265 menuButton.ClickedSignal().Connect( this, &SizeNegotiationController::OnMenuSelect );
266 266
267 tableView.Add( menuButton ); 267 tableView.Add( menuButton );
@@ -354,7 +354,7 @@ public: @@ -354,7 +354,7 @@ public:
354 354
355 Toolkit::PushButton okayButton = Toolkit::PushButton::New(); 355 Toolkit::PushButton okayButton = Toolkit::PushButton::New();
356 okayButton.SetName( OKAY_BUTTON_ID ); 356 okayButton.SetName( OKAY_BUTTON_ID );
357 - okayButton.SetLabel( "OK!" ); 357 + okayButton.SetLabelText( "OK!" );
358 358
359 okayButton.ClickedSignal().Connect( this, &SizeNegotiationController::OnButtonClicked ); 359 okayButton.ClickedSignal().Connect( this, &SizeNegotiationController::OnButtonClicked );
360 360
@@ -368,7 +368,7 @@ public: @@ -368,7 +368,7 @@ public:
368 368
369 Toolkit::PushButton cancelButton = Toolkit::PushButton::New(); 369 Toolkit::PushButton cancelButton = Toolkit::PushButton::New();
370 cancelButton.SetName( CANCEL_BUTTON_ID ); 370 cancelButton.SetName( CANCEL_BUTTON_ID );
371 - cancelButton.SetLabel( "Cancel" ); 371 + cancelButton.SetLabelText( "Cancel" );
372 372
373 cancelButton.ClickedSignal().Connect( this, &SizeNegotiationController::OnButtonClicked ); 373 cancelButton.ClickedSignal().Connect( this, &SizeNegotiationController::OnButtonClicked );
374 374
@@ -376,7 +376,7 @@ public: @@ -376,7 +376,7 @@ public:
376 376
377 Toolkit::PushButton okayButton = Toolkit::PushButton::New(); 377 Toolkit::PushButton okayButton = Toolkit::PushButton::New();
378 okayButton.SetName( OKAY_BUTTON_ID ); 378 okayButton.SetName( OKAY_BUTTON_ID );
379 - okayButton.SetLabel( "OK!" ); 379 + okayButton.SetLabelText( "OK!" );
380 380
381 okayButton.ClickedSignal().Connect( this, &SizeNegotiationController::OnButtonClicked ); 381 okayButton.ClickedSignal().Connect( this, &SizeNegotiationController::OnButtonClicked );
382 382
@@ -391,7 +391,7 @@ public: @@ -391,7 +391,7 @@ public:
391 391
392 Toolkit::PushButton cancelButton = Toolkit::PushButton::New(); 392 Toolkit::PushButton cancelButton = Toolkit::PushButton::New();
393 cancelButton.SetName( CANCEL_BUTTON_ID ); 393 cancelButton.SetName( CANCEL_BUTTON_ID );
394 - cancelButton.SetLabel( "Cancel" ); 394 + cancelButton.SetLabelText( "Cancel" );
395 395
396 cancelButton.ClickedSignal().Connect( this, &SizeNegotiationController::OnButtonClicked ); 396 cancelButton.ClickedSignal().Connect( this, &SizeNegotiationController::OnButtonClicked );
397 397
@@ -399,7 +399,7 @@ public: @@ -399,7 +399,7 @@ public:
399 399
400 Toolkit::PushButton okayButton = Toolkit::PushButton::New(); 400 Toolkit::PushButton okayButton = Toolkit::PushButton::New();
401 okayButton.SetName( OKAY_BUTTON_ID ); 401 okayButton.SetName( OKAY_BUTTON_ID );
402 - okayButton.SetLabel( "OK!" ); 402 + okayButton.SetLabelText( "OK!" );
403 403
404 okayButton.ClickedSignal().Connect( this, &SizeNegotiationController::OnButtonClicked ); 404 okayButton.ClickedSignal().Connect( this, &SizeNegotiationController::OnButtonClicked );
405 405
@@ -428,7 +428,7 @@ public: @@ -428,7 +428,7 @@ public:
428 { 428 {
429 mPopup = CreatePopup(); 429 mPopup = CreatePopup();
430 430
431 - ImageActor image = ImageActor::New( ResourceImage::New( IMAGE2 ) ); 431 + Toolkit::ImageView image = Toolkit::ImageView::New( IMAGE2 );
432 image.SetResizePolicy( ResizePolicy::FILL_TO_PARENT, Dimension::WIDTH ); 432 image.SetResizePolicy( ResizePolicy::FILL_TO_PARENT, Dimension::WIDTH );
433 image.SetResizePolicy( ResizePolicy::DIMENSION_DEPENDENCY, Dimension::HEIGHT ); 433 image.SetResizePolicy( ResizePolicy::DIMENSION_DEPENDENCY, Dimension::HEIGHT );
434 image.SetPadding( Padding( 20.0f, 20.0f, 20.0f, 20.0f ) ); 434 image.SetPadding( Padding( 20.0f, 20.0f, 20.0f, 20.0f ) );
@@ -444,7 +444,7 @@ public: @@ -444,7 +444,7 @@ public:
444 mPopup.SetResizePolicy( ResizePolicy::SIZE_RELATIVE_TO_PARENT, Dimension::ALL_DIMENSIONS ); 444 mPopup.SetResizePolicy( ResizePolicy::SIZE_RELATIVE_TO_PARENT, Dimension::ALL_DIMENSIONS );
445 mPopup.SetSizeModeFactor( Vector3( 0.75f, 0.5f, 1.0f ) ); 445 mPopup.SetSizeModeFactor( Vector3( 0.75f, 0.5f, 1.0f ) );
446 446
447 - ImageActor image = ImageActor::New( ResourceImage::New( IMAGE2 ) ); 447 + Toolkit::ImageView image = Toolkit::ImageView::New( IMAGE2 );
448 image.SetResizePolicy( ResizePolicy::FILL_TO_PARENT, Dimension::ALL_DIMENSIONS ); 448 image.SetResizePolicy( ResizePolicy::FILL_TO_PARENT, Dimension::ALL_DIMENSIONS );
449 449
450 mPopup.Add( image ); 450 mPopup.Add( image );
@@ -458,7 +458,7 @@ public: @@ -458,7 +458,7 @@ public:
458 mPopup.SetResizePolicy( ResizePolicy::SIZE_RELATIVE_TO_PARENT, Dimension::ALL_DIMENSIONS ); 458 mPopup.SetResizePolicy( ResizePolicy::SIZE_RELATIVE_TO_PARENT, Dimension::ALL_DIMENSIONS );
459 mPopup.SetSizeModeFactor( Vector3( 0.75f, 0.5f, 1.0f ) ); 459 mPopup.SetSizeModeFactor( Vector3( 0.75f, 0.5f, 1.0f ) );
460 460
461 - ImageActor image = ImageActor::New( ResourceImage::New( IMAGE2 ) ); 461 + Toolkit::ImageView image = Toolkit::ImageView::New( IMAGE2 );
462 image.SetResizePolicy( ResizePolicy::FILL_TO_PARENT, Dimension::ALL_DIMENSIONS ); 462 image.SetResizePolicy( ResizePolicy::FILL_TO_PARENT, Dimension::ALL_DIMENSIONS );
463 image.SetSizeScalePolicy( SizeScalePolicy::FIT_WITH_ASPECT_RATIO ); 463 image.SetSizeScalePolicy( SizeScalePolicy::FIT_WITH_ASPECT_RATIO );
464 464
@@ -473,7 +473,7 @@ public: @@ -473,7 +473,7 @@ public:
473 mPopup.SetResizePolicy( ResizePolicy::SIZE_RELATIVE_TO_PARENT, Dimension::ALL_DIMENSIONS ); 473 mPopup.SetResizePolicy( ResizePolicy::SIZE_RELATIVE_TO_PARENT, Dimension::ALL_DIMENSIONS );
474 mPopup.SetSizeModeFactor( Vector3( 0.75f, 0.5f, 1.0f ) ); 474 mPopup.SetSizeModeFactor( Vector3( 0.75f, 0.5f, 1.0f ) );
475 475
476 - ImageActor image = ImageActor::New( ResourceImage::New( IMAGE2 ) ); 476 + Toolkit::ImageView image = Toolkit::ImageView::New( IMAGE2 );
477 image.SetResizePolicy( ResizePolicy::FILL_TO_PARENT, Dimension::ALL_DIMENSIONS ); 477 image.SetResizePolicy( ResizePolicy::FILL_TO_PARENT, Dimension::ALL_DIMENSIONS );
478 image.SetSizeScalePolicy( SizeScalePolicy::FILL_WITH_ASPECT_RATIO ); 478 image.SetSizeScalePolicy( SizeScalePolicy::FILL_WITH_ASPECT_RATIO );
479 479
@@ -513,7 +513,7 @@ public: @@ -513,7 +513,7 @@ public:
513 513
514 Toolkit::PushButton cancelButton = Toolkit::PushButton::New(); 514 Toolkit::PushButton cancelButton = Toolkit::PushButton::New();
515 cancelButton.SetName( CANCEL_BUTTON_ID ); 515 cancelButton.SetName( CANCEL_BUTTON_ID );
516 - cancelButton.SetLabel( "Cancel" ); 516 + cancelButton.SetLabelText( "Cancel" );
517 517
518 cancelButton.ClickedSignal().Connect( this, &SizeNegotiationController::OnButtonClicked ); 518 cancelButton.ClickedSignal().Connect( this, &SizeNegotiationController::OnButtonClicked );
519 519
@@ -521,7 +521,7 @@ public: @@ -521,7 +521,7 @@ public:
521 521
522 Toolkit::PushButton okayButton = Toolkit::PushButton::New(); 522 Toolkit::PushButton okayButton = Toolkit::PushButton::New();
523 okayButton.SetName( OKAY_BUTTON_ID ); 523 okayButton.SetName( OKAY_BUTTON_ID );
524 - okayButton.SetLabel( "OK!" ); 524 + okayButton.SetLabelText( "OK!" );
525 525
526 okayButton.ClickedSignal().Connect( this, &SizeNegotiationController::OnButtonClicked ); 526 okayButton.ClickedSignal().Connect( this, &SizeNegotiationController::OnButtonClicked );
527 527
@@ -555,7 +555,7 @@ public: @@ -555,7 +555,7 @@ public:
555 555
556 // Image 556 // Image
557 { 557 {
558 - ImageActor image = ImageActor::New( ResourceImage::New( IMAGE1 ) ); 558 + Toolkit::ImageView image = Toolkit::ImageView::New( IMAGE1 );
559 image.SetName( "COMPLEX_IMAGE" ); 559 image.SetName( "COMPLEX_IMAGE" );
560 image.SetResizePolicy( ResizePolicy::FILL_TO_PARENT, Dimension::WIDTH ); 560 image.SetResizePolicy( ResizePolicy::FILL_TO_PARENT, Dimension::WIDTH );
561 image.SetResizePolicy( ResizePolicy::DIMENSION_DEPENDENCY, Dimension::HEIGHT ); 561 image.SetResizePolicy( ResizePolicy::DIMENSION_DEPENDENCY, Dimension::HEIGHT );
@@ -591,7 +591,7 @@ public: @@ -591,7 +591,7 @@ public:
591 // Buttons 591 // Buttons
592 Toolkit::PushButton cancelButton = Toolkit::PushButton::New(); 592 Toolkit::PushButton cancelButton = Toolkit::PushButton::New();
593 cancelButton.SetName( CANCEL_BUTTON_ID ); 593 cancelButton.SetName( CANCEL_BUTTON_ID );
594 - cancelButton.SetLabel( "Cancel" ); 594 + cancelButton.SetLabelText( "Cancel" );
595 595
596 cancelButton.ClickedSignal().Connect( this, &SizeNegotiationController::OnButtonClicked ); 596 cancelButton.ClickedSignal().Connect( this, &SizeNegotiationController::OnButtonClicked );
597 597
@@ -599,7 +599,7 @@ public: @@ -599,7 +599,7 @@ public:
599 599
600 Toolkit::PushButton okayButton = Toolkit::PushButton::New(); 600 Toolkit::PushButton okayButton = Toolkit::PushButton::New();
601 okayButton.SetName( OKAY_BUTTON_ID ); 601 okayButton.SetName( OKAY_BUTTON_ID );
602 - okayButton.SetLabel( "OK!" ); 602 + okayButton.SetLabelText( "OK!" );
603 603
604 okayButton.ClickedSignal().Connect( this, &SizeNegotiationController::OnButtonClicked ); 604 okayButton.ClickedSignal().Connect( this, &SizeNegotiationController::OnButtonClicked );
605 605
@@ -1226,7 +1226,7 @@ public: // From ItemFactory @@ -1226,7 +1226,7 @@ public: // From ItemFactory
1226 { 1226 {
1227 Toolkit::PushButton popupButton = Toolkit::PushButton::New(); 1227 Toolkit::PushButton popupButton = Toolkit::PushButton::New();
1228 popupButton.SetName( buttonDataArray[ itemId ].name ); 1228 popupButton.SetName( buttonDataArray[ itemId ].name );
1229 - popupButton.SetLabel( buttonDataArray[ itemId ].text ); 1229 + popupButton.SetLabelText( buttonDataArray[ itemId ].text );
1230 popupButton.SetResizePolicy( ResizePolicy::USE_NATURAL_SIZE, Dimension::ALL_DIMENSIONS ); 1230 popupButton.SetResizePolicy( ResizePolicy::USE_NATURAL_SIZE, Dimension::ALL_DIMENSIONS );
1231 1231
1232 popupButton.ClickedSignal().Connect( this, &SizeNegotiationController::OnButtonClicked ); 1232 popupButton.ClickedSignal().Connect( this, &SizeNegotiationController::OnButtonClicked );
examples/text-field/text-field-example.cpp
@@ -38,6 +38,7 @@ namespace @@ -38,6 +38,7 @@ namespace
38 { 38 {
39 39
40 const char* const FOLDER_ICON_IMAGE = DALI_IMAGE_DIR "folder_appicon_empty_bg.png"; 40 const char* const FOLDER_ICON_IMAGE = DALI_IMAGE_DIR "folder_appicon_empty_bg.png";
  41 + const char* const FOLDER_OPEN_ICON_IMAGE = DALI_IMAGE_DIR "folder_appicon_empty_open_bg.png";
41 42
42 const float BORDER_WIDTH = 4.0f; 43 const float BORDER_WIDTH = 4.0f;
43 44
@@ -82,14 +83,12 @@ public: @@ -82,14 +83,12 @@ public:
82 PushButton CreateFolderButton() 83 PushButton CreateFolderButton()
83 { 84 {
84 PushButton button = PushButton::New(); 85 PushButton button = PushButton::New();
85 - ResourceImage image = ResourceImage::New( FOLDER_ICON_IMAGE );  
86 - ImageActor folderButton = ImageActor::New( image );  
87 - folderButton.SetColor( Color::WHITE );  
88 - button.SetButtonImage( folderButton );  
89 - button.SetSelectedImage( Actor() ); 86 + button.SetUnselectedImage( FOLDER_ICON_IMAGE );
  87 + button.SetSelectedImage( FOLDER_OPEN_ICON_IMAGE );
90 button.SetAnchorPoint( AnchorPoint::TOP_LEFT ); 88 button.SetAnchorPoint( AnchorPoint::TOP_LEFT );
91 button.SetResizePolicy( ResizePolicy::FIXED, Dimension::ALL_DIMENSIONS ); 89 button.SetResizePolicy( ResizePolicy::FIXED, Dimension::ALL_DIMENSIONS );
92 - button.SetSize( image.GetWidth(), image.GetHeight() ); 90 + ResourceImage imageClosed = ResourceImage::New( FOLDER_ICON_IMAGE );
  91 + button.SetSize( imageClosed.GetWidth(), imageClosed.GetHeight() );
93 92
94 return button; 93 return button;
95 } 94 }
@@ -149,7 +148,7 @@ public: @@ -149,7 +148,7 @@ public:
149 { 148 {
150 Property::Value text = mField.GetProperty( TextField::Property::TEXT ); 149 Property::Value text = mField.GetProperty( TextField::Property::TEXT );
151 mButtonLabel = text.Get< std::string >(); 150 mButtonLabel = text.Get< std::string >();
152 - mButton.SetLabel( mButtonLabel ); 151 + mButton.SetLabelText( mButtonLabel );
153 } 152 }
154 153
155 // Hide & discard the pop-up 154 // Hide & discard the pop-up
@@ -175,7 +174,7 @@ public: @@ -175,7 +174,7 @@ public:
175 { 174 {
176 Property::Value text = mField.GetProperty( TextField::Property::TEXT ); 175 Property::Value text = mField.GetProperty( TextField::Property::TEXT );
177 mButtonLabel = text.Get< std::string >(); 176 mButtonLabel = text.Get< std::string >();
178 - mButton.SetLabel( mButtonLabel ); 177 + mButton.SetLabelText( mButtonLabel );
179 mField.ClearKeyInputFocus(); 178 mField.ClearKeyInputFocus();
180 } 179 }
181 break; 180 break;
examples/text-message-field/text-message-field-example.cpp
@@ -77,8 +77,7 @@ public: @@ -77,8 +77,7 @@ public:
77 const Size mTargetActorSize( mStageSize.width, DESKTOP_SIZE.height ); 77 const Size mTargetActorSize( mStageSize.width, DESKTOP_SIZE.height );
78 78
79 // Create Desktop 79 // Create Desktop
80 - ResourceImage backgroundImage = ResourceImage::New( DESKTOP_IMAGE );  
81 - ImageActor desktop = ImageActor::New( backgroundImage ); 80 + ImageView desktop = ImageView::New( DESKTOP_IMAGE );
82 desktop.SetName("desktopActor"); 81 desktop.SetName("desktopActor");
83 desktop.SetAnchorPoint( AnchorPoint::TOP_LEFT ); 82 desktop.SetAnchorPoint( AnchorPoint::TOP_LEFT );
84 desktop.SetResizePolicy( ResizePolicy::FIXED, Dimension::ALL_DIMENSIONS ); 83 desktop.SetResizePolicy( ResizePolicy::FIXED, Dimension::ALL_DIMENSIONS );
packaging/com.samsung.dali-demo.spec
@@ -2,7 +2,7 @@ @@ -2,7 +2,7 @@
2 2
3 Name: com.samsung.dali-demo 3 Name: com.samsung.dali-demo
4 Summary: The OpenGLES Canvas Core Demo 4 Summary: The OpenGLES Canvas Core Demo
5 -Version: 1.0.49 5 +Version: 1.0.50
6 Release: 1 6 Release: 1
7 Group: System/Libraries 7 Group: System/Libraries
8 License: Apache-2.0 8 License: Apache-2.0
resources/images/folder_appicon_empty_open_bg.png 0 โ†’ 100644

6.21 KB

resources/scripts/button.json
@@ -26,18 +26,8 @@ @@ -26,18 +26,8 @@
26 "anchor-point": "TOP_CENTER", 26 "anchor-point": "TOP_CENTER",
27 "position": [0, 0, 0], 27 "position": [0, 0, 0],
28 "size": [400, 200, 0], 28 "size": [400, 200, 0],
29 - "normal-state-actor": {  
30 - "type": "ImageActor",  
31 - "image": {  
32 - "filename": "{DALI_IMAGE_DIR}blocks-brick-1.png"  
33 - }  
34 - },  
35 - "selected-state-actor": {  
36 - "type": "ImageActor",  
37 - "image": {  
38 - "filename": "{DALI_IMAGE_DIR}blocks-brick-2.png"  
39 - }  
40 - }, 29 + "unselected-state-actor": "{DALI_IMAGE_DIR}blocks-brick-1.png",
  30 + "selected-state-actor": "{DALI_IMAGE_DIR}blocks-brick-2.png",
41 "label-actor": { 31 "label-actor": {
42 "type": "TextLabel", 32 "type": "TextLabel",
43 "text": "Normal" 33 "text": "Normal"
@@ -56,24 +46,9 @@ @@ -56,24 +46,9 @@
56 "text": "Disabled" 46 "text": "Disabled"
57 }, 47 },
58 "disabled": true, 48 "disabled": true,
59 - "normal-state-actor": {  
60 - "type": "ImageActor",  
61 - "image": {  
62 - "filename": "{DALI_IMAGE_DIR}blocks-brick-1.png"  
63 - }  
64 - },  
65 - "selected-state-actor": {  
66 - "type": "ImageActor",  
67 - "image": {  
68 - "filename": "{DALI_IMAGE_DIR}blocks-brick-2.png"  
69 - }  
70 - },  
71 - "disabled-state-actor": {  
72 - "type": "ImageActor",  
73 - "image": {  
74 - "filename": "{DALI_IMAGE_DIR}blocks-brick-3.png"  
75 - }  
76 - } 49 + "unselected-state-actor": "{DALI_IMAGE_DIR}blocks-brick-1.png",
  50 + "selected-state-actor": "{DALI_IMAGE_DIR}blocks-brick-2.png",
  51 + "disabled-state-actor": "{DALI_IMAGE_DIR}blocks-brick-3.png"
77 }, 52 },
78 53
79 // Third Button 54 // Third Button
@@ -89,22 +64,8 @@ @@ -89,22 +64,8 @@
89 "text": "Toggle" 64 "text": "Toggle"
90 }, 65 },
91 "togglable": true, 66 "togglable": true,
92 - "normal-state-actor": {  
93 - "type": "ImageActor",  
94 - "style": "STYLE_NINE_PATCH",  
95 - "border": [26, 24, 26, 23],  
96 - "image": {  
97 - "filename": "{DALI_IMAGE_DIR}blocks-brick-1.png"  
98 - }  
99 - },  
100 - "selected-state-actor": {  
101 - "type": "ImageActor",  
102 - "style": "STYLE_NINE_PATCH",  
103 - "border": [26, 24, 26, 23],  
104 - "image": {  
105 - "filename": "{DALI_IMAGE_DIR}blocks-paddle.png"  
106 - }  
107 - }, 67 + "unselected-state-actor": "{DALI_IMAGE_DIR}blocks-brick-1.png",
  68 + "selected-state-actor": "{DALI_IMAGE_DIR}blocks-paddle.png",
108 "signals": [{ 69 "signals": [{
109 "name": "selected", 70 "name": "selected",
110 "action": "set", 71 "action": "set",
resources/scripts/super-blur-view.json
@@ -70,22 +70,8 @@ @@ -70,22 +70,8 @@
70 "type": "TextLabel", 70 "type": "TextLabel",
71 "text": "Blur" 71 "text": "Blur"
72 }, 72 },
73 - "normal-state-actor": {  
74 - "type": "ImageActor",  
75 - "style": "STYLE_NINE_PATCH",  
76 - "border": [26, 24, 26, 23],  
77 - "image": {  
78 - "filename": "{DALI_IMAGE_DIR}button-background.png"  
79 - }  
80 - },  
81 - "selected-state-actor": {  
82 - "type": "ImageActor",  
83 - "style": "STYLE_NINE_PATCH",  
84 - "border": [26, 24, 26, 23],  
85 - "image": {  
86 - "filename": "{DALI_IMAGE_DIR}button-background.png"  
87 - }  
88 - }, 73 + "unselected-state-actor": "{DALI_IMAGE_DIR}button-background.png",
  74 + "selected-state-actor": "{DALI_IMAGE_DIR}button-background.png",
89 "signals": [{ 75 "signals": [{
90 "name": "pressed", 76 "name": "pressed",
91 "action": "play", 77 "action": "play",
resources/style/demo-theme.json
@@ -53,7 +53,7 @@ distributing this software or its derivatives. @@ -53,7 +53,7 @@ distributing this software or its derivatives.
53 "option-divider-size":[2,0], 53 "option-divider-size":[2,0],
54 "popup-divider-color":[0.23,0.72,0.8,0.11], 54 "popup-divider-color":[0.23,0.72,0.8,0.11],
55 "popup-icon-color":[1.0,1.0,1.0,1.0], 55 "popup-icon-color":[1.0,1.0,1.0,1.0],
56 - "popup-pressed-color":[0.24,0.72,0.8,0.11], 56 + "popup-pressed-color":[0.24,0.72,0.8,0.9],
57 "background-image": { 57 "background-image": {
58 "filename": "{DALI_IMAGE_DIR}selection-popup-bg.9.png" 58 "filename": "{DALI_IMAGE_DIR}selection-popup-bg.9.png"
59 } 59 }