CBuildInfo: move InitInfoItems() into exec()

ensures paint of data on each repaint.
This commit is contained in:
2017-01-23 21:58:42 +01:00
committed by M. Liebmann
parent 44eebba080
commit 9df86b6c37
2 changed files with 9 additions and 4 deletions

View File

@@ -35,9 +35,13 @@
using namespace std;
CBuildInfo::CBuildInfo() : CComponentsWindow(0, 0, 700, 500, LOCALE_BUILDINFO_MENU, NEUTRINO_ICON_INFO)
CBuildInfo::CBuildInfo(bool show) : CComponentsWindow(0, 0, 700, 500, LOCALE_BUILDINFO_MENU, NEUTRINO_ICON_INFO)
{
initVarBuildInfo();
if (show)
exec(NULL, "");
else
InitInfoItems();
}
//init all var members
@@ -47,7 +51,6 @@ void CBuildInfo::initVarBuildInfo()
font = g_Font[SNeutrinoSettings::FONT_TYPE_MENU_HINT];
setWindowHeaderButtons(CComponentsHeader::CC_BTN_MENU | CComponentsHeader::CC_BTN_EXIT);
InitInfoItems();
shadow = true;
@@ -60,7 +63,9 @@ int CBuildInfo::exec(CMenuTarget* parent, const string & /*actionKey*/)
if (parent)
parent->hide();
InitInfoItems();
//exit if no informations available
if (!HasData()){
return res;

View File

@@ -69,7 +69,7 @@ class CBuildInfo : public CMenuTarget, public CComponentsWindow
BI_TYPE_IDS
};
CBuildInfo();
CBuildInfo(bool show = false);
///assigns text Font type
void setFontType(Font* font_text);