--- st.c | 9 +++++++++ 1 file changed, 9 insertions(+) diff -r a15194f48b1c -r 07a1189fbf89 st.c --- a/st.c Wed Sep 05 21:54:52 2012 +0200 +++ b/st.c Wed Sep 05 21:55:45 2012 +0200 _AT_@ -311,6 +311,7 @@ static void bpress(XEvent *); static void bmotion(XEvent *); static void selnotify(XEvent *); +static void selclear(XEvent *); static void selrequest(XEvent *); static void selinit(void); _AT_@ -336,6 +337,7 @@ [MotionNotify] = bmotion, [ButtonPress] = bpress, [ButtonRelease] = brelease, + [SelectionClear] = selclear, [SelectionNotify] = selnotify, [SelectionRequest] = selrequest, }; _AT_@ -612,6 +614,13 @@ XConvertSelection(xw.dpy, XA_PRIMARY, sel.xtarget, XA_PRIMARY, xw.win, CurrentTime); } +void selclear(XEvent *e) { + if(sel.bx == -1) + return; + sel.bx = -1; + tsetdirt(sel.b.y, sel.e.y); +} + void selrequest(XEvent *e) { XSelectionRequestEvent *xsre;Received on Wed Sep 05 2012 - 22:19:29 CEST
This archive was generated by hypermail 2.3.0 : Wed Sep 05 2012 - 22:24:08 CEST