Allow chaining for .select2('readonly', ...)
This commit is contained in:
parent
596cf52d07
commit
bd3bd55719
@ -1146,12 +1146,11 @@ the specific language governing permissions and limitations under the Apache Lic
|
|||||||
// abstract
|
// abstract
|
||||||
readonly: function(enabled) {
|
readonly: function(enabled) {
|
||||||
if (enabled === undefined) enabled = false;
|
if (enabled === undefined) enabled = false;
|
||||||
if (this._readonly === enabled) return false;
|
if (this._readonly === enabled) return;
|
||||||
this._readonly = enabled;
|
this._readonly = enabled;
|
||||||
|
|
||||||
this.opts.element.prop("readonly", enabled);
|
this.opts.element.prop("readonly", enabled);
|
||||||
this.enableInterface();
|
this.enableInterface();
|
||||||
return true;
|
|
||||||
},
|
},
|
||||||
|
|
||||||
// abstract
|
// abstract
|
||||||
|
Loading…
Reference in New Issue
Block a user