From 3f2591f833603bc9841ff8e20cc6c294357bbc12 Mon Sep 17 00:00:00 2001 From: Kris Maglione Date: Mon, 26 Feb 2007 05:51:49 -0500 Subject: [PATCH] Remove tests for menu bounds in 9menu.c, since the mouse is confined to the menu. --- 9menu.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/9menu.c b/9menu.c index 1220f419..7ecf04ab 100644 --- 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);