From: leslie Date: Fri, 18 Jan 2008 17:38:44 +0000 (+0100) Subject: add setup option to toggle comment out or remove of superseded keys in keyfile X-Git-Tag: 0.9.0~31 X-Git-Url: http://www.vanbest.org/gitweb/?a=commitdiff_plain;h=4684dbcff46481f5692753fce1c37f9aa78a9499;p=sasc-ng.git add setup option to toggle comment out or remove of superseded keys in keyfile --- diff --git a/data.c b/data.c index 299b8d3..f94c84a 100644 --- a/data.c +++ b/data.c @@ -274,6 +274,13 @@ bool cStructLoader::CheckUnmodified(void) return true; } +bool cStructLoader::CheckDoSave(void) +{ + return !SL_TSTFLAG(SL_DISABLED) && SL_TSTFLAG(SL_READWRITE) + && !SL_TSTFLAG(SL_NOACCESS) && SL_TSTFLAG(SL_LOADED) + && IsModified() && CheckUnmodified(); +} + void cStructLoader::LoadFinished(void) { SL_CLRFLAG(SL_SHUTUP); @@ -385,13 +392,6 @@ void cStructLoader::Purge(void) } } -bool cStructLoader::CheckDoSave(void) -{ - return !SL_TSTFLAG(SL_DISABLED) && SL_TSTFLAG(SL_READWRITE) - && !SL_TSTFLAG(SL_NOACCESS) && SL_TSTFLAG(SL_LOADED) - && IsModified() && CheckUnmodified(); -} - void cStructLoader::Save(void) { if(CheckDoSave()) { @@ -891,7 +891,7 @@ bool cPlainKeys::AddNewKey(cPlainKey *nk, const char *reason) for(k=0; (k=FindKeyNoTrig(nk->type,nk->id,nk->keynr,nk->Size(),k)); ) { if(nk->CanSupersede()) { PRINTF(L_GEN_INFO,"supersedes key: %s",*k->ToString(true)); - DelItem(k,true); + DelItem(k,ScSetup.SuperKeys==0); } if(!ref) ref=k; } diff --git a/po/de_DE.po b/po/de_DE.po index 76e4e14..77b2e67 100644 --- a/po/de_DE.po +++ b/po/de_DE.po @@ -6,7 +6,7 @@ msgid "" msgstr "" "Project-Id-Version: VDR 1.5.9\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2008-01-07 22:10+0100\n" +"POT-Creation-Date: 2008-01-18 18:31+0100\n" "PO-Revision-Date: 2007-08-27 12:45+0200\n" "Last-Translator: somebody\n" "Language-Team: somebody\n" @@ -115,12 +115,21 @@ msgstr "aktive CAIDs" msgid "all CAIDs" msgstr "alle CAIDs" +msgid "comment out" +msgstr "auskommentieren" + +msgid "remove" +msgstr "entfernen" + msgid "Update keys (AU)" msgstr "Keys updaten (AU)" msgid "Start AU on EPG scan" msgstr "AU starten bei EPG-Scan" +msgid "Superseded keys" +msgstr "Veraltete Keys" + msgid "Concurrent FF streams" msgstr "Gleichzeitige FF Streams" diff --git a/po/fi_FI.po b/po/fi_FI.po index 0768b39..03c800c 100644 --- a/po/fi_FI.po +++ b/po/fi_FI.po @@ -6,7 +6,7 @@ msgid "" msgstr "" "Project-Id-Version: VDR 1.5.9\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2008-01-07 22:10+0100\n" +"POT-Creation-Date: 2008-01-18 18:31+0100\n" "PO-Revision-Date: 2007-08-27 12:45+0200\n" "Last-Translator: somebody\n" "Language-Team: somebody\n" @@ -115,12 +115,21 @@ msgstr "aktiiviset CAID:t" msgid "all CAIDs" msgstr "kaikki CAID:t" +msgid "comment out" +msgstr "" + +msgid "remove" +msgstr "" + msgid "Update keys (AU)" msgstr "Tilausten päivitys (AU)" msgid "Start AU on EPG scan" msgstr "Aloita AU EPG-päivityksessä" +msgid "Superseded keys" +msgstr "" + msgid "Concurrent FF streams" msgstr "Yhtäaikainen salauksenpurku (FF)" diff --git a/po/fr_FR.po b/po/fr_FR.po index 4e31102..301d52e 100644 --- a/po/fr_FR.po +++ b/po/fr_FR.po @@ -6,7 +6,7 @@ msgid "" msgstr "" "Project-Id-Version: VDR 1.5.9\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2008-01-07 22:10+0100\n" +"POT-Creation-Date: 2008-01-18 18:31+0100\n" "PO-Revision-Date: 2007-08-27 12:45+0200\n" "Last-Translator: somebody\n" "Language-Team: somebody\n" @@ -115,12 +115,21 @@ msgstr "CAIDs actifs" msgid "all CAIDs" msgstr "tous les CAIDs" +msgid "comment out" +msgstr "" + +msgid "remove" +msgstr "" + msgid "Update keys (AU)" msgstr "Mise à jour des Clés (AU)" msgid "Start AU on EPG scan" msgstr "" +msgid "Superseded keys" +msgstr "" + msgid "Concurrent FF streams" msgstr "" diff --git a/po/hu_HU.po b/po/hu_HU.po index 7b76ea3..22994ee 100644 --- a/po/hu_HU.po +++ b/po/hu_HU.po @@ -6,7 +6,7 @@ msgid "" msgstr "" "Project-Id-Version: VDR 1.5.11\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2008-01-07 22:10+0100\n" +"POT-Creation-Date: 2008-01-18 18:31+0100\n" "PO-Revision-Date: 2007-11-01 16:45+0200\n" "Last-Translator: jv\n" "Language-Team: somebody\n" @@ -115,12 +115,21 @@ msgstr "aktív CAIDok" msgid "all CAIDs" msgstr "minden CAID" +msgid "comment out" +msgstr "" + +msgid "remove" +msgstr "" + msgid "Update keys (AU)" msgstr "Kulcsok automatikus frissítése (AU)" msgid "Start AU on EPG scan" msgstr "" +msgid "Superseded keys" +msgstr "" + msgid "Concurrent FF streams" msgstr "Párhuzamos FF streamek" diff --git a/po/it_IT.po b/po/it_IT.po index d0ca6eb..7da4f97 100644 --- a/po/it_IT.po +++ b/po/it_IT.po @@ -6,7 +6,7 @@ msgid "" msgstr "" "Project-Id-Version: VDR 1.5.9\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2008-01-07 22:10+0100\n" +"POT-Creation-Date: 2008-01-18 18:31+0100\n" "PO-Revision-Date: 2007-08-27 12:45+0200\n" "Last-Translator: somebody\n" "Language-Team: somebody\n" @@ -115,12 +115,21 @@ msgstr "CAIDs attivi" msgid "all CAIDs" msgstr "tutti i CAIDs" +msgid "comment out" +msgstr "" + +msgid "remove" +msgstr "" + msgid "Update keys (AU)" msgstr "Aggiornamento chiavi (AU)" msgid "Start AU on EPG scan" msgstr "Avvia AU con la scansione EPG" +msgid "Superseded keys" +msgstr "" + msgid "Concurrent FF streams" msgstr "Flussi simultanei per scheda FF" diff --git a/po/nl_NL.po b/po/nl_NL.po index eb9e6b8..b8d74a3 100644 --- a/po/nl_NL.po +++ b/po/nl_NL.po @@ -6,7 +6,7 @@ msgid "" msgstr "" "Project-Id-Version: VDR 1.5.9\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2008-01-07 22:10+0100\n" +"POT-Creation-Date: 2008-01-18 18:31+0100\n" "PO-Revision-Date: 2007-08-27 12:45+0200\n" "Last-Translator: somebody\n" "Language-Team: somebody\n" @@ -115,12 +115,21 @@ msgstr "actieve CAIDS" msgid "all CAIDs" msgstr "alle CAIDs" +msgid "comment out" +msgstr "" + +msgid "remove" +msgstr "" + msgid "Update keys (AU)" msgstr "Keys updaten (AU)" msgid "Start AU on EPG scan" msgstr "" +msgid "Superseded keys" +msgstr "" + msgid "Concurrent FF streams" msgstr "" diff --git a/po/pl_PL.po b/po/pl_PL.po index 709c728..c50a644 100644 --- a/po/pl_PL.po +++ b/po/pl_PL.po @@ -6,7 +6,7 @@ msgid "" msgstr "" "Project-Id-Version: VDR 1.5.9\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2008-01-07 22:10+0100\n" +"POT-Creation-Date: 2008-01-18 18:31+0100\n" "PO-Revision-Date: 2007-08-27 12:45+0200\n" "Last-Translator: somebody\n" "Language-Team: somebody\n" @@ -115,12 +115,21 @@ msgstr "aktywne CAID" msgid "all CAIDs" msgstr "wszystkie CAID" +msgid "comment out" +msgstr "" + +msgid "remove" +msgstr "" + msgid "Update keys (AU)" msgstr "Aktualizuj klucze (AU)" msgid "Start AU on EPG scan" msgstr "" +msgid "Superseded keys" +msgstr "" + msgid "Concurrent FF streams" msgstr "" diff --git a/po/ru_RU.po b/po/ru_RU.po index f370e5f..a40e7a0 100644 --- a/po/ru_RU.po +++ b/po/ru_RU.po @@ -6,7 +6,7 @@ msgid "" msgstr "" "Project-Id-Version: VDR 1.5.9\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2008-01-07 22:10+0100\n" +"POT-Creation-Date: 2008-01-18 18:31+0100\n" "PO-Revision-Date: 2008-01-03 14:21+0100\n" "Last-Translator: somebody\n" "Language-Team: ru\n" @@ -116,12 +116,21 @@ msgstr " msgid "all CAIDs" msgstr "ÒáÕ CAID" +msgid "comment out" +msgstr "" + +msgid "remove" +msgstr "" + msgid "Update keys (AU)" msgstr "¾ÑÝÞÒÛïâì ÚÛîçØ (AU)" msgid "Start AU on EPG scan" msgstr "ÁâÐàâ ÐÒâÞÞÑÝÞÒÛÕÝØï ßàØ EPG áÚÐÝØàÞÒÐÝØØ" +msgid "Superseded keys" +msgstr "" + msgid "Concurrent FF streams" msgstr "¿ÐàÐÛÛÕÛìÝëÕ ßÞâÞÚØ FF" diff --git a/po/sv_SE.po b/po/sv_SE.po index e424901..21376e8 100644 --- a/po/sv_SE.po +++ b/po/sv_SE.po @@ -6,7 +6,7 @@ msgid "" msgstr "" "Project-Id-Version: VDR 1.5.9\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2008-01-07 22:10+0100\n" +"POT-Creation-Date: 2008-01-18 18:31+0100\n" "PO-Revision-Date: 2007-08-27 12:45+0200\n" "Last-Translator: somebody\n" "Language-Team: somebody\n" @@ -115,12 +115,21 @@ msgstr "aktiva CAID" msgid "all CAIDs" msgstr "alla CAID" +msgid "comment out" +msgstr "" + +msgid "remove" +msgstr "" + msgid "Update keys (AU)" msgstr "Nyckeluppdatering (AU)" msgid "Start AU on EPG scan" msgstr "" +msgid "Superseded keys" +msgstr "" + msgid "Concurrent FF streams" msgstr "" diff --git a/sc.c b/sc.c index 793ce72..815ccf0 100644 --- a/sc.c +++ b/sc.c @@ -944,15 +944,16 @@ cScSetup ScSetup; cScSetup::cScSetup(void) { - AutoUpdate = 1; + AutoUpdate=1; memset(ScCaps,0,sizeof(ScCaps)); - ScCaps[0] = 1; - ScCaps[1] = 2; - ConcurrentFF = 0; + ScCaps[0]=1; + ScCaps[1]=2; + ConcurrentFF=0; memset(CaIgnore,0,sizeof(CaIgnore)); - LocalPriority = 0; - ForceTransfer = 1; - PrestartAU = 0; + LocalPriority=0; + ForceTransfer=1; + PrestartAU=0; + SuperKeys=0; } void cScSetup::Check(void) @@ -1203,9 +1204,11 @@ public: cScPlugin::cScPlugin(void) { static const char *logg[] = { trNOOP("off"),trNOOP("active CAIDs"),trNOOP("all CAIDs") }; - ScOpts=new cOpts(0,7); + static const char *skey[] = { trNOOP("comment out"),trNOOP("remove") }; + ScOpts=new cOpts(0,8); ScOpts->Add(new cOptSel ("AutoUpdate" ,trNOOP("Update keys (AU)") ,&ScSetup.AutoUpdate,3,logg)); ScOpts->Add(new cOptBool ("PrestartAU" ,trNOOP("Start AU on EPG scan") ,&ScSetup.PrestartAU)); + ScOpts->Add(new cOptSel ("SuperKeys" ,trNOOP("Superseded keys") ,&ScSetup.SuperKeys,2,skey)); ScOpts->Add(new cOptBool ("ConcurrentFF" ,trNOOP("Concurrent FF streams"),&ScSetup.ConcurrentFF)); ScOpts->Add(new cOptBool ("ForceTranfer" ,trNOOP("Force TransferMode") ,&ScSetup.ForceTransfer)); ScOpts->Add(new cOptBool ("LocalPriority",trNOOP("Prefer local systems") ,&ScSetup.LocalPriority)); diff --git a/scsetup.h b/scsetup.h index 2c09c8c..8d7c5c6 100644 --- a/scsetup.h +++ b/scsetup.h @@ -34,6 +34,7 @@ public: int LocalPriority; int ForceTransfer; int PrestartAU; + int SuperKeys; public: cScSetup(void); void Check(void);