Signed-off-by: sr.shashank <sr.shashank@samsung.com>
Change-Id: I6eb4b42eaff0d2c007cc563ff6615902f746d14d
Signed-off-by: sr.shashank <sr.shashank@samsung.com>
void
_OptionMenu::OnChangeLayout(_ControlRotation rotation)
{
- if (rotation == _CONTROL_ROTATION_0 || rotation == _CONTROL_ROTATION_180)
- {
- __layout = _CONTROL_ORIENTATION_PORTRAIT;
- }
- else
- {
- __layout = _CONTROL_ORIENTATION_LANDSCAPE;
- }
+ __layout = GetOwner()->GetOrientation();
if (!__isMaxVisibleCountSet)
{
bodyRect.width = __layoutSize.width + bodyLeftMargin + bodyRightMargin;
bodyRect.height = __layoutSize.height + bodyTopMargin + bodyBottomMargin;
- if (rotation == _CONTROL_ROTATION_270)
+ if (rotation == _CONTROL_ROTATION_270 && __pOptionMenu->GetLayout() == _CONTROL_ORIENTATION_LANDSCAPE)
{
bodyRect.x = screen.width - bodyRect.width;
}