Remove globals and use new zapit class members

git-svn-id: file:///home/bas/coolstream_public_svn/THIRDPARTY/applications/neutrino-beta@1698 e54a6e83-5905-42d5-8d5c-058d10e6a962


Origin commit data
------------------
Commit: 6c6c2e9b29
Author: [CST] Focus <focus.cst@gmail.com>
Date: 2011-09-18 (Sun, 18 Sep 2011)
This commit is contained in:
[CST] Focus
2011-09-18 13:35:08 +00:00
parent b3ee2b575d
commit e760d27693
15 changed files with 75 additions and 70 deletions

View File

@@ -56,13 +56,10 @@
#include <zapit/fastscan.h>
#include <zapit/zapit.h>
extern int scan_pids;
extern CZapitChannel *g_current_channel;
extern std::map<transponder_id_t, transponder> select_transponders;
extern Zapit_config zapitCfg;
extern char zapit_lat[20];
extern char zapit_long[20];
extern int scan_pids;
static int all_usals = 1;
sat_iterator_t sit;
@@ -734,7 +731,7 @@ int CScanSetup::addListFlagsItems(CMenuWidget *listflags_menu, const int &shortc
CMenuOptionChooser *useNit = new CMenuOptionChooser(LOCALE_SATSETUP_USE_NIT, (int *)&scansettings.scan_mode, OPTIONS_OFF1_ON0_OPTIONS, OPTIONS_OFF1_ON0_OPTION_COUNT, true, NULL, CRCInput::convertDigitToKey(shortCut++));
CMenuOptionChooser *ftaFlag = new CMenuOptionChooser(LOCALE_SATSETUP_USE_FTA_FLAG, (int *)&scansettings.scan_fta_flag, OPTIONS_OFF0_ON1_OPTIONS, OPTIONS_OFF1_ON0_OPTION_COUNT, true, NULL, CRCInput::convertDigitToKey(shortCut++));
CMenuOptionChooser *scanPid = new CMenuOptionChooser(LOCALE_EXTRA_ZAPIT_SCANPIDS, &scan_pids, OPTIONS_OFF0_ON1_OPTIONS, OPTIONS_OFF0_ON1_OPTION_COUNT, true, NULL, CRCInput::convertDigitToKey(shortCut++));
CMenuOptionChooser *scanPid = new CMenuOptionChooser(LOCALE_EXTRA_ZAPIT_SCANPIDS, &zapitCfg.scanPids, OPTIONS_OFF0_ON1_OPTIONS, OPTIONS_OFF0_ON1_OPTION_COUNT, true, NULL, CRCInput::convertDigitToKey(shortCut++));
listflags_menu->addItem(useNit);
listflags_menu->addItem(ftaFlag);
@@ -827,9 +824,10 @@ int CTPSelectHandler::exec(CMenuTarget* parent, const std::string &/*actionkey*/
break;
}
if(!old_selected && g_current_channel && g_current_channel->getSatellitePosition() == position)
CZapitChannel * channel = CZapit::getInstance()->GetCurrentChannel();
if(!old_selected && channel && channel->getSatellitePosition() == position)
{
if(g_current_channel->getFreqId() == GET_FREQ_FROM_TPID(tI->first))
if(channel->getFreqId() == GET_FREQ_FROM_TPID(tI->first))
old_selected = i;
}