Desktop: Fix missing taskbar icon on Windows (#3490)

* fix missing taskbar icon

* focus window after init
This commit is contained in:
Timon
2025-12-18 12:51:01 +00:00
committed by GitHub
parent 6733a24e47
commit 14b8cdf4cb
7 changed files with 61 additions and 29 deletions
+6
View File
@@ -52,6 +52,7 @@ impl Window {
.with_min_surface_size(winit::dpi::LogicalSize::new(400, 300))
.with_surface_size(winit::dpi::LogicalSize::new(1200, 800))
.with_resizable(true)
.with_visible(false)
.with_theme(Some(winit::window::Theme::Dark));
attributes = native::NativeWindowImpl::configure(attributes, event_loop);
@@ -67,6 +68,11 @@ impl Window {
}
}
pub(crate) fn show(&self) {
self.winit_window.set_visible(true);
self.winit_window.focus_window();
}
pub(crate) fn request_redraw(&self) {
self.winit_window.request_redraw();
}