diff --git a/src-tauri/src/lib.rs b/src-tauri/src/lib.rs index f7703cb5..250f3c1b 100644 --- a/src-tauri/src/lib.rs +++ b/src-tauri/src/lib.rs @@ -5020,9 +5020,6 @@ struct Setup { inputs: Vec, inputs_error: Option, inputs_ready: bool, - /// The files it was set up with before, by name (Use My Previous Setup), when they're - /// remembered and it isn't set up now. - previous: Vec, /// A build already in the game's folder, to use instead of building it again. prebuilt: Option, /// Set up from the build already on this PC. @@ -5142,7 +5139,6 @@ fn game_setup(app: AppHandle, st: State<'_, App>, id: String) -> Option { inputs: inputs::rows(&p, &g, &st.dir).unwrap_or_default(), inputs_error: inputs::validate(&p).err(), inputs_ready, - previous: if set_up { vec![] } else { previous_files(&p, &g, &st.dir) }, prebuilt: if set_up { None } else { p.build_folder_here(&g.path) }, prebuilt_on: g.prebuilt && built, kept: setup_state::builds_from_kept(&p, &g), @@ -5283,89 +5279,6 @@ async fn free_up_space(st: State<'_, App>, id: String) -> Res { Ok(size) } -/// The files a game was set up with, by name: its copy and its picked files, remembered after an -/// update or a lost setup. Empty when nothing is remembered. -fn previous_files(p: &profile::Profile, g: &Installed, dir: &Path) -> Vec { - let name = |x: &Path| x.file_name().map(|n| n.to_string_lossy().to_string()).unwrap_or_else(|| x.display().to_string()); - let mut out = vec![]; - if p.game.is_some() { - if let Some(c) = &g.game_copy { - out.push(name(c)); - } - } - let active: Vec = inputs::rows(p, g, dir).unwrap_or_default().into_iter().filter(|r| r.active && r.shared.is_empty() && !r.runtime).collect(); - for r in active { - if let Some(x) = g.setup_inputs.get(&r.id) { - out.push(name(x)); - } - } - out -} - -/// Use My Previous Setup: the files it was set up with are checked as Easy Setup checks them, -/// the setup step is skipped when what it leaves is still there, and the game is set up again. -/// `RELINK_MISSING||