aboutsummaryrefslogtreecommitdiff
path: root/src/input.rs
diff options
context:
space:
mode:
authorJoe Wilm <joe@jwilm.com>2016-10-08 18:42:33 -0700
committerJoe Wilm <joe@jwilm.com>2016-10-08 18:42:33 -0700
commit9d491f9f676536634040fea8294dc672f3466e26 (patch)
tree81d4ddc867c570a9004c3d878647feb69e0e2d91 /src/input.rs
parent7e69a070aaf92eff3bea1878bd77821b5ae60ede (diff)
downloadalacritty-9d491f9f676536634040fea8294dc672f3466e26.tar.gz
alacritty-9d491f9f676536634040fea8294dc672f3466e26.zip
Start implementing copypasta, a clipboard library
Currently it only supports x11 via the xclip program, and that only supports reading the clipboard contents.
Diffstat (limited to 'src/input.rs')
-rw-r--r--src/input.rs6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/input.rs b/src/input.rs
index d0cbc600..f1022814 100644
--- a/src/input.rs
+++ b/src/input.rs
@@ -25,7 +25,7 @@
//! TODO handling xmodmap would be good
use std::borrow::Cow;
-use clipboard::ClipboardContext;
+use copypasta::{Clipboard, Load};
use glutin::{ElementState, VirtualKeyCode, MouseButton};
use glutin::{Mods, mods};
@@ -349,8 +349,8 @@ impl Processor {
Action::Esc(s) => notifier.notify(s.as_bytes()),
Action::Paste => {
println!("paste request");
- let clip = ClipboardContext::new().expect("get clipboard");
- clip.get_contents()
+ let clip = Clipboard::new().expect("get clipboard");
+ clip.load_selection()
.map(|contents| {
println!("got contents");
notifier.notify(contents.into_bytes())