[third] Mouse-enable naturalSearch option in typeahead.

When hover over a typeahead menu item, the semantics have always been
to make it active, and now we also respect the naturalSearch option
there, which will set the text of the search box to the suggestion
immediately upon hover.

(imported from commit 02318d3d830e7e28d638efee0ef27023a73f52f7)
This commit is contained in:
Steve Howell 2013-07-25 15:52:59 -04:00
parent 7a3a3be7e5
commit 6217c1a3be
1 changed files with 4 additions and 0 deletions

View File

@ -2100,6 +2100,10 @@
, mouseenter: function (e) {
this.$menu.find('.active').removeClass('active')
$(e.currentTarget).addClass('active')
if (this.options.naturalSearch) {
this.set_value();
}
}
}