diff options
author | Johns <johns98@gmx.net> | 2014-06-04 14:49:18 +0200 |
---|---|---|
committer | Johns <johns98@gmx.net> | 2014-06-04 14:49:18 +0200 |
commit | 90538ebfa9e9fb29aab6a969cf812e045b2a37d8 (patch) | |
tree | a97ecac828a300132a76e075711e46569022617e | |
parent | ac7672053a9d185544e7a93deac770e15d57ae93 (diff) | |
download | vdr-plugin-softhddevice-90538ebfa9e9fb29aab6a969cf812e045b2a37d8.tar.gz vdr-plugin-softhddevice-90538ebfa9e9fb29aab6a969cf812e045b2a37d8.tar.bz2 |
Support detach or suspend in plugin menu.
-rw-r--r-- | ChangeLog | 10 | ||||
-rw-r--r-- | po/de_DE.po | 13 | ||||
-rw-r--r-- | softhddevice.cpp | 41 |
3 files changed, 58 insertions, 6 deletions
@@ -1,6 +1,16 @@ User johns Date: + Config for automatic AES parameters. + +User master_red +Date: Wed Jun 4 14:44:32 CEST 2014 + + Support detach or suspend in plugin menu. + +User johns +Date: Fri May 30 10:18:20 CEST 2014 + Fix "make clean-plugins". Fix compile with newer libav. Fix OSD bugs. diff --git a/po/de_DE.po b/po/de_DE.po index e27d67a..50f7528 100644 --- a/po/de_DE.po +++ b/po/de_DE.po @@ -7,7 +7,7 @@ msgid "" msgstr "" "Project-Id-Version: VDR \n" "Report-Msgid-Bugs-To: <see README>\n" -"POT-Creation-Date: 2014-02-26 15:08+0100\n" +"POT-Creation-Date: 2014-03-20 11:50+0100\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n" "Language-Team: LANGUAGE <LL@li.org>\n" @@ -489,6 +489,9 @@ msgstr "OSD Höhe" msgid "Suspend" msgstr "Unterbrechen" +msgid "Detach from main menu entry" +msgstr "Detach durch Hauptmenüeintrag" + msgid "Suspend closes video+audio" msgstr "Unterbrechen schließt Video+Audio" @@ -604,7 +607,7 @@ msgid " E-AC-3 pass-through" msgstr "" msgid "Enable (E-)AC-3 (decoder) downmix" -msgstr "" +msgstr "Aktiviere (E-)AC-3 (decoder) downmix"" msgid "Volume control" msgstr "Lautstärkesteuerung" @@ -633,6 +636,9 @@ msgstr "Reduziere Steropegel (/1000)" msgid "Audio buffer size (ms)" msgstr "Audio Puffergröße (ms)" +msgid "Enable automatic AES" +msgstr "Aktiviere automatiche AES" + msgid "Picture-In-Picture" msgstr "Bild in Bild (PIP)" @@ -697,6 +703,9 @@ msgstr "" msgid "Channel not available!" msgstr "Kanal nicht verfügbar!" +msgid "Detach SoftHdDevice" +msgstr "" + msgid "Suspend SoftHdDevice" msgstr "Unterbreche SoftHdDevice" diff --git a/softhddevice.cpp b/softhddevice.cpp index f7b7a46..b3467a5 100644 --- a/softhddevice.cpp +++ b/softhddevice.cpp @@ -79,6 +79,7 @@ static const char *const Resolution[RESOLUTIONS] = { static char ConfigMakePrimary; ///< config primary wanted static char ConfigHideMainMenuEntry; ///< config hide main menu entry +static char ConfigDetachFromMainMenu; ///< detach from main menu entry instead of suspend static char ConfigSuspendClose; ///< suspend should close devices static char ConfigSuspendX11; ///< suspend should stop x11 @@ -139,6 +140,7 @@ static char ConfigAudioCompression; ///< config use volume compression static int ConfigAudioMaxCompression; ///< config max volume compression static int ConfigAudioStereoDescent; ///< config reduce stereo loudness int ConfigAudioBufferTime; ///< config size ms of audio buffer +static int ConfigAudioAutoAES; ///< config automatic AES handling static char *ConfigX11Display; ///< config x11 display static char *ConfigAudioDevice; ///< config audio stereo device @@ -597,6 +599,7 @@ class cMenuSetupSoft:public cMenuSetupPage int General; int MakePrimary; int HideMainMenuEntry; + int DetachFromMainMenu; int OsdSize; int OsdWidth; int OsdHeight; @@ -648,6 +651,7 @@ class cMenuSetupSoft:public cMenuSetupPage int AudioMaxCompression; int AudioStereoDescent; int AudioBufferTime; + int AudioAutoAES; #ifdef USE_PIP int Pip; @@ -775,6 +779,8 @@ void cMenuSetupSoft::Create(void) // suspend // Add(SeparatorItem(tr("Suspend"))); + Add(new cMenuEditBoolItem(tr("Detach from main menu entry"), + &DetachFromMainMenu, trVDR("no"), trVDR("yes"))); Add(new cMenuEditBoolItem(tr("Suspend closes video+audio"), &SuspendClose, trVDR("no"), trVDR("yes"))); Add(new cMenuEditBoolItem(tr("Suspend stops x11"), &SuspendX11, @@ -892,6 +898,8 @@ void cMenuSetupSoft::Create(void) &AudioStereoDescent, 0, 1000)); Add(new cMenuEditIntItem(tr("Audio buffer size (ms)"), &AudioBufferTime, 0, 1000)); + Add(new cMenuEditBoolItem(tr("Enable automatic AES"), &AudioAutoAES, + trVDR("no"), trVDR("yes"))); } #ifdef USE_PIP // @@ -997,6 +1005,7 @@ cMenuSetupSoft::cMenuSetupSoft(void) General = 0; MakePrimary = ConfigMakePrimary; HideMainMenuEntry = ConfigHideMainMenuEntry; + DetachFromMainMenu = ConfigDetachFromMainMenu; // // osd // @@ -1074,6 +1083,7 @@ cMenuSetupSoft::cMenuSetupSoft(void) AudioMaxCompression = ConfigAudioMaxCompression; AudioStereoDescent = ConfigAudioStereoDescent; AudioBufferTime = ConfigAudioBufferTime; + AudioAutoAES = ConfigAudioAutoAES; #ifdef USE_PIP // @@ -1110,6 +1120,8 @@ void cMenuSetupSoft::Store(void) SetupStore("MakePrimary", ConfigMakePrimary = MakePrimary); SetupStore("HideMainMenuEntry", ConfigHideMainMenuEntry = HideMainMenuEntry); + SetupStore("DetachFromMainMenu", ConfigDetachFromMainMenu = + DetachFromMainMenu); switch (OsdSize) { case 0: OsdWidth = 0; @@ -1236,6 +1248,8 @@ void cMenuSetupSoft::Store(void) AudioStereoDescent); AudioSetStereoDescent(ConfigAudioStereoDescent); SetupStore("AudioBufferTime", ConfigAudioBufferTime = AudioBufferTime); + SetupStore("AudioAutoAES", ConfigAudioAutoAES = AudioAutoAES); + AudioSetAutoAES(ConfigAudioAutoAES); #ifdef USE_PIP SetupStore("pip.X", ConfigPipX = PipX); @@ -1768,7 +1782,12 @@ void cSoftHdMenu::Create(void) Clear(); // clear the menu SetHasHotkeys(); - Add(new cOsdItem(hk(tr("Suspend SoftHdDevice")), osUser1)); + + if (ConfigDetachFromMainMenu) { + Add(new cOsdItem(hk(tr("Detach SoftHdDevice")), osUser1)); + } else { + Add(new cOsdItem(hk(tr("Suspend SoftHdDevice")), osUser1)); + } #ifdef USE_PIP if (PipReceiver) { Add(new cOsdItem(hk(tr("PIP toggle on/off: off")), osUser2)); @@ -2016,9 +2035,14 @@ eOSState cSoftHdMenu::ProcessKey(eKeys key) if (SuspendMode == NOT_SUSPENDED && !cSoftHdControl::Player) { cControl::Launch(new cSoftHdControl); cControl::Attach(); - Suspend(ConfigSuspendClose, ConfigSuspendClose, - ConfigSuspendX11); - SuspendMode = SUSPEND_NORMAL; + if (ConfigDetachFromMainMenu) { + Suspend(1, 1, 0); + SuspendMode = SUSPEND_DETACHED; + } else { + Suspend(ConfigSuspendClose, ConfigSuspendClose, + ConfigSuspendX11); + SuspendMode = SUSPEND_NORMAL; + } if (ShutdownHandler.GetUserInactiveTime()) { dsyslog("[softhddev]%s: set user inactive\n", __FUNCTION__); @@ -2841,6 +2865,10 @@ bool cPluginSoftHdDevice::SetupParse(const char *name, const char *value) ConfigHideMainMenuEntry = atoi(value); return true; } + if (!strcasecmp(name, "DetachFromMainMenu")) { + ConfigDetachFromMainMenu = atoi(value); + return true; + } if (!strcasecmp(name, "Osd.Width")) { ConfigOsdWidth = atoi(value); VideoSetOsdSize(ConfigOsdWidth, ConfigOsdHeight); @@ -3040,6 +3068,11 @@ bool cPluginSoftHdDevice::SetupParse(const char *name, const char *value) ConfigAudioBufferTime = atoi(value); return true; } + if (!strcasecmp(name, "AudioAutoAES")) { + ConfigAudioAutoAES = atoi(value); + AudioSetAutoAES(ConfigAudioAutoAES); + return true; + } #ifdef USE_PIP if (!strcasecmp(name, "pip.X")) { ConfigPipX = atoi(value); |