Menu: Only look for .ui-menu-item elements to determine if a menu item is the first or last element in the menu. Fixes #5528 - Autocomplete: Issue when try to navigate using up key by keyboard in IE6.

This commit is contained in:
Scott González 2010-07-19 11:51:05 -04:00
parent a090faa833
commit 5311fe22f3

View File

@ -433,11 +433,11 @@ $.widget("ui.menu", {
},
first: function() {
return this.active && !this.active.prev().length;
return this.active && !this.active.prevAll(".ui-menu-item").length;
},
last: function() {
return this.active && !this.active.next().length;
return this.active && !this.active.nextAll(".ui-menu-item").length;
},
move: function(direction, edge, event) {