diff options
Diffstat (limited to 'src/event.rs')
-rw-r--r-- | src/event.rs | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/event.rs b/src/event.rs index 6c4c375..5a5b1b9 100644 --- a/src/event.rs +++ b/src/event.rs @@ -12,12 +12,12 @@ use x11::xlib::{ XMapEvent, XConfigureEvent, }; - use x11::xlib; use x11::xlib::Display; +use libc::c_int; use std::fmt; -use safe_x11::next_xevent; +use safe_x11::event::next_xevent; pub enum Event { Key(XKeyEvent, bool), @@ -55,8 +55,8 @@ impl fmt::Debug for Event { } } -pub fn next_event(display: *mut Display) -> Event { - let ev = next_xevent(display); +pub fn next_event(display: *mut Display, fd: c_int) -> Event { + let ev = next_xevent(display, fd); match ev.get_type() { 2 => Event::Key(xlib::XKeyEvent::from(ev), true), |