- menue-widget: set header-offset and align sub-headers

This commit is contained in:
svenhoefer
2013-05-30 23:06:27 +02:00
parent b318c15895
commit 07b4716ebf

View File

@@ -894,6 +894,7 @@ void CMenuWidget::paint()
// paint head // paint head
CComponentsHeader header(x, y, width + sb_width, hheight, nameString, iconfile.c_str()); CComponentsHeader header(x, y, width + sb_width, hheight, nameString, iconfile.c_str());
header.setShadowOnOff(CC_SHADOW_ON); header.setShadowOnOff(CC_SHADOW_ON);
header.setOffset(10);
header.paint(CC_SAVE_SCREEN_NO); header.paint(CC_SAVE_SCREEN_NO);
// paint body shadow // paint body shadow
@@ -1870,7 +1871,7 @@ int CMenuSeparator::paint(bool selected)
/* if no alignment is specified, align centered */ /* if no alignment is specified, align centered */
if (type & ALIGN_LEFT) if (type & ALIGN_LEFT)
name_start_x = x + (!SUB_HEAD ? name_start_x : 20 +18); name_start_x = x + (!SUB_HEAD ? name_start_x : 20 + 24 /*std icon_width is 24px - this should be determinated from NEUTRINO_ICON_BUTTON_HOME or so*/);
else if (type & ALIGN_RIGHT) else if (type & ALIGN_RIGHT)
name_start_x = x + dx - stringwidth - 20; name_start_x = x + dx - stringwidth - 20;
else /* ALIGN_CENTER */ else /* ALIGN_CENTER */