about summary refs log tree commit diff stats
diff options
context:
space:
mode:
authorAnselm R.Garbe <arg@10ksloc.org>2006-08-15 09:37:12 +0200
committerAnselm R.Garbe <arg@10ksloc.org>2006-08-15 09:37:12 +0200
commit24d91e3b8a6e173bf65d5dd611b164dcb6a01978 (patch)
tree097e9daa6013e199f2d93e0c59c9ffc8845361ce
parentce04a665282e4f63d47aa4c4b2f108ebb4fce5e6 (diff)
downloaddwm-24d91e3b8a6e173bf65d5dd611b164dcb6a01978.tar.gz
extended cleanup
-rw-r--r--config.arg.h7
-rw-r--r--main.c7
2 files changed, 12 insertions, 2 deletions
diff --git a/config.arg.h b/config.arg.h
index 8b3c59b..c9c2ad8 100644
--- a/config.arg.h
+++ b/config.arg.h
@@ -20,8 +20,11 @@ static Key key[] = { \
 	/* modifier			key		function	arguments */ \
 	{ MODKEY|ShiftMask,		XK_Return,	spawn, \
 		{ .cmd = "exec urxvt +sb -tr -bg black -fg '#eeeeee' -fn '"FONT"'" } }, \
-	{ MODKEY,			XK_Tab,		focusnext,	{ 0 } }, \
-	{ MODKEY|ShiftMask,		XK_Tab,		focusprev,	{ 0 } }, \
+	{ MODKEY,			XK_p,		spawn, \
+		{ .cmd = "exec `ls -lL /usr/bin /usr/local/bin 2>/dev/null | " \
+			"awk 'NF>2 && $1 ~ /^[^d].*x/ {print $NF}' | sort | uniq | dmenu`" } }, \
+	{ MODKEY,			XK_j,		focusnext,	{ 0 } }, \
+	{ MODKEY,			XK_k,		focusprev,	{ 0 } }, \
 	{ MODKEY,			XK_Return,	zoom,		{ 0 } }, \
 	{ MODKEY,			XK_m,		togglemax,	{ 0 } }, \
 	{ MODKEY|ShiftMask,		XK_1,		tag,		{ .i = 0 } }, \
diff --git a/main.c b/main.c
index d0048be..545efe9 100644
--- a/main.c
+++ b/main.c
@@ -27,7 +27,14 @@ cleanup()
 		resize(sel, True, TopLeft);
 		unmanage(sel);
 	}
+	if(dc.font.set)
+		XFreeFontSet(dpy, dc.font.set);
+	else
+		XFreeFont(dpy, dc.font.xfont);
 	XUngrabKey(dpy, AnyKey, AnyModifier, root);
+	XDestroyWindow(dpy, barwin);
+	XFreePixmap(dpy, dc.drawable);
+	XFreeGC(dpy, dc.gc);
 	XSetInputFocus(dpy, PointerRoot, RevertToPointerRoot, CurrentTime);
 	XSync(dpy, False);
 }