[SSE] Fix Bug 40188
This commit is contained in:
parent
164378dfaa
commit
d4d0607546
|
@ -44,5 +44,21 @@
|
|||
<div id="cell-back-color-btn" style="display: inline-block;text-align:left;"></div>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="padding-small" colspan=2>
|
||||
<div class="separator horizontal"></div>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td colspan=2 class="padding-small">
|
||||
<label class="header"><%= scope.textOrientation %></label>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="padding-small" colspan=2>
|
||||
<label class="input-label"><%= scope.textAngle %></label>
|
||||
<div id="cell-spin-angle" style="display: inline-block;margin-left:5px;"></div>
|
||||
</td>
|
||||
</tr>
|
||||
<tr class="finish-cell"></tr>
|
||||
</table>
|
|
@ -69,7 +69,8 @@ define([
|
|||
|
||||
this._state = {
|
||||
BackColor: undefined,
|
||||
DisabledControls: true
|
||||
DisabledControls: true,
|
||||
CellAngle: undefined
|
||||
};
|
||||
this.lockedControls = [];
|
||||
this._locked = true;
|
||||
|
@ -133,6 +134,10 @@ define([
|
|||
this.BorderType = record.value;
|
||||
},
|
||||
|
||||
onAngleChange: function(field, newValue, oldValue, eOpts) {
|
||||
this.api && this.api.asc_setCellAngle(field.getNumberValue());
|
||||
},
|
||||
|
||||
render: function () {
|
||||
var el = $(this.el);
|
||||
el.html(this.template({
|
||||
|
@ -218,6 +223,18 @@ define([
|
|||
this.btnBackColor.render( $('#cell-back-color-btn'));
|
||||
this.btnBackColor.setColor('transparent');
|
||||
this.lockedControls.push(this.btnBackColor);
|
||||
|
||||
this.spnAngle = new Common.UI.MetricSpinner({
|
||||
el: $('#cell-spin-angle'),
|
||||
step: 1,
|
||||
width: 60,
|
||||
defaultUnit : "°",
|
||||
value: '0 °',
|
||||
maxValue: 90,
|
||||
minValue: -90
|
||||
});
|
||||
this.lockedControls.push(this.spnAngle);
|
||||
this.spnAngle.on('change', _.bind(this.onAngleChange, this));
|
||||
},
|
||||
|
||||
createDelayedElements: function() {
|
||||
|
@ -267,6 +284,12 @@ define([
|
|||
}
|
||||
this._state.BackColor = clr;
|
||||
}
|
||||
|
||||
var value = props.asc_getAngle();
|
||||
if ( Math.abs(this._state.CellAngle-value)>0.1 || (this._state.CellAngle===undefined)&&(this._state.CellAngle!==value)) {
|
||||
this.spnAngle.setValue((value !== null) ? value : '', true);
|
||||
this._state.CellAngle=value;
|
||||
}
|
||||
}
|
||||
},
|
||||
|
||||
|
@ -341,7 +364,9 @@ define([
|
|||
tipInnerHor: 'Set Horizontal Inner Lines Only',
|
||||
tipOuter: 'Set Outer Border Only',
|
||||
tipDiagU: 'Set Diagonal Up Border',
|
||||
tipDiagD: 'Set Diagonal Down Border'
|
||||
tipDiagD: 'Set Diagonal Down Border',
|
||||
textOrientation: 'Text Orientation',
|
||||
textAngle: 'Angle'
|
||||
|
||||
}, SSE.Views.CellSettings || {}));
|
||||
});
|
|
@ -1133,6 +1133,8 @@
|
|||
"SSE.Views.CellSettings.tipOuter": "Set outer border only",
|
||||
"SSE.Views.CellSettings.tipRight": "Set outer right border only",
|
||||
"SSE.Views.CellSettings.tipTop": "Set outer top border only",
|
||||
"SSE.Views.CellSettings.textOrientation": "Text Orientation",
|
||||
"SSE.Views.CellSettings.textAngle": "Angle",
|
||||
"SSE.Views.ChartSettings.strLineWeight": "Line Weight",
|
||||
"SSE.Views.ChartSettings.strSparkColor": "Color",
|
||||
"SSE.Views.ChartSettings.strTemplate": "Template",
|
||||
|
|
Loading…
Reference in a new issue