1
0
Fork 0
forked from wry/wry

all: address clippy lints

This commit is contained in:
Julian Orth 2025-08-29 11:21:04 +02:00
parent e5fd0fa192
commit 9e67158f47
29 changed files with 31 additions and 68 deletions

View file

@ -6,7 +6,6 @@ use {
wire::{WlCallbackId, wl_callback::*},
},
std::{convert::Infallible, rc::Rc},
thiserror::Error,
};
pub struct WlCallback {
@ -44,6 +43,3 @@ object_base! {
impl Object for WlCallback {}
simple_add_obj!(WlCallback);
#[derive(Debug, Error)]
pub enum WlCallbackError {}

View file

@ -371,7 +371,7 @@ impl XdgSurface {
Ok(())
}
fn pending(&self) -> RefMut<Box<PendingXdgSurfaceData>> {
fn pending(&self) -> RefMut<'_, Box<PendingXdgSurfaceData>> {
RefMut::map(self.surface.pending.borrow_mut(), |p| {
p.xdg_surface.get_or_insert_default_ext()
})

View file

@ -36,7 +36,6 @@ use {
},
ahash::{AHashMap, AHashSet},
jay_config::window::TileState,
num_derive::FromPrimitive,
std::{
cell::{Cell, RefCell},
fmt::{Debug, Formatter},
@ -46,19 +45,6 @@ use {
thiserror::Error,
};
#[derive(Copy, Clone, Debug, FromPrimitive)]
pub enum ResizeEdge {
None = 0,
Top = 1,
Bottom = 2,
Left = 4,
TopLeft = 5,
BottomLeft = 6,
Right = 8,
TopRight = 9,
BottomRight = 10,
}
#[expect(dead_code)]
const STATE_MAXIMIZED: u32 = 1;
const STATE_FULLSCREEN: u32 = 2;

View file

@ -208,7 +208,7 @@ impl ZwlrLayerSurfaceV1 {
self.client.event(Closed { self_id: self.id });
}
fn pending(&self) -> RefMut<Box<PendingLayerSurfaceData>> {
fn pending(&self) -> RefMut<'_, Box<PendingLayerSurfaceData>> {
RefMut::map(self.surface.pending.borrow_mut(), |m| {
m.layer_surface.get_or_insert_default_ext()
})

View file

@ -7,7 +7,6 @@ use {
wire::{WpPresentationFeedbackId, wp_presentation_feedback::*},
},
std::{convert::Infallible, rc::Rc},
thiserror::Error,
};
pub struct WpPresentationFeedback {
@ -62,6 +61,3 @@ object_base! {
impl Object for WpPresentationFeedback {}
simple_add_obj!(WpPresentationFeedback);
#[derive(Debug, Error)]
pub enum WpPresentationFeedbackError {}