1
0
mirror of https://github.com/emilk/egui.git synced 2026-08-31 05:40:03 -04:00

Clamp eframe window size to at most the size of the largest monitor (#2445)

This can hopefully fix some reported bugs where
This commit is contained in:
Emil Ernerfeldt
2022-12-13 09:09:36 +01:00
committed by GitHub
parent 32677a54e4
commit 4a72abc8ec
4 changed files with 36 additions and 12 deletions

View File

@@ -504,7 +504,7 @@ mod glow_integration {
let window_settings = epi_integration::load_window_settings(storage);
let winit_window =
epi_integration::window_builder(title, native_options, &window_settings)
epi_integration::window_builder(event_loop, title, native_options, window_settings)
.build(event_loop)?;
// a lot of the code below has been lifted from glutin example in their repo.
let glutin_window_context =
@@ -937,7 +937,7 @@ mod wgpu_integration {
) -> Result<winit::window::Window> {
let window_settings = epi_integration::load_window_settings(storage);
Ok(
epi_integration::window_builder(title, native_options, &window_settings)
epi_integration::window_builder(event_loop, title, native_options, window_settings)
.build(event_loop)?,
)
}