diff options
author | Felix Nagel <info@felixnagel.com> | 2011-04-16 17:24:49 +0200 |
---|---|---|
committer | Felix Nagel <info@felixnagel.com> | 2011-04-16 17:24:49 +0200 |
commit | 61a0844fb94298a4468834c9f7f6e9fcf25af301 (patch) | |
tree | dfa016a00b2432f423ba804da9769fd784d4ae8c | |
parent | 351b73989861d6d8cd1ec750aebc900779d9ab6e (diff) | |
download | jquery-ui-61a0844fb94298a4468834c9f7f6e9fcf25af301.tar.gz jquery-ui-61a0844fb94298a4468834c9f7f6e9fcf25af301.zip |
fixed: keyboards loop issue, thanks to gcko, see https://github.com/fnagel/jquery-ui/issues/89
-rw-r--r-- | ui/jquery.ui.selectmenu.js | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/ui/jquery.ui.selectmenu.js b/ui/jquery.ui.selectmenu.js index 7c0f61a7a..93f1ac858 100644 --- a/ui/jquery.ui.selectmenu.js +++ b/ui/jquery.ui.selectmenu.js @@ -579,7 +579,8 @@ $.widget("ui.selectmenu", { _moveSelection: function(amt) { var currIndex = parseInt(this._selectedOptionLi().data('index'), 10); var newIndex = currIndex + amt; - return this._optionLis.eq(newIndex).trigger('mouseup'); + // do not loop when using up key + if (newIndex >= 0 ) return this._optionLis.eq(newIndex).trigger('mouseup'); }, _moveFocus: function(amt) { |