1
0
mirror of synced 2024-11-22 21:16:10 +03:00

Merge pull request #2720 from josmardias/fix-ie8-ie9

Fixing IE8 and IE9 issues on select2#3.5.1
This commit is contained in:
Kevin Brown 2014-10-07 12:25:56 -04:00
commit 08ee57a03c

View File

@ -855,7 +855,9 @@ the specific language governing permissions and limitations under the Apache Lic
if (element.length && element[0].detachEvent && self._sync) { if (element.length && element[0].detachEvent && self._sync) {
element.each(function () { element.each(function () {
if (self._sync) {
this.detachEvent("onpropertychange", self._sync); this.detachEvent("onpropertychange", self._sync);
}
}); });
} }
if (this.propertyObserver) { if (this.propertyObserver) {
@ -1116,11 +1118,15 @@ the specific language governing permissions and limitations under the Apache Lic
if (readonly === undefined) readonly = false; if (readonly === undefined) readonly = false;
this.readonly(readonly); this.readonly(readonly);
if (this.container) {
syncCssClasses(this.container, this.opts.element, this.opts.adaptContainerCssClass); syncCssClasses(this.container, this.opts.element, this.opts.adaptContainerCssClass);
this.container.addClass(evaluate(this.opts.containerCssClass, this.opts.element)); this.container.addClass(evaluate(this.opts.containerCssClass, this.opts.element));
}
if (this.dropdown) {
syncCssClasses(this.dropdown, this.opts.element, this.opts.adaptDropdownCssClass); syncCssClasses(this.dropdown, this.opts.element, this.opts.adaptDropdownCssClass);
this.dropdown.addClass(evaluate(this.opts.dropdownCssClass, this.opts.element)); this.dropdown.addClass(evaluate(this.opts.dropdownCssClass, this.opts.element));
}
}); });