1
0
mirror of https://github.com/emilk/egui.git synced 2026-06-26 22:53:14 -04:00

Update the glow example to avoid a white flash when the app starts. (#2345)

This commit is contained in:
Fotis Gimian
2022-11-30 01:04:17 +11:00
committed by GitHub
parent a3f1e5961f
commit 975cbac83a

View File

@@ -53,6 +53,7 @@ fn main() {
// draw things on top of egui here
gl_window.swap_buffers().unwrap();
gl_window.window().set_visible(true);
}
};
@@ -111,7 +112,8 @@ fn create_display(
width: 800.0,
height: 600.0,
})
.with_title("egui_glow example");
.with_title("egui_glow example")
.with_visible(false); // Keep hidden until we've painted something. See https://github.com/emilk/egui/pull/2279
let gl_window = unsafe {
glutin::ContextBuilder::new()