neutrino: fix menu position for right or bottom aligned

Origin commit data
------------------
Branch: ni/coolstream
Commit: c6ff06736a
Author: Stefan Seyfried <seife@tuxbox-git.slipkontur.de>
Date: 2012-07-28 (Sat, 28 Jul 2012)


------------------
No further description and justification available within origin commit message!

------------------
This commit was generated by Migit
This commit is contained in:
Stefan Seyfried
2012-07-28 23:50:03 +02:00
parent cda2c8d91c
commit 6188182b7d

View File

@@ -843,7 +843,7 @@ void CMenuWidget::calcSize()
full_width = width+sb_width+SHADOW_OFFSET;
full_height = height+RADIUS_LARGE-2+SHADOW_OFFSET;
setMenuPos(width - sb_width);
setMenuPos(full_width);
}
void CMenuWidget::paint()
@@ -890,7 +890,7 @@ void CMenuWidget::setMenuPos(const int& menu_width)
{
case MENU_POS_CENTER:
x = offx + scr_x + ((scr_w - mn_width ) >> 1 );
y = offy + scr_y + ((scr_h - height) >> 1 );
y = offy + scr_y + ((scr_h - full_height) >> 1 );
break;
case MENU_POS_TOP_LEFT:
@@ -900,17 +900,17 @@ void CMenuWidget::setMenuPos(const int& menu_width)
case MENU_POS_TOP_RIGHT:
y = offy + scr_y + 10;
x = offx + scr_x + scr_w - mn_width - 10;
x = /*offx +*/ scr_x + scr_w - mn_width - 10;
break;
case MENU_POS_BOTTOM_LEFT:
y = offy + scr_y + scr_h - height - 10;
y = /*offy +*/ scr_y + scr_h - full_height - 10;
x = offx + scr_x + 10;
break;
case MENU_POS_BOTTOM_RIGHT:
y = offy + scr_y + scr_h - height - 10;
x = offx + scr_x + scr_w - mn_width - 10;
y = /*offy +*/ scr_y + scr_h - full_height - 10;
x = /*offx +*/ scr_x + scr_w - mn_width - 10;
break;
}
}