Merge branch 'dvbsi++' of coolstreamtech.de:cst-public-gui-neutrino into dvbsi++

Origin commit data
------------------
Commit: 3f475d9eea
Author: [CST] Focus <focus.cst@gmail.com>
Date: 2012-06-25 (Mon, 25 Jun 2012)
This commit is contained in:
[CST] Focus
2012-06-25 13:57:50 +04:00
10 changed files with 18 additions and 9 deletions

View File

@@ -453,7 +453,7 @@ void CRemoteControl::getNVODs()
void CRemoteControl::processAPIDnames()
{
has_unresolved_ctags= false;
has_ac3 = false; //FIXME what this variable suppoused to do ?? seems unused
has_ac3 = false; //use in infoviewer
int pref_found = -1;
int pref_ac3_found = -1;
int pref_idx = -1;

View File

@@ -163,7 +163,8 @@ void CInfoViewerBB::getBBIconInfo()
break;
#endif
case CInfoViewerBB::ICON_DD:
iconView = checkBBIcon(NEUTRINO_ICON_DD, &w, &h);
if( g_settings.infobar_show_dd_available )
iconView = checkBBIcon(NEUTRINO_ICON_DD, &w, &h);
break;
case CInfoViewerBB::ICON_16_9: //no radio
if (neutrino->getMode() != NeutrinoMessages::mode_radio)
@@ -414,14 +415,14 @@ void CInfoViewerBB::showIcon_VTXT()
void CInfoViewerBB::showIcon_DD()
{
if (!is_visible)
if (!is_visible || !g_settings.infobar_show_dd_available)
return;
std::string dd_icon;
if ((g_RemoteControl->current_PIDs.PIDs.selected_apid < g_RemoteControl->current_PIDs.APIDs.size()) &&
(g_RemoteControl->current_PIDs.APIDs[g_RemoteControl->current_PIDs.PIDs.selected_apid].is_ac3))
dd_icon = NEUTRINO_ICON_DD;
else
dd_icon = (g_RemoteControl->has_ac3) ? NEUTRINO_ICON_DD_AVAIL : NEUTRINO_ICON_DD_GREY;
else
dd_icon = g_RemoteControl->has_ac3 ? NEUTRINO_ICON_DD_AVAIL : NEUTRINO_ICON_DD_GREY;
showBBIcons(CInfoViewerBB::ICON_DD, dd_icon);
}

View File

@@ -616,6 +616,7 @@ void COsdSetup::showOsdInfobarSetup(CMenuWidget *menu_infobar)
menu_infobar->addItem(new CMenuOptionChooser(LOCALE_MISCSETTINGS_INFOBAR_SAT_DISPLAY, &g_settings.infobar_sat_display, OPTIONS_OFF0_ON1_OPTIONS, OPTIONS_OFF0_ON1_OPTION_COUNT, true));
menu_infobar->addItem(new CMenuOptionChooser(LOCALE_MISCSETTINGS_INFOBAR_SHOW_SYSFS_HDD, &g_settings.infobar_show_sysfs_hdd, OPTIONS_OFF0_ON1_OPTIONS, OPTIONS_OFF0_ON1_OPTION_COUNT, true));
menu_infobar->addItem(new CMenuOptionChooser(LOCALE_MISCSETTINGS_INFOBAR_SHOW_RES, &g_settings.infobar_show_res, INFOBAR_SHOW_RES_MODE_OPTIONS, INFOBAR_SHOW_RES_MODE_OPTION_COUNT, true));
menu_infobar->addItem(new CMenuOptionChooser(LOCALE_MISCSETTINGS_INFOBAR_SHOW_DD_AVAILABLE, &g_settings.infobar_show_dd_available, OPTIONS_OFF0_ON1_OPTIONS, OPTIONS_OFF0_ON1_OPTION_COUNT, true));
menu_infobar->addItem(new CMenuOptionChooser(LOCALE_MISCSETTINGS_INFOBAR_SHOW_TUNER, &g_settings.infobar_show_tuner, OPTIONS_OFF0_ON1_OPTIONS, OPTIONS_OFF0_ON1_OPTION_COUNT, true));
menu_infobar->addItem(new CMenuOptionChooser(LOCALE_MISCSETTINGS_INFOBAR_SHOW, &g_settings.infobar_show, OPTIONS_OFF0_ON1_OPTIONS, OPTIONS_OFF0_ON1_OPTION_COUNT, true));
menu_infobar->addItem(new CMenuOptionChooser(LOCALE_MISCSETTINGS_INFOBAR_COLORED_EVENTS, &g_settings.colored_events_infobar, OPTIONS_COLORED_EVENTS_OPTIONS, OPTIONS_COLORED_EVENTS_OPTION_COUNT, true));

View File

@@ -40,6 +40,8 @@
#include <dirent.h>
#include <dlfcn.h>
#include <sys/types.h>
#include <sys/stat.h>
#include <unistd.h>
#include <stdio.h>
@@ -91,10 +93,9 @@ int CPlugins::find_plugin(const std::string & filename)
bool CPlugins::pluginfile_exists(const std::string & filename)
{
FILE *file = fopen(filename.c_str(),"r");
if (file != NULL)
struct stat stat_buf;
if(::stat(filename.c_str(), &stat_buf) == 0)
{
fclose(file);
return true;
} else
{
@@ -324,7 +325,6 @@ void CPlugins::startScriptPlugin(int number)
script, plugin_list[number].cfgfile.c_str());
return;
}
FILE *f = popen(script,"r");
if (f != NULL)
{

View File

@@ -408,6 +408,7 @@ int CNeutrinoApp::loadSetup(const char * fname)
g_settings.infobar_show_sysfs_hdd = configfile.getBool("infobar_show_sysfs_hdd" , true );
g_settings.show_mute_icon = configfile.getInt32("show_mute_icon" ,0);
g_settings.infobar_show_res = configfile.getInt32("infobar_show_res", 0 );
g_settings.infobar_show_dd_available = configfile.getInt32("infobar_show_dd_available", 1 );
g_settings.infobar_show_tuner = configfile.getInt32("infobar_show_tuner", 1 );
g_settings.radiotext_enable = configfile.getBool("radiotext_enable" , false);
//audio
@@ -851,6 +852,7 @@ void CNeutrinoApp::saveSetup(const char * fname)
configfile.setInt32("infobar_show_sysfs_hdd" , g_settings.infobar_show_sysfs_hdd );
configfile.setInt32("show_mute_icon" , g_settings.show_mute_icon);
configfile.setInt32("infobar_show_res" , g_settings.infobar_show_res );
configfile.setInt32("infobar_show_dd_available" , g_settings.infobar_show_dd_available );
configfile.setInt32("infobar_show_tuner" , g_settings.infobar_show_tuner );
configfile.setBool("radiotext_enable" , g_settings.radiotext_enable);
//audio

View File

@@ -763,6 +763,7 @@ typedef enum
LOCALE_MISCSETTINGS_INFOBAR_LOGO_HDD_DIR,
LOCALE_MISCSETTINGS_INFOBAR_SAT_DISPLAY,
LOCALE_MISCSETTINGS_INFOBAR_SHOW,
LOCALE_MISCSETTINGS_INFOBAR_SHOW_DD_AVAILABLE,
LOCALE_MISCSETTINGS_INFOBAR_SHOW_RES,
LOCALE_MISCSETTINGS_INFOBAR_SHOW_RES_SIMPLE,
LOCALE_MISCSETTINGS_INFOBAR_SHOW_SYSFS_HDD,

View File

@@ -763,6 +763,7 @@ const char * locale_real_names[] =
"miscsettings.infobar_logo_hdd_dir",
"miscsettings.infobar_sat_display",
"miscsettings.infobar_show",
"miscsettings.infobar_show_dd_available",
"miscsettings.infobar_show_res",
"miscsettings.infobar_show_res_simple",
"miscsettings.infobar_show_sysfs_hdd",

View File

@@ -76,6 +76,7 @@ struct SNeutrinoSettings
int infobar_show_sysfs_hdd;
int infobar_show_res;
int infobar_show_tuner;
int infobar_show_dd_available;
//audio
int audio_AnalogMode;
int audio_DolbyDigital;