Skip to content

Commit

Permalink
Autocomplete: Add 1px to the width of the menu to avoid wrapping in F…
Browse files Browse the repository at this point in the history
…irefox. Fixes #7513 - Autocomplete: long text wraps in Firefox.
  • Loading branch information
scottgonzalez committed Oct 25, 2011
1 parent 6625060 commit 4cc61b4
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion ui/jquery.ui.autocomplete.js
Expand Up @@ -452,7 +452,9 @@ $.widget( "ui.autocomplete", {
_resizeMenu: function() { _resizeMenu: function() {
var ul = this.menu.element; var ul = this.menu.element;
ul.outerWidth( Math.max( ul.outerWidth( Math.max(
ul.width( "" ).outerWidth(), // Firefox wraps long text (possibly a rounding bug)
// so we add 1px to avoid the wrapping (#7513)
ul.width( "" ).outerWidth() + 1,
this.element.outerWidth() this.element.outerWidth()
) ); ) );
}, },
Expand Down

0 comments on commit 4cc61b4

Please sign in to comment.