diff options
Diffstat (limited to 'winit/src/clipboard.rs')
-rw-r--r-- | winit/src/clipboard.rs | 17 |
1 files changed, 1 insertions, 16 deletions
diff --git a/winit/src/clipboard.rs b/winit/src/clipboard.rs index c1fd8813..7271441d 100644 --- a/winit/src/clipboard.rs +++ b/winit/src/clipboard.rs @@ -1,7 +1,4 @@ //! Access the clipboard. -pub use iced_native::clipboard::Action; - -use crate::command::{self, Command}; /// A buffer for short-term storage and transfer within and between /// applications. @@ -56,7 +53,7 @@ impl Clipboard { } } -impl iced_native::Clipboard for Clipboard { +impl crate::core::Clipboard for Clipboard { fn read(&self) -> Option<String> { self.read() } @@ -65,15 +62,3 @@ impl iced_native::Clipboard for Clipboard { self.write(contents) } } - -/// Read the current contents of the clipboard. -pub fn read<Message>( - f: impl Fn(Option<String>) -> Message + 'static, -) -> Command<Message> { - Command::single(command::Action::Clipboard(Action::Read(Box::new(f)))) -} - -/// Write the given contents to the clipboard. -pub fn write<Message>(contents: String) -> Command<Message> { - Command::single(command::Action::Clipboard(Action::Write(contents))) -} |