fix: window id handling for multi-window

This commit is contained in:
Ashley Wulber 2026-08-05 21:20:51 +02:00 • committed by Michael Murphy
parent 324ef6e905
commit 8a017a15ee
5 changed files with 38 additions and 9 deletions

View file

@ -743,6 +743,7 @@ where
#[cfg(feature = "multi-window")]
pub fn view(&self, id: window::Id) -> Element<'_, crate::Action<T::Message>> {
crate::widget::text_context_menu::set_current_window_id(id);
#[cfg(all(wayland_platform, target_os = "linux"))]
if let Some((_, _, _, Some(v))) = self.surface_views.get(&id) {
return v(&self.app);
@ -756,8 +757,6 @@ where
return self.app.view_window(id).map(crate::Action::App);
}
crate::widget::text_context_menu::set_current_window_id(id);
let view = if self.app.core().window.use_template {
self.app.view_main()
} else {