marcj/jquery-selectBox — pull request #150 by bogdanRada (2014-03-05 17:53:53+00:00)
Title: Small fix for when selectbox destroyed

This is a fix for this case:

-- If a selectbox is destroyed but in code you still use this code
$('#element').selectBox('options', data) the select won't get changed with the new options

Changes made for selectbox to work when disabled

remove code " if (selectBox = $(this).data('selectBox')) {" from method $.extend($.fn, { Selectbox:
inside the case with "options" (because the code was only working if the selectbox was enabled)

move method SelectBox.prototype.setOptions inside $.extend($.fn, { setOptions
and set the select variable to $(this) instead of $(this.selectElement)
and for refresing replace code this.refresh(); with $(this).selectBox('refresh');

There might be better ways of dealing with this, but this fixed the issue for me.
I hope you will find it useful