Commit 3d1aaebf authored by Sergey.Luzyanin's avatar Sergey.Luzyanin Committed by Alexander.Trofimov

Bug 27643 - Вместо заливки изображением у диаграммы рисуется "красный крест" во фрейме

git-svn-id: svn://192.168.3.15/activex/AVS/Sources/TeamlabOffice/trunk/OfficeWeb@59942 954022d7-b5bf-4e40-9824-e11837661b57
parent c2e52089
......@@ -178,6 +178,10 @@ function asc_CChartBinary(chart) {
pptx_writer.WriteRecord1(1, chart.colorMapOverride, pptx_writer.WriteClrMap);
this["colorMapBinary"] = pptx_writer.pos + ";" + pptx_writer.GetBase64Memory();
}
if(typeof chart.DocumentUrl === "string" && chart.DocumentUrl.length > 0)
{
this["DocumentUrl"] = chart.DocumentUrl;
}
}
}
......@@ -2487,6 +2491,16 @@ function DrawingObjects() {
{
DEFAULT_COLOR_MAP = colorMapOverride;
}
if(typeof chart["DocumentUrl"] === "string")
{
var DocumentUrl = chart["DocumentUrl"];
if(DocumentUrl.indexOf(g_sResourceServiceLocalUrl) === 0)
{
window["Asc"]["editor"].documentId = DocumentUrl.slice(g_sResourceServiceLocalUrl.length, DocumentUrl.length);
}
}
var font_map = {};
oNewChartSpace.documentGetAllFontNames(font_map);
checkThemeFonts(font_map, worksheet.model.workbook.theme.themeElements.fontScheme);
......@@ -2644,6 +2658,7 @@ function DrawingObjects() {
}
}
worksheet._updateCellsRange(new asc_Range(0, 0, Math.max(worksheet.nColsCount - 1, max_c), Math.max(worksheet.nRowsCount - 1, max_r)));
aImagesSync.length = 0;
oNewChartSpace.getAllRasterImages(aImagesSync);
oNewChartSpace.setBDeleted(false);
oNewChartSpace.setWorksheet(worksheet.model);
......
......@@ -4307,6 +4307,13 @@ DrawingObjectsController.prototype =
Document_UpdateInterfaceState: function()
{},
getDocumentUrl: function()
{
if(typeof editor !== "undefined" && isRealObject(editor) && typeof editor.DocumentUrl === "string")
return editor.DocumentUrl;
return null;
},
getChartObject: function(type)
{
if(null != type)
......@@ -4346,6 +4353,7 @@ DrawingObjectsController.prototype =
ret.spPr.xfrm.setOffY(0);
ret.theme = this.getTheme();
ret.colorMapOverride = this.getColorMapOverride();
ret.DocumentUrl = this.getDocumentUrl();
return ret;
}, this, []);
}
......@@ -4357,6 +4365,7 @@ DrawingObjectsController.prototype =
{
this.selection.groupSelection.selectedObjects[0].theme = this.getTheme();
this.selection.groupSelection.selectedObjects[0].colorMapOverride = this.getColorMapOverride();
this.selection.groupSelection.selectedObjects[0].DocumentUrl = this.getDocumentUrl();
ExecuteNoHistory(function()
{
CheckSpPrXfrm2(this.selection.groupSelection.selectedObjects[0]);
......@@ -4370,6 +4379,7 @@ DrawingObjectsController.prototype =
{
this.selectedObjects[0].theme = this.getTheme();
this.selectedObjects[0].colorMapOverride = this.getColorMapOverride();
this.selectedObjects[0].DocumentUrl = this.getDocumentUrl();
ExecuteNoHistory(function()
{
CheckSpPrXfrm2(this.selectedObjects[0]);
......
......@@ -118,6 +118,8 @@ CGraphicObjects.prototype =
return null;
},
getDocumentUrl: DrawingObjectsController.prototype.getDocumentUrl,
isViewMode: function()
{
return editor.isViewMode;
......
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