diff --git a/src/app/update/dialog.rs b/src/app/update/dialog.rs index c72f0f7d8..93473f6ba 100644 --- a/src/app/update/dialog.rs +++ b/src/app/update/dialog.rs @@ -107,17 +107,8 @@ impl OpenCADStudio { pub(super) fn on_ribbon_tool_click(&mut self, tool_id: String, event: ModuleEvent) -> Task { - // On the Start page there is no drawing to act on, so a tool that - // touches the scene is inert — point the user at New / Open - // instead of running it into the empty welcome tab (#299). - // - // Commands are exempt: `dispatch_command` already decides which - // ones stand alone (About, Donate, Report, the web link…) and - // reports the rest. Refusing them here shadowed that list and - // killed the welcome page's own buttons, which by definition can - // only ever be clicked while `is_start` holds (#388, #389). - // Keep the policy in one place — this door must not second-guess - // it. Every other event below mutates the scene or its panels. + // Commands use `start_allowed`; other events need a drawing + // and stay blocked on the Start page (#299, #388, #389). if self.tabs[self.active_tab].is_start && !matches!(event, ModuleEvent::Command(_)) { self.ribbon.close_dropdown(); self.command_line diff --git a/src/app/update/mod.rs b/src/app/update/mod.rs index 2c0adb8ed..a061cbd41 100644 --- a/src/app/update/mod.rs +++ b/src/app/update/mod.rs @@ -1267,11 +1267,7 @@ impl OpenCADStudio { } Message::RibbonToolClick { tool_id, event } => { - if self.tabs[self.active_tab].is_start { - Task::none() - } else { - self.on_ribbon_tool_click(tool_id, event) - } + self.on_ribbon_tool_click(tool_id, event) } Message::PluginFileDialogResult { command, path } => { if let Some(path) = path { @@ -5722,7 +5718,15 @@ impl OpenCADStudio { crate::ui::window::about::platform_name(), crate::ui::window::about::architecture_name(), ); - iced::clipboard::write(info).discard() + #[cfg(target_arch = "wasm32")] + { + crate::sys::write_clipboard_text(&info); + Task::none() + } + #[cfg(not(target_arch = "wasm32"))] + { + iced::clipboard::write(info).discard() + } } // ── Plugin Manager window ─────────────────────────────────────