The truly free, open-source, local-first, cross-platform CapCut replacement. Scriptable through a JSON-RPC API & MCP.
Rust ffmpegfree-video-editormodel-context-protocolnon-linear-editoroffline-firstopen-source-video-editorself-hostedvideo-editingvideo-editing-automationvideo-editing-softwarevideo-editing-toolsvideo-editorvoice-cloningyoutube-automationyoutube-shorts
fix(start): new projects default to the desktop the system names
Jareer8e4133e45ecc
diff --git a/src/Cargo.lock b/src/Cargo.lockindex 3ab870bd..1a21bb0b 100644--- a/src/Cargo.lock+++ b/src/Cargo.lock@@ -1143,6 +1143,7 @@ dependencies = ["concat-speech","concat-text","concat-vision",+ "dirs","image","log","opener",@@ -1771,6 +1772,27 @@ dependencies = ["subtle",]+[[package]]+name = "dirs"+version = "6.0.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "c3e8aa94d75141228480295a7d0e7feb620b1a5ad9f12bc40be62411e38cce4e"+dependencies = [+ "dirs-sys",+]++[[package]]+name = "dirs-sys"+version = "0.5.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "e01a3366d27ee9890022452ee61b2b63a67e6f13f58900b651ff5665f0bb1fab"+dependencies = [+ "libc",+ "option-ext",+ "redox_users",+ "windows-sys 0.61.2",+]+[[package]]name = "dispatch"version = "0.2.0"@@ -4736,6 +4758,12 @@ dependencies = ["vcpkg",]+[[package]]+name = "option-ext"+version = "0.2.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "04744f49eae99ab78e0d5c0b603ab218f515ea8cfe5a456d7629ad883a3b6e7d"+[[package]]name = "orbclient"version = "0.3.55"@@ -5450,6 +5478,16 @@ dependencies = ["bitflags 2.13.1",]+[[package]]+name = "redox_users"+version = "0.5.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "60dc65c0ff1a7ae1294b0c67b9f14baf70b644404010370171787bfac1038fc0"+dependencies = [+ "libredox",+ "thiserror 2.0.20",+]+[[package]]name = "regex"version = "1.13.1"diff --git a/src/crates/concat/Cargo.toml b/src/crates/concat/Cargo.tomlindex bbba86f6..5630fded 100644--- a/src/crates/concat/Cargo.toml+++ b/src/crates/concat/Cargo.toml@@ -44,6 +44,10 @@ path = "src/main.rs"# (see platform.rs). The renderer and wgpu features are the same on all# three.[target.'cfg(not(any(target_os = "android", target_os = "ios")))'.dependencies]+# Where the desktop really is: Windows' known folder, which OneDrive may+# have moved, and the XDG user dirs, which name it in the desktop's own+# language. New projects default to a folder on it.+dirs = "6"slint = { version = "1.18", default-features = false, features = ["std","backend-default",diff --git a/src/crates/concat/src/panes/start.rs b/src/crates/concat/src/panes/start.rsindex da4b43df..c7c0b1c6 100644--- a/src/crates/concat/src/panes/start.rs+++ b/src/crates/concat/src/panes/start.rs@@ -70,13 +70,7 @@ impl Default for StartPane {Self {composing: false,name: "Untitled project".into(),- // A phone has no desk: its projects live at the top of the- // folder the file manager shows for the app.- location: home_folder(if cfg!(target_os = "android") {- "Concat"- } else {- "Desktop/Concat"- }),+ location: default_location(),aspect: 0,// 1080p, not the first of the three. The size everything else// in the app assumes, and the one a phone and a desk agree on.@@ -90,6 +84,22 @@ impl Default for StartPane {}}+/// Where a new project goes unless told otherwise: a Concat folder on the+/// desktop. The desktop the system names, not `~/Desktop`: on Windows+/// OneDrive often moves it, and on Linux it is called what the desktop's+/// language calls it. A phone has no desk: its projects live at the top of+/// the folder the file manager shows for the app.+fn default_location() -> String {+ if cfg!(target_os = "android") {+ return home_folder("Concat");+ }+ #[cfg(not(any(target_os = "android", target_os = "ios")))]+ if let Some(desktop) = dirs::desktop_dir() {+ return desktop.join("Concat").to_string_lossy().into_owned();+ }+ home_folder("Desktop/Concat")+}+impl StartPane {/// Applies one message. The studio is the rest of the window; while/// this runs the studio's copy of the pane is a blank it must not read.