[DE] Fix changing focus on form settings panel
This commit is contained in:
parent
7b225d6864
commit
6a34c61181
|
@ -341,21 +341,23 @@ define([
|
||||||
},
|
},
|
||||||
|
|
||||||
onPlaceholderChanged: function(input, newValue, oldValue, e) {
|
onPlaceholderChanged: function(input, newValue, oldValue, e) {
|
||||||
if (this.api && !this._noApply) {
|
if (this.api && !this._noApply && (newValue!==oldValue)) {
|
||||||
var props = this._originalProps || new AscCommon.CContentControlPr();
|
var props = this._originalProps || new AscCommon.CContentControlPr();
|
||||||
props.put_PlaceholderText(newValue || ' ');
|
props.put_PlaceholderText(newValue || ' ');
|
||||||
this.api.asc_SetContentControlProperties(props, this.internalId);
|
this.api.asc_SetContentControlProperties(props, this.internalId);
|
||||||
|
if (!e.relatedTarget || (e.relatedTarget.localName != 'input' && e.relatedTarget.localName != 'textarea') || !/form-control/.test(e.relatedTarget.className))
|
||||||
this.fireEvent('editcomplete', this);
|
this.fireEvent('editcomplete', this);
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
onHelpChanged: function(input, newValue, oldValue, e) {
|
onHelpChanged: function(input, newValue, oldValue, e) {
|
||||||
if (this.api && !this._noApply) {
|
if (this.api && !this._noApply && (newValue!==oldValue)) {
|
||||||
var props = this._originalProps || new AscCommon.CContentControlPr();
|
var props = this._originalProps || new AscCommon.CContentControlPr();
|
||||||
var formPr = this._originalFormProps || new AscCommon.CSdtFormPr();
|
var formPr = this._originalFormProps || new AscCommon.CSdtFormPr();
|
||||||
formPr.put_HelpText(newValue);
|
formPr.put_HelpText(newValue);
|
||||||
props.put_FormPr(formPr);
|
props.put_FormPr(formPr);
|
||||||
this.api.asc_SetContentControlProperties(props, this.internalId);
|
this.api.asc_SetContentControlProperties(props, this.internalId);
|
||||||
|
if (!e.relatedTarget || (e.relatedTarget.localName != 'input' && e.relatedTarget.localName != 'textarea') || !/form-control/.test(e.relatedTarget.className))
|
||||||
this.fireEvent('editcomplete', this);
|
this.fireEvent('editcomplete', this);
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
Loading…
Reference in a new issue