For Bug 48260

This commit is contained in:
Julia Radzhabova 2021-01-16 19:00:17 +03:00
parent 7ecb043d4d
commit 43997a0c4e
3 changed files with 14 additions and 11 deletions

View file

@ -360,20 +360,15 @@ define([
return false;
}
else if (e.keyCode == Common.UI.Keys.RETURN && (this.editable || this.isMenuOpen())) {
var isopen = this.isMenuOpen();
$(e.target).click();
var me = this;
if (this.rendered) {
if (Common.Utils.isIE)
this._input.trigger('change', { onkeydown: true });
else
this._input.blur();
}
if (!this.isMenuOpen()) {
if ((this.getRawValue() === this.lastValue))
return true;
this.setRawValue(this._input.val());
}
return false;
return !isopen;
}
else if (e.keyCode == Common.UI.Keys.ESC && this.isMenuOpen()) {
this._input.val(this.lastValue);

View file

@ -131,6 +131,8 @@ define([
if ($(e.target).closest('input').length) { // enter in input field
if (this.lastValue !== this._input.val())
this._input.trigger('change');
else
return true;
} else { // enter in dropdown list
$(e.target).click();
if (this.rendered) {

View file

@ -551,8 +551,11 @@ define([
if (combo.getSelectedRecord()) {
me._changedProps.put_XAlign(record.value);
} else {
var number = Common.Utils.String.parseFloat(record.value);
if (!isNaN(number)) {
me._changedProps.put_XAlign(undefined);
me._changedProps.put_X(Common.Utils.Metric.fnRecalcToMM(Common.Utils.String.parseFloat(record.value)));
me._changedProps.put_X(Common.Utils.Metric.fnRecalcToMM(number));
}
}
}
}, me))
@ -600,10 +603,13 @@ define([
if (combo.getSelectedRecord()) {
me._changedProps.put_YAlign(record.value);
} else {
var number = Common.Utils.String.parseFloat(record.value);
if (!isNaN(number)) {
me._changedProps.put_YAlign(undefined);
me._changedProps.put_Y(Common.Utils.Metric.fnRecalcToMM(Common.Utils.String.parseFloat(record.value)));
}
}
}
}, me))
.on('selected', _.bind(function(combo, record) {
if (me._changedProps) {