From ac8a4db76f49f6730b7eb55278f6b8153d2ded84 Mon Sep 17 00:00:00 2001 From: Mitko Tschimev Date: Wed, 4 Jul 2012 13:16:29 +0200 Subject: [PATCH] bugfix moveHighlight: disabled list elements were highlighted now they are ignored Signed-off-by: Igor Vaynberg --- select2.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/select2.js b/select2.js index 4884a0fb..45c4f62a 100755 --- a/select2.js +++ b/select2.js @@ -823,7 +823,8 @@ while (index > -1 && index < choices.length) { index += delta; - if ($(choices[index]).hasClass("select2-result-selectable")) { + var choice = $(choices[index]); + if (choice.hasClass("select2-result-selectable") && !choice.hasClass("select2-disabled")) { this.highlight(index); break; }