From 0f3cf887c868ace108e814bd31fb3bffa1e6568a Mon Sep 17 00:00:00 2001 From: anbr Date: Sat, 26 Oct 2013 16:56:20 +0200 Subject: Fix display wrong time for HD recording if they greater than one hour (Close #1568) --- HISTORY | 2 ++ watch.c | 8 ++++++++ 2 files changed, 10 insertions(+) diff --git a/HISTORY b/HISTORY index de3fed4..a9fab4a 100644 --- a/HISTORY +++ b/HISTORY @@ -1,6 +1,8 @@ VDR Plugin 'targavfd' Revision History ------------------------------------- +- Fix display wrong time for HD recording if they greater than one hour (Bug #1568) + 2013-04-12: Version 0.2.1 - On amd64 linker binds not libusb (Bug #1338) - Fix warning on amd64: format '%d' expects argument of type 'int'... [-Wformat] diff --git a/watch.c b/watch.c index 9a8cb72..29efe69 100644 --- a/watch.c +++ b/watch.c @@ -630,14 +630,22 @@ const char * cVFDWatch::FormatReplayTime(int current, int total, double dFrameRa if (total > 1) { if(g) { +#if VDRVERSNUM >= 10703 + snprintf(s, sizeof(s), "%s (%s)", (const char*)IndexToHMSF(current,false,dFrameRate), (const char*)IndexToHMSF(total,false,dFrameRate)); +#else snprintf(s, sizeof(s), "%s (%s)", (const char*)IndexToHMSF(current), (const char*)IndexToHMSF(total)); +#endif } else { snprintf(s, sizeof(s), "%02d:%02d (%02d:%02d)", cm, cs, tm, ts); } } else { if(g) { +#if VDRVERSNUM >= 10703 + snprintf(s, sizeof(s), "%s", (const char*)IndexToHMSF(current,false,dFrameRate)); +#else snprintf(s, sizeof(s), "%s", (const char*)IndexToHMSF(current)); +#endif } else { snprintf(s, sizeof(s), "%02d:%02d", cm, cs); } -- cgit v1.2.3