diff options
author | Martin Prochnow <nordlicht@martins-kabuff.de> | 2006-12-04 11:35:54 +0100 |
---|---|---|
committer | Andreas Mair <andreas@vdr-developer.org> | 2006-12-04 11:35:54 +0100 |
commit | 01be0f47d4fcfce954f77a037f8ab4d5368c8fe7 (patch) | |
tree | c9ef3945e2f0303987e0770b6425efd5ebb4e5a4 /tools.c | |
parent | 978605b653893d76a6e34f923d74bb64dfb957ca (diff) | |
download | vdr-plugin-extrecmenu-01be0f47d4fcfce954f77a037f8ab4d5368c8fe7.tar.gz vdr-plugin-extrecmenu-01be0f47d4fcfce954f77a037f8ab4d5368c8fe7.tar.bz2 |
Version 0.12bv0.12b
- type of sorting (ascending/descending) selectable at the setup menu of the plugin
- 'Blue' also closes the info menu for a recording
Diffstat (limited to 'tools.c')
-rw-r--r-- | tools.c | 19 |
1 files changed, 16 insertions, 3 deletions
@@ -162,9 +162,18 @@ char *myRecListItem::StripEpisodeName(char *s) } t++; } - *s1=255; + if(mysetup.DescendSorting) + { + if(SortByName) + *s1=1; + else + *(s2+1)=255; + } + else + *s1=255; + if(s1&&s2&&!SortByName) - memmove(s1+1,s2,t-s2+1); + memmove(s1+1,s2,t-s2+1); return s; } @@ -176,7 +185,11 @@ int myRecListItem::Compare(const cListObject &ListObject)const char *s1=StripEpisodeName(strdup(filename+strlen(VideoDirectory))); char *s2=StripEpisodeName(strdup(item->filename+strlen(VideoDirectory))); - int compare=strcasecmp(s1,s2); + int compare; + if(mysetup.DescendSorting) + compare=strcasecmp(s2,s1); + else + compare=strcasecmp(s1,s2); free(s1); free(s2); |