mirror of
https://github.com/tuxbox-fork-migrations/recycled-ni-neutrino.git
synced 2025-08-29 16:31:05 +02:00
Display error EPG (Buttons are partially drawn out of the EPG screen)
- Use ::paintButtons (buttons.cpp) calculating to the height FunctionBar.
git-svn-id: file:///home/bas/coolstream_public_svn/THIRDPARTY/applications/neutrino-beta@1810 e54a6e83-5905-42d5-8d5c-058d10e6a962
Origin commit data
------------------
Branch: ni/coolstream
Commit: b9ac051420
Author: Michael Liebmann <tuxcode.bbg@gmail.com>
Date: 2011-11-03 (Thu, 03 Nov 2011)
------------------
This commit was generated by Migit
This commit is contained in:
@@ -248,21 +248,18 @@ int EventList::exec(const t_channel_id channel_id, const std::string& channelnam
|
|||||||
neutrino_msg_t msg;
|
neutrino_msg_t msg;
|
||||||
neutrino_msg_data_t data;
|
neutrino_msg_data_t data;
|
||||||
bool in_search = false;
|
bool in_search = false;
|
||||||
|
|
||||||
iheight = 30; // info bar height (see below, hard coded at this time)
|
|
||||||
|
|
||||||
|
// Calculate iheight
|
||||||
|
struct button_label tmp_button[1] = { { NEUTRINO_ICON_BUTTON_RED, NONEXISTANT_LOCALE } };
|
||||||
|
iheight = ::paintButtons(0, 0, 0, 1, tmp_button, 0, 0, false, COL_INFOBAR_SHADOW, NULL, 0, false);
|
||||||
if(iheight < fh)
|
if(iheight < fh)
|
||||||
iheight = fh;
|
iheight = fh;
|
||||||
|
|
||||||
int icol_w = 0, icol_h = 0;
|
// Calculate theight
|
||||||
frameBuffer->getIconSize(NEUTRINO_ICON_BUTTON_RED, &icol_w, &icol_h);
|
|
||||||
|
|
||||||
iheight = std::max(iheight, icol_h);
|
|
||||||
theight = g_Font[SNeutrinoSettings::FONT_TYPE_EVENTLIST_TITLE]->getHeight();
|
theight = g_Font[SNeutrinoSettings::FONT_TYPE_EVENTLIST_TITLE]->getHeight();
|
||||||
|
|
||||||
const int pic_h = 39;
|
const int pic_h = 39;
|
||||||
theight = std::max(theight, pic_h);
|
theight = std::max(theight, pic_h);
|
||||||
|
int icol_w = 0, icol_h = 0;
|
||||||
frameBuffer->getIconSize(NEUTRINO_ICON_BUTTON_HELP, &icol_w, &icol_h);
|
frameBuffer->getIconSize(NEUTRINO_ICON_BUTTON_HELP, &icol_w, &icol_h);
|
||||||
theight = std::max(theight, icol_h);
|
theight = std::max(theight, icol_h);
|
||||||
|
|
||||||
|
@@ -68,7 +68,8 @@ int paintButtons( const int &x,
|
|||||||
bool vertical_paint,
|
bool vertical_paint,
|
||||||
const unsigned char fcolor,
|
const unsigned char fcolor,
|
||||||
const char * alt_buttontext,
|
const char * alt_buttontext,
|
||||||
const uint &buttontext_id)
|
const uint &buttontext_id,
|
||||||
|
bool show)
|
||||||
{
|
{
|
||||||
CFrameBuffer *frameBuffer = CFrameBuffer::getInstance();
|
CFrameBuffer *frameBuffer = CFrameBuffer::getInstance();
|
||||||
Font * font = g_Font[SNeutrinoSettings::FONT_TYPE_INFOBAR_SMALL];
|
Font * font = g_Font[SNeutrinoSettings::FONT_TYPE_INFOBAR_SMALL];
|
||||||
@@ -122,6 +123,9 @@ int paintButtons( const int &x,
|
|||||||
//calculate footer heigth
|
//calculate footer heigth
|
||||||
h_footer = footerheight == 0 ? (h_button + 2*h_space) : footerheight;
|
h_footer = footerheight == 0 ? (h_button + 2*h_space) : footerheight;
|
||||||
|
|
||||||
|
if (!show)
|
||||||
|
return h_footer;
|
||||||
|
|
||||||
//paint footer
|
//paint footer
|
||||||
if (w_footer > 0)
|
if (w_footer > 0)
|
||||||
frameBuffer->paintBoxRel(x_footer, y_footer, w_footer, h_footer, COL_INFOBAR_SHADOW_PLUS_1, RADIUS_LARGE, CORNER_BOTTOM); //round
|
frameBuffer->paintBoxRel(x_footer, y_footer, w_footer, h_footer, COL_INFOBAR_SHADOW_PLUS_1, RADIUS_LARGE, CORNER_BOTTOM); //round
|
||||||
|
@@ -43,7 +43,7 @@ int paintButtons( const int &x,
|
|||||||
bool vertical_paint = false,
|
bool vertical_paint = false,
|
||||||
const unsigned char fcolor = COL_INFOBAR_SHADOW,
|
const unsigned char fcolor = COL_INFOBAR_SHADOW,
|
||||||
const char * alt_buttontext = NULL,
|
const char * alt_buttontext = NULL,
|
||||||
const uint &buttontext_id = 0);
|
const uint &buttontext_id = 0,
|
||||||
|
bool show = true);
|
||||||
|
|
||||||
#endif /* __gui_widget_buttons_h__ */
|
#endif /* __gui_widget_buttons_h__ */
|
||||||
|
Reference in New Issue
Block a user