fix(scene): clear selection after erase

This commit is contained in:
Hakan Seven 2026-07-28 17:35:21 +03:00
commit 8050fc79fd
7 changed files with 50 additions and 11 deletions

View file

@ -801,7 +801,9 @@ pub(super) fn on_open_file(&mut self) -> Task<Message> {
if let Some(prepared) = prepared_geometry {
self.tabs[i].scene.install_prepared_open_geometry(prepared);
}
self.tabs[i].scene.selected = rustc_hash::FxHashSet::default();
self.tabs[i]
.scene
.replace_selection(rustc_hash::FxHashSet::default());
self.tabs[i].scene.preview_wires = vec![];
// Reopen in whichever space the file was saved in — the CTAB
// tab name when recorded, else the $TILEMODE model/paper flag —