- miscsettings_menu: allow to reset movieplayer plugin

This commit is contained in:
svenhoefer
2016-02-22 21:06:46 +01:00
parent 0f771856ab
commit a4bd8cc5a8
7 changed files with 25 additions and 14 deletions

View File

@@ -1772,7 +1772,7 @@ movieplayer.bookmarkname Bookmark Name
movieplayer.bookmarkname_hint1 Geben Sie den Namen für das neue Lesezeichen ein
movieplayer.bookmarkname_hint2
movieplayer.chapters Kapitel
movieplayer.defplugin Start-Plugin
movieplayer.plugin Movieplayer-Plugin
movieplayer.fileplayback Abspielen (Multiformat)
movieplayer.head Movieplayer
movieplayer.starting Wiedergabe starten...
@@ -1996,6 +1996,7 @@ ping.unreachable ist nicht erreichbar (unerreichbar)
pinprotection.head PIN-Abfrage
pinprotection.wrongcode Geben Sie den Code nocheinmal ein!
plugins.hdd_dir Externes Plugin-Verz.
plugins.no_plugin Kein Plugin
plugins.result Pluginausgabe
plugintype.disabled Deaktiviert
plugintype.game Spiel

View File

@@ -1772,7 +1772,7 @@ movieplayer.bookmarkname Bookmarkname
movieplayer.bookmarkname_hint1 Enter a name for your new bookmark
movieplayer.bookmarkname_hint2
movieplayer.chapters Chapters
movieplayer.defplugin Start-Plugin
movieplayer.plugin Movieplayer plugin
movieplayer.fileplayback File play
movieplayer.head Movieplayer
movieplayer.starting Starting playback...
@@ -1996,6 +1996,7 @@ ping.unreachable is unreachable
pinprotection.head Enter PIN code
pinprotection.wrongcode PIN-Code was wrong! Try again.
plugins.hdd_dir Plugin HDD dir.
plugins.no_plugin No plugin
plugins.result plugin output
plugintype.disabled Disabled
plugintype.game Game

View File

@@ -100,11 +100,11 @@ int CMiscMenue::exec(CMenuTarget* parent, const std::string &actionKey)
}
else if(actionKey == "movieplayer_plugin")
{
CMenuWidget MoviePluginSelector(LOCALE_MOVIEPLAYER_DEFPLUGIN, NEUTRINO_ICON_FEATURES);
CMenuWidget MoviePluginSelector(LOCALE_MOVIEPLAYER_PLUGIN, NEUTRINO_ICON_FEATURES);
MoviePluginSelector.addItem(GenericMenuSeparator);
MoviePluginSelector.addItem(new CMenuForwarder(LOCALE_PLUGINS_NO_PLUGIN, true, NULL, new CMoviePluginChangeExec(), "---", CRCInput::RC_red));
MoviePluginSelector.addItem(GenericMenuSeparatorLine);
char id[5];
int cnt = 0;
int enabled_count = 0;
for(unsigned int count=0;count < (unsigned int) g_PluginList->getNumberOfPlugins();count++)
{
@@ -112,8 +112,7 @@ int CMiscMenue::exec(CMenuTarget* parent, const std::string &actionKey)
{
sprintf(id, "%d", count);
enabled_count++;
MoviePluginSelector.addItem(new CMenuForwarder(g_PluginList->getName(count), true, NULL, new CMoviePluginChangeExec(), id, CRCInput::convertDigitToKey(count)), (cnt == 0));
cnt++;
MoviePluginSelector.addItem(new CMenuForwarder(g_PluginList->getName(count), true, NULL, new CMoviePluginChangeExec(), id, CRCInput::convertDigitToKey(count)));
}
}

View File

@@ -638,7 +638,7 @@ int CNeutrinoApp::loadSetup(const char * fname)
g_settings.recording_startstop_msg = configfile.getBool("recording_startstop_msg" , true);
// default plugin for movieplayer
g_settings.movieplayer_plugin = configfile.getString( "movieplayer_plugin", "noplugin" );
g_settings.movieplayer_plugin = configfile.getString( "movieplayer_plugin", "---" );
g_settings.plugin_hdd_dir = configfile.getString( "plugin_hdd_dir", "/media/sda1/plugins" );
g_settings.plugins_disabled = configfile.getString( "plugins_disabled", "" );

View File

@@ -1799,7 +1799,7 @@ typedef enum
LOCALE_MOVIEPLAYER_BOOKMARKNAME_HINT1,
LOCALE_MOVIEPLAYER_BOOKMARKNAME_HINT2,
LOCALE_MOVIEPLAYER_CHAPTERS,
LOCALE_MOVIEPLAYER_DEFPLUGIN,
LOCALE_MOVIEPLAYER_PLUGIN,
LOCALE_MOVIEPLAYER_FILEPLAYBACK,
LOCALE_MOVIEPLAYER_HEAD,
LOCALE_MOVIEPLAYER_STARTING,
@@ -2023,6 +2023,7 @@ typedef enum
LOCALE_PINPROTECTION_HEAD,
LOCALE_PINPROTECTION_WRONGCODE,
LOCALE_PLUGINS_HDD_DIR,
LOCALE_PLUGINS_NO_PLUGIN,
LOCALE_PLUGINS_RESULT,
LOCALE_PLUGINTYPE_DISABLED,
LOCALE_PLUGINTYPE_GAME,

View File

@@ -1799,7 +1799,7 @@ const char * locale_real_names[] =
"movieplayer.bookmarkname_hint1",
"movieplayer.bookmarkname_hint2",
"movieplayer.chapters",
"movieplayer.defplugin",
"movieplayer.plugin",
"movieplayer.fileplayback",
"movieplayer.head",
"movieplayer.starting",
@@ -2023,6 +2023,7 @@ const char * locale_real_names[] =
"pinprotection.head",
"pinprotection.wrongcode",
"plugins.hdd_dir",
"plugins.no_plugin",
"plugins.result",
"plugintype.disabled",
"plugintype.game",

View File

@@ -375,12 +375,20 @@ int CNVODChangeExec::exec(CMenuTarget* parent, const std::string & actionKey)
int CMoviePluginChangeExec::exec(CMenuTarget* parent, const std::string & actionKey)
{
int sel= atoi(actionKey.c_str());
parent->hide();
if (sel>=0)
if (parent)
parent->hide();
if (actionKey == "---")
{
g_settings.movieplayer_plugin=g_PluginList->getName(sel);
g_settings.movieplayer_plugin = actionKey;
}
else
{
int sel = atoi(actionKey.c_str());
if (sel >= 0)
g_settings.movieplayer_plugin = g_PluginList->getName(sel);
}
return menu_return::RETURN_EXIT;
}