(&mut self, context: &str, e: &anyhow::Error)
| 439 | } |
| 440 | |
| 441 | pub fn show_error_toast(&mut self, context: &str, e: &anyhow::Error) { |
| 442 | let mut job = LayoutJob::default(); |
| 443 | job.append(context, 0.0, Default::default()); |
| 444 | job.append("\n", 0.0, Default::default()); |
| 445 | job.append(&format!("{e:#}"), 0.0, egui::TextFormat { |
| 446 | color: egui::Color32::LIGHT_RED, |
| 447 | ..Default::default() |
| 448 | }); |
| 449 | self.top_left_toasts.error(job).closable(true).duration(None); |
| 450 | } |
| 451 | } |
| 452 | |
| 453 | pub type AppStateRef = Arc<RwLock<AppState>>; |
no outgoing calls
no test coverage detected