mirror of
https://github.com/VDR4Arch/vdr.git
synced 2023-10-10 13:36:52 +02:00
Fixed sorting recordings by time in the Recordings menu if "Setup/OSD/Recording directories" is set to "no"
This commit is contained in:
parent
9eda923269
commit
6a9502ab17
4
HISTORY
4
HISTORY
@ -8170,7 +8170,7 @@ Video Disk Recorder Revision History
|
|||||||
- Fixed a superfluous call to the skin's SetRecording() function after renaming a
|
- Fixed a superfluous call to the skin's SetRecording() function after renaming a
|
||||||
recording (reported by Christoph Haubrich).
|
recording (reported by Christoph Haubrich).
|
||||||
|
|
||||||
2014-01-26: Version 2.1.5
|
2014-01-29: Version 2.1.5
|
||||||
|
|
||||||
- Now checking whether the primary device actually has a decoder before retuning the
|
- Now checking whether the primary device actually has a decoder before retuning the
|
||||||
current channel after a change in its parameters. This fixes broken recordings on
|
current channel after a change in its parameters. This fixes broken recordings on
|
||||||
@ -8179,3 +8179,5 @@ Video Disk Recorder Revision History
|
|||||||
of actual video TS packets in cTsPayload in order to be able to record channels that
|
of actual video TS packets in cTsPayload in order to be able to record channels that
|
||||||
sometimes need even more than 10 TS packets for detecting frame borders (reported by
|
sometimes need even more than 10 TS packets for detecting frame borders (reported by
|
||||||
Oliver Endriss).
|
Oliver Endriss).
|
||||||
|
- Fixed sorting recordings by time in the Recordings menu if "Setup/OSD/Recording
|
||||||
|
directories" is set to "no".
|
||||||
|
4
menu.c
4
menu.c
@ -4,7 +4,7 @@
|
|||||||
* See the main source file 'vdr.c' for copyright information and
|
* See the main source file 'vdr.c' for copyright information and
|
||||||
* how to reach the author.
|
* how to reach the author.
|
||||||
*
|
*
|
||||||
* $Id: menu.c 3.16 2014/01/25 12:40:28 kls Exp $
|
* $Id: menu.c 3.17 2014/01/29 10:41:10 kls Exp $
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include "menu.h"
|
#include "menu.h"
|
||||||
@ -3024,7 +3024,7 @@ eOSState cMenuSetupOSD::ProcessKey(eKeys Key)
|
|||||||
ModifiedAppearance = true;
|
ModifiedAppearance = true;
|
||||||
if (strcmp(data.FontFix, Setup.FontFix) || !DoubleEqual(data.FontFixSizeP, Setup.FontFixSizeP))
|
if (strcmp(data.FontFix, Setup.FontFix) || !DoubleEqual(data.FontFixSizeP, Setup.FontFixSizeP))
|
||||||
ModifiedAppearance = true;
|
ModifiedAppearance = true;
|
||||||
if (data.AlwaysSortFoldersFirst != Setup.AlwaysSortFoldersFirst)
|
if (data.AlwaysSortFoldersFirst != Setup.AlwaysSortFoldersFirst || data.RecordingDirs != Setup.RecordingDirs)
|
||||||
Recordings.ClearSortNames();
|
Recordings.ClearSortNames();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
26
recording.c
26
recording.c
@ -4,7 +4,7 @@
|
|||||||
* See the main source file 'vdr.c' for copyright information and
|
* See the main source file 'vdr.c' for copyright information and
|
||||||
* how to reach the author.
|
* how to reach the author.
|
||||||
*
|
*
|
||||||
* $Id: recording.c 3.13 2014/01/18 12:54:56 kls Exp $
|
* $Id: recording.c 3.14 2014/01/29 10:38:46 kls Exp $
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include "recording.h"
|
#include "recording.h"
|
||||||
@ -969,14 +969,22 @@ char *cRecording::SortName(void) const
|
|||||||
{
|
{
|
||||||
char **sb = (RecordingsSortMode == rsmName) ? &sortBufferName : &sortBufferTime;
|
char **sb = (RecordingsSortMode == rsmName) ? &sortBufferName : &sortBufferTime;
|
||||||
if (!*sb) {
|
if (!*sb) {
|
||||||
char *s = strdup(FileName() + strlen(cVideoDirectory::Name()));
|
if (RecordingsSortMode == rsmTime && !Setup.RecordingDirs) {
|
||||||
if (RecordingsSortMode != rsmName || Setup.AlwaysSortFoldersFirst)
|
char buf[32];
|
||||||
s = StripEpisodeName(s, RecordingsSortMode != rsmName);
|
struct tm tm_r;
|
||||||
strreplace(s, '/', '0'); // some locales ignore '/' when sorting
|
strftime(buf, sizeof(buf), "%Y%m%d%H%I", localtime_r(&start, &tm_r));
|
||||||
int l = strxfrm(NULL, s, 0) + 1;
|
*sb = strdup(buf);
|
||||||
*sb = MALLOC(char, l);
|
}
|
||||||
strxfrm(*sb, s, l);
|
else {
|
||||||
free(s);
|
char *s = strdup(FileName() + strlen(cVideoDirectory::Name()));
|
||||||
|
if (RecordingsSortMode != rsmName || Setup.AlwaysSortFoldersFirst)
|
||||||
|
s = StripEpisodeName(s, RecordingsSortMode != rsmName);
|
||||||
|
strreplace(s, '/', '0'); // some locales ignore '/' when sorting
|
||||||
|
int l = strxfrm(NULL, s, 0) + 1;
|
||||||
|
*sb = MALLOC(char, l);
|
||||||
|
strxfrm(*sb, s, l);
|
||||||
|
free(s);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
return *sb;
|
return *sb;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user