diff --git a/crates/eframe/src/native/epi_integration.rs b/crates/eframe/src/native/epi_integration.rs index 62da6976563..e70d340549c 100644 --- a/crates/eframe/src/native/epi_integration.rs +++ b/crates/eframe/src/native/epi_integration.rs @@ -427,7 +427,7 @@ impl EpiIntegration { let saved_memory: egui::Memory = self.egui_ctx.memory(|mem| mem.clone()); self.egui_ctx .memory_mut(|mem| mem.set_everything_is_visible(true)); - let full_output = self.update(app, window, egui_winit, &None, ViewportIdPair::ROOT); + let full_output = self.update(app, window, egui_winit, None, ViewportIdPair::ROOT); self.pending_full_output.append(full_output); // Handle it next frame self.egui_ctx.memory_mut(|mem| *mem = saved_memory); // We don't want to remember that windows were huge. self.egui_ctx.clear_animations(); @@ -483,7 +483,7 @@ impl EpiIntegration { app: &mut dyn epi::App, window: &winit::window::Window, egui_winit: &mut egui_winit::State, - viewport_ui_cb: &Option>, + viewport_ui_cb: Option<&ViewportUiCallback>, id_pair: ViewportIdPair, ) -> egui::FullOutput { let frame_start = std::time::Instant::now(); diff --git a/crates/eframe/src/native/run.rs b/crates/eframe/src/native/run.rs index 203d89f7140..e27840eb922 100644 --- a/crates/eframe/src/native/run.rs +++ b/crates/eframe/src/native/run.rs @@ -1479,7 +1479,7 @@ mod glow_integration { app.as_mut(), &window, egui_winit, - &viewport.viewport_ui_cb.clone(), + viewport.viewport_ui_cb.as_deref(), viewport.id_pair, ); @@ -2425,7 +2425,7 @@ mod wgpu_integration { app.as_mut(), &window.borrow(), state.borrow_mut().as_mut().unwrap(), - &viewport_ui_cb.clone(), + viewport_ui_cb.as_deref(), ViewportIdPair { this: viewport_id, parent: parent_id,