1
0
mirror of synced 2025-02-09 16:49:24 +03:00

Merge pull request #2095 from mkurz/readonly_chaining

Allow chaining for .select2('readonly', ...)
This commit is contained in:
Kevin Brown 2014-02-03 15:46:53 -08:00
commit 3c28c35503

View File

@ -1151,12 +1151,11 @@ the specific language governing permissions and limitations under the Apache Lic
// abstract
readonly: function(enabled) {
if (enabled === undefined) enabled = false;
if (this._readonly === enabled) return false;
if (this._readonly === enabled) return;
this._readonly = enabled;
this.opts.element.prop("readonly", enabled);
this.enableInterface();
return true;
},
// abstract