[PE] Fix bug 43820

This commit is contained in:
Julia Svinareva 2019-12-10 13:09:52 +03:00
parent 77fa200246
commit 9eac6bf8f2

View file

@ -210,7 +210,7 @@ define([ 'text!presentationeditor/main/app/template/ParagraphSettingsAdvanced
var properties = (this._originalProps) ? this._originalProps : new Asc.asc_CParagraphProperty();
this.Spacing = properties.get_Spacing();
}
this.Spacing.Before = Common.Utils.Metric.fnRecalcToMM(field.getNumberValue());
this.Spacing.put_Before(Common.Utils.Metric.fnRecalcToMM(field.getNumberValue()));
}, this));
this.spinners.push(this.numSpacingBefore);
@ -230,7 +230,7 @@ define([ 'text!presentationeditor/main/app/template/ParagraphSettingsAdvanced
var properties = (this._originalProps) ? this._originalProps : new Asc.asc_CParagraphProperty();
this.Spacing = properties.get_Spacing();
}
this.Spacing.After = Common.Utils.Metric.fnRecalcToMM(field.getNumberValue());
this.Spacing.put_After(Common.Utils.Metric.fnRecalcToMM(field.getNumberValue()));
}, this));
this.spinners.push(this.numSpacingAfter);
@ -745,14 +745,14 @@ define([ 'text!presentationeditor/main/app/template/ParagraphSettingsAdvanced
var properties = (this._originalProps) ? this._originalProps : new Asc.asc_CParagraphProperty();
this.Spacing = properties.get_Spacing();
}
this.Spacing.LineRule = record.value;
this.Spacing.put_LineRule(record.value);
var selectItem = _.findWhere(this._arrLineRule, {value: record.value}),
indexSelectItem = this._arrLineRule.indexOf(selectItem);
if ( this.CurLineRuleIdx !== indexSelectItem ) {
this.numLineHeight.setDefaultUnit(this._arrLineRule[indexSelectItem].defaultUnit);
this.numLineHeight.setMinValue(this._arrLineRule[indexSelectItem].minValue);
this.numLineHeight.setStep(this._arrLineRule[indexSelectItem].step);
if (this.Spacing.LineRule === c_paragraphLinerule.LINERULE_AUTO) {
if (this.Spacing.get_LineRule() === c_paragraphLinerule.LINERULE_AUTO) {
this.numLineHeight.setValue(this._arrLineRule[indexSelectItem].defaultValue);
} else {
this.numLineHeight.setValue(Common.Utils.Metric.fnRecalcFromMM(this._arrLineRule[indexSelectItem].defaultValue));
@ -768,7 +768,7 @@ define([ 'text!presentationeditor/main/app/template/ParagraphSettingsAdvanced
var properties = (this._originalProps) ? this._originalProps : new Asc.asc_CParagraphProperty();
this.Spacing = properties.get_Spacing();
}
this.Spacing.Line = (this.cmbLineRule.getValue()==c_paragraphLinerule.LINERULE_AUTO) ? field.getNumberValue() : Common.Utils.Metric.fnRecalcToMM(field.getNumberValue());
this.Spacing.put_Line((this.cmbLineRule.getValue()==c_paragraphLinerule.LINERULE_AUTO) ? field.getNumberValue() : Common.Utils.Metric.fnRecalcToMM(field.getNumberValue()));
},
textTitle: 'Paragraph - Advanced Settings',