improve dir picker - don't auto cd

tzemanovic
Mar 6, 2026, 9:43 AM
JVNYA2MSZWSEE67MIF6GYJ72LTIMDAKPZ4HBL3KBWSA7Y7SSMNSQC

Dependencies

  • [2] YRGDFHAB project dir picker
  • [3] TMDH7GPV dir picker scrollables handling + confirmation
  • [4] LPSUBGUB add projects picker

Change contents

  • replacement in inflorescence_iced_widget/src/dir_picker.rs at line 156
    [2.3910][2.3910:3979]()
    let mut matches = if input.ends_with(PATH_SEP) {
    [2.3910]
    [2.3979]
    let ends_with_path_sep = input.ends_with(PATH_SEP);
    let mut matches = if ends_with_path_sep {
  • replacement in inflorescence_iced_widget/src/dir_picker.rs at line 161
    [2.4180][2.4180:4465]()
    if state.child_dirs.iter().any(|dir| {
    dir.file_name().map(|name| name.to_string_lossy())
    == Some(Cow::Borrowed(exact))
    }) {
    vec![input.to_string()]
    [2.4180]
    [2.4465]
    // We're looking for a case-insensitive match, but the
    // returned `matched` name has the actual file name case
    if let Some(matched) =
    state.child_dirs.iter().find_map(|dir| {
    dir.file_name()
    .and_then(|name| name.to_str())
    .and_then(|name| {
    (name.to_lowercase()
    == exact.to_lowercase())
    .then_some(name)
    })
    })
    {
    vec![matched.to_string()]
  • replacement in inflorescence_iced_widget/src/dir_picker.rs at line 181
    [2.4667][2.4667:4994]()
    // Change dir if there is only one match
    if matches.len() == 1 {
    let matched =
    state.current_dir.join(matches.pop().unwrap());
    state.input = String::default();
    change_dir(state, matched)
    [2.4667]
    [2.4994]
    // Change dir only if there are some matches
    if ends_with_path_sep {
    if !matches.is_empty() {
    let matched =
    state.current_dir.join(matches.pop().unwrap());
    state.input = String::default();
    change_dir(state, matched)
    } else {
    Task::none()
    }