CBuildInfo: move InitInfoItems() into exec()

ensures paint of data on each repaint.


Origin commit data
------------------
Commit: 9df86b6c37
Author: Thilo Graf <dbt@novatux.de>
Date: 2017-01-23 (Mon, 23 Jan 2017)
This commit is contained in:
2017-01-23 21:58:42 +01:00
committed by Michael Liebmann
parent 7f7babeb52
commit 40d08c4a7c
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);