Toolkit::Popup popup = Toolkit::Popup::New();
// Setup for Toast Popup type.
- popup.SetSizeModeFactor( DEFAULT_TOAST_WIDTH_OF_STAGE_RATIO );
+ popup.SetProperty( Actor::Property::SIZE_MODE_FACTOR, DEFAULT_TOAST_WIDTH_OF_STAGE_RATIO );
popup.SetResizePolicy( ResizePolicy::SIZE_RELATIVE_TO_PARENT, Dimension::WIDTH );
popup.SetResizePolicy( ResizePolicy::USE_NATURAL_SIZE, Dimension::HEIGHT );
popup.SetProperty( Toolkit::Popup::Property::CONTEXTUAL_MODE, Toolkit::Popup::NON_CONTEXTUAL );
self.SetProperty( Actor::Property::PARENT_ORIGIN, ParentOrigin::CENTER );
self.SetProperty( Actor::Property::ANCHOR_POINT, AnchorPoint::CENTER );
- self.SetSizeModeFactor( DEFAULT_POPUP_PARENT_RELATIVE_SIZE );
+ self.SetProperty( Actor::Property::SIZE_MODE_FACTOR, DEFAULT_POPUP_PARENT_RELATIVE_SIZE );
self.SetResizePolicy( ResizePolicy::SIZE_RELATIVE_TO_PARENT, Dimension::WIDTH );
self.SetResizePolicy( ResizePolicy::USE_NATURAL_SIZE, Dimension::HEIGHT );
mPopupLayout.SetResizePolicy( ResizePolicy::USE_ASSIGNED_SIZE, Dimension::WIDTH );
mPopupLayout.SetResizePolicy( ResizePolicy::USE_NATURAL_SIZE, Dimension::HEIGHT );
- mPopupLayout.SetSize( Stage::GetCurrent().GetSize().x * DEFAULT_RELATIVE_PARENT_WIDTH, 0.0f );
+ mPopupLayout.SetProperty( Actor::Property::SIZE, Vector2( Stage::GetCurrent().GetSize().x * DEFAULT_RELATIVE_PARENT_WIDTH, 0.0f ) );
mPopupLayout.SetFitHeight( 0 ); // Set row to fit.
mPopupLayout.SetFitHeight( 1 ); // Set row to fit.
case Toolkit::Popup::ZOOM:
{
// Zoom animations start fully zoomed out.
- mPopupContainer.SetScale( Vector3::ZERO );
+ mPopupContainer.SetProperty( Actor::Property::SCALE, Vector3::ZERO );
break;
}
}
else
{
- mPopupContainer.SetScale( transitionIn ? Vector3::ONE : Vector3::ZERO );
+ mPopupContainer.SetProperty( Actor::Property::SCALE, transitionIn ? Vector3::ONE : Vector3::ZERO );
}
break;
}
{
// Set up padding to give sensible default behaviour
// (an application developer can later override this if they wish).
- mTitle.SetPadding( DEFAULT_TITLE_PADDING );
+ mTitle.SetProperty( Actor::Property::PADDING, DEFAULT_TITLE_PADDING );
mPopupLayout.AddChild( mTitle, Toolkit::TableView::CellPosition( 0, 0 ) );
}
{
if( !mContent && !mFooter )
{
- mTitle.SetPadding( DEFAULT_TITLE_ONLY_PADDING );
+ mTitle.SetProperty( Actor::Property::PADDING, DEFAULT_TITLE_ONLY_PADDING );
}
else
{
- mTitle.SetPadding( DEFAULT_TITLE_PADDING );
+ mTitle.SetProperty( Actor::Property::PADDING, DEFAULT_TITLE_PADDING );
}
}
mTailImage.SetProperty( Dali::Actor::Property::NAME, "tailImage" );
mTailImage.SetProperty( Actor::Property::PARENT_ORIGIN, parentOrigin );
mTailImage.SetProperty( Actor::Property::ANCHOR_POINT, anchorPoint );
- mTailImage.SetPosition( position );
+ mTailImage.SetProperty( Actor::Property::POSITION, position );
if( mPopupBackgroundImage )
{
// Always the full size of the stage.
backing.SetResizePolicy( ResizePolicy::FIXED, Dimension::ALL_DIMENSIONS );
- backing.SetSize( Stage::GetCurrent().GetSize() );
+ backing.SetProperty( Actor::Property::SIZE, Stage::GetCurrent().GetSize() );
// Catch events.
backing.SetProperty( Actor::Property::SENSITIVE, true );
if( mPopupBackgroundImage )
{
mPopupBackgroundImage.SetResizePolicy( ResizePolicy::SIZE_FIXED_OFFSET_FROM_PARENT, Dimension::ALL_DIMENSIONS );
- mPopupBackgroundImage.SetSizeModeFactor( Vector3( mBackgroundBorder.left + mBackgroundBorder.right, mBackgroundBorder.top + mBackgroundBorder.bottom, 0.0f ) );
+ mPopupBackgroundImage.SetProperty( Actor::Property::SIZE_MODE_FACTOR, Vector3( mBackgroundBorder.left + mBackgroundBorder.right, mBackgroundBorder.top + mBackgroundBorder.bottom, 0.0f ) );
// Adjust the position of the background so the transparent areas are set appropriately
- mPopupBackgroundImage.SetPosition( ( mBackgroundBorder.right - mBackgroundBorder.left ) * 0.5f, ( mBackgroundBorder.bottom - mBackgroundBorder.top ) * 0.5f );
+ mPopupBackgroundImage.SetProperty( Actor::Property::POSITION, Vector2( ( mBackgroundBorder.right - mBackgroundBorder.left ) * 0.5f, ( mBackgroundBorder.bottom - mBackgroundBorder.top ) * 0.5f ));
}
}
}
// Block anything behind backing becoming touched.
- mLayer.SetTouchConsumed( true );
+ mLayer.SetProperty( Layer::Property::CONSUMES_TOUCH, true );
return true;
}
}
// Consume wheel event in dimmed backing actor.
- mLayer.SetTouchConsumed( true );
+ mLayer.SetProperty( Layer::Property::CONSUMES_TOUCH, true );
return true;
}
}
// Consume event (stops backing actor receiving touch events)
- mLayer.SetTouchConsumed( true );
+ mLayer.SetProperty( Layer::Property::CONSUMES_TOUCH, true );
return true;
}
}
// Set the final position.
- mPopupContainer.SetPosition( newPosition );
+ mPopupContainer.SetProperty( Actor::Property::POSITION, newPosition );
}
void Popup::OnRelayout( const Vector2& size, RelayoutContainer& container )