Make SolveApp::start honour a command's enabled flag, and disable solid.move inside a sketch (#740)
`SolveApp::start` now honours a command's enabled flag, so shortcuts, the command palette and the control channel can't start a disabled command, and Move is disabled while a sketch is open.
This commit is contained in:
1 parent
62a7f903f2
commit
ff609bc320
8 files changed
+132
-4
No files matched your search
@@ -137,6 +137,7 @@ pub fn handle(app: &mut SolveApp, ctx: &egui::Context, req: &ControlRequest) ->
|
||||
"camera": app.cam,
|
||||
"tool": app.tool.as_ref().map(|t| t.cmd),
|
||||
"dialog": app.dialog.as_ref().map(|d| format!("{d:?}")),
|
||||
"status": app.status.as_ref().map(|(text, _, error)| json!({"text": text, "error": error})),
|
||||
"hover": app.viewport.hover.as_ref().map(|h| format!("{h:?}")),
|
||||
"renderer": if app.viewport.gpu.is_some() { "gpu" } else { "cpu" },
|
||||
"frame_ms": app.frame_ms,
|
||||
|
||||
Reference in new issue
Block a user