From 98f20e4cc18dffbf777c2200b8661722d831fe7d Mon Sep 17 00:00:00 2001 From: Imbris Date: Sat, 1 Feb 2020 22:05:25 -0500 Subject: [PATCH 1/2] Make Clipboard public --- winit/src/lib.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/winit/src/lib.rs b/winit/src/lib.rs index 13824f32..b0f235ad 100644 --- a/winit/src/lib.rs +++ b/winit/src/lib.rs @@ -43,9 +43,9 @@ mod debug; mod debug; pub use application::Application; +pub use clipboard::Clipboard; pub use mode::Mode; pub use settings::Settings; -use clipboard::Clipboard; use debug::Debug; use proxy::Proxy; From 9a875864cfc69d3c349d8568d3f60021052b63a8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?H=C3=A9ctor=20Ram=C3=B3n=20Jim=C3=A9nez?= Date: Tue, 4 Feb 2020 03:58:40 +0100 Subject: [PATCH 2/2] Write docs for `iced_winit::Clipboard` Also explicitly allow the missing debug implementation. --- winit/src/clipboard.rs | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/winit/src/clipboard.rs b/winit/src/clipboard.rs index 4739c603..1ff029ab 100644 --- a/winit/src/clipboard.rs +++ b/winit/src/clipboard.rs @@ -1,6 +1,12 @@ +/// A buffer for short-term storage and transfer within and between +/// applications. +#[allow(missing_debug_implementations)] pub struct Clipboard(window_clipboard::Clipboard); impl Clipboard { + /// Creates a new [`Clipboard`] for the given window. + /// + /// [`Clipboard`]: struct.Clipboard.html pub fn new(window: &winit::window::Window) -> Option { window_clipboard::Clipboard::new(window).map(Clipboard).ok() }