From 700f7a9ed2e5fcbda8d427682df1619b67813404 Mon Sep 17 00:00:00 2001 From: Deven Blake Date: Tue, 11 May 2021 14:28:01 -0400 Subject: [PATCH] remove paste --- dmenubar/dmenu.c | 22 ---------------------- 1 file changed, 22 deletions(-) diff --git a/dmenubar/dmenu.c b/dmenubar/dmenu.c index d8dc767..94345aa 100644 --- a/dmenubar/dmenu.c +++ b/dmenubar/dmenu.c @@ -217,24 +217,6 @@ insert(const char *str, ssize_t n) match(); } -static void -paste(void) -{ - char *p, *q; - int di; - unsigned long dl; - Atom da; - - /* we have been given the current selection, now insert it into input */ - if (XGetWindowProperty(dpy, win, utf8, 0, (sizeof text / 4) + 1, False, - utf8, &da, &di, &dl, &dl, (unsigned char **)&p) - == Success && p) { - insert(p, (q = strchr(p, '\n')) ? q - p : (ssize_t)strlen(p)); - XFree(p); - } - drawmenu(); -} - static void readstdin(void) { @@ -281,10 +263,6 @@ run(void) if (ev.xexpose.count == 0) drw_map(drw, win, 0, 0, mw, mh); break; - case SelectionNotify: - if (ev.xselection.property == utf8) - paste(); - break; case VisibilityNotify: if (ev.xvisibility.state != VisibilityUnobscured) XRaiseWindow(dpy, win);