graphic design tool
git clone https://git.lucas.co/cce-designer.git
fix: HTTP set_param applies settings params like the interactive path
The SetParam handler updated the param default but never ran
apply_settings_from_menubar_subnets / sync_grid_settings, so Main-node
settings params (viewport flags, grid) set over HTTP changed the stored
value without taking effect. Mirror the interactive param-pane sequence.
Co-Authored-By: Claude Fable 5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01G5djCURa3LVnRU8WacanLC
src/window.rs | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/src/window.rs b/src/window.rs
index cce70a4..c873b8d 100644
--- a/src/window.rs
+++ b/src/window.rs
@@ -1358,6 +1358,11 @@ impl AppState {
if let Some(child) = dir.children.get_mut(slot) {
if let Some(p) = child.params.iter_mut().find(|p| p.name == name) {
p.default = value;
+ // Same sequence as the interactive param-pane
+ // path, so settings params (viewport flags,
+ // grid) actually take effect over HTTP.
+ state.apply_settings_from_menubar_subnets();
+ state.sync_grid_settings();
state.sync_nodes();
state.rebuild_scene_geometry();
state.upload_vertices();