mirror of
https://github.com/rust-windowing/winit.git
synced 2026-06-28 07:33:14 -04:00
Handle scale factor change on web-sys backend (#1690)
* Change web backend `event_handler` to without 'static lifetime * Refactor web runner and fix ControlFlow::Exit not being sticky * Impl. scaling change event for web-sys backend * Improve `dpi` docs regarding the web backend * Add changes to changelog * Update features.md
This commit is contained in:
13
src/platform_impl/web/stdweb/scaling.rs
Normal file
13
src/platform_impl/web/stdweb/scaling.rs
Normal file
@@ -0,0 +1,13 @@
|
||||
use super::super::ScaleChangeArgs;
|
||||
|
||||
pub struct ScaleChangeDetector(());
|
||||
|
||||
impl ScaleChangeDetector {
|
||||
pub(crate) fn new<F>(_handler: F) -> Self
|
||||
where
|
||||
F: 'static + FnMut(ScaleChangeArgs),
|
||||
{
|
||||
// TODO: Stub, unimplemented (see web_sys for reference).
|
||||
Self(())
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user