Commit 75e93642 authored by Sergey.Luzyanin's avatar Sergey.Luzyanin Committed by Alexander.Trofimov

Bug 24635 - Не появляются границы диапазона данных при использовании функции...

Bug 24635 - Не появляются границы диапазона данных при использовании функции "select data" во фрейме диаграммы

git-svn-id: svn://192.168.3.15/activex/AVS/Sources/TeamlabOffice/trunk/OfficeWeb@57732 954022d7-b5bf-4e40-9824-e11837661b57
parent c2d84e93
......@@ -225,21 +225,26 @@ DrawingObjectsController.prototype =
}
},
checkChartForProps: function()
checkChartForProps: function(bStart)
{
if(this.chartForProps)
return;
if(this.selection.groupSelection)
if(bStart)
{
if(this.selection.groupSelection.selectedObjects.length === 1 && this.selection.groupSelection.selectedObjects[0].getObjectType() === historyitem_type_ChartSpace)
{
this.chartForProps = this.selection.groupSelection.selectedObjects[0];
}
this.chartForProps = this.getSelectionState();
this.resetSelection();
this.drawingObjects.getWorksheet().arrActiveChartsRanges = [];
var oldIsStartAdd = window["Asc"]["editor"].isStartAddShape;
window["Asc"]["editor"].isStartAddShape = true;
this.updateOverlay();
window["Asc"]["editor"].isStartAddShape = oldIsStartAdd;
}
else if(this.selectedObjects.length === 1 && this.selectedObjects[0].getObjectType() === historyitem_type_ChartSpace)
else
{
this.chartForProps = this.selectedObjects[0];
this.setSelectionState(this.chartForProps, this.chartForProps.length - 1);
this.updateOverlay();
this.drawingObjects.getWorksheet().setSelectionShape(true);
this.chartForProps = null;
}
},
resetInternalSelection: function()
......@@ -2236,6 +2241,16 @@ DrawingObjectsController.prototype =
new_chart_type.upDownBars.setGapWidth(150);
new_chart_type.upDownBars.setUpBars(new CSpPr());
new_chart_type.upDownBars.setDownBars(new CSpPr());
val_axis = new_chart_type.getAxisByTypes().valAx;
for(i = 0; i < val_axis.length; ++i)
{
if(!val_axis[i].numFmt)
{
val_axis[i].setNumFmt(new CNumFmt());
}
if(val_axis[i].numFmt.formatCode !== "General")
val_axis[i].numFmt.setFormatCode("General");
}
}
break;
}
......
......@@ -10255,6 +10255,7 @@
WorksheetView.prototype.setSelectionDialogMode = function (selectionDialogType, selectRange) {
if (selectionDialogType === this.selectionDialogType)
return;
var oldSelectionDialogType = this.selectionDialogType;
this.selectionDialogType = selectionDialogType;
this.isSelectionDialogMode = c_oAscSelectionDialogType.None !== this.selectionDialogType;
this.cleanSelection();
......@@ -10263,7 +10264,12 @@
if (null !== this.copyActiveRange)
this.activeRange = this.copyActiveRange.clone(true);
this.copyActiveRange = null;
if(oldSelectionDialogType === c_oAscSelectionDialogType.Chart)
{
this.objectRender.controller.checkChartForProps(false);
}
} else {
this.copyActiveRange = this.activeRange.clone(true);
if (selectRange) {
if (typeof selectRange === 'string') {
......@@ -10275,9 +10281,12 @@
if (null != selectRange)
this.activeRange.assign(selectRange.c1, selectRange.r1, selectRange.c2, selectRange.r2);
}
if(selectionDialogType === c_oAscSelectionDialogType.Chart)
{
this.objectRender.controller.checkChartForProps(true);
}
}
this._drawSelection();
this.objectRender.controller.checkChartForProps();
};
// Получаем свойство: редактируем мы сейчас или нет
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment