Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/lib/ui/src/filelist.c

    r2309891 raccdf882  
    349349                goto error;
    350350        }
    351 
    352         ui_file_list_clear_entries(flist);
    353351
    354352        if (str_cmp(ndir, "/") != 0) {
     
    424422}
    425423
    426 /** Return path to the current directory.
    427  *
    428  * @return Path to current directory or @c NULL if out of memory
    429  */
    430 char *ui_file_list_get_dir(ui_file_list_t *flist)
    431 {
    432         return str_dup(flist->dir);
    433 }
    434 
    435 /** Re-read file list from directory.
    436  *
    437  * @param flist File list
    438  * @return EOK on success or an error code
    439  */
    440 errno_t ui_file_list_refresh(ui_file_list_t *flist)
    441 {
    442         errno_t rc;
    443         ui_list_pos_t pos;
    444 
    445         ui_list_save_pos(flist->list, &pos);
    446         rc = ui_file_list_read_dir(flist, flist->dir);
    447         if (rc != EOK)
    448                 return rc;
    449         ui_list_restore_pos(flist->list, &pos);
    450         return EOK;
    451 }
    452 
    453424/** Sort file list entries.
    454425 *
     
    622593                return ENOMEM;
    623594
     595        ui_file_list_clear_entries(flist);
     596
    624597        rc = ui_file_list_read_dir(flist, dirname);
    625598        if (rc != EOK) {
Note: See TracChangeset for help on using the changeset viewer.