diff --git a/src/gui/widget/menue.cpp b/src/gui/widget/menue.cpp index 23af427ce..3b6389265 100644 --- a/src/gui/widget/menue.cpp +++ b/src/gui/widget/menue.cpp @@ -491,10 +491,14 @@ int CMenuWidget::exec(CMenuTarget* parent, const std::string &) } } } +#if 0 GenericMenuBack->setHint("", NONEXISTANT_LOCALE); +#endif checkHints(); +#if 0 if (has_hints) GenericMenuBack->setHint(NEUTRINO_ICON_HINT_BACK, LOCALE_MENU_HINT_BACK); +#endif if(savescreen) { calcSize(); @@ -758,8 +762,9 @@ void CMenuWidget::hide() restoreScreen();//FIXME else { frameBuffer->paintBackgroundBoxRel(x, y, full_width, full_height); - paintHint(-1); + //paintHint(-1); } + paintHint(-1); /* setActive() paints item for hidden parent menu, if called from child menu */ for (unsigned int count = 0; count < items.size(); count++) @@ -878,8 +883,8 @@ void CMenuWidget::calcSize() if(total_pages > 1) sb_width=15; - full_width = ConnectLineBox_Width+width+sb_width+SHADOW_OFFSET; - full_height = height+RADIUS_LARGE+SHADOW_OFFSET*2+hint_height+INFO_BOX_Y_OFFSET; + full_width = /*ConnectLineBox_Width+*/width+sb_width+SHADOW_OFFSET; + full_height = height+RADIUS_LARGE+SHADOW_OFFSET*2 /*+hint_height+INFO_BOX_Y_OFFSET*/; setMenuPos(width - sb_width); } @@ -1039,14 +1044,14 @@ void CMenuWidget::saveScreen() background = new fb_pixel_t [full_width * full_height]; if(background) - frameBuffer->SaveScreen(x-ConnectLineBox_Width, y, full_width, full_height, background); + frameBuffer->SaveScreen(x /*-ConnectLineBox_Width*/, y, full_width, full_height, background); } void CMenuWidget::restoreScreen() { if(background) { if(savescreen) - frameBuffer->RestoreScreen(x-ConnectLineBox_Width, y, full_width, full_height, background); + frameBuffer->RestoreScreen(x /*-ConnectLineBox_Width*/, y, full_width, full_height, background); } } @@ -1075,12 +1080,22 @@ void CMenuWidget::paintHint(int pos) if (hint_painted) { /* clear detailsline line */ - if (details_line != NULL) - details_line->restore(); + // TODO CComponents::hide with param restore ? or auto (if it have saved screens) ? + if (details_line != NULL) { + if (savescreen) + details_line->restore(); + else + details_line->hide(); + } /* clear info box */ - if (info_box != NULL) - if (pos == -1) - info_box->restore(); + if (info_box != NULL) { + if (pos == -1) { + if (savescreen) + info_box->restore(); + else + info_box->hide(); + } + } hint_painted = false; } if (pos < 0) @@ -1090,8 +1105,12 @@ void CMenuWidget::paintHint(int pos) //printf("paintHint: icon %s text %s\n", item->hintIcon.c_str(), g_Locale->getText(item->hint)); if (item->hintIcon.empty() && item->hint == NONEXISTANT_LOCALE) { - if (info_box != NULL) - info_box->restore(); + if (info_box != NULL) { + if (savescreen) + info_box->restore(); + else + info_box->hide(); + } return; } @@ -1114,7 +1133,7 @@ void CMenuWidget::paintHint(int pos) details_line->setYPosDown(ypos2a); details_line->setHMarkDown(markh); } - details_line->paint(); + details_line->paint(savescreen); if (info_box == NULL) info_box = new CComponentsInfoBox(x, ypos2, iwidth, hint_height); @@ -1123,7 +1142,8 @@ void CMenuWidget::paintHint(int pos) info_box->setYPos(ypos2); info_box->setWidth(iwidth); } - info_box->paint(); + /* force full paint - menu-over i.e. option chooser with pulldown can overwrite */ + info_box->paint(savescreen, true); int offset = 10; if (!item->hintIcon.empty()) {