mirror of
https://github.com/tuxbox-neutrino/neutrino.git
synced 2025-08-29 08:21:12 +02:00
- usermenu: cleanup from unused code
This commit is contained in:
@@ -82,15 +82,6 @@ CUserMenu::~CUserMenu()
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
#if 0
|
|
||||||
#define MAINMENU_RECORDING_OPTION_COUNT 2
|
|
||||||
const CMenuOptionChooser::keyval MAINMENU_RECORDING_OPTIONS[MAINMENU_RECORDING_OPTION_COUNT] =
|
|
||||||
{
|
|
||||||
{ 0, LOCALE_MAINMENU_RECORDING_START },
|
|
||||||
{ 1, LOCALE_MAINMENU_RECORDING_STOP }
|
|
||||||
};
|
|
||||||
#endif
|
|
||||||
|
|
||||||
// USERMENU
|
// USERMENU
|
||||||
bool CUserMenu::showUserMenu(int button)
|
bool CUserMenu::showUserMenu(int button)
|
||||||
{
|
{
|
||||||
@@ -392,40 +383,13 @@ bool CUserMenu::showUserMenu(int button)
|
|||||||
menu->addItem(menu_item, 0);
|
menu->addItem(menu_item, 0);
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
|
|
||||||
#if 0 // FIXME not supported yet
|
|
||||||
case SNeutrinoSettings::ITEM_MOVIEPLAYER_TS:
|
|
||||||
menu_items++;
|
|
||||||
menu_prev = SNeutrinoSettings::ITEM_MOVIEPLAYER_TS;
|
|
||||||
keyhelper.get(&key,&icon,CRCInput::RC_green);
|
|
||||||
menu_item = new CMenuForwarder(LOCALE_MOVIEPLAYER_TSPLAYBACK, true, NULL, moviePlayerGui, "tsplayback", key, icon);
|
|
||||||
menu->addItem(menu_item, false);
|
|
||||||
break;
|
|
||||||
|
|
||||||
case SNeutrinoSettings::ITEM_VTXT:
|
|
||||||
for (unsigned int count = 0; count < (unsigned int) g_PluginList->getNumberOfPlugins(); count++)
|
|
||||||
{
|
|
||||||
std::string tmp = g_PluginList->getName(count);
|
|
||||||
if (g_PluginList->getType(count)== CPlugins::P_TYPE_TOOL && !g_PluginList->isHidden(count) && tmp.find("Teletext") != std::string::npos)
|
|
||||||
{
|
|
||||||
sprintf(id, "%d", count);
|
|
||||||
menu_items++;
|
|
||||||
menu_prev = SNeutrinoSettings::ITEM_VTXT;
|
|
||||||
|
|
||||||
//keyhelper.get(&key,&icon,CRCInput::RC_blue);
|
|
||||||
keyhelper.get(&key,&icon);
|
|
||||||
menu_item = new CMenuForwarderNonLocalized(g_PluginList->getName(count), true, NULL, StreamFeaturesChanger, id, key, icon);
|
|
||||||
menu->addItem(menu_item, 0);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
break;
|
|
||||||
#endif
|
|
||||||
default:
|
default:
|
||||||
printf("[neutrino] WARNING! menu wrong item!!\n");
|
printf("[neutrino] WARNING! menu wrong item!!\n");
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#if 0
|
||||||
// Allow some tailoring for privat image bakers ;)
|
// Allow some tailoring for privat image bakers ;)
|
||||||
if (button == SNeutrinoSettings::BUTTON_RED) {
|
if (button == SNeutrinoSettings::BUTTON_RED) {
|
||||||
}
|
}
|
||||||
@@ -434,17 +398,8 @@ bool CUserMenu::showUserMenu(int button)
|
|||||||
else if ( button == SNeutrinoSettings::BUTTON_YELLOW) {
|
else if ( button == SNeutrinoSettings::BUTTON_YELLOW) {
|
||||||
}
|
}
|
||||||
else if ( button == SNeutrinoSettings::BUTTON_BLUE) {
|
else if ( button == SNeutrinoSettings::BUTTON_BLUE) {
|
||||||
#ifdef _EXPERIMENTAL_SETTINGS_
|
|
||||||
//Experimental Settings
|
|
||||||
if (menu_prev != -1)
|
|
||||||
menu->addItem(GenericMenuSeparatorLine);
|
|
||||||
menu_items ++;
|
|
||||||
menu_key++;
|
|
||||||
// FYI: there is a memory leak with 'new CExperimentalSettingsMenuHandler()
|
|
||||||
menu_item = new CMenuForwarder(LOCALE_EXPERIMENTALSETTINGS, true, NULL, new CExperimentalSettingsMenuHandler(), "-1", CRCInput::convertDigitToKey(menu_key));
|
|
||||||
menu->addItem(menu_item, false);
|
|
||||||
#endif
|
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
// show menu if there are more than 2 items only
|
// show menu if there are more than 2 items only
|
||||||
// otherwise, we start the item directly (must be the last one)
|
// otherwise, we start the item directly (must be the last one)
|
||||||
@@ -456,9 +411,6 @@ bool CUserMenu::showUserMenu(int button)
|
|||||||
|
|
||||||
user_menu[button].selected = menu->getSelected();
|
user_menu[button].selected = menu->getSelected();
|
||||||
|
|
||||||
// restore mute symbol
|
|
||||||
//AudioMute(current_muted, true);
|
|
||||||
|
|
||||||
// clear the heap
|
// clear the heap
|
||||||
if (tmpFavorites) delete tmpFavorites;
|
if (tmpFavorites) delete tmpFavorites;
|
||||||
if (tmpAudioSelectMenuHandler) delete tmpAudioSelectMenuHandler;
|
if (tmpAudioSelectMenuHandler) delete tmpAudioSelectMenuHandler;
|
||||||
@@ -483,19 +435,6 @@ bool CUserMenu::showUserMenu(int button)
|
|||||||
**************************************************************************************/
|
**************************************************************************************/
|
||||||
bool CUserMenu::changeNotify(const neutrino_locale_t OptionName, void * Data)
|
bool CUserMenu::changeNotify(const neutrino_locale_t OptionName, void * Data)
|
||||||
{
|
{
|
||||||
#if 0
|
|
||||||
bool res = !CRecordManager::getInstance()->RecordingStatus() ? false:true;
|
|
||||||
|
|
||||||
if ((ARE_LOCALES_EQUAL(OptionName, LOCALE_MAINMENU_RECORDING_START)) || (ARE_LOCALES_EQUAL(OptionName, LOCALE_MAINMENU_RECORDING)))
|
|
||||||
{
|
|
||||||
CNeutrinoApp::getInstance()->exec(NULL, "handle_record");
|
|
||||||
|
|
||||||
if (CRecordManager::getInstance()->RecordingStatus())
|
|
||||||
res = false;
|
|
||||||
else
|
|
||||||
res = true;
|
|
||||||
} else
|
|
||||||
#endif
|
|
||||||
if (ARE_LOCALES_EQUAL(OptionName, LOCALE_MAINMENU_PAUSESECTIONSD)) {
|
if (ARE_LOCALES_EQUAL(OptionName, LOCALE_MAINMENU_PAUSESECTIONSD)) {
|
||||||
g_Sectionsd->setPauseScanning((*((int *)Data)) == 0);
|
g_Sectionsd->setPauseScanning((*((int *)Data)) == 0);
|
||||||
}
|
}
|
||||||
|
@@ -34,7 +34,6 @@
|
|||||||
#include <config.h>
|
#include <config.h>
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
||||||
#include "user_menue_setup.h"
|
#include "user_menue_setup.h"
|
||||||
|
|
||||||
#include <global.h>
|
#include <global.h>
|
||||||
|
@@ -58,7 +58,7 @@ const struct usermenu_props_t usermenu[USERMENU_ITEMS_COUNT] =
|
|||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
class CUserMenuSetup : public CMenuTarget
|
class CUserMenuSetup : public CMenuTarget
|
||||||
{
|
{
|
||||||
private:
|
private:
|
||||||
int width;
|
int width;
|
||||||
|
@@ -755,10 +755,10 @@ int CNeutrinoApp::loadSetup(const char * fname)
|
|||||||
//-------------------------------------------
|
//-------------------------------------------
|
||||||
// this is as the current neutrino usermen
|
// this is as the current neutrino usermen
|
||||||
const char* usermenu_default[SNeutrinoSettings::BUTTON_MAX]={
|
const char* usermenu_default[SNeutrinoSettings::BUTTON_MAX]={
|
||||||
"2,3,4,13", // RED
|
"2,3,4,13", // RED
|
||||||
"6", // GREEN
|
"6", // GREEN
|
||||||
"7", // YELLOW
|
"7", // YELLOW
|
||||||
"12,11,20,21,19,14,15" // BLUE
|
"12,11,20,21,19,14,15" // BLUE
|
||||||
};
|
};
|
||||||
char txt1[81];
|
char txt1[81];
|
||||||
std::string txt2;
|
std::string txt2;
|
||||||
|
@@ -656,9 +656,6 @@ struct SNeutrinoSettings
|
|||||||
ITEM_SCRIPTS = 21,
|
ITEM_SCRIPTS = 21,
|
||||||
ITEM_YOUTUBE = 22,
|
ITEM_YOUTUBE = 22,
|
||||||
ITEM_FILEPLAY = 23,
|
ITEM_FILEPLAY = 23,
|
||||||
#if 0
|
|
||||||
ITEM_MOVIEPLAYER_TS,
|
|
||||||
#endif
|
|
||||||
ITEM_MAX // MUST be always the last in the list
|
ITEM_MAX // MUST be always the last in the list
|
||||||
} USER_ITEM;
|
} USER_ITEM;
|
||||||
std::string usermenu_text[BUTTON_MAX];
|
std::string usermenu_text[BUTTON_MAX];
|
||||||
|
Reference in New Issue
Block a user