diff options
author | Klaus Schmidinger <vdr@tvdr.de> | 2000-04-23 15:38:16 +0200 |
---|---|---|
committer | Klaus Schmidinger <vdr@tvdr.de> | 2000-04-23 15:38:16 +0200 |
commit | 160c6ec5eb369d309350e9fdf588e29d4ea215bd (patch) | |
tree | e3fc59f1dba568d3b2f895c6fca2626045a609dd /recording.c | |
parent | 88f13b1b296218589a44dac227964a8a47a75e50 (diff) | |
download | vdr-160c6ec5eb369d309350e9fdf588e29d4ea215bd.tar.gz vdr-160c6ec5eb369d309350e9fdf588e29d4ea215bd.tar.bz2 |
Implemented replay progress display
Diffstat (limited to 'recording.c')
-rw-r--r-- | recording.c | 21 |
1 files changed, 20 insertions, 1 deletions
diff --git a/recording.c b/recording.c index de202ce0..6d70bd49 100644 --- a/recording.c +++ b/recording.c @@ -4,7 +4,7 @@ * See the main source file 'osm.c' for copyright information and * how to reach the author. * - * $Id: recording.c 1.3 2000/04/16 15:47:45 kls Exp $ + * $Id: recording.c 1.4 2000/04/23 09:48:35 kls Exp $ */ #define _GNU_SOURCE @@ -140,12 +140,14 @@ cRecording::cRecording(const char *FileName) name[p - FileName] = 0; } } + titleBuffer = NULL; } cRecording::~cRecording() { delete fileName; delete name; + delete titleBuffer; } const char *cRecording::FileName(void) @@ -157,6 +159,23 @@ const char *cRecording::FileName(void) return fileName; } +const char *cRecording::Title(char Delimiter) +{ + delete titleBuffer; + titleBuffer = NULL; + struct tm *t = localtime(&start); + asprintf(&titleBuffer, "%02d.%02d.%04d%c%02d:%02d%c%s", + t->tm_mday, + t->tm_mon + 1, + t->tm_year + 1900, + Delimiter, + t->tm_hour, + t->tm_min, + Delimiter, + name); + return titleBuffer; +} + bool cRecording::Delete(void) { bool result = true; |