aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--ui/jquery.ui.autocomplete.js4
1 files changed, 4 insertions, 0 deletions
diff --git a/ui/jquery.ui.autocomplete.js b/ui/jquery.ui.autocomplete.js
index 7349ce98b..2efd4e64b 100644
--- a/ui/jquery.ui.autocomplete.js
+++ b/ui/jquery.ui.autocomplete.js
@@ -117,6 +117,9 @@ $.widget( "ui.autocomplete", {
if ( self.element[0] !== doc.activeElement ) {
self.element.focus();
}
+ },
+ blur: function( event, ui ) {
+ self.element.val( self.term );
}
})
.zIndex( this.element.zIndex() + 1 )
@@ -379,6 +382,7 @@ $.widget("ui.menu", {
this.active.children("a")
.removeClass("ui-state-hover")
.removeAttr("id");
+ this._trigger("blur", null, {});
this.active = null;
},