Origin commit data
------------------
Branch: ni/coolstream
Commit: 4589862ad3
Author: gixxpunk <thomas.harfmann@gmail.com>
Date: 2017-05-07 (Sun, 07 May 2017)


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

------------------
This commit was generated by Migit
This commit is contained in:
gixxpunk
2017-05-07 19:05:56 +02:00
10 changed files with 326 additions and 114 deletions

View File

@@ -123,10 +123,10 @@ CChannelList::CChannelList(const char * const pName, bool phistoryMode, bool _vl
fheight = g_Font[SNeutrinoSettings::FONT_TYPE_CHANNELLIST]->getHeight(); fheight = g_Font[SNeutrinoSettings::FONT_TYPE_CHANNELLIST]->getHeight();
fdescrheight = g_Font[SNeutrinoSettings::FONT_TYPE_CHANNELLIST_DESCR]->getHeight(); fdescrheight = g_Font[SNeutrinoSettings::FONT_TYPE_CHANNELLIST_DESCR]->getHeight();
previous_channellist_additional = -1; previous_channellist_additional = g_settings.channellist_additional;
eventFont = SNeutrinoSettings::FONT_TYPE_CHANNELLIST_EVENT; eventFont = SNeutrinoSettings::FONT_TYPE_CHANNELLIST_EVENT;
dline = NULL; dline = NULL;
cc_minitv = NULL;
minitv_is_active = false; minitv_is_active = false;
headerNew = true; headerNew = true;
bouquet = NULL; bouquet = NULL;
@@ -137,6 +137,7 @@ CChannelList::CChannelList(const char * const pName, bool phistoryMode, bool _vl
paint_events_index = -2; paint_events_index = -2;
CFrameBuffer::getInstance()->OnAfterSetPallette.connect(sigc::mem_fun(this, &CChannelList::ResetModules)); CFrameBuffer::getInstance()->OnAfterSetPallette.connect(sigc::mem_fun(this, &CChannelList::ResetModules));
CNeutrinoApp::getInstance()->OnAfterSetupFonts.connect(sigc::mem_fun(this, &CChannelList::ResetModules));
} }
CChannelList::~CChannelList() CChannelList::~CChannelList()
@@ -301,7 +302,7 @@ int CChannelList::doChannelMenu(void)
int shortcut = 0; int shortcut = 0;
static int old_selected = 0; static int old_selected = 0;
char cnt[5]; char cnt[5];
bool unlocked = true;
int ret = 0; int ret = 0;
if(g_settings.minimode) if(g_settings.minimode)
@@ -363,7 +364,8 @@ int CChannelList::doChannelMenu(void)
CBouquetList *blist = tvmode ? TVfavList : RADIOfavList; CBouquetList *blist = tvmode ? TVfavList : RADIOfavList;
bool fav_found = true; bool fav_found = true;
switch(select) { switch(select) {
case 0: // edit mode case 0: {// edit mode
bool unlocked = true;
if (g_settings.parentallock_prompt == PARENTALLOCK_PROMPT_CHANGETOLOCKED) { if (g_settings.parentallock_prompt == PARENTALLOCK_PROMPT_CHANGETOLOCKED) {
int pl_z = g_settings.parentallock_zaptime * 60; int pl_z = g_settings.parentallock_zaptime * 60;
if (g_settings.personalize[SNeutrinoSettings::P_MSER_BOUQUET_EDIT] == CPersonalizeGui::PERSONALIZE_MODE_PIN) { if (g_settings.personalize[SNeutrinoSettings::P_MSER_BOUQUET_EDIT] == CPersonalizeGui::PERSONALIZE_MODE_PIN) {
@@ -388,7 +390,7 @@ int CChannelList::doChannelMenu(void)
editMode(true); editMode(true);
ret = -1; ret = -1;
break; break;
case 1: // add to }case 1: // add to
if (!addChannelToBouquet()) if (!addChannelToBouquet())
return -1; return -1;
ret = 1; ret = 1;
@@ -487,7 +489,7 @@ void CChannelList::calcSize()
fheight = 1; /* avoid div-by-zero crash on invalid font */ fheight = 1; /* avoid div-by-zero crash on invalid font */
footerHeight = g_Font[SNeutrinoSettings::FONT_TYPE_MENU_FOOT]->getHeight()+6; footerHeight = g_Font[SNeutrinoSettings::FONT_TYPE_MENU_FOOT]->getHeight()+6;
minitv_is_active = ( (g_settings.channellist_additional == 2) && (CNeutrinoApp::getInstance()->getMode() != NeutrinoMessages::mode_ts) ); minitv_is_active = ( (g_settings.channellist_additional == SNeutrinoSettings::CHANNELLIST_ADDITIONAL_MODE_MINITV) && (CNeutrinoApp::getInstance()->getMode() != NeutrinoMessages::mode_ts) );
// calculate width // calculate width
full_width = frameBuffer->getScreenWidthRel(); //NI full_width = frameBuffer->getScreenWidthRel(); //NI
@@ -961,11 +963,11 @@ int CChannelList::show()
void CChannelList::hide() void CChannelList::hide()
{ {
paint_events(-2); // cancel paint_events thread paint_events(-2); // cancel paint_events thread
if ((g_settings.channellist_additional == 2) || (previous_channellist_additional == 2)) // with miniTV if ((g_settings.channellist_additional == SNeutrinoSettings::CHANNELLIST_ADDITIONAL_MODE_MINITV) || (previous_channellist_additional == SNeutrinoSettings::CHANNELLIST_ADDITIONAL_MODE_MINITV)) // with miniTV
{ {
if (cc_minitv) if (cc_minitv){
delete cc_minitv; delete cc_minitv; cc_minitv = NULL;
cc_minitv = NULL; }
} }
if(header) if(header)
header->kill(); header->kill();
@@ -2184,13 +2186,17 @@ void CChannelList::paintHead()
CComponentsHeader* CChannelList::getHeaderObject() CComponentsHeader* CChannelList::getHeaderObject()
{ {
if (header)
return header; return header;
return NULL;
} }
void CChannelList::ResetModules() void CChannelList::ResetModules()
{ {
if (header){
delete header; delete header;
header = NULL; header = NULL;
}
if(dline){ if(dline){
delete dline; delete dline;
dline = NULL; dline = NULL;

View File

@@ -67,7 +67,7 @@ enum {
class CFrameBuffer; class CFrameBuffer;
class CBouquet; class CBouquet;
class CChannelList : public CListHelpers class CChannelList : public CListHelpers, public sigc::trackable
{ {
private: private:
enum state_ enum state_

View File

@@ -127,10 +127,6 @@ CEpgData::CEpgData()
mp_movie_info = NULL; mp_movie_info = NULL;
header = NULL; header = NULL;
Bottombox = NULL; Bottombox = NULL;
lpic = NULL;
rpic = NULL;
lText = NULL;
rText = NULL;
pb = NULL; pb = NULL;
font_title = NULL; font_title = NULL;
@@ -915,65 +911,17 @@ int CEpgData::show(const t_channel_id channel_id, uint64_t a_id, time_t* a_start
showText(showPos, sy + toph); showText(showPos, sy + toph);
// small bottom box with left/right navigation // small bottom box with left/right navigation
if (!Bottombox){ if (!Bottombox)
Bottombox = new CComponentsFrmChain(sx, sy+oy-botboxheight, ox, botboxheight); Bottombox = new CNaviBar(sx, sy+oy-botboxheight, ox, botboxheight);
Bottombox->setColorBody(COL_MENUFOOT_PLUS_0);
Bottombox->setCornerType(CORNER_NONE);
Bottombox->enableColBodyGradient(g_settings.theme.infobar_gradient_bottom,COL_MENUFOOT_PLUS_0,g_settings.theme.infobar_gradient_bottom_direction);
Bottombox->set2ndColor(COL_MENUCONTENT_PLUS_0);
}
if (!mp_info){ if (!mp_info){
std::string fromto = epg_start + " - " + epg_end; std::string fromto = epg_start + " - " + epg_end;
int x_off = OFFSET_INNER_MID;
int mid_width = ox * 40 / 100; // 40%
int side_width = ((ox - mid_width) / 2) - (2 * x_off);
GetPrevNextEPGData(epgData.eventID, &epgData.epg_times.startzeit); GetPrevNextEPGData(epgData.eventID, &epgData.epg_times.startzeit);
// init left arrow Bottombox->enableArrows(prev_id && !call_fromfollowlist, next_id && !call_fromfollowlist);
if (!lpic){ Bottombox->setText(fromto, epg_date);
lpic = new CComponentsPictureScalable(x_off,CC_CENTERED,NEUTRINO_ICON_BUTTON_LEFT);
lpic->doPaintBg(false);
Bottombox->addCCItem(lpic);
lpic->enableSaveBg();
} }
lpic->allowPaint(prev_id && !call_fromfollowlist);
// init right arrow
if (!rpic){
rpic = new CComponentsPictureScalable(0,CC_CENTERED,NEUTRINO_ICON_BUTTON_RIGHT);
rpic->doPaintBg(false);
Bottombox->addCCItem(rpic);
rpic->enableSaveBg();
int x_pos = ox - rpic->getWidth() - x_off;
rpic->setXPos(x_pos);
}
rpic->allowPaint(next_id && !call_fromfollowlist);
// init text left "from to"
if (!lText){
lText = new CComponentsText(x_off + lpic->getWidth() + x_off, CC_CENTERED, side_width, toph, "", CTextBox::NO_AUTO_LINEBREAK, g_Font[SNeutrinoSettings::FONT_TYPE_EPG_DATE], CComponentsText::FONT_STYLE_REGULAR, NULL, CC_SHADOW_OFF, COL_MENUHEAD_TEXT);
lText->doPaintBg(false);
Bottombox->addCCItem(lText);
lText->enableSaveBg();
}
lText->setText(fromto, CTextBox::NO_AUTO_LINEBREAK, g_Font[SNeutrinoSettings::FONT_TYPE_EPG_DATE], COL_MENUHEAD_TEXT, CComponentsText::FONT_STYLE_REGULAR);
// init text right "follow"
if (!rText){
rText = new CComponentsText(0, CC_CENTERED, side_width, toph, "", CTextBox::NO_AUTO_LINEBREAK | CTextBox::RIGHT, g_Font[SNeutrinoSettings::FONT_TYPE_EPG_DATE], CComponentsText::FONT_STYLE_REGULAR, Bottombox, CC_SHADOW_OFF, COL_MENUHEAD_TEXT);
rText->doPaintBg(false);
rText->enableSaveBg();
}
rText->setText(epg_date, CTextBox::NO_AUTO_LINEBREAK | CTextBox::RIGHT, g_Font[SNeutrinoSettings::FONT_TYPE_EPG_DATE]);
rText->setXPos(rpic->getXPos() - x_off - rText->getWidth());
}
//ensure clean background
if(Bottombox->isPainted())
Bottombox->hideCCItems();
//paint bottombox contents //paint bottombox contents
Bottombox->paint(false); Bottombox->paint(false);
@@ -1749,9 +1697,6 @@ void CEpgData::ResetModules()
} }
if (Bottombox){ if (Bottombox){
delete Bottombox; Bottombox = NULL; delete Bottombox; Bottombox = NULL;
// bottom box items are destroyed but explicit reset of bottom box items here required
lpic = rpic = NULL;
lText = rText = NULL;
} }
if (pb){ if (pb){
delete pb; pb = NULL; delete pb; pb = NULL;

View File

@@ -39,7 +39,7 @@
#include <gui/imdb.h> //NI #include <gui/imdb.h> //NI
#include <driver/movieinfo.h> #include <driver/movieinfo.h>
#include "widget/menue.h" #include "widget/menue.h"
#include "widget/navibar.h"
#include <vector> #include <vector>
#include <string> #include <string>
@@ -54,9 +54,7 @@ class CEpgData
CIMDB *imdb; //NI CIMDB *imdb; //NI
CComponentsHeader *header; CComponentsHeader *header;
CComponentsFrmChain *Bottombox; CNaviBar *Bottombox;
CComponentsPictureScalable *lpic, *rpic;
CComponentsText *lText, *rText;
CProgressBar *pb; CProgressBar *pb;
Font *font_title; Font *font_title;
std::string epg_date; std::string epg_date;

View File

@@ -897,44 +897,14 @@ void CEventList::paintHead(t_channel_id _channel_id, std::string _channelname, s
void CEventList::paintBottomBox(std::string _channelname_prev, std::string _channelname_next) void CEventList::paintBottomBox(std::string _channelname_prev, std::string _channelname_next)
{ {
int by = y + height - iheight - botboxheight; int by = y + height - iheight - botboxheight;
int font_lr = SNeutrinoSettings::FONT_TYPE_EVENTLIST_ITEMLARGE;
int x_off = OFFSET_INNER_MID;
int mid_width = full_width * 40 / 100; // 40%
int side_width = ((full_width - mid_width) / 2) - (2 * x_off);
if (!Bottombox){ if (!Bottombox){
Bottombox = new CComponentsFrmChain(x, by, full_width, botboxheight); Bottombox = new CNaviBar(x, by, full_width, botboxheight);
Bottombox->setColorBody(COL_MENUFOOT_PLUS_0); Bottombox->setFont(g_Font[SNeutrinoSettings::FONT_TYPE_EVENTLIST_ITEMLARGE]);
Bottombox->enableColBodyGradient(g_settings.theme.infobar_gradient_bottom,COL_MENUFOOT_PLUS_0,g_settings.theme.infobar_gradient_bottom_direction);
Bottombox->set2ndColor(COL_MENUCONTENT_PLUS_0);
}else{
if (Bottombox->isPainted())
Bottombox->hideCCItems();
Bottombox->clear();
} }
if (!_channelname_prev.empty()) { Bottombox->enableArrows(!_channelname_prev.empty(), !_channelname_next.empty());
CComponentsPictureScalable *lpic = new CComponentsPictureScalable(x_off,CC_CENTERED,NEUTRINO_ICON_BUTTON_LEFT,Bottombox); Bottombox->setText(_channelname_prev, _channelname_next);
lpic->doPaintBg(false);
lpic->enableSaveBg();
CComponentsText *lText = new CComponentsText(x_off + lpic->getWidth() + OFFSET_INNER_MID, CC_CENTERED, side_width, theight, _channelname_prev, CTextBox::NO_AUTO_LINEBREAK, g_Font[font_lr], CComponentsText::FONT_STYLE_REGULAR, Bottombox, CC_SHADOW_OFF, COL_MENUHEAD_TEXT);
lText->doPaintBg(false);
lText->enableSaveBg();
}
if (!_channelname_next.empty()) {
CComponentsPictureScalable *rpic = new CComponentsPictureScalable(0,CC_CENTERED,NEUTRINO_ICON_BUTTON_RIGHT,Bottombox);
int x_pos = full_width - rpic->getWidth() - OFFSET_INNER_MID;
rpic->doPaintBg(false);
rpic->setXPos(x_pos);
rpic->enableSaveBg();
CComponentsText *rText = new CComponentsText(0, CC_CENTERED, side_width, theight, _channelname_next, CTextBox::NO_AUTO_LINEBREAK | CTextBox::RIGHT, g_Font[font_lr], CComponentsText::FONT_STYLE_REGULAR, Bottombox, CC_SHADOW_OFF, COL_MENUHEAD_TEXT);
rText->setXPos(x_pos - OFFSET_INNER_MID - rText->getWidth());
rText->doPaintBg(false);
rText->enableSaveBg();
}
Bottombox->paint(false); Bottombox->paint(false);
} }

View File

@@ -32,7 +32,7 @@
#include <driver/rcinput.h> #include <driver/rcinput.h>
#include <system/settings.h> #include <system/settings.h>
#include <gui/components/cc.h> #include <gui/components/cc.h>
#include <gui/widget/navibar.h>
#include "infoviewer.h" #include "infoviewer.h"
#include "widget/menue.h" #include "widget/menue.h"
@@ -105,7 +105,7 @@ class CEventList : public CListHelpers
CComponentsText *cc_infozone; CComponentsText *cc_infozone;
CComponentsHeader *header; CComponentsHeader *header;
CProgressBar *pb; CProgressBar *pb;
CComponentsFrmChain *Bottombox; CNaviBar *Bottombox;
const char * unit_short_minute; const char * unit_short_minute;
void paintItem(unsigned pos, t_channel_id channel_id = 0); void paintItem(unsigned pos, t_channel_id channel_id = 0);

View File

@@ -27,6 +27,7 @@ libneutrino_gui_widget_a_SOURCES = \
menue.cpp \ menue.cpp \
mountchooser.cpp \ mountchooser.cpp \
msgbox.cpp \ msgbox.cpp \
navibar.cpp \
shellwindow.cpp \ shellwindow.cpp \
stringinput.cpp \ stringinput.cpp \
stringinput_ext.cpp \ stringinput_ext.cpp \

116
src/gui/widget/navibar.cpp Normal file
View File

@@ -0,0 +1,116 @@
/*
Based up Neutrino-GUI - Tuxbox-Project
Copyright (C) 2001 by Steffen Hehn 'McClean'
Class for epg window navigation bar.
Copyright (C) 2017, Thilo Graf 'dbt'
License: GPL
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public
License as published by the Free Software Foundation; either
version 2 of the License, or (at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
#ifdef HAVE_CONFIG_H
#include <config.h>
#endif
#include "navibar.h"
using namespace std;
CNaviBar::CNaviBar( const int& x,
const int& y,
const int& dx,
const int& dy,
CComponentsForm* parent,
int shadow_mode,
fb_pixel_t& color_frame,
fb_pixel_t& color_body,
fb_pixel_t& color_shadow)
: CComponentsFrmChain( x, y, dx, dy,
NULL,
CC_DIR_X,
parent,
shadow_mode,
color_frame,
color_body,
color_shadow)
{
setCornerType(CORNER_NONE);
enableColBodyGradient(g_settings.theme.infobar_gradient_bottom,COL_MENUFOOT_PLUS_0,g_settings.theme.infobar_gradient_bottom_direction);
set2ndColor(COL_MENUCONTENT_PLUS_0);
nb_lpic = nb_rpic = NULL;
nb_lText = nb_rText = NULL;
nb_font = g_Font[SNeutrinoSettings::FONT_TYPE_EPG_DATE];;
nb_lpic_enable = nb_rpic_enable = false;
nb_l_text = nb_r_text = string();
initCCItems();
}
void CNaviBar::initCCItems()
{
int x_off = OFFSET_INNER_MID;
int mid_width = width * 40 / 100; // 40%
int side_width = ((width - mid_width) / 2) - (2 * x_off);
int h_text = height;
// init left arrow
if (!nb_lpic){
nb_lpic = new CComponentsPictureScalable(x_off,CC_CENTERED,NEUTRINO_ICON_BUTTON_LEFT);
nb_lpic->doPaintBg(false);
this->addCCItem(nb_lpic);
nb_lpic->enableSaveBg();
}
nb_lpic->allowPaint(nb_lpic_enable);
// init right arrow
if (!nb_rpic){
nb_rpic = new CComponentsPictureScalable(0,CC_CENTERED,NEUTRINO_ICON_BUTTON_RIGHT);
nb_rpic->doPaintBg(false);
this->addCCItem(nb_rpic);
nb_rpic->enableSaveBg();
int x_pos = width - nb_rpic->getWidth() - x_off;
nb_rpic->setXPos(x_pos);
}
nb_rpic->allowPaint(nb_rpic_enable);
// init text left
if (!nb_lText){
nb_lText = new CComponentsText(x_off + nb_lpic->getWidth() + x_off, CC_CENTERED, side_width, h_text, "", CTextBox::NO_AUTO_LINEBREAK, g_Font[SNeutrinoSettings::FONT_TYPE_EPG_DATE], CComponentsText::FONT_STYLE_REGULAR, this, CC_SHADOW_OFF, COL_MENUHEAD_TEXT);
nb_lText->doPaintBg(false);
nb_lText->enableSaveBg();
}
nb_lText->setText(nb_l_text, CTextBox::NO_AUTO_LINEBREAK, nb_font, COL_MENUHEAD_TEXT, CComponentsText::FONT_STYLE_REGULAR);
// init text right
if (!nb_rText){
nb_rText = new CComponentsText(0, CC_CENTERED, side_width, h_text, "", CTextBox::NO_AUTO_LINEBREAK | CTextBox::RIGHT, g_Font[SNeutrinoSettings::FONT_TYPE_EPG_DATE], CComponentsText::FONT_STYLE_REGULAR, this, CC_SHADOW_OFF, COL_MENUHEAD_TEXT);
nb_rText->doPaintBg(false);
nb_rText->enableSaveBg();
}
nb_rText->setText(nb_r_text, CTextBox::NO_AUTO_LINEBREAK | CTextBox::RIGHT, nb_font);
nb_rText->setXPos(nb_rpic->getXPos() - x_off - nb_rText->getWidth());
}
void CNaviBar::paint(bool do_save_bg)
{
hideCCItems();
CComponentsFrmChain::paint(do_save_bg);
}

169
src/gui/widget/navibar.h Normal file
View File

@@ -0,0 +1,169 @@
/*
Based up Neutrino-GUI - Tuxbox-Project
Copyright (C) 2001 by Steffen Hehn 'McClean'
Class for epg window navigation bar.
Copyright (C) 2017, Thilo Graf 'dbt'
License: GPL
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public
License as published by the Free Software Foundation; either
version 2 of the License, or (at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
#ifndef __C_NAVIBAR__
#define __C_NAVIBAR__
#include <gui/components/cc.h>
#include <driver/fontrenderer.h>
/**
CNaviBar is sub class of CComponentsFrmChain.
Shows a navigation bar with text and navigation icons.
You can enable/disable predefined icons and texts
on the left and/or right side of bar.
*/
class CNaviBar : public CComponentsFrmChain
{
private:
CComponentsPictureScalable *nb_lpic, *nb_rpic;
CComponentsText *nb_lText, *nb_rText;
Font *nb_font;
bool nb_lpic_enable;
bool nb_rpic_enable;
std::string nb_l_text;
std::string nb_r_text;
void initCCItems();
public:
/**CNaviBar Constructor
* @param[in] x
* @li expects type int, x position
* @param[in] y
* @li expects type int, y position
* @param[in] dx
* @li expects type int, width
* @param[in] dy
* @li expects type int, height
* @param[in] parent
* @li optional: expects type CComponentsForm or derivates, allows usage as item inside CComponentsForm container, default = NULL
* @param[in] shadow_mode
* @li optional: expects type fb_pixel_t, defines shadow mode, default CC_SHADOW_OFF
* @param[in] color_frame
* @li optional: expects type fb_pixel_t, defines frame color, default value = COL_FRAME_PLUS_0
* @param[in] color_body
* @li optional: expects type fb_pixel_t, defines body color, default value = COL_MENUFOOT_PLUS_0
* @param[in] color_shadow
* @li optional: expects type fb_pixel_t, defines shadow color, default value = COL_SHADOW_PLUS_0
*
* @see class CComponentsFrmChain()
*/
CNaviBar( const int& x,
const int& y,
const int& dx,
const int& dy,
CComponentsForm* parent = NULL,
int shadow_mode = CC_SHADOW_OFF,
fb_pixel_t& color_frame = COL_FRAME_PLUS_0,
fb_pixel_t& color_body = COL_MENUFOOT_PLUS_0,
fb_pixel_t& color_shadow = COL_SHADOW_PLUS_0);
//~CNaviBar(); //is inherited
/**
* Enable or disable left icon
* @param[in] enable
* @li exepts type bool, default = true
*/
void enableLeftArrow(bool enable = true){nb_lpic_enable = enable; initCCItems();}
/**
* Enable or disable right icon
* @param[in] enable
* @li exepts type bool, default = true
*/
void enableRightArrow(bool enable = true){nb_rpic_enable = enable; initCCItems();}
/**
* disable left icon
* no parameter
*/
void disableLeftArrow(){enableLeftArrow(false);}
/**
* disable right icon
* no parameter
*/
void disableRightArrow(){enableRightArrow(false);}
/**
* Enable or disable both icons at once.
* @param[in] enable_left
* @li exepts type bool, default = true
* @param[in] enable_right
* @li exepts type bool, default = true
*/
void enableArrows(bool enable_left = true, bool enable_right = true){enableLeftArrow(enable_left); enableRightArrow(enable_right);}
/**
* Disable all icons.
* no parameter
*/
void disableArrows(){disableLeftArrow(); disableRightArrow();}
/**
* Sets font type for texts.
* @param[in] font
* @li exepts type Font*
*/
void setFont(Font *font) {nb_font = font; initCCItems();}
/**
* Sets left text.
* @param[in] text
* @li exepts type std::string
*/
void setLeftText(const std::string& text) {nb_l_text = text; initCCItems();}
/**
* Sets right text
* @param[in] text
* @li exepts type std::string
*/
void setRightText(const std::string& text) {nb_r_text = text; initCCItems();}
/**
* Sets left and right text at once.
* @param[in] left
* @li exepts type std::string
* @param[in] right
* @li exepts type std::string
*/
void setText(const std::string& left, const std::string& right) {setLeftText(left); setRightText(right);}
/**
* Paint bar on screen.
* @param[in] do_save_bg
* @li optional: exepts type bool, default = CC_SAVE_SCREEN_YES.
*/
void paint(bool do_save_bg = CC_SAVE_SCREEN_YES);
};
#endif

View File

@@ -605,6 +605,13 @@ struct SNeutrinoSettings
int window_height; int window_height;
int eventlist_additional; int eventlist_additional;
int eventlist_epgplus; int eventlist_epgplus;
enum CHANNELLIST_ADDITIONAL_MODES
{
CHANNELLIST_ADDITIONAL_MODE_OFF = 0,
CHANNELLIST_ADDITIONAL_MODE_EPG = 1,
CHANNELLIST_ADDITIONAL_MODE_MINITV = 2
};
int channellist_additional; int channellist_additional;
int channellist_epgtext_align_right; int channellist_epgtext_align_right;
int channellist_foot; int channellist_foot;