summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--config.c2
-rw-r--r--config.h7
-rw-r--r--po/ca_ES.po14
-rw-r--r--po/de_DE.po14
-rw-r--r--po/it_IT.po14
-rw-r--r--po/ru_RU.po14
-rw-r--r--po/sk_SK.po14
-rw-r--r--recmanager.c17
-rw-r--r--setup.c10
-rw-r--r--setup.h1
-rw-r--r--tools.c1
11 files changed, 98 insertions, 10 deletions
diff --git a/config.c b/config.c
index 71895aa..502e474 100644
--- a/config.c
+++ b/config.c
@@ -34,6 +34,7 @@ cTVGuideConfig::cTVGuideConfig() {
channelJumpMode = eNumJump;
jumpChannels = 0;
blueKeyMode = 2;
+ addSubtitleToTimer = 1;
closeOnSwitch = 1;
numkeyMode = 0;
useRemoteTimers = 0;
@@ -295,6 +296,7 @@ bool cTVGuideConfig::SetupParse(const char *Name, const char *Value) {
else if (strcmp(Name, "footerHeightPercent") == 0) footerHeightPercent = atoi(Value);
else if (strcmp(Name, "instRecFolderMode") == 0) instRecFolderMode = atoi(Value);
else if (strcmp(Name, "instRecFixedFolder") == 0) instRecFixedFolder = Value;
+ else if (strcmp(Name, "addSubtitleToTimer") == 0) addSubtitleToTimer = atoi(Value);
else if (strcmp(Name, "favWhatsOnNow") == 0) favWhatsOnNow = atoi(Value);
else if (strcmp(Name, "favWhatsOnNext") == 0) favWhatsOnNext = atoi(Value);
else if (strcmp(Name, "favUseTime1") == 0) favUseTime1 = atoi(Value);
diff --git a/config.h b/config.h
index 9fe9bdf..472eed8 100644
--- a/config.h
+++ b/config.h
@@ -43,6 +43,12 @@ enum eInstRecFolderMode {
eFolderFixed
};
+typedef enum {
+ addSubtitleNever = 0,
+ addSubtitleSmart,
+ addSubtitleAlways
+} addSubtitleToTimerMode;
+
class cTVGuideConfig {
private:
cString checkSlashAtEnd(std::string path);
@@ -82,6 +88,7 @@ class cTVGuideConfig {
int channelJumpMode;
int jumpChannels;
int blueKeyMode;
+ int addSubtitleToTimer;
int closeOnSwitch;
int numkeyMode;
int useRemoteTimers;
diff --git a/po/ca_ES.po b/po/ca_ES.po
index 8007492..77a9b1a 100644
--- a/po/ca_ES.po
+++ b/po/ca_ES.po
@@ -3,7 +3,7 @@ msgid ""
msgstr ""
"Project-Id-Version: vdr-tvguide 0.0.1\n"
"Report-Msgid-Bugs-To: <see README>\n"
-"POT-Creation-Date: 2020-02-12 17:37+0100\n"
+"POT-Creation-Date: 2020-02-17 14:30+0100\n"
"PO-Revision-Date: 2013-09-21 17:49+0200\n"
"Last-Translator: My friend <Sampep> Thanks David <Gabychan> <gbonich@gmail.com>\n"
"Language-Team: \n"
@@ -891,15 +891,27 @@ msgstr ""
msgid "Use fixed folder"
msgstr ""
+msgid "smart"
+msgstr ""
+
+msgid "Instant recording:"
+msgstr ""
+
msgid "Folder for instant Recordings"
msgstr ""
msgid "Folder"
msgstr ""
+msgid "Add episode to manual timers"
+msgstr ""
+
msgid "Use Remotetimers"
msgstr "Utilitza temporitzadors remots"
+msgid "Favorites:"
+msgstr ""
+
msgid "Limit channels in favorites"
msgstr ""
diff --git a/po/de_DE.po b/po/de_DE.po
index 81138ce..a654efd 100644
--- a/po/de_DE.po
+++ b/po/de_DE.po
@@ -3,7 +3,7 @@ msgid ""
msgstr ""
"Project-Id-Version: vdr-tvguide 0.0.1\n"
"Report-Msgid-Bugs-To: <see README>\n"
-"POT-Creation-Date: 2020-02-12 17:37+0100\n"
+"POT-Creation-Date: 2020-02-17 14:30+0100\n"
"PO-Revision-Date: 2012-08-25 17:49+0200\n"
"Last-Translator: Horst\n"
"Language-Team: \n"
@@ -888,15 +888,27 @@ msgstr "Verzeichnis aus Liste auswählen"
msgid "Use fixed folder"
msgstr "Festes Verzeichnis benutzen"
+msgid "smart"
+msgstr "intelligent"
+
+msgid "Instant recording:"
+msgstr "Sofortaufnahmen:"
+
msgid "Folder for instant Recordings"
msgstr "Verzeichnis für Sofortaufnahmen"
msgid "Folder"
msgstr "Verzeichnis"
+msgid "Add episode to manual timers"
+msgstr "Untertitel in manuellen Timern"
+
msgid "Use Remotetimers"
msgstr "RemoteTimers benutzen"
+msgid "Favorites:"
+msgstr "Favoriten:"
+
msgid "Limit channels in favorites"
msgstr "Kanäle in Favoriten beschränken"
diff --git a/po/it_IT.po b/po/it_IT.po
index 0931b0c..a2ef64b 100644
--- a/po/it_IT.po
+++ b/po/it_IT.po
@@ -3,7 +3,7 @@ msgid ""
msgstr ""
"Project-Id-Version: vdr-tvguide 0.0.1\n"
"Report-Msgid-Bugs-To: <see README>\n"
-"POT-Creation-Date: 2020-02-12 17:37+0100\n"
+"POT-Creation-Date: 2020-02-17 14:30+0100\n"
"PO-Revision-Date: 2012-08-25 17:49+0200\n"
"Last-Translator: fiveten_59\n"
"Language-Team: \n"
@@ -888,15 +888,27 @@ msgstr "Scegli dall'elenco cartelle"
msgid "Use fixed folder"
msgstr "Usa cartella fissa"
+msgid "smart"
+msgstr "intelligente"
+
+msgid "Instant recording:"
+msgstr ""
+
msgid "Folder for instant Recordings"
msgstr "Cartella per la registrazione immediata"
msgid "Folder"
msgstr "Cartella"
+msgid "Add episode to manual timers"
+msgstr "Aggiungi episodi ai timer manuali"
+
msgid "Use Remotetimers"
msgstr "Usa Remotetimers"
+msgid "Favorites:"
+msgstr ""
+
msgid "Limit channels in favorites"
msgstr "Limite dei canali nei favoriti"
diff --git a/po/ru_RU.po b/po/ru_RU.po
index 67f05dd..1d42229 100644
--- a/po/ru_RU.po
+++ b/po/ru_RU.po
@@ -3,7 +3,7 @@ msgid ""
msgstr ""
"Project-Id-Version: vdr-tvguide 1.0.0\n"
"Report-Msgid-Bugs-To: <see README>\n"
-"POT-Creation-Date: 2020-02-12 17:37+0100\n"
+"POT-Creation-Date: 2020-02-17 14:30+0100\n"
"PO-Revision-Date: 2013-09-25 17:49+0400\n"
"Last-Translator: AmiD, ilya\n"
"Language-Team: Russia-Cherepovets(wm.amid@gmail.com)\n"
@@ -888,15 +888,27 @@ msgstr ""
msgid "Use fixed folder"
msgstr ""
+msgid "smart"
+msgstr ""
+
+msgid "Instant recording:"
+msgstr ""
+
msgid "Folder for instant Recordings"
msgstr ""
msgid "Folder"
msgstr ""
+msgid "Add episode to manual timers"
+msgstr ""
+
msgid "Use Remotetimers"
msgstr "RemoteTimers benutzen"
+msgid "Favorites:"
+msgstr ""
+
msgid "Limit channels in favorites"
msgstr ""
diff --git a/po/sk_SK.po b/po/sk_SK.po
index 3283b9a..de867a7 100644
--- a/po/sk_SK.po
+++ b/po/sk_SK.po
@@ -3,7 +3,7 @@ msgid ""
msgstr ""
"Project-Id-Version: vdr-tvguide 1.1.0\n"
"Report-Msgid-Bugs-To: <see README>\n"
-"POT-Creation-Date: 2020-02-12 17:37+0100\n"
+"POT-Creation-Date: 2020-02-17 14:30+0100\n"
"PO-Revision-Date: 2013-09-15 00:12+0100\n"
"Last-Translator: Milan Hrala <hrala.milan@gmail.com>\n"
"Language-Team: \n"
@@ -888,15 +888,27 @@ msgstr ""
msgid "Use fixed folder"
msgstr ""
+msgid "smart"
+msgstr "chytrý"
+
+msgid "Instant recording:"
+msgstr ""
+
msgid "Folder for instant Recordings"
msgstr ""
msgid "Folder"
msgstr ""
+msgid "Add episode to manual timers"
+msgstr "Prida¿ epizódy do ru¿ného ¿asova¿a"
+
msgid "Use Remotetimers"
msgstr "Pou¾i» vzdialený plánovaè"
+msgid "Favorites:"
+msgstr ""
+
msgid "Limit channels in favorites"
msgstr ""
diff --git a/recmanager.c b/recmanager.c
index 18e38e9..1c56c97 100644
--- a/recmanager.c
+++ b/recmanager.c
@@ -175,12 +175,25 @@ void cRecManager::SetTimerPath(cTimer *timer, const cEvent *event, std::string p
return;
}
//Set choosen path
+ bool addSubtitle = false;
+ if (!isempty(event->ShortText())) { // add subtitle if present
+ addSubtitle = (config.addSubtitleToTimer != addSubtitleNever);
+ if (config.addSubtitleToTimer == addSubtitleSmart)
+ if (event->Duration() > 80 * 60)
+ addSubtitle = false;
+ }
cString newFileName;
if (path.size() > 0) {
std::replace(path.begin(), path.end(), '/', '~');
- newFileName = cString::sprintf("%s~%s", path.c_str(), timer->File());
+ if (addSubtitle)
+ newFileName = cString::sprintf("%s~%s~%s", path.c_str(), event->Title(), event->ShortText());
+ else
+ newFileName = cString::sprintf("%s~%s", path.c_str(), timer->File());
} else {
- newFileName = event->Title();
+ if (addSubtitle)
+ newFileName = cString::sprintf("%s~%s", event->Title(), event->ShortText());
+ else
+ newFileName = event->Title();
}
timer->SetFile(*newFileName);
}
diff --git a/setup.c b/setup.c
index c2c111c..fa8b0a8 100644
--- a/setup.c
+++ b/setup.c
@@ -108,6 +108,7 @@ void cTvguideSetup::Store(void) {
SetupStore("footerHeightPercent", config.footerHeightPercent);
SetupStore("instRecFolderMode", config.instRecFolderMode);
SetupStore("instRecFixedFolder", config.instRecFixedFolder.c_str());
+ SetupStore("AddSubtitleToTimerMode", config.addSubtitleToTimer);
SetupStore("favWhatsOnNow", config.favWhatsOnNow);
SetupStore("favWhatsOnNext", config.favWhatsOnNext);
SetupStore("favUseTime1", config.favUseTime1);
@@ -410,6 +411,9 @@ cMenuSetupFavorites::cMenuSetupFavorites(cTVGuideConfig* data) : cMenuSetupSubM
recFolderMode[1] = tr("Select from folder list");
recFolderMode[2] = tr("Use fixed folder");
strn0cpy(fixedFolder, data->instRecFixedFolder.c_str(), sizeof(fixedFolder));
+ addSubtitleMode[0] = tr("never");
+ addSubtitleMode[1] = tr("smart");
+ addSubtitleMode[2] = tr("always");
switchModeItems[0] = (tr("switch"));
switchModeItems[1] = (tr("announce only"));
switchModeItems[2] = (tr("ask for switch"));
@@ -420,13 +424,15 @@ void cMenuSetupFavorites::Set(void) {
int currentItem = Current();
Clear();
- Add(new cMenuEditStraItem(tr("Folder for instant Recordings"), &tmpConfig->instRecFolderMode, 3, recFolderMode));
+ Add(new cOsdItem(tr("Instant recording:"), osUnknown, false));
+ Add(new cMenuEditStraItem(tr("Folder for instant Recordings"), &tmpConfig->instRecFolderMode, 3, recFolderMode));
if (tmpConfig->instRecFolderMode == eFolderFixed) {
Add(new cMenuEditStrItem(cString::sprintf("%s%s", *indent, tr("Folder")), fixedFolder, sizeof(fixedFolder), trVDR(FileNameChars)));
}
+ Add(new cMenuEditStraItem(tr("Add episode to manual timers"), &tmpConfig->addSubtitleToTimer, 3, addSubtitleMode));
if (pRemoteTimers)
Add(new cMenuEditBoolItem(tr("Use Remotetimers"), &tmpConfig->useRemoteTimers));
-
+ Add(new cOsdItem(tr("Favorites:"), osUnknown, false));
Add(new cMenuEditBoolItem(tr("Limit channels in favorites"), &tmpConfig->favLimitChannels));
if (tmpConfig->favLimitChannels) {
Add(new cMenuEditChanItem(tr("Start Channel"), &tmpConfig->favStartChannel));
diff --git a/setup.h b/setup.h
index 77536cf..cfc5c07 100644
--- a/setup.h
+++ b/setup.h
@@ -70,6 +70,7 @@ class cMenuSetupFavorites : public cMenuSetupSubMenu {
char description3[256];
char description4[256];
const char * recFolderMode[3];
+ const char * addSubtitleMode[3];
const char * switchModeItems[3];
char fixedFolder[256];
void Set(void);
diff --git a/tools.c b/tools.c
index 04271d3..866929b 100644
--- a/tools.c
+++ b/tools.c
@@ -130,7 +130,6 @@ void ReadRecordingDirectories(std::vector<std::string> *folders, cList<cNestedIt
}
}
-
/****************************************************************************************
* DrawRoundedCorners
****************************************************************************************/