[Commits] : Tuxbox-GIT: apps branch master updated. CVS-Final-139-g51c9a02
Tuxbox Sources
Brought to you by:
dbt1
|
From: Thilo G. <tux...@ne...> - 2013-04-30 06:15:37
|
Project "Tuxbox-GIT: apps":
The branch, master has been updated
via 51c9a02e9630fb0744eea7664b6772aca8b6d7f3 (commit)
via 2ee986630202e9b08b881fe972cc33b7b68967dd (commit)
via 09fe447728d819946215b26f3ce1a75a12b8de19 (commit)
via a8c58ff7f14ce3e28ae35090aa931f4bea75823f (commit)
via 6854af4a1f6d7cd12f23ccd3f179fa36eb70276d (commit)
via 72e67085ff69553395eb5d23c24896c156b8248c (commit)
via 8c56d34e5591a42768b96ddd3305c755441ba8d4 (commit)
via a967ebae0744fe64f265c98d1fed0c1a6a162fb5 (commit)
via d7b95b5a94e6f0c44a410bde47ad6a3c7c556e1c (commit)
via 275bf133983690f10d36cc141bef989889575e89 (commit)
via 524fe056252cd77792885c9bb081e1f80cff52b1 (commit)
via df0adb40aef302167639dd79b141e550a9350a34 (commit)
via 8d58661d3e921afc184233a5896ec1f3eaab1e19 (commit)
via 5b3a1e1f3272ee141083e97b8f6ca94c804baf40 (commit)
via ebe5796b56af0d90fed1b07c32eb6d2f45a0a20a (commit)
via d61aadd2ba940cd52a15f45ff7d3feb7796d7fe6 (commit)
via ad82c8eed470084299f37a718e1be5cf8d837fe7 (commit)
via 83716e51dca34a19feaf414b298af2363fcc5bd9 (commit)
via 15f3b51886a333256e7698be8cebfcc8c8540828 (commit)
via 4876e6f59be97e12e9caa76cd775a33e50faf80e (commit)
via 5a61b058ba4e4f5328c2c32eae69916ba152a741 (commit)
via 8a9a9871586d6386d4443c2d84fbd5d772dde940 (commit)
via 53a3fa70e547b8a164184dc466d7d833bad6aa89 (commit)
via 31f4161bd4b7900a1299e3475eef51a5622e07b1 (commit)
via aa628e1b7f5aa7539749dd61e9b7a0096145a607 (commit)
from db94409e9100a7cac7f438cbd8aebce09c7b1126 (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
commit 51c9a02e9630fb0744eea7664b6772aca8b6d7f3
Author: GetAway <get...@t-...>
Date: Mon Apr 29 17:27:44 2013 +0200
audioplayer: use new style of item2Detailsline recalc playlistsize if filled and empty
Signed-off-by: Thilo Graf <db...@no...>
diff --git a/tuxbox/neutrino/src/gui/audioplayer.cpp b/tuxbox/neutrino/src/gui/audioplayer.cpp
index 58e9c7d..66ffe51 100644
--- a/tuxbox/neutrino/src/gui/audioplayer.cpp
+++ b/tuxbox/neutrino/src/gui/audioplayer.cpp
@@ -92,10 +92,10 @@
#define DVR ADAP "/dvr0"
#endif
-#ifdef ConnectLineBox_Width
-#undef ConnectLineBox_Width
-#endif
-#define ConnectLineBox_Width 16
+//#ifdef ConnectLineBox_Width
+//#undef ConnectLineBox_Width
+//#endif
+#define ConnectLineBox_Width 12
#define AUDIOPLAYERGUI_SMSKEY_TIMEOUT 1000
#define SHOW_FILE_LOAD_LIMIT 50
@@ -250,7 +250,7 @@ int CAudioPlayerGui::exec(CMenuTarget* parent, const std::string &)
m_current = 0;
m_selected = 0;
- m_width = w_max(710, ConnectLineBox_Width);
+ m_width = w_max(720, 2 * ConnectLineBox_Width);
m_height = h_max(570, 0);
m_sheight = g_Font[SNeutrinoSettings::FONT_TYPE_INFOBAR_SMALL]->getHeight();
m_buttonHeight = std::min(25, m_sheight);
@@ -260,9 +260,8 @@ int CAudioPlayerGui::exec(CMenuTarget* parent, const std::string &)
m_info_height = m_fheight*2;
m_listmaxshow = (m_height - m_info_height - m_title_height - m_theight - 2*m_buttonHeight) / (m_fheight);
m_height = m_theight + m_info_height + m_title_height + 2*m_buttonHeight + m_listmaxshow * m_fheight; // recalc height
+ calcSize();
- m_x = getScreenStartX(m_width + ConnectLineBox_Width) + ConnectLineBox_Width;
- m_y = getScreenStartY(m_height);
m_idletime=time(NULL);
m_screensaver=false;
@@ -387,6 +386,13 @@ int CAudioPlayerGui::exec(CMenuTarget* parent, const std::string &)
//------------------------------------------------------------------------
+void CAudioPlayerGui::calcSize()
+{
+ m_x = getScreenStartX(m_width - (m_playlist.empty() ? 0 : ConnectLineBox_Width));
+ m_y = getScreenStartY(m_height);
+}
+//------------------------------------------------------------------------
+
int CAudioPlayerGui::show()
{
neutrino_msg_t msg;
@@ -431,6 +437,7 @@ int CAudioPlayerGui::show()
clear_before_update = false;
}
update = false;
+ calcSize();
paint();
}
g_RCInput->getMsg(&msg, &data, 10); // 1 sec timeout to update play/stop state display
@@ -1881,29 +1888,34 @@ void CAudioPlayerGui::paintItemID3DetailsLine (int pos)
m_height - m_title_height - m_info_height);
// paint Line if detail info (and not valid list pos)
- if (!m_playlist.empty() && (pos >= 0))
+ if (!m_playlist.empty() && (pos > -1))
{
// paint id3 infobox
- int yoffs = g_settings.rounded_corners ? 7 : 0;
- m_frameBuffer->paintBoxRel(xpos + ConnectLineBox_Width - 4, ypos2+yoffs, 1, m_info_height-2*yoffs, col2);
- m_frameBuffer->paintBoxRel(m_x - 3, ypos2+yoffs, 3, m_info_height-2*yoffs, col1);
m_frameBuffer->paintBoxFrame(m_x, ypos2, m_width, m_info_height, 2,col1, RADIUS_MID);
m_frameBuffer->paintBoxRel(m_x + 2, ypos2 + 2 , m_width - 4, m_info_height - 4, col3, RADIUS_MID);
- // 1. col thick line
- m_frameBuffer->paintBoxRel(xpos + ConnectLineBox_Width - 4, ypos1, 4, m_fheight, col2, RADIUS_SMALL, CORNER_LEFT);
- m_frameBuffer->paintBoxRel(xpos + ConnectLineBox_Width - 3, ypos1, 8, m_fheight, col1, RADIUS_SMALL, CORNER_LEFT); // item marker
- m_frameBuffer->paintBoxRel(xpos + ConnectLineBox_Width - 16, ypos1a, 4, ypos2a - ypos1a, col1);
+ // 1. top line vert.
+ m_frameBuffer->paintBoxRel(xpos+11, ypos1+4, 1,m_fheight-8, col2); // item marker gray vert.
+ m_frameBuffer->paintBoxRel(xpos+8, ypos1+4, 3,m_fheight-8, col1); // white vert.
+
+ // 2. top line hor.
+ m_frameBuffer->paintBoxRel(xpos, ypos1a , 8, 3, col1); //top small hor. line
+ m_frameBuffer->paintBoxRel(xpos, ypos1a+3, 8, 1, col2); // hor. gray top xxx
+
+ // 3. long line
+ m_frameBuffer->paintBoxRel(xpos, ypos1a, 3,ypos2a-ypos1a, col1); // white
+ m_frameBuffer->paintBoxRel(xpos+3, ypos1a+4, 1,ypos2a-ypos1a-4, col2); //vert. gray
- m_frameBuffer->paintBoxRel(xpos + ConnectLineBox_Width - 16, ypos1a, 12, 4, col1);
- m_frameBuffer->paintBoxRel(xpos + ConnectLineBox_Width - 16, ypos2a, 12, 4, col1);
+ // 4. bottom line vert.
+ m_frameBuffer->paintBoxRel(xpos, ypos2a , 8,3, col1); // white
+ m_frameBuffer->paintBoxRel(xpos, ypos2a+3, 8,1, col2); // gray
- // 2. col small line
- m_frameBuffer->paintBoxRel(xpos + ConnectLineBox_Width - 16, ypos1a, 1, ypos2a - ypos1a + 4, col2);
+ // 5. col thick line bottom
+ int yoffs = g_settings.rounded_corners ? 10 : 0;
+ m_frameBuffer->paintBoxRel(m_x-1, ypos2+yoffs, 1, m_info_height-2*yoffs, col2);
+ m_frameBuffer->paintBoxRel(m_x-4, ypos2+yoffs, 3, m_info_height-2*yoffs, col1);
- m_frameBuffer->paintBoxRel(xpos + ConnectLineBox_Width - 16, ypos1a, 12, 1, col2);
- m_frameBuffer->paintBoxRel(xpos + ConnectLineBox_Width - 12, ypos2a, 8, 1, col2);
g_Font[SNeutrinoSettings::FONT_TYPE_MENU]->RenderString(m_x + 10, ypos2 + 2 + 1*m_fheight, m_width- 80,
m_playlist[m_selected].MetaData.title, COL_MENUCONTENTDARK, 0, true); // UTF-8
diff --git a/tuxbox/neutrino/src/gui/audioplayer.h b/tuxbox/neutrino/src/gui/audioplayer.h
index cb06273..f288e97 100644
--- a/tuxbox/neutrino/src/gui/audioplayer.h
+++ b/tuxbox/neutrino/src/gui/audioplayer.h
@@ -147,6 +147,7 @@ class CAudioPlayerGui : public CMenuTarget
void paintInfo();
void paintLCD();
void hide();
+ void calcSize();
void get_id3(CAudiofileExt * audiofile);
void get_mp3info(CAudiofileExt * audiofile);
commit 2ee986630202e9b08b881fe972cc33b7b68967dd
Author: Christian Schuett <Gau...@ho...>
Date: Mon Apr 29 16:16:53 2013 +0200
Neutrino moviebrowser: only add separator line to serie menu if needed
Signed-off-by: Christian Schuett <Gau...@ho...>
Signed-off-by: Thilo Graf <db...@no...>
diff --git a/tuxbox/neutrino/src/gui/moviebrowser.cpp b/tuxbox/neutrino/src/gui/moviebrowser.cpp
index d218780..16713ee 100644
--- a/tuxbox/neutrino/src/gui/moviebrowser.cpp
+++ b/tuxbox/neutrino/src/gui/moviebrowser.cpp
@@ -3008,7 +3008,8 @@ int CMovieBrowser::showMovieInfoMenu(MI_MOVIE_INFO* movie_info)
CMenuWidget serieMenu(LOCALE_MOVIEBROWSER_INFO_HEAD, NEUTRINO_ICON_STREAMING);
serieMenu.addIntroItems(LOCALE_MOVIEBROWSER_SERIE_HEAD);
serieMenu.addItem( new CMenuForwarder(LOCALE_MOVIEBROWSER_SERIE_NAME, true, movie_info->serieName,&serieUserInput));
- serieMenu.addItem(GenericMenuSeparatorLine);
+ if (!m_vHandleSerienames.empty())
+ serieMenu.addItem(GenericMenuSeparatorLine);
for(unsigned int i=0; i < m_vHandleSerienames.size(); i++)
serieMenu.addItem( new CMenuSelector(m_vHandleSerienames[i]->serieName.c_str(), true, movie_info->serieName));
commit 09fe447728d819946215b26f3ce1a75a12b8de19
Author: [CST] Focus <foc...@gm...>
Date: Mon Apr 29 11:09:30 2013 +0200
settings: remove useDefaults(), init all variables to default values
Signed-off-by: GetAway <get...@t-...>
Signed-off-by: Thilo Graf <db...@no...>
diff --git a/tuxbox/neutrino/src/system/settings.cpp b/tuxbox/neutrino/src/system/settings.cpp
index 36f0352..70dfb99 100644
--- a/tuxbox/neutrino/src/system/settings.cpp
+++ b/tuxbox/neutrino/src/system/settings.cpp
@@ -36,7 +36,10 @@ CScanSettings::CScanSettings(void)
: configfile('\t')
{
delivery_system = DVB_S;
- satNameNoDiseqc[0] = 0;
+ bouquetMode = CZapitClient::BM_UPDATEBOUQUETS;
+ scanType = CZapitClient::ST_ALL;
+ strcpy(satNameNoDiseqc, "none");
+
for( int i = 0; i < MAX_SATELLITES; i++)
{
satName[i][0] = 0;
@@ -183,60 +186,31 @@ void CScanSettings::toMotorPosList(CZapitClient::ScanMotorPosList& motorPosList)
}
}
-void CScanSettings::useDefaults(const delivery_system_t _delivery_system)
+bool CScanSettings::loadSettings(const char * const fileName, const delivery_system_t dsys)
{
- delivery_system = _delivery_system;
- bouquetMode = CZapitClient::BM_UPDATEBOUQUETS;
- scanType = CZapitClient::ST_ALL;
- diseqcMode = NO_DISEQC;
- diseqcRepeat = 0;
- uni_qrg = 1210;
- uni_scr = 0;
-
- motorRotationSpeed = 8;
- useGotoXX = 0;
- gotoXXLatitude = 00.000000;
- gotoXXLongitude = 00.000000;
- gotoXXLaDirection = 1;
- gotoXXLoDirection = 1;
+ bool ret = configfile.loadConfig(fileName);
-#ifdef HAVE_TRIPLEDRAGON
- TP_mod = 0;
-#elif HAVE_DVB_API_VERSION >= 3
- TP_mod = QAM_AUTO;
-#else
- // i do not know how to do it correctly for old API -- seife
- TP_mod = QAM_256;
-#endif
- strcpy(satNameNoDiseqc, "none");
-}
-
-bool CScanSettings::loadSettings(const char * const fileName, const delivery_system_t _delivery_system)
-{
- useDefaults(_delivery_system);
-
- if(!configfile.loadConfig(fileName))
- return false;
-
- if (configfile.getInt32("delivery_system", -1) != delivery_system)
+ if (configfile.getInt32("delivery_system", -1) != dsys)
{
// configfile is not for this delivery system
configfile.clear();
- return false;
+ ret = false;
}
- diseqcMode = (diseqc_t) configfile.getInt32("diseqcMode" , diseqcMode);
- diseqcRepeat = configfile.getInt32("diseqcRepeat", diseqcRepeat);
- uni_qrg = configfile.getInt32("uni_qrg", uni_qrg);
- uni_scr = configfile.getInt32("uni_scr", uni_scr);
- bouquetMode = (CZapitClient::bouquetMode) configfile.getInt32("bouquetMode" , bouquetMode);
+ delivery_system = dsys;
+
+ diseqcMode = (diseqc_t) configfile.getInt32("diseqcMode", NO_DISEQC);
+ diseqcRepeat = configfile.getInt32("diseqcRepeat", 0);
+ uni_qrg = configfile.getInt32("uni_qrg", 1210);
+ uni_scr = configfile.getInt32("uni_scr", 0);
+ bouquetMode = (CZapitClient::bouquetMode) configfile.getInt32("bouquetMode", bouquetMode);
scanType=(CZapitClient::scanType) configfile.getInt32("scanType", scanType);
strcpy(satNameNoDiseqc, configfile.getString("satNameNoDiseqc", satNameNoDiseqc).c_str());
motorRotationSpeed = configfile.getInt32("motorRotationSpeed", 8);
useGotoXX = configfile.getInt32("useGotoXX", 0);
- gotoXXLatitude = strtod(configfile.getString("gotoXXLatitude", "00.000000").c_str(), NULL);
- gotoXXLongitude = strtod(configfile.getString("gotoXXLongitude", "00.000000").c_str(), NULL);
+ gotoXXLatitude = strtod(configfile.getString("gotoXXLatitude", "0.0").c_str(), NULL);
+ gotoXXLongitude = strtod(configfile.getString("gotoXXLongitude", "0.0").c_str(), NULL);
gotoXXLaDirection = configfile.getInt32("gotoXXLaDirection", 1);
gotoXXLoDirection = configfile.getInt32("gotoXXLoDirection", 1);
@@ -271,16 +245,22 @@ bool CScanSettings::loadSettings(const char * const fileName, const delivery_sys
// i do not know how to do it correctly for old API -- seife
TP_mod = configfile.getInt32("TP_mod", QAM_256); // default qam 256
#endif
- strcpy(TP_freq, configfile.getString("TP_freq", "10100000").c_str());
- strcpy(TP_rate, configfile.getString("TP_rate", "27500000").c_str());
- strncpy(TP_satname, configfile.getString("TP_satname", "Astra 19.2E").c_str(), 30);
+
+ if(delivery_system == DVB_S) {
+ strcpy(TP_freq, configfile.getString("TP_freq", "10100000").c_str());
+ strcpy(TP_rate, configfile.getString("TP_rate", "27500000").c_str());
+ } else {
+ strcpy(TP_freq, configfile.getString("TP_freq", "362000000").c_str());
+ strcpy(TP_rate, configfile.getString("TP_rate", "6875000").c_str());
+ }
+ strncpy(TP_satname, configfile.getString("TP_satname", "").c_str(), 30);
TP_diseqc = *diseqscOfSat(TP_satname);
#if HAVE_DVB_API_VERSION >= 3
if(TP_fec == 4) TP_fec = 5;
#endif
scanSectionsd = configfile.getInt32("scanSectionsd", 0);
- return true;
+ return ret;
}
bool CScanSettings::saveSettings(const char * const fileName)
diff --git a/tuxbox/neutrino/src/system/settings.h b/tuxbox/neutrino/src/system/settings.h
index b78ecac..1ec81e7 100644
--- a/tuxbox/neutrino/src/system/settings.h
+++ b/tuxbox/neutrino/src/system/settings.h
@@ -633,9 +633,7 @@ class CScanSettings
void toSatList( CZapitClient::ScanSatelliteList& ) const;
void toMotorPosList( CZapitClient::ScanMotorPosList& ) const;
- void useDefaults(const delivery_system_t _delivery_system);
-
- bool loadSettings(const char * const fileName, const delivery_system_t _delivery_system);
+ bool loadSettings(const char * const fileName, const delivery_system_t dsys);
bool saveSettings(const char * const fileName);
};
commit a8c58ff7f14ce3e28ae35090aa931f4bea75823f
Author: Christian Schuett <Gau...@ho...>
Date: Mon Apr 29 00:33:53 2013 +0200
Neutrino CMenuWidget: consider scrollbar width when calculating start pos
Signed-off-by: Christian Schuett <Gau...@ho...>
Signed-off-by: Thilo Graf <db...@no...>
diff --git a/tuxbox/neutrino/src/gui/widget/menue.cpp b/tuxbox/neutrino/src/gui/widget/menue.cpp
index e43d379..7c98c5c 100644
--- a/tuxbox/neutrino/src/gui/widget/menue.cpp
+++ b/tuxbox/neutrino/src/gui/widget/menue.cpp
@@ -669,15 +669,15 @@ void CMenuWidget::paint()
if(hheight+itemHeightTotal < height)
height=hheight+itemHeightTotal;
- x = getScreenStartX(width);
- y = getScreenStartY(height);
-
int sb_width;
if(total_pages > 1)
sb_width=15;
else
sb_width=0;
+ x = getScreenStartX(width + sb_width);
+ y = getScreenStartY(height);
+
int c_rad_mid = RADIUS_MID;
frameBuffer->paintBoxRel(x + SHADOW_OFFSET, y + SHADOW_OFFSET, width + sb_width, height + (c_rad_mid / 3 * 2), COL_MENUCONTENTDARK_PLUS_0, c_rad_mid);
commit 6854af4a1f6d7cd12f23ccd3f179fa36eb70276d
Author: Christian Schuett <Gau...@ho...>
Date: Sun Apr 28 22:49:11 2013 +0200
Neutrino: move redundant code from menu item classes into base class
ported from Neutrino-HD
Signed-off-by: Christian Schuett <Gau...@ho...>
Signed-off-by: Thilo Graf <db...@no...>
diff --git a/tuxbox/neutrino/src/gui/moviebrowser.cpp b/tuxbox/neutrino/src/gui/moviebrowser.cpp
index 2d6a71c..d218780 100644
--- a/tuxbox/neutrino/src/gui/moviebrowser.cpp
+++ b/tuxbox/neutrino/src/gui/moviebrowser.cpp
@@ -3677,7 +3677,6 @@ bool CBookItemMenuForwarderNotifier::changeNotify(const neutrino_locale_t, void*
CMenuSelector::CMenuSelector(const char * OptionName, const bool Active , char * OptionValue, int* ReturnInt ,int ReturnIntValue ) : CMenuItem()
{
- height = g_Font[SNeutrinoSettings::FONT_TYPE_MENU]->getHeight();
optionValueString = NULL;
optionName = OptionName;
optionValue = OptionValue;
@@ -3688,7 +3687,6 @@ CMenuSelector::CMenuSelector(const char * OptionName, const bool Active , char *
CMenuSelector::CMenuSelector(const char * OptionName, const bool Active , std::string& OptionValue, int* ReturnInt ,int ReturnIntValue ) : CMenuItem()
{
- height = g_Font[SNeutrinoSettings::FONT_TYPE_MENU]->getHeight();
optionValueString = &OptionValue;
optionName = OptionName;
strncpy(buffer,OptionValue.c_str(),BUFFER_MAX);
@@ -3699,6 +3697,11 @@ CMenuSelector::CMenuSelector(const char * OptionName, const bool Active , std::s
returnInt = ReturnInt;
};
+int CMenuSelector::getHeight(void) const
+{
+ return g_Font[SNeutrinoSettings::FONT_TYPE_MENU]->getHeight();
+}
+
int CMenuSelector::exec(CMenuTarget* /*parent*/)
{
if(returnInt != NULL)
@@ -3716,28 +3719,16 @@ int CMenuSelector::exec(CMenuTarget* /*parent*/)
int CMenuSelector::paint(bool selected)
{
- CFrameBuffer * frameBuffer = CFrameBuffer::getInstance();
-
- unsigned char color = COL_MENUCONTENT;
- fb_pixel_t bgcolor = COL_MENUCONTENT_PLUS_0;
- if (selected)
- {
- color = COL_MENUCONTENTSELECTED;
- bgcolor = COL_MENUCONTENTSELECTED_PLUS_0;
- }
- if (!active)
- {
- color = COL_MENUCONTENTINACTIVE;
- bgcolor = COL_MENUCONTENTINACTIVE_PLUS_0;
- }
+ int height = getHeight();
- frameBuffer->paintBoxRel(x, y, dx, height, bgcolor);
+ //paint item
+ prepareItem(selected, height);
- int stringstartposName = x + offx + 10;
- g_Font[SNeutrinoSettings::FONT_TYPE_MENU]->RenderString(stringstartposName, y+height,dx- (stringstartposName - x), optionName, color, 0, true); // UTF-8
+ //paint item icon
+ paintItemButton(selected, height, NEUTRINO_ICON_BUTTON_OKAY);
- if (selected)
- CLCD::getInstance()->showMenuText(0, optionName, -1, true); // UTF-8
+ //paint text
+ paintItemCaption(selected, height, optionName);
return y+height;
}
diff --git a/tuxbox/neutrino/src/gui/moviebrowser.h b/tuxbox/neutrino/src/gui/moviebrowser.h
index 03e096c..9065a47 100644
--- a/tuxbox/neutrino/src/gui/moviebrowser.h
+++ b/tuxbox/neutrino/src/gui/moviebrowser.h
@@ -427,14 +427,13 @@ class CMenuSelector : public CMenuItem
std::string* optionValueString;
int returnIntValue;
int* returnInt;
- int height;
char buffer[BUFFER_MAX];
public:
CMenuSelector(const char * OptionName, const bool Active = true, char * OptionValue = NULL, int* ReturnInt = NULL,int ReturnIntValue = 0);
CMenuSelector(const char * OptionName, const bool Active , std::string & OptionValue, int* ReturnInt = NULL,int ReturnIntValue = 0);
int exec(CMenuTarget* parent);
int paint(bool selected);
- int getHeight(void) const{return height;};
+ int getHeight(void) const;
bool isSelectable(void) const { return active;}
};
diff --git a/tuxbox/neutrino/src/gui/widget/menue.cpp b/tuxbox/neutrino/src/gui/widget/menue.cpp
index 441bb99..e43d379 100644
--- a/tuxbox/neutrino/src/gui/widget/menue.cpp
+++ b/tuxbox/neutrino/src/gui/widget/menue.cpp
@@ -92,11 +92,78 @@ void CMenuItem::setItemButton(const std::string& icon_Name, const bool is_select
iconName = icon_Name;
}
-void CMenuItem::paintItemButton(const int startX, const int frame_height, const bool select_mode, const std::string &icon_Name)
+void CMenuItem::initItemColors(const bool select_mode)
+{
+ if (select_mode)
+ {
+ item_color = COL_MENUCONTENTSELECTED;
+ item_bgcolor = COL_MENUCONTENTSELECTED_PLUS_0;
+ }
+ else if (!active)
+ {
+ item_color = COL_MENUCONTENTINACTIVE;
+ item_bgcolor = COL_MENUCONTENTINACTIVE_PLUS_0;
+ }
+ else
+ {
+ item_color = COL_MENUCONTENT;
+ item_bgcolor = COL_MENUCONTENT_PLUS_0;
+ }
+}
+
+void CMenuItem::paintItemBackground (const bool /*select_mode*/, const int &item_height)
+{
+ CFrameBuffer *frameBuffer = CFrameBuffer::getInstance();
+#if 0
+ //FIXME what select_mode change here ??
+ if (select_mode)
+ frameBuffer->paintBoxRel(x, y, dx, item_height, item_bgcolor, RADIUS_SMALL);
+ else
+#endif
+ frameBuffer->paintBoxRel(x, y, dx, item_height, item_bgcolor, RADIUS_SMALL);
+}
+
+void CMenuItem::paintItemCaption(const bool select_mode, const int &item_height, const char * left_text, const char * right_text)
+{
+ bool right_text_is_utf8 = (right_text != NULL) ? isUTF8(right_text, strlen(right_text)) : false;
+
+ if (select_mode)
+ {
+ CLCD::getInstance()->showMenuText(0, left_text, -1, true); // UTF-8
+ if (right_text != NULL)
+ CLCD::getInstance()->showMenuText(1, right_text, -1, right_text_is_utf8);
+ else
+ CLCD::getInstance()->showMenuText(1, "");
+ }
+
+ //left text
+ int stringstartposName = x + offx + 10;
+ g_Font[SNeutrinoSettings::FONT_TYPE_MENU]->RenderString(stringstartposName, y + item_height, dx - (stringstartposName - x), left_text, item_color, 0, true); // UTF-8
+
+ //right text
+ if (right_text != NULL)
+ {
+ int stringwidth = g_Font[SNeutrinoSettings::FONT_TYPE_MENU]->getRenderWidth(right_text, right_text_is_utf8);
+ int stringstartposOption = std::max(stringstartposName + g_Font[SNeutrinoSettings::FONT_TYPE_MENU]->getRenderWidth(left_text, true) + 10,
+ x + dx - stringwidth - 10); //+ offx
+ g_Font[SNeutrinoSettings::FONT_TYPE_MENU]->RenderString(stringstartposOption, y + item_height, dx - (stringstartposOption - x), right_text, item_color, 0, right_text_is_utf8);
+ }
+}
+
+void CMenuItem::prepareItem(const bool select_mode, const int &item_height)
+{
+ //set colors
+ initItemColors(select_mode);
+
+ //paint item background
+ paintItemBackground(select_mode, item_height);
+}
+
+void CMenuItem::paintItemButton(const bool select_mode, const int &item_height, const std::string &icon_Name)
{
CFrameBuffer *frameBuffer = CFrameBuffer::getInstance();
bool selected = select_mode;
- int height = frame_height;
+ int height = item_height;
bool icon_painted = false;
std::string icon_name = iconName;
@@ -128,7 +195,7 @@ void CMenuItem::paintItemButton(const int startX, const int frame_height, const
frameBuffer->getIconSize(NEUTRINO_ICON_RIGHT_MARKER, &m_icon_w, &m_icon_h);
int icon_x = 0;
- int icon_space = (x+(startX-x)/2);
+ int icon_space = x + (offx+10)/2;
if (!icon_name.empty())
{
@@ -744,27 +811,10 @@ int CMenuOptionNumberChooser::exec(CMenuTarget*)
int CMenuOptionNumberChooser::paint(bool selected)
{
- CFrameBuffer * frameBuffer = CFrameBuffer::getInstance();
int height = getHeight();
- unsigned char color = COL_MENUCONTENT;
- fb_pixel_t bgcolor = COL_MENUCONTENT_PLUS_0;
- if (selected)
- {
- color = COL_MENUCONTENTSELECTED;
- bgcolor = COL_MENUCONTENTSELECTED_PLUS_0;
- }
- if (!active)
- {
- color = COL_MENUCONTENTINACTIVE;
- bgcolor = COL_MENUCONTENTINACTIVE_PLUS_0;
- }
-
- frameBuffer->paintBoxRel(x, y, dx, height, bgcolor, RADIUS_SMALL);
-
const char * l_option;
char option_value[11];
-
if ((localized_value_name == NONEXISTANT_LOCALE) || ((*optionValue) != localized_value))
{
sprintf(option_value, "%d", ((*optionValue) + display_offset));
@@ -775,21 +825,14 @@ int CMenuOptionNumberChooser::paint(bool selected)
const char * l_optionName = (optionString != NULL) ? optionString : g_Locale->getText(optionName);
- int stringwidth = g_Font[SNeutrinoSettings::FONT_TYPE_MENU]->getRenderWidth(l_option, true); // UTF-8
- int stringstartposName = x + offx + 10;
- int stringstartposOption = std::max(stringstartposName + g_Font[SNeutrinoSettings::FONT_TYPE_MENU]->getRenderWidth(l_optionName, true) + 10,
- x + dx - stringwidth - 10); //+ offx
+ //paint item
+ prepareItem(selected, height);
- g_Font[SNeutrinoSettings::FONT_TYPE_MENU]->RenderString(stringstartposName, y+height,dx- (stringstartposName - x), l_optionName, color, 0, true); // UTF-8
- g_Font[SNeutrinoSettings::FONT_TYPE_MENU]->RenderString(stringstartposOption, y+height,dx- (stringstartposOption - x), l_option, color, 0, true); // UTF-8
-
- paintItemButton(stringstartposName, height, selected, NEUTRINO_ICON_BUTTON_OKAY);
+ //paint item icon
+ paintItemButton(selected, height, NEUTRINO_ICON_BUTTON_OKAY);
- if (selected)
- {
- CLCD::getInstance()->showMenuText(0, l_optionName, -1, true); // UTF-8
- CLCD::getInstance()->showMenuText(1, l_option, -1, true); // UTF-8
- }
+ //paint text
+ paintItemCaption(selected, height, l_optionName, l_option);
return y+height;
}
@@ -903,26 +946,9 @@ int CMenuOptionChooser::exec(CMenuTarget* parent)
int CMenuOptionChooser::paint( bool selected )
{
- CFrameBuffer * frameBuffer = CFrameBuffer::getInstance();
int height = getHeight();
- unsigned char color = COL_MENUCONTENT;
- fb_pixel_t bgcolor = COL_MENUCONTENT_PLUS_0;
- if (selected)
- {
- color = COL_MENUCONTENTSELECTED;
- bgcolor = COL_MENUCONTENTSELECTED_PLUS_0;
- }
- if (!active)
- {
- color = COL_MENUCONTENTINACTIVE;
- bgcolor = COL_MENUCONTENTINACTIVE_PLUS_0;
- }
-
- frameBuffer->paintBoxRel(x, y, dx, height, bgcolor, RADIUS_SMALL);
-
neutrino_locale_t option = NONEXISTANT_LOCALE;
-
for(unsigned int count = 0 ; count < number_of_options; count++)
{
if (options[count].key == *optionValue)
@@ -931,27 +957,16 @@ int CMenuOptionChooser::paint( bool selected )
break;
}
}
-
- if (optionName != NONEXISTANT_LOCALE)
- optionNameString = g_Locale->getText(optionName);
-
const char * l_option = g_Locale->getText(option);
- int stringwidth = g_Font[SNeutrinoSettings::FONT_TYPE_MENU]->getRenderWidth(l_option, true); // UTF-8
- int stringstartposName = x + offx + 10;
- int stringstartposOption = std::max(stringstartposName + g_Font[SNeutrinoSettings::FONT_TYPE_MENU]->getRenderWidth(optionNameString.c_str(), true) + 10,
- x + dx - stringwidth - 10); //+ offx
-
- g_Font[SNeutrinoSettings::FONT_TYPE_MENU]->RenderString(stringstartposName, y+height,dx- (stringstartposName - x), optionNameString.c_str(), color, 0, true); // UTF-8
- g_Font[SNeutrinoSettings::FONT_TYPE_MENU]->RenderString(stringstartposOption, y+height,dx- (stringstartposOption - x), l_option, color, 0, true); // UTF-8
+ //paint item
+ prepareItem(selected, height);
- paintItemButton(stringstartposName, height, selected, NEUTRINO_ICON_BUTTON_OKAY);
+ //paint item icon
+ paintItemButton(selected, height, NEUTRINO_ICON_BUTTON_OKAY);
- if (selected)
- {
- CLCD::getInstance()->showMenuText(0, optionNameString.c_str(), -1, true); // UTF-8
- CLCD::getInstance()->showMenuText(1, l_option, -1, true); // UTF-8
- }
+ //paint text
+ paintItemCaption(selected, height, optionNameString.c_str(), l_option);
return y+height;
}
@@ -1050,39 +1065,16 @@ int CMenuOptionStringChooser::exec(CMenuTarget* parent)
int CMenuOptionStringChooser::paint( bool selected )
{
int height = getHeight();
-
- unsigned char color = COL_MENUCONTENT;
- fb_pixel_t bgcolor = COL_MENUCONTENT_PLUS_0;
- if (selected)
- {
- color = COL_MENUCONTENTSELECTED;
- bgcolor = COL_MENUCONTENTSELECTED_PLUS_0;
- }
- if (!active)
- {
- color = COL_MENUCONTENTINACTIVE;
- bgcolor = COL_MENUCONTENTINACTIVE_PLUS_0;
- }
-
- CFrameBuffer::getInstance()->paintBoxRel(x, y, dx, height, bgcolor, RADIUS_SMALL);
-
const char * l_optionName = g_Locale->getText(optionName);
- int stringwidth = g_Font[SNeutrinoSettings::FONT_TYPE_MENU]->getRenderWidth(optionValue);
- int stringstartposName = x + offx + 10;
- int stringstartposOption = std::max(stringstartposName + g_Font[SNeutrinoSettings::FONT_TYPE_MENU]->getRenderWidth(l_optionName, true) + 10,
- x + dx - stringwidth - 10); //+ offx
+ //paint item
+ prepareItem(selected, height);
- g_Font[SNeutrinoSettings::FONT_TYPE_MENU]->RenderString(stringstartposName, y+height,dx- (stringstartposName - x), l_optionName, color, 0, true); // UTF-8
- g_Font[SNeutrinoSettings::FONT_TYPE_MENU]->RenderString(stringstartposOption, y+height,dx- (stringstartposOption - x), optionValue, color);
+ //paint item icon
+ paintItemButton(selected, height, NEUTRINO_ICON_BUTTON_OKAY);
- paintItemButton(stringstartposName, height, selected, NEUTRINO_ICON_BUTTON_OKAY);
-
- if (selected)
- {
- CLCD::getInstance()->showMenuText(0, l_optionName, -1, true); // UTF-8
- CLCD::getInstance()->showMenuText(1, optionValue);
- }
+ //paint text
+ paintItemCaption(selected, height, l_optionName, optionValue);
return y+height;
}
@@ -1168,52 +1160,18 @@ const char * CMenuForwarder::getName(void)
int CMenuForwarder::paint(bool selected)
{
- CFrameBuffer * frameBuffer = CFrameBuffer::getInstance();
int height = getHeight();
const char * l_text = getName();
-
- int stringstartposX = x + offx + 10;
-
const char * option_text = getOption();
- bool option_text_is_utf8 = (option_text != NULL) ? isUTF8(option_text, strlen(option_text)) : false;
-
- if (selected)
- {
- CLCD * lcd = CLCD::getInstance();
- lcd->showMenuText(0, l_text, -1, true); // UTF-8
-
- if (option_text != NULL)
- lcd->showMenuText(1, option_text, -1, option_text_is_utf8);
- else
- lcd->showMenuText(1, "", -1, true); // UTF-8
- }
-
- unsigned char color = COL_MENUCONTENT;
- fb_pixel_t bgcolor = COL_MENUCONTENT_PLUS_0;
- if (selected)
- {
- color = COL_MENUCONTENTSELECTED;
- bgcolor = COL_MENUCONTENTSELECTED_PLUS_0;
- }
- if (!active)
- {
- color = COL_MENUCONTENTINACTIVE;
- bgcolor = COL_MENUCONTENTINACTIVE_PLUS_0;
- }
-
- frameBuffer->paintBoxRel(x, y, dx, height, bgcolor, RADIUS_SMALL);
- g_Font[SNeutrinoSettings::FONT_TYPE_MENU]->RenderString(stringstartposX, y+ height, dx- (stringstartposX - x), l_text, color, 0, true); // UTF-8
- paintItemButton(stringstartposX, height, selected);
+ //paint item
+ prepareItem(selected, height);
- if (option_text != NULL)
- {
- int stringwidth = g_Font[SNeutrinoSettings::FONT_TYPE_MENU]->getRenderWidth(option_text, option_text_is_utf8);
- int stringstartposOption = std::max(stringstartposX + g_Font[SNeutrinoSettings::FONT_TYPE_MENU]->getRenderWidth(l_text, true) + 10,
- x + dx - stringwidth - 10); //+ offx
+ //paint item icon
+ paintItemButton(selected, height);
- g_Font[SNeutrinoSettings::FONT_TYPE_MENU]->RenderString(stringstartposOption, y + height, dx - (stringstartposOption - x), option_text, color, 0, option_text_is_utf8);
- }
+ //paint text
+ paintItemCaption(selected, height, l_text, option_text);
return y+ height;
}
@@ -1276,27 +1234,23 @@ void CMenuSeparator::setString(const std::string& s_text)
}
-int CMenuSeparator::paint(bool selected)
+int CMenuSeparator::paint(bool /*selected*/)
{
- int height;
+ int height = getHeight();
CFrameBuffer * frameBuffer = CFrameBuffer::getInstance();
- height = getHeight();
- uint8_t color;
- fb_pixel_t bgcolor0;
if ((type & SUB_HEAD))
{
- color = COL_MENUHEAD;
- bgcolor0 = COL_MENUHEAD_PLUS_0;
+ item_color = COL_MENUHEAD;
+ item_bgcolor = COL_MENUHEAD_PLUS_0;
}
else
{
- color = COL_MENUCONTENTINACTIVE;
- bgcolor0 = COL_MENUCONTENT_PLUS_0;
+ item_color = COL_MENUCONTENTINACTIVE;
+ item_bgcolor = COL_MENUCONTENT_PLUS_0;
}
-
- frameBuffer->paintBoxRel(x,y, dx, height, bgcolor0);
+ frameBuffer->paintBoxRel(x,y, dx, height, item_bgcolor);
if ((type & LINE))
{
frameBuffer->paintHLineRel(x+10,dx-20,y+(height>>1), COL_MENUCONTENT_PLUS_3);
@@ -1322,20 +1276,15 @@ int CMenuSeparator::paint(bool selected)
stringstartposX = x + (dx >> 1) - (stringwidth >> 1);
if (type & LINE)
- frameBuffer->paintBoxRel(stringstartposX-5, y, stringwidth+10, height, bgcolor0);
+ frameBuffer->paintBoxRel(stringstartposX - 5, y, stringwidth + 10, height, item_bgcolor);
- g_Font[SNeutrinoSettings::FONT_TYPE_MENU]->RenderString(stringstartposX, y+height,dx- (stringstartposX- x) , l_text, color, 0, true); // UTF-8
+ g_Font[SNeutrinoSettings::FONT_TYPE_MENU]->RenderString(stringstartposX, y + height, dx - (stringstartposX - x), l_text, item_color, 0, true); // UTF-8
if (type & SUB_HEAD)
CLCD::getInstance()->setMode(CLCD::MODE_MENU_UTF8, l_text);
-
- if (selected)
- {
- CLCD::getInstance()->showMenuText(0, l_text, -1, true); // UTF-8
- CLCD::getInstance()->showMenuText(1, "", -1, true); // UTF-8
- }
}
}
+
return y+ height;
}
diff --git a/tuxbox/neutrino/src/gui/widget/menue.h b/tuxbox/neutrino/src/gui/widget/menue.h
index 6929980..be6de3d 100644
--- a/tuxbox/neutrino/src/gui/widget/menue.h
+++ b/tuxbox/neutrino/src/gui/widget/menue.h
@@ -80,6 +80,11 @@ class CMenuItem
protected:
int x, y, dx, offx;
bool used;
+ unsigned char item_color;
+ fb_pixel_t item_bgcolor;
+
+ void initItemColors(const bool select_mode);
+
public:
bool active;
neutrino_msg_t directKey;
@@ -116,9 +121,15 @@ class CMenuItem
}
virtual void setActive(const bool Active);
- virtual void paintItemButton(const int startX, const int frame_height, const bool select_mode, const std::string& icon_Name = NEUTRINO_ICON_BUTTON_RIGHT);
+ virtual void paintItemButton(const bool select_mode, const int &item_height, const std::string& icon_Name = NEUTRINO_ICON_BUTTON_RIGHT);
+
+ virtual void paintItemBackground (const bool select_mode, const int &item_height);
+
+ virtual void prepareItem(const bool select_mode, const int &item_height);
virtual void setItemButton(const std::string& icon_Name, const bool is_select_button = false);
+
+ virtual void paintItemCaption(const bool select_mode, const int &item_height, const char * left_text = NULL, const char * right_text = NULL);
};
class CMenuSeparator : public CMenuItem
commit 72e67085ff69553395eb5d23c24896c156b8248c
Author: Christian Schuett <Gau...@ho...>
Date: Sun Apr 28 22:46:19 2013 +0200
Neutrino CMenuOption*Chooser: remove icon from pulldown list ...
... and use width of corresponding menu option chooser
Signed-off-by: Christian Schuett <Gau...@ho...>
Signed-off-by: Thilo Graf <db...@no...>
diff --git a/tuxbox/neutrino/src/gui/widget/menue.cpp b/tuxbox/neutrino/src/gui/widget/menue.cpp
index bb3bc99..441bb99 100644
--- a/tuxbox/neutrino/src/gui/widget/menue.cpp
+++ b/tuxbox/neutrino/src/gui/widget/menue.cpp
@@ -848,13 +848,14 @@ int CMenuOptionChooser::exec(CMenuTarget* parent)
if (pulldown)
{
+ int menu_width = dx;
int select = -1;
char cnt[5];
if (parent)
parent->hide();
- CMenuWidget* menu = new CMenuWidget(optionNameString.c_str(), NEUTRINO_ICON_SETTINGS);
+ CMenuWidget* menu = new CMenuWidget(optionNameString.c_str(), "", menu_width);
menu->addIntroItems(NONEXISTANT_LOCALE, NONEXISTANT_LOCALE, CMenuWidget::BTN_TYPE_CANCEL);
CMenuSelectorTarget * selector = new CMenuSelectorTarget(&select);
for(unsigned int count = 0; count < number_of_options; count++)
@@ -996,13 +997,14 @@ int CMenuOptionStringChooser::exec(CMenuTarget* parent)
if (pulldown)
{
+ int menu_width = dx;
int select = -1;
char cnt[5];
if (parent)
parent->hide();
- CMenuWidget* menu = new CMenuWidget(optionName, NEUTRINO_ICON_SETTINGS);
+ CMenuWidget* menu = new CMenuWidget(optionName, "", menu_width);
menu->addIntroItems(NONEXISTANT_LOCALE, NONEXISTANT_LOCALE, CMenuWidget::BTN_TYPE_CANCEL);
CMenuSelectorTarget * selector = new CMenuSelectorTarget(&select);
for (unsigned int count = 0; count < options.size(); count++)
commit 8c56d34e5591a42768b96ddd3305c755441ba8d4
Author: Christian Schuett <Gau...@ho...>
Date: Sun Apr 28 21:21:46 2013 +0200
Neutrino CMenuWidget: fix segfault if head iconname is empty
Signed-off-by: Christian Schuett <Gau...@ho...>
Signed-off-by: Thilo Graf <db...@no...>
diff --git a/tuxbox/neutrino/src/gui/widget/menue.cpp b/tuxbox/neutrino/src/gui/widget/menue.cpp
index e47e89c..bb3bc99 100644
--- a/tuxbox/neutrino/src/gui/widget/menue.cpp
+++ b/tuxbox/neutrino/src/gui/widget/menue.cpp
@@ -617,10 +617,15 @@ void CMenuWidget::paint()
frameBuffer->paintBoxRel(x, y + height - ((c_rad_mid * 2) + 1) + (c_rad_mid / 3 * 2), width + sb_width, ((c_rad_mid * 2) + 1), COL_MENUCONTENT_PLUS_0, c_rad_mid, CORNER_BOTTOM);
frameBuffer->paintBoxRel(x, y, width + sb_width, hheight, COL_MENUHEAD_PLUS_0, c_rad_mid, CORNER_TOP);
- int iconw, iconh;
- frameBuffer->getIconSize(iconfile.c_str(), &iconw, &iconh);
- g_Font[SNeutrinoSettings::FONT_TYPE_MENU_TITLE]->RenderString(x + 8 + iconw + 10, y + hheight + 2, width - 8 - iconw - 10, nameString.c_str(), COL_MENUHEAD, 0, true); // UTF-8
- frameBuffer->paintIcon(iconfile, x + 8, y + hheight / 2 - iconh / 2);
+ int head_iconoffset = 0;
+ if (!iconfile.empty())
+ {
+ int iconw, iconh;
+ frameBuffer->getIconSize(iconfile.c_str(), &iconw, &iconh);
+ frameBuffer->paintIcon(iconfile, x + 8, y + hheight / 2 - iconh / 2);
+ head_iconoffset = 8 + iconw;
+ }
+ g_Font[SNeutrinoSettings::FONT_TYPE_MENU_TITLE]->RenderString(x + head_iconoffset + 10, y + hheight + 2, width - head_iconoffset - 10, nameString.c_str(), COL_MENUHEAD, 0, true); // UTF-8
item_start_y = y+hheight;
paintItems();
commit a967ebae0744fe64f265c98d1fed0c1a6a162fb5
Author: Christian Schuett <Gau...@ho...>
Date: Sun Apr 28 20:59:34 2013 +0200
Neutrino moviebrowser: reduce console spam
Signed-off-by: Christian Schuett <Gau...@ho...>
Signed-off-by: Thilo Graf <db...@no...>
diff --git a/tuxbox/neutrino/src/gui/moviebrowser.cpp b/tuxbox/neutrino/src/gui/moviebrowser.cpp
index c67a6af..2d6a71c 100644
--- a/tuxbox/neutrino/src/gui/moviebrowser.cpp
+++ b/tuxbox/neutrino/src/gui/moviebrowser.cpp
@@ -2888,7 +2888,7 @@ void CMovieBrowser::loadMovies(bool doRefresh)
{
time_t time_start = time(NULL);
clock_t clock_start = clock()/10000; // CLOCKS_PER_SECOND
- clock_t clock_prev = clock_start;
+ //clock_t clock_prev = clock_start;
clock_t clock_act = clock_start;
TRACE("[mb] loadMovies: \n");
@@ -2896,15 +2896,15 @@ void CMovieBrowser::loadMovies(bool doRefresh)
CHintBox loadBox(LOCALE_MOVIEBROWSER_HEAD,g_Locale->getText(LOCALE_MOVIEBROWSER_SCAN_FOR_MOVIES));
loadBox.paint();
- clock_act = clock()/10000;TRACE("[mb] *1: time %9ld clock %6ld dclock %6ld*\n",(long)time(NULL),clock_act,clock_act - clock_prev);clock_prev = clock_act;
+ //clock_act = clock()/10000;TRACE("[mb] *1: time %9ld clock %6ld dclock %6ld*\n",(long)time(NULL),clock_act,clock_act - clock_prev);clock_prev = clock_act;
loadAllTsFileNamesFromStorage(); // P1
- clock_act = clock()/10000;TRACE("[mb] *2: time %9ld clock %6ld dclock %6ld*\n",(long)time(NULL),clock_act,clock_act - clock_prev);clock_prev = clock_act;
+ //clock_act = clock()/10000;TRACE("[mb] *2: time %9ld clock %6ld dclock %6ld*\n",(long)time(NULL),clock_act,clock_act - clock_prev);clock_prev = clock_act;
loadAllMovieInfo(); // P1
- clock_act = clock()/10000;TRACE("[mb] *3: time %9ld clock %6ld dclock %6ld*\n",(long)time(NULL),clock_act,clock_act - clock_prev);clock_prev = clock_act;
+ //clock_act = clock()/10000;TRACE("[mb] *3: time %9ld clock %6ld dclock %6ld*\n",(long)time(NULL),clock_act,clock_act - clock_prev);clock_prev = clock_act;
m_file_info_stale = false;
m_seriename_stale = true; // we reloded the movie info, so make sure the other list are updated later on as well
updateSerienames();
- clock_act = clock()/10000;TRACE("[mb] *4: time %9ld clock %6ld dclock %6ld*\n",(long)time(NULL),clock_act,clock_act - clock_prev);clock_prev = clock_act;
+ //clock_act = clock()/10000;TRACE("[mb] *4: time %9ld clock %6ld dclock %6ld*\n",(long)time(NULL),clock_act,clock_act - clock_prev);clock_prev = clock_act;
if(m_settings.serie_auto_create == 1)
{
autoFindSerie();
@@ -2914,16 +2914,17 @@ void CMovieBrowser::loadMovies(bool doRefresh)
if (doRefresh)
{
- clock_act = clock()/10000;TRACE("[mb] *5: time %9ld clock %6ld dclock %6ld*\n",(long)time(NULL),clock_act,clock_act - clock_prev);clock_prev = clock_act;
+ //clock_act = clock()/10000;TRACE("[mb] *5: time %9ld clock %6ld dclock %6ld*\n",(long)time(NULL),clock_act,clock_act - clock_prev);clock_prev = clock_act;
refreshBrowserList();
- clock_act = clock()/10000;TRACE("[mb] *6: time %9ld clock %6ld dclock %6ld*\n",(long)time(NULL),clock_act,clock_act - clock_prev);clock_prev = clock_act;
+ //clock_act = clock()/10000;TRACE("[mb] *6: time %9ld clock %6ld dclock %6ld*\n",(long)time(NULL),clock_act,clock_act - clock_prev);clock_prev = clock_act;
refreshLastPlayList();
refreshLastRecordList();
refreshFilterList();
refreshMovieInfo(); // is done by refreshBrowserList if needed
- clock_act = clock()/10000;TRACE("[mb] *7: time %9ld clock %6ld dclock %6ld*\n",(long)time(NULL),clock_act,clock_act - clock_prev);clock_prev = clock_act;
+ //clock_act = clock()/10000;TRACE("[mb] *7: time %9ld clock %6ld dclock %6ld*\n",(long)time(NULL),clock_act,clock_act - clock_prev);clock_prev = clock_act;
}
+ clock_act = clock()/10000;
TRACE("[mb] ***Total:time %ld clock %ld***\n",(time(NULL)-time_start), clock_act-clock_start);
}
/************************************************************************
commit d7b95b5a94e6f0c44a410bde47ad6a3c7c556e1c
Author: Christian Schuett <Gau...@ho...>
Date: Sat Apr 27 22:34:14 2013 +0200
Neutrino moviebrowser: use pulldown list to change genre
Signed-off-by: Christian Schuett <Gau...@ho...>
Signed-off-by: Thilo Graf <db...@no...>
diff --git a/tuxbox/neutrino/src/gui/moviebrowser.cpp b/tuxbox/neutrino/src/gui/moviebrowser.cpp
index 93b6bba..c67a6af 100644
--- a/tuxbox/neutrino/src/gui/moviebrowser.cpp
+++ b/tuxbox/neutrino/src/gui/moviebrowser.cpp
@@ -3063,7 +3063,7 @@ int CMovieBrowser::showMovieInfoMenu(MI_MOVIE_INFO* movie_info)
movieInfoMenu.addItem( new CMenuForwarder(LOCALE_MOVIEBROWSER_INFO_TITLE, true, movie_info->epgTitle, &titelUserInput,NULL, CRCInput::RC_1, NEUTRINO_ICON_BUTTON_1));
movieInfoMenu.addItem( new CMenuForwarder(LOCALE_MOVIEBROWSER_INFO_SERIE, true, movie_info->serieName, &serieMenu,NULL, CRCInput::RC_2, NEUTRINO_ICON_BUTTON_2));
movieInfoMenu.addItem( new CMenuForwarder(LOCALE_MOVIEBROWSER_INFO_INFO1, true, movie_info->epgInfo1, &epgUserInput,NULL, CRCInput::RC_3, NEUTRINO_ICON_BUTTON_3));
- movieInfoMenu.addItem( new CMenuOptionChooser(LOCALE_MOVIEBROWSER_INFO_GENRE_MAJOR, &movie_info->genreMajor, GENRE_ALL, GENRE_ALL_COUNT, true,NULL, CRCInput::RC_4, NEUTRINO_ICON_BUTTON_4));
+ movieInfoMenu.addItem( new CMenuOptionChooser(LOCALE_MOVIEBROWSER_INFO_GENRE_MAJOR, &movie_info->genreMajor, GENRE_ALL, GENRE_ALL_COUNT, true, NULL, CRCInput::RC_4, NEUTRINO_ICON_BUTTON_4, true));
movieInfoMenu.addItem(GenericMenuSeparatorLine);
movieInfoMenu.addItem( new CMenuOptionNumberChooser(LOCALE_MOVIEBROWSER_INFO_QUALITY, &movie_info->quality, true, 0, 3, 0, 0, NONEXISTANT_LOCALE, NULL, CRCInput::RC_5, NEUTRINO_ICON_BUTTON_5));
movieInfoMenu.addItem( new CMenuOptionChooser(LOCALE_MOVIEBROWSER_INFO_PARENTAL_LOCKAGE, &movie_info->parentalLockAge, MESSAGEBOX_PARENTAL_LOCKAGE_OPTIONS, MESSAGEBOX_PARENTAL_LOCKAGE_OPTION_COUNT, true,NULL, CRCInput::RC_6, NEUTRINO_ICON_BUTTON_6 ));
commit 275bf133983690f10d36cc141bef989889575e89
Author: GetAway <get...@t-...>
Date: Fri Apr 26 16:57:55 2013 +0200
settings.cpp: hardcoded sat/provider not longer needed
Signed-off-by: Thilo Graf <db...@no...>
diff --git a/tuxbox/neutrino/src/system/settings.cpp b/tuxbox/neutrino/src/system/settings.cpp
index 3bca8c6..36f0352 100644
--- a/tuxbox/neutrino/src/system/settings.cpp
+++ b/tuxbox/neutrino/src/system/settings.cpp
@@ -208,19 +208,7 @@ void CScanSettings::useDefaults(const delivery_system_t _delivery_system)
// i do not know how to do it correctly for old API -- seife
TP_mod = QAM_256;
#endif
-
- switch (delivery_system)
- {
- case DVB_C:
- strcpy(satNameNoDiseqc, "Kabel Deutschland");
- break;
- case DVB_S:
- strcpy(satNameNoDiseqc, "Astra 19.2E");
- break;
- case DVB_T:
- strcpy(satNameNoDiseqc, "");
- break;
- }
+ strcpy(satNameNoDiseqc, "none");
}
bool CScanSettings::loadSettings(const char * const fileName, const delivery_system_t _delivery_system)
commit 524fe056252cd77792885c9bb081e1f80cff52b1
Author: GetAway <get...@t-...>
Date: Fri Apr 26 10:22:37 2013 +0200
scan-setup: use pulldown list to select providers/sats
Signed-off-by: Thilo Graf <db...@no...>
diff --git a/tuxbox/neutrino/src/gui/scan_setup.cpp b/tuxbox/neutrino/src/gui/scan_setup.cpp
index 2b573f1..ca73633 100644
--- a/tuxbox/neutrino/src/gui/scan_setup.cpp
+++ b/tuxbox/neutrino/src/gui/scan_setup.cpp
@@ -247,15 +247,25 @@ int CScanSetup::showScanService()
//sat-lnb-settings
if(g_info.delivery_system == DVB_S)
{
+ satList.clear();
g_Zapit->getScanSatelliteList(satList);
//prepare diseqc
- CMenuOptionStringChooser* ojSat = new CMenuOptionStringChooser(LOCALE_SATSETUP_SATELLITE, scanSettings.satNameNoDiseqc, ((scanSettings.diseqcMode == DISEQC_1_2) || (scanSettings.diseqcMode == NO_DISEQC)|| scanSettings.diseqcMode == DISEQC_UNICABLE));
+ CMenuOptionStringChooser* ojSat = new CMenuOptionStringChooser(LOCALE_SATSETUP_SATELLITE, (char*)&scanSettings.satNameNoDiseqc, ((scanSettings.diseqcMode == DISEQC_1_2) || (scanSettings.diseqcMode == NO_DISEQC)|| scanSettings.diseqcMode == DISEQC_UNICABLE), NULL, CRCInput::RC_nokey, "", true);
- for (uint i=0; i < sat_list_size; i++)
- {
- ojSat->addOption(satList[i].satName);
- dprintf(DEBUG_DEBUG, "got scanprovider (sat): %s\n", satList[i].satName );
+ bool sfound = false;
+ for (CZapitClient::SatelliteList::iterator it = satList.begin(); it != satList.end(); ++it) {
+
+ ojSat->addOption(it->satName);
+
+ if (!sfound && strcmp(scanSettings.satNameNoDiseqc, it->satName) == 0)
+ sfound = true;
+ dprintf(DEBUG_DEBUG, "got scanprovider (sat): %s\n", it->satName);
+ }
+
+ if (!sfound && !satList.empty()) {
+ CZapitClient::SatelliteList::iterator it = satList.begin();
+ snprintf(scanSettings.satNameNoDiseqc, sizeof(scanSettings.satNameNoDiseqc), "%s", it->satName);
}
//prepare diseqc repeats
@@ -354,14 +364,23 @@ int CScanSetup::showScanService()
CZapitClient::SatelliteList providerList;
g_Zapit->getScanSatelliteList(providerList);
-
- //prepare/show providers
- CMenuOptionStringChooser* oj = new CMenuOptionStringChooser(LOCALE_CABLESETUP_PROVIDER, (char*)&scanSettings.satNameNoDiseqc, true);
- for( uint i=0; i< provider_list_size; i++)
- {
- oj->addOption(providerList[i].satName);
- dprintf(DEBUG_DEBUG, "got scanprovider (cable): %s\n", providerList[i].satName );
+ // sat/provider selector
+ CMenuOptionStringChooser * ojProv = new CMenuOptionStringChooser(LOCALE_CABLESETUP_PROVIDER, (char*)&scanSettings.satNameNoDiseqc, true, NULL, CRCInput::RC_nokey, "", true);
+
+ bool sfound = false;
+ for (CZapitClient::SatelliteList::iterator it = providerList.begin(); it != providerList.end(); ++it) {
+
+ ojProv->addOption(it->satName);
+
+ if (!sfound && strcmp(scanSettings.satNameNoDiseqc, it->satName) == 0)
+ sfound = true;
+ dprintf(DEBUG_DEBUG, "got scanprovider (cable): %s\n", it->satName);
+ }
+
+ if (!sfound && !providerList.empty()) {
+ CZapitClient::SatelliteList::iterator it = providerList.begin();
+ snprintf(scanSettings.satNameNoDiseqc, sizeof(scanSettings.satNameNoDiseqc), "%s", it->satName);
}
//show general entries
@@ -369,7 +388,7 @@ int CScanSetup::showScanService()
scansetup->addItem( ojBouquets );
//show cable provider
- scansetup->addItem( oj);
+ scansetup->addItem( ojProv );
}
//prepare scan mode (fast->on/off)
@@ -522,7 +541,7 @@ void CScanSetup::initScanSettings()
scanSettings.satMotorPos[i] = satList[i].motorPosition;
strcpy(scanSettings.satName[i], satList[i].satName);
//scanSettings.satDiseqc[i] = satList[i].satDiseqc;
- if (satList[i].satPosition == currentSatellitePosition)
+ if (satList[i].satPosition == currentSatellitePosition) // make that sense?
strcpy(scanSettings.satNameNoDiseqc, satList[i].satName);
}
for (uint i = satList.size(); i < MAX_SATELLITES; i++)
@@ -540,7 +559,7 @@ void CScanSetup::initScanSettings()
CZapitClient::SatelliteList providerList;
g_Zapit->getScanSatelliteList(providerList);
- printf("[scan-setup] received %d providers\n", providerList.size());
+ printf("[scan-setup] received %d cable provider(s)\n", providerList.size());
provider_list_size = providerList.size();
}
commit df0adb40aef302167639dd79b141e550a9350a34
Author: GetAway <get...@t-...>
Date: Fri Apr 26 10:18:47 2013 +0200
Neutrino: add pulldown list functionality to CMenuOption*Chooser
ported from Neutrino-HD
Signed-off-by: Christian Schuett <Gau...@ho...>
Signed-off-by: Thilo Graf <db...@no...>
diff --git a/tuxbox/neutrino/src/gui/widget/menue.cpp b/tuxbox/neutrino/src/gui/widget/menue.cpp
index 1860107..e47e89c 100644
--- a/tuxbox/neutrino/src/gui/widget/menue.cpp
+++ b/tuxbox/neutrino/src/gui/widget/menue.cpp
@@ -792,7 +792,7 @@ int CMenuOptionNumberChooser::paint(bool selected)
-CMenuOptionChooser::CMenuOptionChooser(const neutrino_locale_t OptionName, int * const OptionValue, const struct keyval * const Options, const unsigned Number_Of_Options, const bool Active, CChangeObserver * const Observ, const neutrino_msg_t DirectKey, const std::string & IconName)
+CMenuOptionChooser::CMenuOptionChooser(const neutrino_locale_t OptionName, int * const OptionValue, const struct keyval * const Options, const unsigned Number_Of_Options, const bool Active, CChangeObserver * const Observ, const neutrino_msg_t DirectKey, const std::string & IconName, bool Pulldown)
{
optionNameString = g_Locale->getText(OptionName);
optionName = OptionName;
@@ -803,9 +803,10 @@ CMenuOptionChooser::CMenuOptionChooser(const neutrino_locale_t OptionName, int *
observ = Observ;
directKey = DirectKey;
iconName = IconName;
+ pulldown = Pulldown;
}
-CMenuOptionChooser::CMenuOptionChooser(const char* OptionName, int * const OptionValue, const struct keyval * const Options, const unsigned Number_Of_Options, const bool Active, CChangeObserver * const Observ, const neutrino_msg_t DirectKey, const std::string & IconName)
+CMenuOptionChooser::CMenuOptionChooser(const char* OptionName, int * const OptionValue, const struct keyval * const Options, const unsigned Number_Of_Options, const bool Active, CChangeObserver * const Observ, const neutrino_msg_t DirectKey, const std::string & IconName, bool Pulldown)
{
optionNameString = OptionName;
optionName = NONEXISTANT_LOCALE;
@@ -816,6 +817,7 @@ CMenuOptionChooser::CMenuOptionChooser(const char* OptionName, int * const Optio
observ = Observ;
directKey = DirectKey;
iconName = IconName;
+ pulldown = Pulldown;
}
int CMenuOptionChooser::getHeight(void) const
@@ -834,33 +836,63 @@ int CMenuOptionChooser::getOptionValue(void) const
}
-int CMenuOptionChooser::exec(CMenuTarget*)
+int CMenuOptionChooser::exec(CMenuTarget* parent)
{
bool wantsRepaint = false;
- unsigned int count;
+ int ret = menu_return::RETURN_NONE;
- for(count = 0; count < number_of_options; count++)
+ if (pulldown)
{
- if (options[count].key == (*optionValue))
+ int select = -1;
+ char cnt[5];
+
+ if (parent)
+ parent->hide();
+
+ CMenuWidget* menu = new CMenuWidget(optionNameString.c_str(), NEUTRINO_ICON_SETTINGS);
+ menu->addIntroItems(NONEXISTANT_LOCALE, NONEXISTANT_LOCALE, CMenuWidget::BTN_TYPE_CANCEL);
+ CMenuSelectorTarget * selector = new CMenuSelectorTarget(&select);
+ for(unsigned int count = 0; count < number_of_options; count++)
{
- *optionValue = options[(count+1) % number_of_options].key;
- break;
+ bool selected = false;
+ if (options[count].key == (*optionValue))
+ selected = true;
+ sprintf(cnt, "%d", count);
+ CMenuForwarder *mn_option = new CMenuForwarder(options[count].value, true, NULL, selector, cnt);
+ mn_option->setItemButton(NEUTRINO_ICON_BUTTON_OKAY, true /*for selected item*/);
+ menu->addItem(mn_option, selected);
}
+ menu->exec(NULL, "");
+ ret = menu_return::RETURN_REPAINT;
+ if (select >= 0)
+ *optionValue = options[select].key;
+ delete menu;
+ delete selector;
}
- // if options are removed optionValue may not exist anymore -> use 1st available option
- if ((count == number_of_options) && number_of_options) {
- *optionValue = options[0].key;
+ else
+ {
+ unsigned int count;
+ for(count = 0; count < number_of_options; count++)
+ {
+ if (options[count].key == (*optionValue))
+ {
+ *optionValue = options[(count+1) % number_of_options].key;
+ break;
+ }
+ }
+ // if options are removed optionValue may not exist anymore -> use 1st available option
+ if ((count == number_of_options) && number_of_options)
+ *optionValue = options[0].key;
+ paint(true);
}
- paint(true);
- if(observ)
- {
+ if (observ)
wantsRepaint = observ->changeNotify(optionName, optionValue);
- }
- if ( wantsRepaint )
- return menu_return::RETURN_REPAINT;
- else
- return menu_return::RETURN_NONE;
+
+ if (wantsRepaint)
+ ret = menu_return::RETURN_REPAINT;
+
+ return ret;
}
int CMenuOptionChooser::paint( bool selected )
@@ -921,15 +953,15 @@ int CMenuOptionChooser::paint( bool selected )
//-------------------------------------------------------------------------------------------------------------------------------
-CMenuOptionStringChooser::CMenuOptionStringChooser(const neutrino_locale_t OptionName, char* OptionValue, bool Active, CChangeObserver* Observ)
+CMenuOptionStringChooser::CMenuOptionStringChooser(const neutrino_locale_t OptionName, char* OptionValue, bool Active, CChangeObserver* Observ, const neutrino_msg_t DirectKey, const std::string & IconName, bool Pulldown)
{
optionName = OptionName;
active = Active;
optionValue = OptionValue;
observ = Observ;
-
- directKey = CRCInput::RC_nokey;
- iconName = "";
+ directKey = DirectKey;
+ iconName = IconName;
+ pulldown = Pulldown;
}
int CMenuOptionStringChooser::getHeight(void) const
@@ -952,28 +984,60 @@ void CMenuOptionStringChooser::addOption(const char * const value)
options.push_back(std::string(value));
}
-int CMenuOptionStringChooser::exec(CMenuTarget*)
+int CMenuOptionStringChooser::exec(CMenuTarget* parent)
{
bool wantsRepaint = false;
- //select next value
- for(unsigned int count = 0; count < options.size(); count++)
+ int ret = menu_return::RETURN_NONE;
+
+ if (pulldown)
{
- if ((strcmp(options[count].c_str(), optionValue) == 0) || (optionValue[0] == '\0'))
+ int select = -1;
+ char cnt[5];
+
+ if (parent)
+ parent->hide();
+
+ CMenuWidget* menu = new CMenuWidget(optionName, NEUTRINO_ICON_SETTINGS);
+ menu->addIntroItems(NONEXISTANT_LOCALE, NONEXISTANT_LOCALE, CMenuWidget::BTN_TYPE_CANCEL);
+ CMenuSelectorTarget * selector = new CMenuSelectorTarget(&select);
+ for (unsigned int count = 0; count < options.size(); count++)
{
- strcpy(optionValue, options[(count + 1) % options.size()].c_str());
- break;
+ bool selected = false;
+ if (strcmp(options[count].c_str(), optionValue) == 0)
+ selected = true;
+ sprintf(cnt, "%d", count);
+ CMenuForwarderNonLocalized *mn_option = new CMenuForwarderNonLocalized(options[count].c_str(), true, NULL, selector, cnt);
+ mn_option->setItemButton(NEUTRINO_ICON_BUTTON_OKAY, true /*for selected item*/);
+ menu->addItem(mn_option, selected);
}
+ menu->exec(NULL, "");
+ ret = menu_return::RETURN_REPAINT;
+ if (select >= 0)
+ strcpy(optionValue, options[select].c_str());
+ delete menu;
+ delete selector;
}
-
- paint(true);
- if(observ)
+ else
{
- wantsRepaint = observ->changeNotify(optionName, optionValue);
+ //select next value
+ for(unsigned int count = 0; count < options.size(); count++)
+ {
+ if ((strcmp(options[count].c_str(), optionValue) == 0) || (optionValue[0] == '\0'))
+ {
+ strcpy(optionValue, options[(count + 1) % options.size()].c_str());
+ break;
+ }
+ }
+ paint(true);
}
- if ( wantsRepaint )
- return menu_return::RETURN_REPAINT;
- else
- return menu_return::RETURN_NONE;
+
+ if (observ)
+ wantsRepaint = observ->changeNotify(optionName, optionValue);
+
+ if (wantsRepaint)
+ ret = menu_return::RETURN_REPAINT;
+
+ return ret;
}
int CMenuOptionStringChooser::paint( bool selected )
diff --git a/tuxbox/neutrino/src/gui/widget/menue.h b/tuxbox/neutrino/src/gui/widget/menue.h
index 6856a33..6929980 100644
--- a/tuxbox/neutrino/src/gui/widget/menue.h
+++ b/tuxbox/neutrino/src/gui/widget/menue.h
@@ -245,10 +245,11 @@ class CMenuOptionChooser : public CAbstractMenuOptionChooser
unsigned number_of_options;
CChangeObserver * observ;
std::string optionNameString;
+ bool pulldown;
public:
- CMenuOptionChooser(const neutrino_locale_t OptionName, int * const OptionValue, const struct keyval * const Options, const unsigned Number_Of_Options, const bool Active = false, CChangeObserver * const Observ = NULL, const neutrino_msg_t DirectKey = CRCInput::RC_nokey, const std::string & IconName= ""); // UTF-8
- CMenuOptionChooser(const char* OptionName, int * const OptionValue, const struct keyval * const Options, const unsigned Number_Of_Options, const bool Active = false, CChangeObserver * const Observ = NULL, const neutrino_msg_t DirectKey = CRCInput::RC_nokey, const std::string & IconName= ""); // UTF-8
+ CMenuOptionChooser(const neutrino_locale_t OptionName, int * const OptionValue, const struct keyval * const Options, const unsigned Number_Of_Options, const bool Active = false, CChangeObserver * const Observ = NULL, const neutrino_msg_t DirectKey = CRCInput::RC_nokey, const std::string & IconName= "", bool Pulldown = false);
+ CMenuOptionChooser(const char* OptionName, int * const OptionValue, const struct keyval * const Options, const unsigned Number_Of_Options, const bool Active = false, CChangeObserver * const Observ = NULL, const neutrino_msg_t DirectKey = CRCInput::RC_nokey, const std::string & IconName= "", bool Pulldown = false);
void setOptionValue(const int newvalue);
int getOptionValue(void) const;
@@ -266,9 +267,10 @@ class CMenuOptionStringChooser : public CMenuItem
char * optionValue;
std::vector<std::string> options;
CChangeObserver * observ;
+ bool pulldown;
public:
- CMenuOptionStringChooser(const neutrino_locale_t OptionName, char* OptionValue, bool Active = false, CChangeObserver* Observ = NULL);
+ CMenuOptionStringChooser(const neutrino_locale_t OptionName, char* OptionValue, bool Active = false, CChangeObserver* Observ = NULL, const neutrino_msg_t DirectKey = CRCInput::RC_nokey, const std::string & IconName= "", bool Pulldown = false);
~CMenuOptionStringChooser();
void addOption(const char * value);
commit 8d58661d3e921afc184233a5896ec1f3eaab1e19
Author: Christian Schuett <Gau...@ho...>
Date: Thu Apr 25 21:53:53 2013 +0200
Neutrino infoviewer: remove offset for green button
offset for green button is not needed anymore because of shorter
locales for red button
Signed-off-by: Christian Schuett <Gau...@ho...>
Signed-off-by: Thilo Graf <db...@no...>
diff --git a/tuxbox/neutrino/src/gui/infoviewer.cpp b/tuxbox/neutrino/src/gui/infoviewer.cpp
index f76a6fb..4f36b70 100644
--- a/tuxbox/neutrino/src/gui/infoviewer.cpp
+++ b/tuxbox/neutrino/src/gui/infoviewer.cpp
@@ -1029,7 +1029,6 @@ void CInfoViewer::showButton(const int button, const bool calledFromMPlayer, con
int bx = BoxStartX + (ChanWidth / 3);
int by = BoxEndY + (InfoHeightY_Info >> 3) + ((g_settings.infobar_sat_display && !calledFromMPlayer) ? 25 : 0);
int startX = bx;
- int xoffset = 0;
bool paint = true;
switch (button)
@@ -1062,10 +1061,7 @@ void CInfoViewer::showButton(const int button, const bool calledFromMPlayer, con
if (mode == VLC_MODE)
InfobarButtons[SNeutrinoSettings::BUTTON_GREEN].locale = LOCALE_MOVIEPLAYER_RESYNC;
else
- {
InfobarButtons[SNeutrinoSettings::BUTTON_GREEN].locale = LOCALE_INFOVIEWER_LANGUAGES;
- xoffset = 18;
- }
}
else
{
@@ -1079,7 +1075,6 @@ void CInfoViewer::showButton(const int button, const bool calledFromMPlayer, con
InfobarButtons[SNeutrinoSettings::BUTTON_GREEN].locale = LOCALE_INFOVIEWER_LANGUAGES;
else
paint = false;
- xoffset = 8;
int ac3state;
if ( ( g_RemoteControl->curr...
[truncated message content] |