summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--i18n-generated.h35
-rw-r--r--i18n.cpp24
-rw-r--r--po/ca_ES.po3
-rw-r--r--po/cs_CZ.po3
-rw-r--r--po/da_DK.po3
-rw-r--r--po/de_DE.po3
-rw-r--r--po/el_GR.po3
-rw-r--r--po/es_ES.po3
-rw-r--r--po/et_EE.po3
-rw-r--r--po/fi_FI.po3
-rw-r--r--po/fr_FR.po3
-rw-r--r--po/hr_HR.po3
-rw-r--r--po/hu_HU.po3
-rw-r--r--[-rwxr-xr-x]po/it_IT.po3
-rw-r--r--po/lt_LT.po4
-rw-r--r--po/nl_NL.po3
-rw-r--r--po/nn_NO.po3
-rw-r--r--po/pl_PL.po3
-rw-r--r--po/pt_PT.po3
-rw-r--r--po/ro_RO.po3
-rw-r--r--po/ru_RU.po3
-rw-r--r--po/sl_SI.po3
-rw-r--r--po/sv_SE.po3
-rw-r--r--po/tr_TR.po3
-rw-r--r--recman.cpp55
-rw-r--r--recman.h4
26 files changed, 169 insertions, 16 deletions
diff --git a/i18n-generated.h b/i18n-generated.h
index 729f38b..bdc1fbc 100644
--- a/i18n-generated.h
+++ b/i18n-generated.h
@@ -501,6 +501,41 @@ const tI18nPhrase Phrases[] = {
"",
#endif
},
+ { "On archive HDD No.",
+ "Auf Archiv-HDD Nr.",
+ "",
+ "In archivio HDD No.",
+ "",
+ "",
+ "Sur le HDD archive noä",
+ "",
+ "Arkistointi-HDD:llä numero",
+ "",
+ "",
+ "",
+ "",
+ "",
+ "",
+ "",
+#if VDRVERSNUM >= 10302
+ "",
+#endif
+#if VDRVERSNUM >= 10307
+ "",
+#endif
+#if VDRVERSNUM >= 10313
+ "",
+#endif
+#if VDRVERSNUM >= 10316
+ "",
+#endif
+#if VDRVERSNUM >= 10342
+ "",
+#endif
+#if VDRVERSNUM >= 10502
+ "",
+#endif
+ },
{ "Couldn't find channel or no channels available.",
"Kann das Programm nicht finden oder keine vorhanden.",
"",
diff --git a/i18n.cpp b/i18n.cpp
index a95bf4a..f0b14da 100644
--- a/i18n.cpp
+++ b/i18n.cpp
@@ -3564,7 +3564,7 @@ const tI18nPhrase Phrases[] = {
{ "On archive DVD No.", // English
"Auf Archiv-DVD Nr.", // Deutsch
"", // Slovenski
- "", // Italiano
+ "In archivio DVD No.", // Italiano
"", // Nederlands
"", // Português
"Sur le DVD archive no°", // Français
@@ -3583,6 +3583,28 @@ const tI18nPhrase Phrases[] = {
"", // Dansk
"", // Czech
},
+ { "On archive HDD No.", // English
+ "Auf Archiv-HDD Nr.", // Deutsch
+ "", // Slovenski
+ "In archivio HDD No.", // Italiano
+ "", // Nederlands
+ "", // Português
+ "Sur le HDD archive no°", // Français
+ "", // Norsk
+ "Arkistointi-HDD:llä numero",
+ "", // Polski
+ "", // Español
+ "", // Greek
+ "", // Svenska
+ "", // Românã
+ "", // Magyar
+ "", // Català
+ "", // Russian
+ "", // Hrvatski
+ "", // Eesti
+ "", // Dansk
+ "", // Czech
+ },
{ "Starts between", // English
"Beginnt zwischen", // Deutsch
"", // Slovenski
diff --git a/po/ca_ES.po b/po/ca_ES.po
index 3c1b6f1..52106ef 100644
--- a/po/ca_ES.po
+++ b/po/ca_ES.po
@@ -60,6 +60,9 @@ msgstr ""
msgid "On archive DVD No."
msgstr ""
+msgid "On archive HDD No."
+msgstr ""
+
msgid "Couldn't find channel or no channels available."
msgstr ""
diff --git a/po/cs_CZ.po b/po/cs_CZ.po
index c63a860..69de7c4 100644
--- a/po/cs_CZ.po
+++ b/po/cs_CZ.po
@@ -58,6 +58,9 @@ msgstr ""
msgid "On archive DVD No."
msgstr ""
+msgid "On archive HDD No."
+msgstr ""
+
msgid "Couldn't find channel or no channels available."
msgstr ""
diff --git a/po/da_DK.po b/po/da_DK.po
index 05536cd..f56d3a9 100644
--- a/po/da_DK.po
+++ b/po/da_DK.po
@@ -58,6 +58,9 @@ msgstr ""
msgid "On archive DVD No."
msgstr ""
+msgid "On archive HDD No."
+msgstr ""
+
msgid "Couldn't find channel or no channels available."
msgstr ""
diff --git a/po/de_DE.po b/po/de_DE.po
index d86caba..df79751 100644
--- a/po/de_DE.po
+++ b/po/de_DE.po
@@ -60,6 +60,9 @@ msgstr "Timer wurde nicht erstellt"
msgid "On archive DVD No."
msgstr "Auf Archiv-DVD Nr."
+msgid "On archive HDD No."
+msgstr "Auf Archiv-HDD Nr."
+
msgid "Couldn't find channel or no channels available."
msgstr "Kann das Programm nicht finden oder keine vorhanden."
diff --git a/po/el_GR.po b/po/el_GR.po
index b5b3793..37c6879 100644
--- a/po/el_GR.po
+++ b/po/el_GR.po
@@ -58,6 +58,9 @@ msgstr ""
msgid "On archive DVD No."
msgstr ""
+msgid "On archive HDD No."
+msgstr ""
+
msgid "Couldn't find channel or no channels available."
msgstr ""
diff --git a/po/es_ES.po b/po/es_ES.po
index 94c1013..12e9a0c 100644
--- a/po/es_ES.po
+++ b/po/es_ES.po
@@ -58,6 +58,9 @@ msgstr ""
msgid "On archive DVD No."
msgstr ""
+msgid "On archive HDD No."
+msgstr ""
+
msgid "Couldn't find channel or no channels available."
msgstr ""
diff --git a/po/et_EE.po b/po/et_EE.po
index 773e9f9..c26cfa0 100644
--- a/po/et_EE.po
+++ b/po/et_EE.po
@@ -58,6 +58,9 @@ msgstr ""
msgid "On archive DVD No."
msgstr ""
+msgid "On archive HDD No."
+msgstr ""
+
msgid "Couldn't find channel or no channels available."
msgstr ""
diff --git a/po/fi_FI.po b/po/fi_FI.po
index 1ceb99b..d9bc903 100644
--- a/po/fi_FI.po
+++ b/po/fi_FI.po
@@ -58,6 +58,9 @@ msgstr "Ajastinta ei ole määritelty"
msgid "On archive DVD No."
msgstr "Arkistointi-DVD:llä numero"
+msgid "On archive HDD No."
+msgstr "Arkistointi-HDD:llä numero"
+
msgid "Couldn't find channel or no channels available."
msgstr "Kanavaa ei löydy tai yhtään kanavaa ei ole saatavilla."
diff --git a/po/fr_FR.po b/po/fr_FR.po
index b0ea638..d093eca 100644
--- a/po/fr_FR.po
+++ b/po/fr_FR.po
@@ -61,6 +61,9 @@ msgstr "Programmation non définit"
msgid "On archive DVD No."
msgstr "Sur le DVD archive no°"
+msgid "On archive HDD No."
+msgstr "Sur le HDD archive noä"
+
msgid "Couldn't find channel or no channels available."
msgstr "Impossible de trouver la chaîne ou pas de chaînes disponibles."
diff --git a/po/hr_HR.po b/po/hr_HR.po
index 147e4de..bbcfbc2 100644
--- a/po/hr_HR.po
+++ b/po/hr_HR.po
@@ -59,6 +59,9 @@ msgstr ""
msgid "On archive DVD No."
msgstr ""
+msgid "On archive HDD No."
+msgstr ""
+
msgid "Couldn't find channel or no channels available."
msgstr ""
diff --git a/po/hu_HU.po b/po/hu_HU.po
index 75bdb96..4dd36ae 100644
--- a/po/hu_HU.po
+++ b/po/hu_HU.po
@@ -59,6 +59,9 @@ msgstr ""
msgid "On archive DVD No."
msgstr ""
+msgid "On archive HDD No."
+msgstr ""
+
msgid "Couldn't find channel or no channels available."
msgstr ""
diff --git a/po/it_IT.po b/po/it_IT.po
index 643e272..2f0c30d 100755..100644
--- a/po/it_IT.po
+++ b/po/it_IT.po
@@ -64,6 +64,9 @@ msgstr "Timer non definito"
msgid "On archive DVD No."
msgstr "In archivio DVD No."
+msgid "On archive HDD No."
+msgstr "In archivio HDD No."
+
msgid "Couldn't find channel or no channels available."
msgstr "Impossibile trovare canale o canali disponibili."
diff --git a/po/lt_LT.po b/po/lt_LT.po
index 30805db..500fcbf 100644
--- a/po/lt_LT.po
+++ b/po/lt_LT.po
@@ -58,6 +58,10 @@ msgstr "Laikmatis nenustatytas"
msgid "On archive DVD No."
msgstr "DVB Nr."
+#, fuzzy
+msgid "On archive HDD No."
+msgstr "DVB Nr."
+
msgid "Couldn't find channel or no channels available."
msgstr "Nerastas arba neegzistuojantis kanalas."
diff --git a/po/nl_NL.po b/po/nl_NL.po
index ed5b0bd..811504c 100644
--- a/po/nl_NL.po
+++ b/po/nl_NL.po
@@ -61,6 +61,9 @@ msgstr ""
msgid "On archive DVD No."
msgstr ""
+msgid "On archive HDD No."
+msgstr ""
+
msgid "Couldn't find channel or no channels available."
msgstr ""
diff --git a/po/nn_NO.po b/po/nn_NO.po
index 725b6f6..6be7d4b 100644
--- a/po/nn_NO.po
+++ b/po/nn_NO.po
@@ -59,6 +59,9 @@ msgstr ""
msgid "On archive DVD No."
msgstr ""
+msgid "On archive HDD No."
+msgstr ""
+
msgid "Couldn't find channel or no channels available."
msgstr ""
diff --git a/po/pl_PL.po b/po/pl_PL.po
index f792346..f04ee69 100644
--- a/po/pl_PL.po
+++ b/po/pl_PL.po
@@ -58,6 +58,9 @@ msgstr ""
msgid "On archive DVD No."
msgstr ""
+msgid "On archive HDD No."
+msgstr ""
+
msgid "Couldn't find channel or no channels available."
msgstr ""
diff --git a/po/pt_PT.po b/po/pt_PT.po
index e77b864..0c6ed4e 100644
--- a/po/pt_PT.po
+++ b/po/pt_PT.po
@@ -58,6 +58,9 @@ msgstr ""
msgid "On archive DVD No."
msgstr ""
+msgid "On archive HDD No."
+msgstr ""
+
msgid "Couldn't find channel or no channels available."
msgstr ""
diff --git a/po/ro_RO.po b/po/ro_RO.po
index 1fcb40a..067e978 100644
--- a/po/ro_RO.po
+++ b/po/ro_RO.po
@@ -59,6 +59,9 @@ msgstr ""
msgid "On archive DVD No."
msgstr ""
+msgid "On archive HDD No."
+msgstr ""
+
msgid "Couldn't find channel or no channels available."
msgstr ""
diff --git a/po/ru_RU.po b/po/ru_RU.po
index ab3f629..75bb5fb 100644
--- a/po/ru_RU.po
+++ b/po/ru_RU.po
@@ -58,6 +58,9 @@ msgstr ""
msgid "On archive DVD No."
msgstr ""
+msgid "On archive HDD No."
+msgstr ""
+
msgid "Couldn't find channel or no channels available."
msgstr ""
diff --git a/po/sl_SI.po b/po/sl_SI.po
index 153d552..4ebaf08 100644
--- a/po/sl_SI.po
+++ b/po/sl_SI.po
@@ -59,6 +59,9 @@ msgstr ""
msgid "On archive DVD No."
msgstr ""
+msgid "On archive HDD No."
+msgstr ""
+
msgid "Couldn't find channel or no channels available."
msgstr ""
diff --git a/po/sv_SE.po b/po/sv_SE.po
index 509dcfc..875e2f0 100644
--- a/po/sv_SE.po
+++ b/po/sv_SE.po
@@ -59,6 +59,9 @@ msgstr ""
msgid "On archive DVD No."
msgstr ""
+msgid "On archive HDD No."
+msgstr ""
+
msgid "Couldn't find channel or no channels available."
msgstr ""
diff --git a/po/tr_TR.po b/po/tr_TR.po
index 210746a..a500dca 100644
--- a/po/tr_TR.po
+++ b/po/tr_TR.po
@@ -59,6 +59,9 @@ msgstr ""
msgid "On archive DVD No."
msgstr ""
+msgid "On archive HDD No."
+msgstr ""
+
msgid "Couldn't find channel or no channels available."
msgstr ""
diff --git a/recman.cpp b/recman.cpp
index 3e9b00d..1f6f40f 100644
--- a/recman.cpp
+++ b/recman.cpp
@@ -1,5 +1,4 @@
#include <unistd.h>
-#include <cstring>
#include <string>
#include <sstream>
#include <fstream>
@@ -13,6 +12,7 @@
#include "recman.h"
#define INDEXFILESUFFIX "/index.vdr"
+#define LENGTHFILESUFFIX "/length.vdr"
using namespace std::tr1;
using namespace std;
@@ -101,24 +101,28 @@ namespace vdrlive {
Recordings.DelByName(name.c_str());
}
- bool RecordingsManager::IsArchived(cRecording const * recording)
+ int RecordingsManager::GetArchiveType(cRecording const * recording)
{
string filename = recording->FileName();
- string vdrFile = filename + "/001.vdr";
- if (0 == access(vdrFile.c_str(), R_OK))
- return false;
-
- filename += "/dvd.vdr";
- return (0 == access(filename.c_str(), R_OK));
+ string dvdFile = filename + "/dvd.vdr";
+ if (0 == access(dvdFile.c_str(), R_OK)) {
+ return 1;
+ }
+ string hddFile = filename + "/hdd.vdr";
+ if (0 == access(hddFile.c_str(), R_OK)) {
+ return 2;
+ }
+ return 0;
}
- string const RecordingsManager::GetArchiveId(cRecording const * recording)
+ string const RecordingsManager::GetArchiveId(cRecording const * recording, int archiveType)
{
string filename = recording->FileName();
- filename += "/dvd.vdr";
- ifstream dvd(filename.c_str());
+ if (archiveType==1) {
+ string dvdFile = filename + "/dvd.vdr";
+ ifstream dvd(dvdFile.c_str());
if (dvd) {
string archiveDisc;
@@ -130,17 +134,35 @@ namespace vdrlive {
}
return archiveDisc;
}
+ } else if(archiveType==2) {
+ string hddFile = filename + "/hdd.vdr";
+ ifstream hdd(hddFile.c_str());
+
+ if (hdd) {
+ string archiveDisc;
+ hdd >> archiveDisc;
+ return archiveDisc;
+ }
+ }
return "";
}
string const RecordingsManager::GetArchiveDescr(cRecording const * recording)
{
+ int archiveType;
string archived;
- if (IsArchived(recording)) {
+ archiveType = GetArchiveType(recording);
+ if (archiveType==1) {
archived += " [";
archived += tr("On archive DVD No.");
archived += ": ";
- archived += GetArchiveId(recording);
+ archived += GetArchiveId(recording, archiveType);
+ archived += "]";
+ } else if (archiveType==2) {
+ archived += " [";
+ archived += tr("On archive HDD No.");
+ archived += ": ";
+ archived += GetArchiveId(recording, archiveType);
archived += "]";
}
return archived;
@@ -266,6 +288,13 @@ namespace vdrlive {
}
delete index;
#endif
+ if (RecLength == 0) {
+ cString lengthFile = cString::sprintf("%s%s", m_recording->FileName(), LENGTHFILESUFFIX);
+ ifstream length(*lengthFile);
+ if(length)
+ length >> RecLength;
+ }
+
return RecLength;
}
diff --git a/recman.h b/recman.h
index 8044d38..e04c16b 100644
--- a/recman.h
+++ b/recman.h
@@ -78,14 +78,14 @@ namespace vdrlive {
* Determine wether the recording has been archived on
* removable media (e.g. DVD-ROM)
*/
- static bool IsArchived(cRecording const * recording);
+ static int GetArchiveType(cRecording const * recording);
/**
* Provide an identification of the removable media
* (e.g. DVD-ROM Number or Name) where the recording has
* been archived.
*/
- static std::string const GetArchiveId(cRecording const * recording);
+ static std::string const GetArchiveId(cRecording const * recording, int archiveType);
static std::string const GetArchiveDescr(cRecording const * recording);