Skip to content

Commit

Permalink
janitor: Remove unused variable warning in winit
Browse files Browse the repository at this point in the history
  • Loading branch information
hunger committed Jun 28, 2024
1 parent 5663aa0 commit dbde3c2
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
4 changes: 2 additions & 2 deletions internal/backends/winit/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,7 @@ fn try_create_window_with_fallback_renderer(
Some(WinitWindowAdapter::new(
renderer,
winit_window,
#[cfg(not(target_family = "wasm"))]
#[cfg(enable_accesskit)]
_proxy.clone(),
))
})
Expand Down Expand Up @@ -273,7 +273,7 @@ impl i_slint_core::platform::Platform for Backend {
WinitWindowAdapter::new(
renderer,
window,
#[cfg(not(target_family = "wasm"))]
#[cfg(enable_accesskit)]
self.proxy.clone(),
)
})
Expand Down
6 changes: 3 additions & 3 deletions internal/backends/winit/winitwindowadapter.rs
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ use corelib::items::{ColorScheme, MouseCursor};
#[cfg(enable_accesskit)]
use corelib::items::{ItemRc, ItemRef};

#[cfg(not(target_family = "wasm"))]
#[cfg(enable_accesskit)]
use crate::SlintUserEvent;
use corelib::api::PhysicalSize;
use corelib::layout::Orientation;
Expand All @@ -37,7 +37,7 @@ use corelib::Property;
use corelib::{graphics::*, Coord};
use i_slint_core as corelib;
use once_cell::unsync::OnceCell;
#[cfg(not(target_family = "wasm"))]
#[cfg(enable_accesskit)]
use winit::event_loop::EventLoopProxy;
use winit::window::WindowAttributes;

Expand Down Expand Up @@ -165,7 +165,7 @@ impl WinitWindowAdapter {
pub(crate) fn new(
renderer: Box<dyn WinitCompatibleRenderer>,
winit_window: Rc<winit::window::Window>,
#[cfg(not(target_family = "wasm"))] proxy: EventLoopProxy<SlintUserEvent>,
#[cfg(enable_accesskit)] proxy: EventLoopProxy<SlintUserEvent>,
) -> Rc<Self> {
let self_rc = Rc::new_cyclic(|self_weak| Self {
window: OnceCell::with_value(corelib::api::Window::new(self_weak.clone() as _)),
Expand Down

0 comments on commit dbde3c2

Please sign in to comment.