fn ui_refresh_itemview(siv: &mut Cursive, state: &mut AppState) {
    state.sel.clear();

    siv.call_on_id("itemview", |v: &mut SelectView<PathBuf>| {
        v.clear();
        for p in state.items_vis.iter() {
            let i = &state.items_all[p];
            v.add_item(i.name.clone(), p.clone());
        }
        v.sort_by_label();
    });

    ui_mark_itemview(siv, state);
    ui_refresh_tagsview(siv, state);
}
/// Refresh UI after an update to the items index
///
/// Also refreshes tags view to prevent it being obsolete.
Refresh UI after an update to the items index
Also refreshes tags view to prevent it being obsolete.
Refresh UI after an update to the items index Also refreshes tags view to prevent it being obsolete .
fn ui_refresh_itemview(siv: &mut Cursive, state: &mut AppState) {
    state.sel.clear();
    siv.call_on_id("itemview", |v: &mut SelectView<PathBuf>| {
        v.clear();
        for p in state.items_vis.iter() {
            let i = &state.items_all[p];
            v.add_item(i.name.clone(), p.clone());
        }
        v.sort_by_label();
    });
    ui_mark_itemview(siv, state);
    ui_refresh_tagsview(siv, state);
}
fn ui_refresh_itemview ( siv : & mut Cursive , state : & mut AppState ) { state . sel . clear ( ) ; siv . call_on_id ( " " , | v : & mut SelectView < PathBuf > | { v . clear ( ) ; for p in state . items_vis . iter ( ) { let i = & state . items_all [ p ] ; v . add_item ( i . name . clone ( ) , p . clone ( ) ) ; } v . sort_by_label ( ) ; } ) ; ui_mark_itemview ( siv , state ) ; ui_refresh_tagsview ( siv , state ) ; }
Refresh UI after an update to the items index
Also refreshes tags view to prevent it being obsolete.
Refresh UI after an update to the items index Also refreshes tags view to prevent it being obsolete .
siv
&mut Cursive
state
&mut AppState