// ToolBar image
background.SetParentOrigin( Dali::ParentOrigin::TOP_CENTER );
background.SetAnchorPoint( Dali::AnchorPoint::TOP_CENTER );
- background.SetPreferredSize( Vector2( mToolBarSize.width, mToolBarSize.height ) );
+ background.SetSize( Vector2( mToolBarSize.width, mToolBarSize.height ) );
RenderableActor renderableActor = RenderableActor::DownCast( background );
if ( renderableActor )
// Create an alignment container where to place the control.
Toolkit::Alignment alignmentContainer = Toolkit::Alignment::New( alignment );
- alignmentContainer.SetSizeScalePolicy( FIT_WITH_ASPECT_RATIO );
+ alignmentContainer.SetSizeScalePolicy( SizeScalePolicy::FIT_WITH_ASPECT_RATIO );
alignmentContainer.SetPadding( padding );
- alignmentContainer.SetResizePolicy( FILL_TO_PARENT, ALL_DIMENSIONS );
+ alignmentContainer.SetResizePolicy( ResizePolicy::FILL_TO_PARENT, Dimension::ALL_DIMENSIONS );
alignmentContainer.Add( control );
// Insert the control in the table view.
// Layout
mLayout = Toolkit::TableView::New( 1, 1 );
mLayout.SetName( "TOOLBAR_LAYOUT" );
- mLayout.SetResizePolicy( FILL_TO_PARENT, ALL_DIMENSIONS );
+ mLayout.SetResizePolicy( ResizePolicy::FILL_TO_PARENT, Dimension::ALL_DIMENSIONS );
mLayout.SetPositionInheritanceMode( Dali::USE_PARENT_POSITION );
Self().Add( mLayout );
void ToolBar::OnControlSizeSet( const Vector3& targetSize )
{
mToolBarSize = targetSize;
- mBackground.SetPreferredSize( Vector2( mToolBarSize.width, mToolBarSize.height ) );
+ mBackground.SetSize( Vector2( mToolBarSize.width, mToolBarSize.height ) );
}
} // namespace Internal