From 95f27171f8f04c5697de592caccff32d62243f3a Mon Sep 17 00:00:00 2001 From: core Date: Tue, 7 Nov 2023 14:39:34 -0500 Subject: [PATCH] pass events --- nexrad-browser/src/lib.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/nexrad-browser/src/lib.rs b/nexrad-browser/src/lib.rs index f9db102..66c3877 100644 --- a/nexrad-browser/src/lib.rs +++ b/nexrad-browser/src/lib.rs @@ -20,7 +20,7 @@ use winit::event::WindowEvent::KeyboardInput; use winit::event_loop::{EventLoop, EventLoopWindowTarget}; use winit::keyboard::KeyCode; use winit::window::WindowBuilder; -use winit::platform::web::{WindowExtWebSys, EventLoopExtWebSys}; +use winit::platform::web::{WindowExtWebSys, WindowBuilderExtWebSys, EventLoopExtWebSys}; use crate::command::{exec, should_newline}; use crate::mode::Mode; use crate::mode::Mode::Reflectivity; @@ -44,7 +44,7 @@ pub async fn __nxrd_browser_init(w: u32, h: u32) -> AbiScopeState { info!("wgpu setup"); let event_loop = EventLoop::new().expect("event loop creation failed"); - let window = WindowBuilder::new().build(&event_loop).unwrap(); + let window = WindowBuilder::new().with_prevent_default(false).build(&event_loop).unwrap(); window.set_min_inner_size(Some(PhysicalSize::new(w, h)));