From d2272f86bcc4f526f886f6b7846e34c0f1442c34 Mon Sep 17 00:00:00 2001 From: Richard Worth Date: Mon, 15 Mar 2010 21:24:42 +0000 Subject: Autocomplete: fixed #5349 - Autocomplete: mouseover of menu item causes data loss --- ui/jquery.ui.autocomplete.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/ui/jquery.ui.autocomplete.js b/ui/jquery.ui.autocomplete.js index 2efd4e64b..92b9878ec 100644 --- a/ui/jquery.ui.autocomplete.js +++ b/ui/jquery.ui.autocomplete.js @@ -119,7 +119,9 @@ $.widget( "ui.autocomplete", { } }, blur: function( event, ui ) { - self.element.val( self.term ); + if ( self.menu.element.is(":visible") ) { + self.element.val( self.term ); + } } }) .zIndex( this.element.zIndex() + 1 ) -- cgit v1.2.3