commit
cd2fa4362e
|
@ -116,13 +116,12 @@ define([
|
|||
}
|
||||
},
|
||||
|
||||
show: function() {
|
||||
Common.UI.Window.prototype.show.apply(this, arguments);
|
||||
getFocusedComponents: function() {
|
||||
return [this.inputPwd, this.repeatPwd];
|
||||
},
|
||||
|
||||
var me = this;
|
||||
setTimeout(function(){
|
||||
me.inputPwd.cmpEl.find('input').focus();
|
||||
}, 500);
|
||||
getDefaultFocusableComponent: function () {
|
||||
return this.inputPwd;
|
||||
},
|
||||
|
||||
onPrimary: function(event) {
|
||||
|
|
|
@ -1092,7 +1092,7 @@ define([
|
|||
var range = props.getRange(),
|
||||
isvalid = (!_.isEmpty(range)) ? me.api.asc_checkDataRange(Asc.c_oAscSelectionDialogType.Chart, range, true, props.getInRows(), props.getType()) : Asc.c_oAscError.ID.No;
|
||||
if (isvalid == Asc.c_oAscError.ID.No) {
|
||||
(ischartedit) ? me.api.asc_editChartDrawingObject(props) : me.api.asc_addChartDrawingObject(props);
|
||||
!ischartedit && me.api.asc_addChartDrawingObject(props);
|
||||
} else {
|
||||
var msg = me.txtInvalidRange;
|
||||
switch (isvalid) {
|
||||
|
|
|
@ -260,6 +260,12 @@ define([ 'text!spreadsheeteditor/main/app/template/ChartSettingsDlg.template'
|
|||
this.chVertHide = [];
|
||||
this.btnVFormat = [];
|
||||
|
||||
this._arrVertTitle = [
|
||||
{value: Asc.c_oAscChartVertAxisLabelShowSettings.none, displayValue: me.textNone},
|
||||
{value: Asc.c_oAscChartVertAxisLabelShowSettings.rotated, displayValue: me.textRotated},
|
||||
{value: Asc.c_oAscChartVertAxisLabelShowSettings.horizontal, displayValue: me.textHorizontal}
|
||||
];
|
||||
|
||||
var addControlsV = function(i) {
|
||||
me.chVertHide[i] = new Common.UI.CheckBox({
|
||||
el: $('#chart-dlg-chk-vert-hide-' + i),
|
||||
|
@ -274,11 +280,7 @@ define([ 'text!spreadsheeteditor/main/app/template/ChartSettingsDlg.template'
|
|||
menuStyle: 'min-width: 140px;',
|
||||
editable: false,
|
||||
cls: 'input-group-nr',
|
||||
data: [
|
||||
{value: Asc.c_oAscChartVertAxisLabelShowSettings.none, displayValue: me.textNone},
|
||||
{value: Asc.c_oAscChartVertAxisLabelShowSettings.rotated, displayValue: me.textRotated},
|
||||
{value: Asc.c_oAscChartVertAxisLabelShowSettings.horizontal, displayValue: me.textHorizontal}
|
||||
],
|
||||
data: me._arrVertTitle,
|
||||
takeFocusOnClose: true
|
||||
}).on('selected', _.bind(function (combo, record) {
|
||||
if (me.currentAxisProps[i])
|
||||
|
@ -535,6 +537,11 @@ define([ 'text!spreadsheeteditor/main/app/template/ChartSettingsDlg.template'
|
|||
this.chHorHide = [];
|
||||
this.btnHFormat = [];
|
||||
|
||||
this._arrHorTitle = [
|
||||
{value: Asc.c_oAscChartHorAxisLabelShowSettings.none, displayValue: me.textNone},
|
||||
{value: Asc.c_oAscChartHorAxisLabelShowSettings.noOverlay, displayValue: me.textNoOverlay}
|
||||
];
|
||||
|
||||
var addControlsH = function(i) {
|
||||
me.chHorHide[i] = new Common.UI.CheckBox({
|
||||
el: $('#chart-dlg-chk-hor-hide-' + i),
|
||||
|
@ -549,10 +556,7 @@ define([ 'text!spreadsheeteditor/main/app/template/ChartSettingsDlg.template'
|
|||
menuStyle: 'min-width: 140px;',
|
||||
editable: false,
|
||||
cls: 'input-group-nr',
|
||||
data: [
|
||||
{value: Asc.c_oAscChartHorAxisLabelShowSettings.none, displayValue: me.textNone},
|
||||
{value: Asc.c_oAscChartHorAxisLabelShowSettings.noOverlay, displayValue: me.textNoOverlay}
|
||||
],
|
||||
data: me._arrHorTitle,
|
||||
takeFocusOnClose: true
|
||||
}).on('selected', _.bind(function (combo, record) {
|
||||
if (me.currentAxisProps[i])
|
||||
|
@ -1192,14 +1196,14 @@ define([ 'text!spreadsheeteditor/main/app/template/ChartSettingsDlg.template'
|
|||
},
|
||||
|
||||
onVCategoryClick: function(index) {
|
||||
(this.vertAxisProps[index].getAxisType()==Asc.c_oAscAxisType.val) ? this.fillVProps(this.vertAxisProps[index], index) : this.fillHProps(this.vertAxisProps[index], index);
|
||||
(this.vertAxisProps[index].getAxisType()==Asc.c_oAscAxisType.val) ? this.fillVProps(this.vertAxisProps[index], index) : this.fillHProps(this.vertAxisProps[index], index, true);
|
||||
},
|
||||
|
||||
onHCategoryClick: function(index) {
|
||||
(this.horAxisProps[index].getAxisType()==Asc.c_oAscAxisType.val) ? this.fillVProps(this.horAxisProps[index], index) : this.fillHProps(this.horAxisProps[index], index);
|
||||
(this.horAxisProps[index].getAxisType()==Asc.c_oAscAxisType.val) ? this.fillVProps(this.horAxisProps[index], index, true) : this.fillHProps(this.horAxisProps[index], index);
|
||||
},
|
||||
|
||||
fillVProps: function(props, index) {
|
||||
fillVProps: function(props, index, hor) {
|
||||
if (props.getAxisType() !== Asc.c_oAscAxisType.val) return;
|
||||
if (this._originalAxisVValues==undefined)
|
||||
this._originalAxisVValues = [];
|
||||
|
@ -1213,6 +1217,9 @@ define([ 'text!spreadsheeteditor/main/app/template/ChartSettingsDlg.template'
|
|||
|
||||
this.chVertHide[index].setValue(!props.getShow());
|
||||
this.cmbVertGrid[index].setValue(props.getGridlines());
|
||||
|
||||
|
||||
this.cmbVertTitle[index].setData(hor ? this._arrHorTitle : this._arrVertTitle);
|
||||
this.cmbVertTitle[index].setValue(props.getLabel());
|
||||
|
||||
this.cmbMinType[index].setValue(props.getMinValRule());
|
||||
|
@ -1250,7 +1257,7 @@ define([ 'text!spreadsheeteditor/main/app/template/ChartSettingsDlg.template'
|
|||
this.currentAxisProps[index] = props;
|
||||
},
|
||||
|
||||
fillHProps: function(props, index) {
|
||||
fillHProps: function(props, index, vert) {
|
||||
if (props.getAxisType() !== Asc.c_oAscAxisType.cat) return;
|
||||
if (this._originalAxisHValues==undefined)
|
||||
this._originalAxisHValues = [];
|
||||
|
@ -1264,6 +1271,8 @@ define([ 'text!spreadsheeteditor/main/app/template/ChartSettingsDlg.template'
|
|||
|
||||
this.chHorHide[index].setValue(!props.getShow());
|
||||
this.cmbHorGrid[index].setValue(props.getGridlines());
|
||||
|
||||
this.cmbHorTitle[index].setData(vert ? this._arrVertTitle : this._arrHorTitle);
|
||||
this.cmbHorTitle[index].setValue(props.getLabel());
|
||||
|
||||
var value = props.getCrossesRule();
|
||||
|
|
Loading…
Reference in a new issue