wmii

git clone git://oldgit.suckless.org/wmii/
Log | Files | Refs | README | LICENSE

commit 3f2591f833603bc9841ff8e20cc6c294357bbc12
parent 16af6d5871f96cd77c2133731892d687ede1d181
Author: Kris Maglione <jg@suckless.org>
Date:   Mon, 26 Feb 2007 05:51:49 -0500

Remove tests for menu bounds in 9menu.c, since the mouse is confined to the menu.

Diffstat:
9menu.c | 8++++----
1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/9menu.c b/9menu.c @@ -569,10 +569,10 @@ run_menu() case MotionNotify: old = cur; cur = ev.xbutton.y/high; - if (ev.xbutton.x < 0 || ev.xbutton.x > wide) - cur = -1; - else if (cur < 0 || cur >= numitems) - cur = -1; + if (cur < 0) + cur = 0; + else if (cur >= numitems) + cur = numitems - 1; if (cur == old) break; redraw(cur, high, wide);