Keep Open and Save asynchronous to prevent macOS resize crashes (#1127)

Open and Save use parented AsyncFileDialog sheets; their answers run on the UI thread in a later frame, so resizing the window while a picker is open no longer re-enters winit and aborts. Editors, tab changes, Close/Quit and model-changing control requests wait for the answer; the local library Open and Export in the Appearance dialog use the same flow. Fixes #1088.
This commit is contained in:
Karl Von Richter authored and GitHub committed 2026-10-14 13:41:29 -04:00
1 parent f425089983
commit 37547f8eba
18 files changed
+564 -137

No files matched your search

+6 -4
View File
@@ -395,10 +395,12 @@ pub fn show(app: &mut SolveApp, ui: &mut egui::Ui) {
ui.add_space(10.0);
if big(ui, "open", "Open…", false) {
action = Some(Box::new(|app: &mut SolveApp| {
if let Some(p) = app.services.pick_open.as_ref().and_then(|f| f()) {
app.home.open = false;
app.open_path_async(&p);
}
app.pick_open(|app, path| {
if let Some(path) = path {
app.home.open = false;
app.open_path_async(&path);
}
});
}));
}
});