1
Fork 0
mirror of git://git.sv.gnu.org/emacs.git synced 2026-01-12 06:21:02 -08:00

Improve test for empty help-echo on NS menu bar items

* src/nsmenu.m ([EmacsMenu menu:willHighlightItem:]): Also check
if idx is valid.
This commit is contained in:
Po Lu 2022-05-13 16:08:54 +08:00
parent 62d2db341c
commit 7dd4e0b72e

View file

@ -782,7 +782,7 @@ prettify_key (const char *key)
}
/* Just dismiss any help-echo that might already be in progress if
no menu item will be highlighted. */
else if (item == nil)
else if (item == nil || idx <= 0)
help = Qnil;
else
{