summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorThomas Günther <tom@toms-cafe.de>2009-07-22 01:00:54 +0200
committerThomas Günther <tom@toms-cafe.de>2009-07-22 01:00:54 +0200
commit53c06587dee00deeabdf75b0f124816ce793fc7d (patch)
tree56c908bab4b1f13ea304400153346bc3bcb4159a
parent2f6dbf5a5ad81d3d59d6f7d058cf3eee6227e019 (diff)
downloadvdr-plugin-text2skin-53c06587dee00deeabdf75b0f124816ce793fc7d.tar.gz
vdr-plugin-text2skin-53c06587dee00deeabdf75b0f124816ce793fc7d.tar.bz2
Added ReplayMode "audiocd" (thanks to Björn Sturzrehm - closes #138)
-rw-r--r--HISTORY1
-rw-r--r--render.c3
-rw-r--r--status.c4
-rw-r--r--status.h3
4 files changed, 8 insertions, 3 deletions
diff --git a/HISTORY b/HISTORY
index 6b0e89a..0384f0f 100644
--- a/HISTORY
+++ b/HISTORY
@@ -97,6 +97,7 @@ ____-__-__: Version 1.3
closes #150)
- Updated Italian language texts (thanks to Diego Pierotto / closes #153)
- Fixed resetting of replay information (closes #156)
+- Added ReplayMode "audiocd" (thanks to Björn Sturzrehm - closes #138)
2009-06-01: Version 1.2
diff --git a/render.c b/render.c
index 6efd473..4cce312 100644
--- a/render.c
+++ b/render.c
@@ -772,7 +772,8 @@ cxType cText2SkinRender::GetToken(const txToken &Token)
Dprintf("MenuTitle 'clean' result: |%s|\n", res.String().c_str());
}
else if (Token.Type == tReplayTitle) {
- if (Text2SkinStatus.ReplayMode() == cText2SkinStatus::replayMP3) {
+ if (Text2SkinStatus.ReplayMode() == cText2SkinStatus::replayMP3
+ && str[0] == '[' && str[3] == ']') {
str.erase(0, 4);
res = str;
}
diff --git a/status.c b/status.c
index 63c9f70..e59764e 100644
--- a/status.c
+++ b/status.c
@@ -10,7 +10,7 @@
#include <vdr/menu.h>
const std::string ReplayNames[__REPLAY_COUNT__] =
- { "", "normal", "mp3", "mplayer", "dvd", "vcd", "image" };
+ { "", "normal", "mp3", "mplayer", "dvd", "vcd", "image", "audiocd" };
cText2SkinStatus Text2SkinStatus;
@@ -70,6 +70,8 @@ void cText2SkinStatus::Replaying(const cControl* /*Control*/, const char *Name,
mReplayMode = replayMPlayer;
else if (strncmp(Name, "[image]", 7) == 0)
mReplayMode = replayImage;
+ else if (strncmp(Name, "[cdda]", 6) == 0)
+ mReplayMode = replayAudioCd;
else if (strlen(Name) > 7) {
int i, n;
for (i = 0, n = 0; Name[i]; ++i) {
diff --git a/status.h b/status.h
index f759645..07e9b73 100644
--- a/status.h
+++ b/status.h
@@ -20,8 +20,9 @@ public:
replayDVD,
replayVCD,
replayImage,
+ replayAudioCd,
-#define __REPLAY_COUNT__ (cText2SkinStatus::replayImage+1)
+#define __REPLAY_COUNT__ (cText2SkinStatus::replayAudioCd+1)
};
typedef std::string tRecordingInfo;