diff options
Diffstat (limited to 'apps/tree.c')
-rw-r--r-- | apps/tree.c | 14 |
1 files changed, 6 insertions, 8 deletions
diff --git a/apps/tree.c b/apps/tree.c index ac64fff1f5..a8f40f3d07 100644 --- a/apps/tree.c +++ b/apps/tree.c | |||
@@ -272,8 +272,7 @@ void browse_root(void) | |||
272 | gui_buttonbar_set_display(&tree_buttonbar, &(screens[SCREEN_MAIN]) ); | 272 | gui_buttonbar_set_display(&tree_buttonbar, &(screens[SCREEN_MAIN]) ); |
273 | #endif | 273 | #endif |
274 | gui_synclist_init(&tree_lists, &tree_get_filename, &tc, false, 1); | 274 | gui_synclist_init(&tree_lists, &tree_get_filename, &tc, false, 1); |
275 | gui_synclist_set_icon_callback(&tree_lists, | 275 | gui_synclist_set_icon_callback(&tree_lists, &tree_get_fileicon); |
276 | global_settings.show_icons?&tree_get_fileicon:NULL); | ||
277 | /* not the best place for this call... but... */ | 276 | /* not the best place for this call... but... */ |
278 | root_menu(); | 277 | root_menu(); |
279 | } | 278 | } |
@@ -377,7 +376,7 @@ static int update_dir(void) | |||
377 | || global_settings.show_path_in_browser == SHOW_PATH_CURRENT) | 376 | || global_settings.show_path_in_browser == SHOW_PATH_CURRENT) |
378 | { | 377 | { |
379 | gui_synclist_set_title(&tree_lists, tagtree_get_title(&tc), | 378 | gui_synclist_set_title(&tree_lists, tagtree_get_title(&tc), |
380 | global_settings.show_icons?filetype_get_icon(ATTR_DIRECTORY):(ICON)NULL); | 379 | filetype_get_icon(ATTR_DIRECTORY)); |
381 | } | 380 | } |
382 | else | 381 | else |
383 | { | 382 | { |
@@ -391,7 +390,7 @@ static int update_dir(void) | |||
391 | if (global_settings.show_path_in_browser == SHOW_PATH_FULL) | 390 | if (global_settings.show_path_in_browser == SHOW_PATH_FULL) |
392 | { | 391 | { |
393 | gui_synclist_set_title(&tree_lists, tc.currdir, | 392 | gui_synclist_set_title(&tree_lists, tc.currdir, |
394 | global_settings.show_icons?filetype_get_icon(ATTR_DIRECTORY):(ICON)NULL); | 393 | filetype_get_icon(ATTR_DIRECTORY)); |
395 | } | 394 | } |
396 | else if (global_settings.show_path_in_browser == SHOW_PATH_CURRENT) | 395 | else if (global_settings.show_path_in_browser == SHOW_PATH_CURRENT) |
397 | { | 396 | { |
@@ -400,11 +399,11 @@ static int update_dir(void) | |||
400 | { | 399 | { |
401 | /* Display "Files" for the root dir */ | 400 | /* Display "Files" for the root dir */ |
402 | gui_synclist_set_title(&tree_lists, str(LANG_DIR_BROWSER), | 401 | gui_synclist_set_title(&tree_lists, str(LANG_DIR_BROWSER), |
403 | global_settings.show_icons?filetype_get_icon(ATTR_DIRECTORY):(ICON)NULL); | 402 | filetype_get_icon(ATTR_DIRECTORY)); |
404 | } | 403 | } |
405 | else | 404 | else |
406 | gui_synclist_set_title(&tree_lists, title, | 405 | gui_synclist_set_title(&tree_lists, title, |
407 | global_settings.show_icons?filetype_get_icon(ATTR_DIRECTORY):(ICON)NULL); | 406 | filetype_get_icon(ATTR_DIRECTORY)); |
408 | } | 407 | } |
409 | else | 408 | else |
410 | { | 409 | { |
@@ -414,8 +413,7 @@ static int update_dir(void) | |||
414 | } | 413 | } |
415 | 414 | ||
416 | gui_synclist_set_nb_items(&tree_lists, tc.filesindir); | 415 | gui_synclist_set_nb_items(&tree_lists, tc.filesindir); |
417 | gui_synclist_set_icon_callback(&tree_lists, | 416 | gui_synclist_set_icon_callback(&tree_lists, tree_get_fileicon); |
418 | global_settings.show_icons?&tree_get_fileicon:NULL); | ||
419 | if( tc.selected_item >= tc.filesindir) | 417 | if( tc.selected_item >= tc.filesindir) |
420 | tc.selected_item=tc.filesindir-1; | 418 | tc.selected_item=tc.filesindir-1; |
421 | 419 | ||