From a83bf83784276aaa882ef13555295a2ad9edd265 Mon Sep 17 00:00:00 2001 From: Ashley Wulber Date: Mon, 21 Oct 2024 11:14:55 -0400 Subject: [PATCH] refactor: remove Box --- src/platform/linux.rs | 2 +- wayland/src/lib.rs | 4 +--- 2 files changed, 2 insertions(+), 4 deletions(-) diff --git a/src/platform/linux.rs b/src/platform/linux.rs index 409a7e4..3d953f1 100644 --- a/src/platform/linux.rs +++ b/src/platform/linux.rs @@ -135,7 +135,7 @@ impl DndProvider for Clipboard { tx: Box + Send + Sync + 'static>, ) { match self { - Clipboard::Wayland(c) => c.init_dnd(DndSender(Arc::new(tx))), + Clipboard::Wayland(c) => c.init_dnd(DndSender(Arc::from(tx))), Clipboard::X11(_) => {} } } diff --git a/wayland/src/lib.rs b/wayland/src/lib.rs index deb59d9..298e87c 100644 --- a/wayland/src/lib.rs +++ b/wayland/src/lib.rs @@ -27,9 +27,7 @@ use smithay_clipboard::dnd::{Icon, Rectangle}; pub use smithay_clipboard::mime::{AllowedMimeTypes, AsMimeTypes, MimeType}; #[derive(Clone)] -pub struct DndSender( - pub Arc + 'static + Send + Sync>>, -); +pub struct DndSender(pub Arc + 'static + Send + Sync>); impl smithay_clipboard::dnd::Sender for DndSender { fn send(