diff --git a/apps/documenteditor/main/app/view/ShapeSettings.js b/apps/documenteditor/main/app/view/ShapeSettings.js index 4a0c4d6c40..bc47700686 100644 --- a/apps/documenteditor/main/app/view/ShapeSettings.js +++ b/apps/documenteditor/main/app/view/ShapeSettings.js @@ -698,15 +698,23 @@ define([ }, onLineTransparencyChange: function(field, newValue, oldValue){ - this._sliderChangedLine = newValue; this.numLineTransparency.setValue(newValue, true); - this.updatesliderline = setInterval(_.bind(this._transparencyLineApplyFunc, this), 100); + this._sliderChangedLine = newValue; + if (this._sendUndoPoint) { + this.api.setStartPointHistory(); + this._sendUndoPoint = false; + this.updatesliderline = setInterval(_.bind(this._transparencyLineApplyFunc, this), 100); + } }, onLineTransparencyChangeComplete: function(field, newValue, oldValue){ clearInterval(this.updatesliderline); this._sliderChangedLine = newValue; - this._transparencyLineApplyFunc(); + if (!this._sendUndoPoint) { // start point was added + this.api.setEndPointHistory(); + this._transparencyLineApplyFunc(); + } + this._sendUndoPoint = true; }, _transparencyLineApplyFunc: function() { diff --git a/apps/documenteditor/main/app/view/TextArtSettings.js b/apps/documenteditor/main/app/view/TextArtSettings.js index ce85e31505..89142bbee7 100644 --- a/apps/documenteditor/main/app/view/TextArtSettings.js +++ b/apps/documenteditor/main/app/view/TextArtSettings.js @@ -74,6 +74,7 @@ define([ this.shapeprops = null; this._sendUndoPoint = true; this._sliderChanged = false; + this._sliderChangedLine = this._sliderChanged; this.txtPt = Common.Utils.Metric.getMetricName(Common.Utils.Metric.c_MetricUnits.pt); @@ -557,7 +558,7 @@ define([ var props = new Asc.asc_TextArtProperties(); var stroke = new Asc.asc_CStroke(); stroke.put_transparent(this._state.LineTransparency); - props.put_stroke(stroke); + props.asc_putLine(stroke); this.shapeprops.put_TextArtProperties(props); this.api.ImgApply(this.imgprops); } @@ -566,13 +567,21 @@ define([ onLineTransparencyChange: function(field, newValue, oldValue){ this._sliderChangedLine = newValue; this.numLineTransparency.setValue(newValue, true); - this.updatesliderline = setInterval(_.bind(this._transparencyLineApplyFunc, this), 100); + if (this._sendUndoPoint) { + this.api.setStartPointHistory(); + this._sendUndoPoint = false; + this.updatesliderline = setInterval(_.bind(this._transparencyLineApplyFunc, this), 100); + } }, onLineTransparencyChangeComplete: function(field, newValue, oldValue){ clearInterval(this.updatesliderline); this._sliderChangedLine = newValue; - this._transparencyLineApplyFunc(); + if (!this._sendUndoPoint) { // start point was added + this.api.setEndPointHistory(); + this._transparencyLineApplyFunc(); + } + this._sendUndoPoint = true; }, _transparencyLineApplyFunc: function() { diff --git a/apps/presentationeditor/main/app/view/ShapeSettings.js b/apps/presentationeditor/main/app/view/ShapeSettings.js index 9cb5734b84..013bbb326f 100644 --- a/apps/presentationeditor/main/app/view/ShapeSettings.js +++ b/apps/presentationeditor/main/app/view/ShapeSettings.js @@ -701,13 +701,21 @@ define([ onLineTransparencyChange: function(field, newValue, oldValue){ this._sliderChangedLine = newValue; this.numLineTransparency.setValue(newValue, true); - this.updatesliderline = setInterval(_.bind(this._transparencyLineApplyFunc, this), 100); + if (this._sendUndoPoint) { + this.api.setStartPointHistory(); + this._sendUndoPoint = false; + this.updatesliderline = setInterval(_.bind(this._transparencyLineApplyFunc, this), 100); + } }, onLineTransparencyChangeComplete: function(field, newValue, oldValue){ clearInterval(this.updatesliderline); this._sliderChangedLine = newValue; - this._transparencyLineApplyFunc(); + if (!this._sendUndoPoint) { // start point was added + this.api.setEndPointHistory(); + this._transparencyLineApplyFunc(); + } + this._sendUndoPoint = true; }, _transparencyLineApplyFunc: function() { diff --git a/apps/presentationeditor/main/app/view/TextArtSettings.js b/apps/presentationeditor/main/app/view/TextArtSettings.js index 234deb1510..11178c49e0 100644 --- a/apps/presentationeditor/main/app/view/TextArtSettings.js +++ b/apps/presentationeditor/main/app/view/TextArtSettings.js @@ -692,13 +692,21 @@ define([ onLineTransparencyChange: function(field, newValue, oldValue){ this._sliderChangedLine = newValue; this.numLineTransparency.setValue(newValue, true); - this.updatesliderline = setInterval(_.bind(this._transparencyLineApplyFunc, this), 100); + if (this._sendUndoPoint) { + this.api.setStartPointHistory(); + this._sendUndoPoint = false; + this.updatesliderline = setInterval(_.bind(this._transparencyLineApplyFunc, this), 100); + } }, onLineTransparencyChangeComplete: function(field, newValue, oldValue){ clearInterval(this.updatesliderline); this._sliderChangedLine = newValue; - this._transparencyLineApplyFunc(); + if (!this._sendUndoPoint) { // start point was added + this.api.setEndPointHistory(); + this._transparencyLineApplyFunc(); + } + this._sendUndoPoint = true; }, _transparencyLineApplyFunc: function() { diff --git a/apps/spreadsheeteditor/main/app/view/ShapeSettings.js b/apps/spreadsheeteditor/main/app/view/ShapeSettings.js index 2420276a77..c684ca6a2e 100644 --- a/apps/spreadsheeteditor/main/app/view/ShapeSettings.js +++ b/apps/spreadsheeteditor/main/app/view/ShapeSettings.js @@ -692,13 +692,21 @@ define([ onLineTransparencyChange: function(field, newValue, oldValue){ this._sliderChangedLine = newValue; this.numLineTransparency.setValue(newValue, true); - this.updatesliderline = setInterval(_.bind(this._transparencyLineApplyFunc, this), 100); + if (this._sendUndoPoint) { + this.api.setStartPointHistory(); + this._sendUndoPoint = false; + this.updatesliderline = setInterval(_.bind(this._transparencyLineApplyFunc, this), 100); + } }, onLineTransparencyChangeComplete: function(field, newValue, oldValue){ clearInterval(this.updatesliderline); this._sliderChangedLine = newValue; - this._transparencyLineApplyFunc(); + if (!this._sendUndoPoint) { // start point was added + this.api.setEndPointHistory(); + this._transparencyLineApplyFunc(); + } + this._sendUndoPoint = true; }, _transparencyLineApplyFunc: function() { diff --git a/apps/spreadsheeteditor/main/app/view/TextArtSettings.js b/apps/spreadsheeteditor/main/app/view/TextArtSettings.js index 92684110a9..df050a9eb7 100644 --- a/apps/spreadsheeteditor/main/app/view/TextArtSettings.js +++ b/apps/spreadsheeteditor/main/app/view/TextArtSettings.js @@ -685,13 +685,21 @@ define([ onLineTransparencyChange: function(field, newValue, oldValue){ this._sliderChangedLine = newValue; this.numLineTransparency.setValue(newValue, true); - this.updatesliderline = setInterval(_.bind(this._transparencyLineApplyFunc, this), 100); + if (this._sendUndoPoint) { + this.api.setStartPointHistory(); + this._sendUndoPoint = false; + this.updatesliderline = setInterval(_.bind(this._transparencyLineApplyFunc, this), 100); + } }, onLineTransparencyChangeComplete: function(field, newValue, oldValue){ clearInterval(this.updatesliderline); this._sliderChangedLine = newValue; - this._transparencyLineApplyFunc(); + if (!this._sendUndoPoint) { // start point was added + this.api.setEndPointHistory(); + this._transparencyLineApplyFunc(); + } + this._sendUndoPoint = true; }, _transparencyLineApplyFunc: function() {