CInfoViewer: ensure hide on deleted info file

Origin commit data
------------------
Branch: ni/coolstream
Commit: e30f4d2764
Author: Thilo Graf <dbt@novatux.de>
Date: 2013-04-25 (Thu, 25 Apr 2013)


------------------
No further description and justification available within origin commit message!

------------------
This commit was generated by Migit
This commit is contained in:
2013-04-25 23:06:35 +02:00
parent b11f2f3cd2
commit dadaa268a5

View File

@@ -1818,8 +1818,11 @@ void CInfoViewer::showInfoFile()
//exit if file not found, don't create an info object, delete old instance if required
if (!file_size(infobar_file.c_str())) {
if (infobar_txt)
if (infobar_txt){
if (infobar_txt->isPainted())
infobar_txt->hide();
delete infobar_txt;
}
infobar_txt = NULL;
return;
}
@@ -1847,9 +1850,13 @@ void CInfoViewer::showInfoFile()
infobar_txt->setDimensionsAll(xStart, yStart, width, height);
infobar_txt->setCornerRadius(RADIUS_SMALL);
infobar_txt->setShadowOnOff(true);
infobar_txt->setColorBody(COL_INFOBAR_PLUS_0);
infobar_txt->doPaintTextBoxBg(false);
//paint info, don't save backscreen, if already painted, global hide is done by killTitle()
bool save_bg = !infobar_txt->isPainted();
infobar_txt->paint(save_bg);
//paint info, don't save backscreen, hide not needed, is already done by killTitle()
infobar_txt->paint(CC_SAVE_SCREEN_NO);
}
void CInfoViewer::killTitle()