mirror of
https://github.com/tuxbox-neutrino/neutrino.git
synced 2025-08-26 23:13:13 +02:00
widget/hintbox.cpp: add explicit init of var picon
Had some issues while compile with gcc 7.x. Exact data type was expected.
This commit is contained in:
@@ -265,6 +265,9 @@ void CHintBox::addHintItem(const std::string& Text, const int& text_mode, const
|
||||
/* set required font and line height */
|
||||
Font* item_font = !font_text ? hb_font : font_text;
|
||||
|
||||
/* set picon */
|
||||
string picon = Picon;
|
||||
|
||||
/* pre define required info height depends of lines and minimal needed height*/
|
||||
int line_breaks = CTextBox::getLines(Text);
|
||||
int h_font = item_font->getHeight();
|
||||
@@ -276,7 +279,7 @@ void CHintBox::addHintItem(const std::string& Text, const int& text_mode, const
|
||||
|
||||
int txt_mode = text_mode;
|
||||
/* remove CENTER mode if picon defined */
|
||||
if (!Picon.empty() && (txt_mode & CTextBox::CENTER)){
|
||||
if (!picon.empty() && (txt_mode & CTextBox::CENTER)){
|
||||
txt_mode &= ~CTextBox::CENTER;
|
||||
}
|
||||
|
||||
@@ -313,7 +316,7 @@ void CHintBox::addHintItem(const std::string& Text, const int& text_mode, const
|
||||
color_text);
|
||||
|
||||
/* define picon and disable bg */
|
||||
info_box->setPicture(Picon);
|
||||
info_box->setPicture(picon);
|
||||
info_box->doPaintBg(false);
|
||||
|
||||
/* recalculate new hintbox dimensions and position*/
|
||||
|
Reference in New Issue
Block a user