Skip to content

Commit

Permalink
Fix issue where nodes that were created after the widget was shown ca…
Browse files Browse the repository at this point in the history
…used it to hide, because the test for nesting depended on ids
  • Loading branch information
saw committed May 11, 2012
1 parent 61056b6 commit ebb4caa
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions src/autocomplete/js/autocomplete-list.js
Original file line number Diff line number Diff line change
Expand Up @@ -609,9 +609,8 @@ List = Y.Base.create('autocompleteList', Y.Widget, [
var boundingBox = this._boundingBox,
target = e.target;

if (target !== this._inputNode && target !== boundingBox &&
!boundingBox.one(target.get('id'))) {

if(target !== this._inputNode && target !== boundingBox &&
target.ancestor('#' + boundingBox.get('id'), true)){
this.hide();
}
},
Expand Down

0 comments on commit ebb4caa

Please sign in to comment.