diff options
Diffstat (limited to 'src/event.rs')
-rw-r--r-- | src/event.rs | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/event.rs b/src/event.rs index 3832a36..b97686f 100644 --- a/src/event.rs +++ b/src/event.rs @@ -11,6 +11,7 @@ use x11::xlib::{ XUnmapEvent, XMapEvent, XConfigureEvent, + XExposeEvent, XPending, }; @@ -48,6 +49,7 @@ pub enum Event { Unmap(XUnmapEvent), Map(XMapEvent), Configure(XConfigureEvent), + Expose(XExposeEvent), Socket(UnixStream), NoEvent } @@ -66,6 +68,7 @@ impl fmt::Debug for Event { &Event::Unmap(ev) => format!("Unmap({})", XEvent::from(ev).get_type()), &Event::Map(ev) => format!("Map({})", XEvent::from(ev).get_type()), &Event::Configure(ev) => format!("Configure({})", XEvent::from(ev).get_type()), + &Event::Expose(ev) => format!("Expose({})", XEvent::from(ev).get_type()), &Event::Socket(_) => format!("Socket()"), &Event::NoEvent => format!("NoEvent"), }; @@ -116,6 +119,7 @@ pub fn next_event(display: *mut Display) -> Event { 6 => Event::Drag(XMotionEvent::from(ev)), 7 => Event::Enter(XCrossingEvent::from(ev)), 8 => Event::Leave(XCrossingEvent::from(ev)), + 12 => Event::Expose(XExposeEvent::from(ev)), 16 => Event::Create(XCreateWindowEvent::from(ev)), 17 => Event::Destroy(XDestroyWindowEvent::from(ev)), 18 => Event::Unmap(XUnmapEvent::from(ev)), |