diff options
Diffstat (limited to 'js')
-rw-r--r-- | js/jquery.multi-select.js | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/js/jquery.multi-select.js b/js/jquery.multi-select.js index 488b9ca..d71ca10 100644 --- a/js/jquery.multi-select.js +++ b/js/jquery.multi-select.js @@ -184,6 +184,14 @@ $container = option.nested === undefined ? that.$element : $("optgroup[label='"+option.nested+"']"), index = parseInt((typeof option.index === 'undefined' ? $container.children().length : option.index)); + if (option.optionClass) { + $option.addClass(option.optionClass); + } + + if (option.disabled) { + $option.prop('disabled', true); + } + $option.insertAt(index, $container); that.generateLisFromOption($option.get(0), index, option.nested); } |