- bouqueteditor: clear details in infobox if no channels available

This commit is contained in:
svenhoefer
2017-09-28 14:01:05 +02:00
committed by Jacek Jendrzej
parent 0f26434550
commit 386c2b4d09
2 changed files with 8 additions and 2 deletions

View File

@@ -95,7 +95,7 @@ void CBEChannelWidget::paintItem(int pos)
if (i_selected)
{
if (current < Channels->size())
if (current < Channels->size() || Channels->empty())
paintDetails(pos, current);
i_radius = RADIUS_LARGE;
@@ -240,6 +240,9 @@ std::string CBEChannelWidget::getInfoText(int index)
{
std::string res = "";
if (Channels->empty())
return res;
std::string satname = CServiceManager::getInstance()->GetSatelliteName((*Channels)[index]->getSatellitePosition());
if (IS_WEBTV((*Channels)[index]->getChannelID()))
satname = "WebTV";

View File

@@ -83,7 +83,7 @@ void CBEChannelSelectWidget::paintItem(int pos)
if (i_selected)
{
if (current < Channels.size())
if (current < Channels.size() || Channels.empty())
paintDetails(pos, current);
i_radius = RADIUS_LARGE;
@@ -246,6 +246,9 @@ std::string CBEChannelSelectWidget::getInfoText(int index)
{
std::string res = "";
if (Channels.empty())
return res;
std::string satname = CServiceManager::getInstance()->GetSatelliteName(Channels[index]->getSatellitePosition());
if (IS_WEBTV(Channels[index]->getChannelID()))
satname = "WebTV";