diff --git a/src/gui/channellist.cpp b/src/gui/channellist.cpp index 8b508ffbd..5bb4f06ef 100644 --- a/src/gui/channellist.cpp +++ b/src/gui/channellist.cpp @@ -493,7 +493,7 @@ void CChannelList::calcSize() else info_height = 0; height = pig_on_win ? frameBuffer->getScreenHeight(): frameBuffer->getScreenHeightRel(); - height = height - info_height; + height = height - OFFSET_INTER - info_height; // calculate x position x = getScreenStartX(full_width); @@ -511,7 +511,7 @@ void CChannelList::calcSize() height = theight + listmaxshow*fheight + footerHeight; // calculate y position - y = getScreenStartY(height + info_height); + y = getScreenStartY(height + OFFSET_INTER + info_height); // calculate width/height of right info_zone and pip-box infozone_width = full_width - width; @@ -974,7 +974,7 @@ void CChannelList::hide() CChannelLogo = NULL; } - frameBuffer->paintBackgroundBoxRel(x, y, full_width, height + info_height); + frameBuffer->paintBackgroundBoxRel(x, y, full_width, height + OFFSET_INTER + info_height); clearItem2DetailsLine(); CInfoClock::getInstance()->enableInfoClock(!CInfoClock::getInstance()->isBlocked()); } @@ -1530,14 +1530,17 @@ void CChannelList::paintDetails(int index) if (!g_settings.channellist_show_infobox) return; + int ypos = y + height + OFFSET_INTER; + int ypos_a = ypos + OFFSET_INNER_SMALL; + CChannelEvent *p_event = NULL; //colored_events init bool colored_event_C = (g_settings.theme.colored_events_channellist == 1); bool colored_event_N = (g_settings.theme.colored_events_channellist == 2); - frameBuffer->paintBoxRel(x, y + height, full_width, info_height, COL_MENUCONTENTDARK_PLUS_0, RADIUS_LARGE); - frameBuffer->paintBoxFrame(x, y + height, full_width, info_height, 2, COL_FRAME_PLUS_0, RADIUS_LARGE); + frameBuffer->paintBoxRel(x, ypos, full_width, info_height, COL_MENUCONTENTDARK_PLUS_0, RADIUS_LARGE); + frameBuffer->paintBoxFrame(x, ypos, full_width, info_height, 2, COL_FRAME_PLUS_0, RADIUS_LARGE); if ((*chanlist).empty()) return; @@ -1587,7 +1590,7 @@ void CChannelList::paintDetails(int index) text3= text3+ " - "; xstart += g_Font[SNeutrinoSettings::FONT_TYPE_CHANNELLIST]->getRenderWidth(text3); - g_Font[SNeutrinoSettings::FONT_TYPE_CHANNELLIST]->RenderString(x+ 10, y+ height+ 5+ 2* fheight, full_width - 30- noch_len, text3, colored_event_C ? COL_COLORED_EVENTS_TEXT : COL_MENUCONTENTDARK_TEXT); + g_Font[SNeutrinoSettings::FONT_TYPE_CHANNELLIST]->RenderString(x+ 10, ypos_a + 2*fheight, full_width - 30- noch_len, text3, colored_event_C ? COL_COLORED_EVENTS_TEXT : COL_MENUCONTENTDARK_TEXT); } if (!(text2.empty())) { @@ -1604,18 +1607,18 @@ void CChannelList::paintDetails(int index) } } #endif - g_Font[SNeutrinoSettings::FONT_TYPE_CHANNELLIST_DESCR]->RenderString(x+ xstart, y+ height+ 5+ fdescrheight+ fheight, full_width- xstart- 30- noch_len, text2, colored_event_C ? COL_COLORED_EVENTS_TEXT : COL_MENUCONTENTDARK_TEXT); + g_Font[SNeutrinoSettings::FONT_TYPE_CHANNELLIST_DESCR]->RenderString(x+ xstart, ypos_a + fdescrheight+ fheight, full_width- xstart- 30- noch_len, text2, colored_event_C ? COL_COLORED_EVENTS_TEXT : COL_MENUCONTENTDARK_TEXT); } - g_Font[SNeutrinoSettings::FONT_TYPE_CHANNELLIST]->RenderString(x+ 10, y+ height+ 5+ fheight, full_width - 30 - seit_len, text1, colored_event_C ? COL_COLORED_EVENTS_TEXT : COL_MENUCONTENTDARK_TEXT); - g_Font[SNeutrinoSettings::FONT_TYPE_CHANNELLIST_DESCR]->RenderString(x+ full_width- 10- seit_len, y+ height+ 5+ fheight, seit_len, cSeit, colored_event_C ? COL_COLORED_EVENTS_TEXT : COL_MENUCONTENTDARK_TEXT); - g_Font[SNeutrinoSettings::FONT_TYPE_CHANNELLIST_DESCR]->RenderString(x+ full_width- 10- noch_len, y+ height+ 5+ fdescrheight+ fheight, noch_len, cNoch, colored_event_C ? COL_COLORED_EVENTS_TEXT : COL_MENUCONTENTDARK_TEXT); + g_Font[SNeutrinoSettings::FONT_TYPE_CHANNELLIST]->RenderString(x+ 10, ypos_a + fheight, full_width - 30 - seit_len, text1, colored_event_C ? COL_COLORED_EVENTS_TEXT : COL_MENUCONTENTDARK_TEXT); + g_Font[SNeutrinoSettings::FONT_TYPE_CHANNELLIST_DESCR]->RenderString(x+ full_width- 10- seit_len, ypos_a + fheight , seit_len, cSeit, colored_event_C ? COL_COLORED_EVENTS_TEXT : COL_MENUCONTENTDARK_TEXT); + g_Font[SNeutrinoSettings::FONT_TYPE_CHANNELLIST_DESCR]->RenderString(x+ full_width- 10- noch_len, ypos_a + fdescrheight+ fheight, noch_len, cNoch, colored_event_C ? COL_COLORED_EVENTS_TEXT : COL_MENUCONTENTDARK_TEXT); } else if (IS_WEBTV((*chanlist)[index]->getChannelID())) { - g_Font[SNeutrinoSettings::FONT_TYPE_CHANNELLIST]->RenderString(x+ 10, y+ height+ 5+ fheight, full_width - 30, (*chanlist)[index]->getDesc(), colored_event_C ? COL_COLORED_EVENTS_TEXT : COL_MENUCONTENTDARK_TEXT, 0, true); + g_Font[SNeutrinoSettings::FONT_TYPE_CHANNELLIST]->RenderString(x+ 10, ypos_a + fheight, full_width - 30, (*chanlist)[index]->getDesc(), colored_event_C ? COL_COLORED_EVENTS_TEXT : COL_MENUCONTENTDARK_TEXT, 0, true); } if (IS_WEBTV((*chanlist)[index]->getChannelID())) { - g_Font[SNeutrinoSettings::FONT_TYPE_CHANNELLIST]->RenderString(x+ 10, y+ height+ 5+ 2*fheight + fdescrheight, full_width - 30, (*chanlist)[index]->getUrl(), COL_MENUCONTENTDARK_TEXT, 0, true); + g_Font[SNeutrinoSettings::FONT_TYPE_CHANNELLIST]->RenderString(x+ 10, ypos_a + 2*fheight + fdescrheight, full_width - 30, (*chanlist)[index]->getUrl(), COL_MENUCONTENTDARK_TEXT, 0, true); } else if(g_settings.channellist_foot == 0) { transponder t; CServiceManager::getInstance()->GetTransponder((*chanlist)[index]->getTransponderId(), t); @@ -1626,7 +1629,7 @@ void CChannelList::paintDetails(int index) else desc = desc + " (" + CServiceManager::getInstance()->GetSatelliteName((*chanlist)[index]->getSatellitePosition()) + ")"; - g_Font[SNeutrinoSettings::FONT_TYPE_CHANNELLIST]->RenderString(x+ 10, y+ height+ 5+ 2*fheight +fdescrheight, full_width - 30, desc.c_str(), COL_MENUCONTENTDARK_TEXT); + g_Font[SNeutrinoSettings::FONT_TYPE_CHANNELLIST]->RenderString(x+ 10, ypos_a + 2*fheight +fdescrheight, full_width - 30, desc.c_str(), COL_MENUCONTENTDARK_TEXT); } else if( !displayNext && g_settings.channellist_foot == 1) { // next Event @@ -1640,8 +1643,8 @@ void CChannelList::paintDetails(int index) snprintf(buf, sizeof(buf), "%s", CurrentNext.next_name.c_str()); int from_len = g_Font[SNeutrinoSettings::FONT_TYPE_CHANNELLIST_DESCR]->getRenderWidth(cFrom); - g_Font[SNeutrinoSettings::FONT_TYPE_CHANNELLIST]->RenderString(x+ 10, y+ height+ 5+ 2*fheight+ fdescrheight, full_width - 30 - from_len, buf, colored_event_N ? COL_COLORED_EVENTS_TEXT :COL_MENUCONTENTDARK_TEXT); - g_Font[SNeutrinoSettings::FONT_TYPE_CHANNELLIST_DESCR]->RenderString(x+ full_width- 10- from_len, y+ height+ 5+ 2*fheight+ fdescrheight, from_len, cFrom, colored_event_N ? COL_COLORED_EVENTS_TEXT : COL_MENUCONTENTDARK_TEXT); + g_Font[SNeutrinoSettings::FONT_TYPE_CHANNELLIST]->RenderString(x+ 10, ypos_a + 2*fheight+ fdescrheight, full_width - 30 - from_len, buf, colored_event_N ? COL_COLORED_EVENTS_TEXT :COL_MENUCONTENTDARK_TEXT); + g_Font[SNeutrinoSettings::FONT_TYPE_CHANNELLIST_DESCR]->RenderString(x+ full_width- 10- from_len, ypos_a + 2*fheight+ fdescrheight, from_len, cFrom, colored_event_N ? COL_COLORED_EVENTS_TEXT : COL_MENUCONTENTDARK_TEXT); } } } @@ -1664,7 +1667,7 @@ void CChannelList::paintItem2DetailsLine (int pos) int xpos = x - ConnectLineBox_Width; int ypos1 = y + theight + pos*fheight + (fheight/2); - int ypos2 = y + height + (info_height/2); + int ypos2 = y + height + OFFSET_INTER + (info_height/2); // paint Line if detail info (and not valid list pos) if (pos >= 0) {