From ab4d8b748d26df79f7e9cf32a5f80d07c05f790b Mon Sep 17 00:00:00 2001 From: Scott González Date: Thu, 10 May 2012 12:57:41 -0400 Subject: Autocomplete: Fixed context for handling async focus in IE; makes change event work properly in IE again. --- ui/jquery.ui.autocomplete.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ui/jquery.ui.autocomplete.js b/ui/jquery.ui.autocomplete.js index a5d832f0a..fab9691a3 100644 --- a/ui/jquery.ui.autocomplete.js +++ b/ui/jquery.ui.autocomplete.js @@ -247,10 +247,10 @@ $.widget( "ui.autocomplete", { // #6109 - IE triggers two focus events and the second // is asynchronous, so we need to reset the previous // term synchronously and asynchronously :-( - setTimeout(function() { + this._delay(function() { this.previous = previous; this.selectedItem = item; - }, 1); + }); } if ( false !== this._trigger( "select", event, { item: item } ) ) { -- cgit v1.2.3