diff options
Diffstat (limited to 'apps')
-rw-r--r-- | apps/tree.c | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/apps/tree.c b/apps/tree.c index 7a7db305cb..4e408b1be3 100644 --- a/apps/tree.c +++ b/apps/tree.c | |||
@@ -146,9 +146,12 @@ static int showdir(char *path, int start) | |||
146 | len = strlen(dircacheptr[i]->name); | 146 | len = strlen(dircacheptr[i]->name); |
147 | 147 | ||
148 | #ifdef HAVE_LCD_BITMAP | 148 | #ifdef HAVE_LCD_BITMAP |
149 | if ( dircacheptr[i]->file ) | 149 | if ( dircacheptr[i]->file ) { |
150 | icon_type=File; | 150 | if(!strcmp(&dircacheptr[i]->name[len-4], ".m3u")) |
151 | else | 151 | icon_type = Playlist; |
152 | else | ||
153 | icon_type=File; | ||
154 | } else | ||
152 | icon_type=Folder; | 155 | icon_type=Folder; |
153 | lcd_bitmap(bitmap_icons_6x8[icon_type], | 156 | lcd_bitmap(bitmap_icons_6x8[icon_type], |
154 | 6, MARGIN_Y+(i-start)*LINE_HEIGTH, 6, 8, true); | 157 | 6, MARGIN_Y+(i-start)*LINE_HEIGTH, 6, 8, true); |
@@ -298,7 +301,8 @@ bool dirbrowse(char *root) | |||
298 | lcd_stop_scroll(); | 301 | lcd_stop_scroll(); |
299 | if((len > 4) && | 302 | if((len > 4) && |
300 | !strcmp(&dircacheptr[dircursor+start]->name[len-4], | 303 | !strcmp(&dircacheptr[dircursor+start]->name[len-4], |
301 | ".m3u")) { | 304 | ".m3u")) |
305 | { | ||
302 | playing = 2; | 306 | playing = 2; |
303 | play_list(currdir, dircacheptr[dircursor+start]->name); | 307 | play_list(currdir, dircacheptr[dircursor+start]->name); |
304 | } | 308 | } |