Enable egui_glow's winit feature on wasm (#4420) (#4421)

Reverts change in #1303, enabling the egui_glow::winit module when using
wasm.

* Closes <https://github.com/emilk/egui/issues/4420>
This commit is contained in:
Simon Frankau 2024-04-29 09:33:23 +01:00 committed by GitHub
parent 0bc59f578b
commit c1fc9213c3
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 3 additions and 3 deletions

View File

@ -54,6 +54,7 @@ x11 = ["winit?/x11"]
[dependencies]
egui = { workspace = true, default-features = false, features = ["bytemuck"] }
egui-winit = { workspace = true, optional = true, default-features = false }
bytemuck = "1.7"
glow.workspace = true
@ -66,7 +67,6 @@ document-features = { workspace = true, optional = true }
# Native:
[target.'cfg(not(target_arch = "wasm32"))'.dependencies]
egui-winit = { workspace = true, optional = true, default-features = false }
puffin = { workspace = true, optional = true }
winit = { workspace = true, optional = true, default-features = false, features = [
"rwh_06", # for compatibility with egui-winit

View File

@ -21,9 +21,9 @@ mod vao;
pub use shader_version::ShaderVersion;
#[cfg(all(not(target_arch = "wasm32"), feature = "winit"))]
#[cfg(feature = "winit")]
pub mod winit;
#[cfg(all(not(target_arch = "wasm32"), feature = "winit"))]
#[cfg(feature = "winit")]
pub use winit::*;
/// Check for OpenGL error and report it using `log::error`.