diff --git a/src/platform_impl/web/web_sys/mod.rs b/src/platform_impl/web/web_sys/mod.rs index 558bd1a2..92d7fd42 100644 --- a/src/platform_impl/web/web_sys/mod.rs +++ b/src/platform_impl/web/web_sys/mod.rs @@ -121,8 +121,8 @@ pub fn is_fullscreen(window: &web_sys::Window, canvas: &HtmlCanvasElement) -> bo match document.fullscreen_element() { Some(elem) => { - let raw: Element = canvas.clone().into(); - raw == elem + let canvas: &Element = canvas; + canvas == &elem } None => false, }