Commit be486715 authored by Alexander.Trofimov's avatar Alexander.Trofimov Committed by Alexander.Trofimov

add ';'

delete unused code
replace this -> _this (may be errors)

git-svn-id: svn://192.168.3.15/activex/AVS/Sources/TeamlabOffice/trunk/OfficeWeb@55874 954022d7-b5bf-4e40-9824-e11837661b57
parent e99955fe
...@@ -37,7 +37,6 @@ function convertFormula(formula, ws) { ...@@ -37,7 +37,6 @@ function convertFormula(formula, ws) {
} }
function getFullImageSrc(src) { function getFullImageSrc(src) {
var start = src.substring(0, 6);
if ( 0 != src.indexOf("http:") && 0 != src.indexOf("data:") && 0 != src.indexOf("https:") && 0 != src.indexOf("ftp:") && 0 != src.indexOf("file:") ) { if ( 0 != src.indexOf("http:") && 0 != src.indexOf("data:") && 0 != src.indexOf("https:") && 0 != src.indexOf("ftp:") && 0 != src.indexOf("file:") ) {
var api = window["Asc"]["editor"]; var api = window["Asc"]["editor"];
if ( 0 == src.indexOf(g_sResourceServiceLocalUrl + api.documentId) ) if ( 0 == src.indexOf(g_sResourceServiceLocalUrl + api.documentId) )
...@@ -65,7 +64,7 @@ function roundPlus(x, n) { //x - число, n - количество знако ...@@ -65,7 +64,7 @@ function roundPlus(x, n) { //x - число, n - количество знако
//----------------------------------------------------------------------------------- //-----------------------------------------------------------------------------------
// Chart style // Chart style
//----------------------------------------------------------------------------------- //-----------------------------------------------------------------------------------
/** @constructor */
function asc_CChartStyle() { function asc_CChartStyle() {
this.style = null; this.style = null;
this.imageUrl = null; this.imageUrl = null;
...@@ -77,7 +76,7 @@ asc_CChartStyle.prototype = { ...@@ -77,7 +76,7 @@ asc_CChartStyle.prototype = {
asc_getImageUrl: function() { return this.imageUrl; }, asc_getImageUrl: function() { return this.imageUrl; },
asc_setImageUrl: function(imageUrl) { this.imageUrl = imageUrl; } asc_setImageUrl: function(imageUrl) { this.imageUrl = imageUrl; }
} };
//{ asc_CChartStyle export //{ asc_CChartStyle export
window["Asc"].asc_CChartStyle = asc_CChartStyle; window["Asc"].asc_CChartStyle = asc_CChartStyle;
...@@ -94,7 +93,7 @@ prot["asc_setImageUrl"] = prot.asc_setImageUrl; ...@@ -94,7 +93,7 @@ prot["asc_setImageUrl"] = prot.asc_setImageUrl;
//----------------------------------------------------------------------------------- //-----------------------------------------------------------------------------------
// Chart translate // Chart translate
//----------------------------------------------------------------------------------- //-----------------------------------------------------------------------------------
/** @constructor */
function asc_CChartTranslate() { function asc_CChartTranslate() {
this.title = "Diagram Title"; this.title = "Diagram Title";
...@@ -116,7 +115,7 @@ asc_CChartTranslate.prototype = { ...@@ -116,7 +115,7 @@ asc_CChartTranslate.prototype = {
asc_getSeries: function() { return this.series; }, asc_getSeries: function() { return this.series; },
asc_setSeries: function(val) { this.series = val; } asc_setSeries: function(val) { this.series = val; }
} };
//{ asc_CChartTranslate export //{ asc_CChartTranslate export
window["Asc"].asc_CChartTranslate = asc_CChartTranslate; window["Asc"].asc_CChartTranslate = asc_CChartTranslate;
...@@ -139,7 +138,7 @@ prot["asc_setSeries"] = prot.asc_setSeries; ...@@ -139,7 +138,7 @@ prot["asc_setSeries"] = prot.asc_setSeries;
//----------------------------------------------------------------------------------- //-----------------------------------------------------------------------------------
// Chart // Chart
//----------------------------------------------------------------------------------- //-----------------------------------------------------------------------------------
/** @constructor */
function asc_CChart(object) { function asc_CChart(object) {
var bCopy = isObject(object); var bCopy = isObject(object);
...@@ -674,7 +673,7 @@ asc_CChart.prototype = { ...@@ -674,7 +673,7 @@ asc_CChart.prototype = {
getLegendInfo: function() { getLegendInfo: function() {
var aInfo = []; var aInfo = [];
function legendInfo() { return { text: null, color: null, marker: null } }; function legendInfo() { return { text: null, color: null, marker: null } }
for ( var i = 0; i < this.series.length; i++ ) { for ( var i = 0; i < this.series.length; i++ ) {
...@@ -1118,7 +1117,7 @@ asc_CChart.prototype = { ...@@ -1118,7 +1117,7 @@ asc_CChart.prototype = {
if ( ws ) if ( ws )
ws.objectRender.rebuildChartGraphicObjects(); ws.objectRender.rebuildChartGraphicObjects();
} }
} };
//{ asc_CChart export //{ asc_CChart export
window["Asc"].asc_CChart = asc_CChart; window["Asc"].asc_CChart = asc_CChart;
...@@ -1166,7 +1165,7 @@ prot["asc_removeSeries"] = prot.asc_removeSeries; ...@@ -1166,7 +1165,7 @@ prot["asc_removeSeries"] = prot.asc_removeSeries;
//----------------------------------------------------------------------------------- //-----------------------------------------------------------------------------------
// Chart binary // Chart binary
//----------------------------------------------------------------------------------- //-----------------------------------------------------------------------------------
/** @constructor */
function asc_CChartBinary(chart) { function asc_CChartBinary(chart) {
this["binary"] = null; this["binary"] = null;
...@@ -1186,14 +1185,13 @@ asc_CChartBinary.prototype = { ...@@ -1186,14 +1185,13 @@ asc_CChartBinary.prototype = {
{ {
var binary = this["binary"]; var binary = this["binary"];
var stream = CreateBinaryReader(this["binary"], 0, this["binary"].length); var stream = CreateBinaryReader(this["binary"], 0, this["binary"].length);
var chartReader = new BinaryChartReader(stream);
var oNewChartSpace = new CChartSpace(); var oNewChartSpace = new CChartSpace();
var oBinaryChartReader = new BinaryChartReader(stream); var oBinaryChartReader = new BinaryChartReader(stream);
oBinaryChartReader.ExternalReadCT_ChartSpace(stream.size , oNewChartSpace, workSheet); oBinaryChartReader.ExternalReadCT_ChartSpace(stream.size , oNewChartSpace, workSheet);
return oNewChartSpace; return oNewChartSpace;
} }
} };
//{ asc_CChartBinary export //{ asc_CChartBinary export
window["Asc"].asc_CChartBinary = asc_CChartBinary; window["Asc"].asc_CChartBinary = asc_CChartBinary;
...@@ -1207,7 +1205,7 @@ prot["asc_setBinary"] = prot.asc_setBinary; ...@@ -1207,7 +1205,7 @@ prot["asc_setBinary"] = prot.asc_setBinary;
//----------------------------------------------------------------------------------- //-----------------------------------------------------------------------------------
// Chart range // Chart range
//----------------------------------------------------------------------------------- //-----------------------------------------------------------------------------------
/** @constructor */
function asc_CChartRange(object) { function asc_CChartRange(object) {
var bCopy = isObject(object); var bCopy = isObject(object);
...@@ -1238,7 +1236,7 @@ asc_CChartRange.prototype = { ...@@ -1238,7 +1236,7 @@ asc_CChartRange.prototype = {
this.rows = !value; this.rows = !value;
this.columns = value; this.columns = value;
} }
} };
//{ asc_CChartRange export //{ asc_CChartRange export
window["Asc"].asc_CChartRange = asc_CChartRange; window["Asc"].asc_CChartRange = asc_CChartRange;
...@@ -1258,7 +1256,7 @@ prot["asc_setColumnsFlag"] = prot.asc_setColumnsFlag; ...@@ -1258,7 +1256,7 @@ prot["asc_setColumnsFlag"] = prot.asc_setColumnsFlag;
//----------------------------------------------------------------------------------- //-----------------------------------------------------------------------------------
// Chart title // Chart title
//----------------------------------------------------------------------------------- //-----------------------------------------------------------------------------------
/** @constructor */
function asc_CChartHeader(object) { function asc_CChartHeader(object) {
var bCopy = isObject(object); var bCopy = isObject(object);
...@@ -1282,7 +1280,7 @@ asc_CChartHeader.prototype = { ...@@ -1282,7 +1280,7 @@ asc_CChartHeader.prototype = {
asc_getDefaultTitleFlag: function() { return this.bDefaultTitle; }, asc_getDefaultTitleFlag: function() { return this.bDefaultTitle; },
asc_setDefaultTitleFlag: function(defaultTitleFlag) { this.bDefaultTitle = defaultTitleFlag; } asc_setDefaultTitleFlag: function(defaultTitleFlag) { this.bDefaultTitle = defaultTitleFlag; }
} };
//{ asc_CChartHeader export //{ asc_CChartHeader export
window["Asc"].asc_CChartHeader = asc_CChartHeader; window["Asc"].asc_CChartHeader = asc_CChartHeader;
...@@ -1302,7 +1300,7 @@ prot["asc_setDefaultTitleFlag"] = prot.asc_setDefaultTitleFlag; ...@@ -1302,7 +1300,7 @@ prot["asc_setDefaultTitleFlag"] = prot.asc_setDefaultTitleFlag;
//----------------------------------------------------------------------------------- //-----------------------------------------------------------------------------------
// Chart axis X // Chart axis X
//----------------------------------------------------------------------------------- //-----------------------------------------------------------------------------------
/** @constructor */
function asc_CChartAxisX(object) { function asc_CChartAxisX(object) {
var bCopy = isObject(object); var bCopy = isObject(object);
...@@ -1330,7 +1328,7 @@ asc_CChartAxisX.prototype = { ...@@ -1330,7 +1328,7 @@ asc_CChartAxisX.prototype = {
asc_getGridFlag: function() { return this.bGrid; }, asc_getGridFlag: function() { return this.bGrid; },
asc_setGridFlag: function(gridFlag) { this.bGrid = gridFlag; } asc_setGridFlag: function(gridFlag) { this.bGrid = gridFlag; }
} };
//{ asc_CChartAxisX export //{ asc_CChartAxisX export
window["Asc"].asc_CChartAxisX = asc_CChartAxisX; window["Asc"].asc_CChartAxisX = asc_CChartAxisX;
...@@ -1353,7 +1351,7 @@ prot["asc_setGridFlag"] = prot.asc_setGridFlag; ...@@ -1353,7 +1351,7 @@ prot["asc_setGridFlag"] = prot.asc_setGridFlag;
//----------------------------------------------------------------------------------- //-----------------------------------------------------------------------------------
// Chart axis Y // Chart axis Y
//----------------------------------------------------------------------------------- //-----------------------------------------------------------------------------------
/** @constructor */
function asc_CChartAxisY(object) { function asc_CChartAxisY(object) {
var bCopy = isObject(object); var bCopy = isObject(object);
...@@ -1381,7 +1379,7 @@ asc_CChartAxisY.prototype = { ...@@ -1381,7 +1379,7 @@ asc_CChartAxisY.prototype = {
asc_getGridFlag: function() { return this.bGrid; }, asc_getGridFlag: function() { return this.bGrid; },
asc_setGridFlag: function(gridFlag) { this.bGrid = gridFlag; } asc_setGridFlag: function(gridFlag) { this.bGrid = gridFlag; }
} };
//{ asc_CChartAxisY export //{ asc_CChartAxisY export
window["Asc"].asc_CChartAxisY = asc_CChartAxisY; window["Asc"].asc_CChartAxisY = asc_CChartAxisY;
...@@ -1404,7 +1402,7 @@ prot["asc_setGridFlag"] = prot.asc_setGridFlag; ...@@ -1404,7 +1402,7 @@ prot["asc_setGridFlag"] = prot.asc_setGridFlag;
//----------------------------------------------------------------------------------- //-----------------------------------------------------------------------------------
// Chart legend // Chart legend
//----------------------------------------------------------------------------------- //-----------------------------------------------------------------------------------
/** @constructor */
function asc_CChartLegend(object) { function asc_CChartLegend(object) {
var bCopy = isObject(object); var bCopy = isObject(object);
...@@ -1428,7 +1426,7 @@ asc_CChartLegend.prototype = { ...@@ -1428,7 +1426,7 @@ asc_CChartLegend.prototype = {
asc_getOverlayFlag: function() { return this.bOverlay; }, asc_getOverlayFlag: function() { return this.bOverlay; },
asc_setOverlayFlag: function(overlayFlag) { this.bOverlay = overlayFlag; } asc_setOverlayFlag: function(overlayFlag) { this.bOverlay = overlayFlag; }
} };
//{ asc_CChartLegend export //{ asc_CChartLegend export
window["Asc"].asc_CChartLegend = asc_CChartLegend; window["Asc"].asc_CChartLegend = asc_CChartLegend;
...@@ -1448,7 +1446,7 @@ prot["asc_setOverlayFlag"] = prot.asc_setOverlayFlag; ...@@ -1448,7 +1446,7 @@ prot["asc_setOverlayFlag"] = prot.asc_setOverlayFlag;
//----------------------------------------------------------------------------------- //-----------------------------------------------------------------------------------
// Chart font // Chart font
//----------------------------------------------------------------------------------- //-----------------------------------------------------------------------------------
/** @constructor */
function asc_CChartFont(object) { function asc_CChartFont(object) {
var bCopy = isObject(object); var bCopy = isObject(object);
...@@ -1522,7 +1520,7 @@ asc_CChartFont.prototype = { ...@@ -1522,7 +1520,7 @@ asc_CChartFont.prototype = {
case this.Properties.underline: this.underline = value; break; case this.Properties.underline: this.underline = value; break;
} }
} }
} };
//{ asc_CChartFont export //{ asc_CChartFont export
window["Asc"].asc_CChartFont = asc_CChartFont; window["Asc"].asc_CChartFont = asc_CChartFont;
...@@ -1551,7 +1549,7 @@ prot["asc_setUnderline"] = prot.asc_setUnderline; ...@@ -1551,7 +1549,7 @@ prot["asc_setUnderline"] = prot.asc_setUnderline;
//----------------------------------------------------------------------------------- //-----------------------------------------------------------------------------------
// Chart series // Chart series
//----------------------------------------------------------------------------------- //-----------------------------------------------------------------------------------
/** @constructor */
function asc_CChartSeria() { function asc_CChartSeria() {
this.Val = { Formula: "", NumCache: [] }; this.Val = { Formula: "", NumCache: [] };
this.xVal = { Formula: "", NumCache: [] }; this.xVal = { Formula: "", NumCache: [] };
...@@ -1597,7 +1595,7 @@ asc_CChartSeria.prototype = { ...@@ -1597,7 +1595,7 @@ asc_CChartSeria.prototype = {
asc_getFormatCode: function() { return this.FormatCode; }, asc_getFormatCode: function() { return this.FormatCode; },
asc_setFormatCode: function(format) { this.FormatCode = format; } asc_setFormatCode: function(format) { this.FormatCode = format; }
} };
//{ asc_CChartSeria export //{ asc_CChartSeria export
window["Asc"].asc_CChartSeria = asc_CChartSeria; window["Asc"].asc_CChartSeria = asc_CChartSeria;
...@@ -1636,7 +1634,7 @@ prot["asc_setFormatCode"] = prot.asc_setFormatCode; ...@@ -1636,7 +1634,7 @@ prot["asc_setFormatCode"] = prot.asc_setFormatCode;
//----------------------------------------------------------------------------------- //-----------------------------------------------------------------------------------
// Selected graphic object(properties) // Selected graphic object(properties)
//----------------------------------------------------------------------------------- //-----------------------------------------------------------------------------------
/** @constructor */
function asc_CSelectedObject( type, val ) { function asc_CSelectedObject( type, val ) {
this.Type = (undefined != type) ? type : null; this.Type = (undefined != type) ? type : null;
this.Value = (undefined != val) ? val : null; this.Value = (undefined != val) ? val : null;
...@@ -1645,7 +1643,7 @@ function asc_CSelectedObject( type, val ) { ...@@ -1645,7 +1643,7 @@ function asc_CSelectedObject( type, val ) {
asc_CSelectedObject.prototype = { asc_CSelectedObject.prototype = {
asc_getObjectType: function() { return this.Type; }, asc_getObjectType: function() { return this.Type; },
asc_getObjectValue: function() { return this.Value; } asc_getObjectValue: function() { return this.Value; }
} };
//{ asc_CSelectedObject export //{ asc_CSelectedObject export
window["Asc"].asc_CSelectedObject = asc_CSelectedObject; window["Asc"].asc_CSelectedObject = asc_CSelectedObject;
...@@ -1659,7 +1657,7 @@ prot["asc_getObjectValue"] = prot.asc_getObjectValue; ...@@ -1659,7 +1657,7 @@ prot["asc_getObjectValue"] = prot.asc_getObjectValue;
//----------------------------------------------------------------------------------- //-----------------------------------------------------------------------------------
// CImgProperty // CImgProperty
//----------------------------------------------------------------------------------- //-----------------------------------------------------------------------------------
/** @constructor */
function asc_CImgProperty( obj ) { function asc_CImgProperty( obj ) {
if( obj ) { if( obj ) {
...@@ -1775,7 +1773,7 @@ asc_CImgProperty.prototype = { ...@@ -1775,7 +1773,7 @@ asc_CImgProperty.prototype = {
asc_putChartProperties: function(v) { this.ChartProperties = v; }, asc_putChartProperties: function(v) { this.ChartProperties = v; },
asc_getShapeProperties: function() { return this.ShapeProperties; }, asc_getShapeProperties: function() { return this.ShapeProperties; },
asc_putShapeProperties: function(v) { this.ShapeProperties = v; } asc_putShapeProperties: function(v) { this.ShapeProperties = v; }
} };
//{ asc_CImgProperty export //{ asc_CImgProperty export
window["Asc"].asc_CImgProperty = asc_CImgProperty; window["Asc"].asc_CImgProperty = asc_CImgProperty;
...@@ -1833,7 +1831,7 @@ prot["asc_putShapeProperties"] = prot.asc_putShapeProperties; ...@@ -1833,7 +1831,7 @@ prot["asc_putShapeProperties"] = prot.asc_putShapeProperties;
//----------------------------------------------------------------------------------- //-----------------------------------------------------------------------------------
// CShapeProperty // CShapeProperty
//----------------------------------------------------------------------------------- //-----------------------------------------------------------------------------------
/** @constructor */
function asc_CShapeProperty() { function asc_CShapeProperty() {
this.type = null; // custom this.type = null; // custom
this.fill = null; this.fill = null;
...@@ -1857,7 +1855,7 @@ asc_CShapeProperty.prototype = { ...@@ -1857,7 +1855,7 @@ asc_CShapeProperty.prototype = {
asc_putCanFill: function(v) { this.canFill = v; }, asc_putCanFill: function(v) { this.canFill = v; },
asc_getCanChangeArrows: function() { return this.canChangeArrows; }, asc_getCanChangeArrows: function() { return this.canChangeArrows; },
asc_setCanChangeArrows: function(v) { this.canChangeArrows = v; } asc_setCanChangeArrows: function(v) { this.canChangeArrows = v; }
} };
//{ asc_CShapeProperty export //{ asc_CShapeProperty export
window["Asc"].asc_CShapeProperty = asc_CShapeProperty; window["Asc"].asc_CShapeProperty = asc_CShapeProperty;
...@@ -1881,7 +1879,7 @@ prot["asc_setCanChangeArrows"] = prot.asc_setCanChangeArrows; ...@@ -1881,7 +1879,7 @@ prot["asc_setCanChangeArrows"] = prot.asc_setCanChangeArrows;
//----------------------------------------------------------------------------------- //-----------------------------------------------------------------------------------
// CPaddings // CPaddings
//----------------------------------------------------------------------------------- //-----------------------------------------------------------------------------------
/** @constructor */
function asc_CPaddings(obj) { function asc_CPaddings(obj) {
if ( obj ) { if ( obj ) {
...@@ -1907,7 +1905,7 @@ asc_CPaddings.prototype = { ...@@ -1907,7 +1905,7 @@ asc_CPaddings.prototype = {
asc_putBottom: function(v) { this.Bottom = v; }, asc_putBottom: function(v) { this.Bottom = v; },
asc_getRight: function() { return this.Right; }, asc_getRight: function() { return this.Right; },
asc_putRight: function(v) { this.Right = v; } asc_putRight: function(v) { this.Right = v; }
} };
//{ asc_CPaddings export //{ asc_CPaddings export
window["Asc"].asc_CPaddings = asc_CPaddings; window["Asc"].asc_CPaddings = asc_CPaddings;
...@@ -1927,7 +1925,7 @@ prot["asc_putRight"] = prot.asc_putRight; ...@@ -1927,7 +1925,7 @@ prot["asc_putRight"] = prot.asc_putRight;
//----------------------------------------------------------------------------------- //-----------------------------------------------------------------------------------
// CImageSize // CImageSize
//----------------------------------------------------------------------------------- //-----------------------------------------------------------------------------------
/** @constructor */
function asc_CImageSize( width, height, isCorrect ) { function asc_CImageSize( width, height, isCorrect ) {
this.Width = (undefined == width) ? 0.0 : width; this.Width = (undefined == width) ? 0.0 : width;
this.Height = (undefined == height) ? 0.0 : height; this.Height = (undefined == height) ? 0.0 : height;
...@@ -1939,7 +1937,7 @@ asc_CImageSize.prototype = { ...@@ -1939,7 +1937,7 @@ asc_CImageSize.prototype = {
asc_getImageWidth: function() { return this.Width; }, asc_getImageWidth: function() { return this.Width; },
asc_getImageHeight: function() { return this.Height; }, asc_getImageHeight: function() { return this.Height; },
asc_getIsCorrect: function() { return this.IsCorrect; } asc_getIsCorrect: function() { return this.IsCorrect; }
} };
//{ asc_CImageSize export //{ asc_CImageSize export
window["Asc"].asc_CImageSize = asc_CImageSize; window["Asc"].asc_CImageSize = asc_CImageSize;
...@@ -1954,7 +1952,7 @@ prot["asc_getIsCorrect"] = prot.asc_getIsCorrect; ...@@ -1954,7 +1952,7 @@ prot["asc_getIsCorrect"] = prot.asc_getIsCorrect;
//----------------------------------------------------------------------------------- //-----------------------------------------------------------------------------------
// CTexture // CTexture
//----------------------------------------------------------------------------------- //-----------------------------------------------------------------------------------
/** @constructor */
function asc_CTexture() { function asc_CTexture() {
this.Id = 0; this.Id = 0;
this.Image = ""; this.Image = "";
...@@ -1963,7 +1961,7 @@ function asc_CTexture() { ...@@ -1963,7 +1961,7 @@ function asc_CTexture() {
asc_CTexture.prototype = { asc_CTexture.prototype = {
asc_getId: function() { return this.Id; }, asc_getId: function() { return this.Id; },
asc_getImage: function() { return this.Image; } asc_getImage: function() { return this.Image; }
} };
//{ asc_CTexture export //{ asc_CTexture export
window["Asc"].asc_CTexture = asc_CTexture; window["Asc"].asc_CTexture = asc_CTexture;
...@@ -1977,7 +1975,7 @@ prot["asc_getImage"] = prot.asc_getImage; ...@@ -1977,7 +1975,7 @@ prot["asc_getImage"] = prot.asc_getImage;
//----------------------------------------------------------------------------------- //-----------------------------------------------------------------------------------
// CParagraphProperty // CParagraphProperty
//----------------------------------------------------------------------------------- //-----------------------------------------------------------------------------------
/** @constructor */
function asc_CParagraphProperty(obj) { function asc_CParagraphProperty(obj) {
if (obj) { if (obj) {
...@@ -2088,7 +2086,7 @@ asc_CParagraphProperty.prototype = { ...@@ -2088,7 +2086,7 @@ asc_CParagraphProperty.prototype = {
asc_putTabs: function (v) { this.Tabs = v; }, asc_putTabs: function (v) { this.Tabs = v; },
asc_getDefaultTab: function () { return this.DefaultTab; }, asc_getDefaultTab: function () { return this.DefaultTab; },
asc_putDefaultTab: function (v) { this.DefaultTab = v; } asc_putDefaultTab: function (v) { this.DefaultTab = v; }
} };
//{ asc_CParagraphProperty export //{ asc_CParagraphProperty export
window["Asc"].asc_CParagraphProperty = asc_CParagraphProperty; window["Asc"].asc_CParagraphProperty = asc_CParagraphProperty;
...@@ -2140,7 +2138,7 @@ prot["asc_putDefaultTab"] = prot.asc_putDefaultTab; ...@@ -2140,7 +2138,7 @@ prot["asc_putDefaultTab"] = prot.asc_putDefaultTab;
//----------------------------------------------------------------------------------- //-----------------------------------------------------------------------------------
// CParagraphInd // CParagraphInd
//----------------------------------------------------------------------------------- //-----------------------------------------------------------------------------------
/** @constructor */
function asc_CParagraphInd(obj) { function asc_CParagraphInd(obj) {
if (obj) { if (obj) {
this.Left = (undefined != obj.Left ) ? obj.Left : null; // Левый отступ this.Left = (undefined != obj.Left ) ? obj.Left : null; // Левый отступ
...@@ -2161,7 +2159,7 @@ asc_CParagraphInd.prototype = { ...@@ -2161,7 +2159,7 @@ asc_CParagraphInd.prototype = {
asc_putRight: function (v) { this.Right = v; }, asc_putRight: function (v) { this.Right = v; },
asc_getFirstLine: function () { return this.FirstLine; }, asc_getFirstLine: function () { return this.FirstLine; },
asc_putFirstLine: function (v) { this.FirstLine = v; } asc_putFirstLine: function (v) { this.FirstLine = v; }
} };
//{ asc_CParagraphInd export //{ asc_CParagraphInd export
window["Asc"].asc_CParagraphInd = asc_CParagraphInd; window["Asc"].asc_CParagraphInd = asc_CParagraphInd;
...@@ -2179,7 +2177,7 @@ prot["asc_getFirstLine"] = prot.asc_getFirstLine; ...@@ -2179,7 +2177,7 @@ prot["asc_getFirstLine"] = prot.asc_getFirstLine;
//----------------------------------------------------------------------------------- //-----------------------------------------------------------------------------------
// CParagraphSpacing // CParagraphSpacing
//----------------------------------------------------------------------------------- //-----------------------------------------------------------------------------------
/** @constructor */
function asc_CParagraphSpacing(obj) { function asc_CParagraphSpacing(obj) {
if (obj) { if (obj) {
...@@ -2201,7 +2199,7 @@ asc_CParagraphSpacing.prototype = { ...@@ -2201,7 +2199,7 @@ asc_CParagraphSpacing.prototype = {
asc_getLineRule: function () { return this.LineRule; }, asc_getLineRule: function () { return this.LineRule; },
asc_getBefore: function () { return this.Before; }, asc_getBefore: function () { return this.Before; },
asc_getAfter: function () { return this.After; } asc_getAfter: function () { return this.After; }
} };
//{ asc_CParagraphSpacing export //{ asc_CParagraphSpacing export
window["Asc"].asc_CParagraphSpacing = asc_CParagraphSpacing; window["Asc"].asc_CParagraphSpacing = asc_CParagraphSpacing;
...@@ -2217,7 +2215,7 @@ prot["asc_getAfter"] = prot.asc_getAfter; ...@@ -2217,7 +2215,7 @@ prot["asc_getAfter"] = prot.asc_getAfter;
//----------------------------------------------------------------------------------- //-----------------------------------------------------------------------------------
// CParagraphShd // CParagraphShd
//----------------------------------------------------------------------------------- //-----------------------------------------------------------------------------------
/** @constructor */
function asc_CParagraphShd(obj) { function asc_CParagraphShd(obj) {
if (obj) { if (obj) {
...@@ -2235,7 +2233,7 @@ asc_CParagraphShd.prototype = { ...@@ -2235,7 +2233,7 @@ asc_CParagraphShd.prototype = {
asc_putValue: function (v){ this.Value = v; }, asc_putValue: function (v){ this.Value = v; },
asc_getColor: function (){ return this.Color; }, asc_getColor: function (){ return this.Color; },
asc_putColor: function (v){ this.Color = (v) ? v : null; } asc_putColor: function (v){ this.Color = (v) ? v : null; }
} };
//{ asc_CParagraphShd export //{ asc_CParagraphShd export
window["Asc"].asc_CParagraphShd = asc_CParagraphShd; window["Asc"].asc_CParagraphShd = asc_CParagraphShd;
...@@ -2251,7 +2249,7 @@ prot["asc_putColor"] = prot.asc_putColor; ...@@ -2251,7 +2249,7 @@ prot["asc_putColor"] = prot.asc_putColor;
//----------------------------------------------------------------------------------- //-----------------------------------------------------------------------------------
// CParagraphTab // CParagraphTab
//----------------------------------------------------------------------------------- //-----------------------------------------------------------------------------------
/** @constructor */
function asc_CParagraphTab(Pos, Value) { function asc_CParagraphTab(Pos, Value) {
this.Pos = Pos; this.Pos = Pos;
this.Value = Value; this.Value = Value;
...@@ -2262,7 +2260,7 @@ asc_CParagraphTab.prototype = { ...@@ -2262,7 +2260,7 @@ asc_CParagraphTab.prototype = {
asc_putValue: function (v){ this.Value = v; }, asc_putValue: function (v){ this.Value = v; },
asc_getPos: function (){ return this.Pos; }, asc_getPos: function (){ return this.Pos; },
asc_putPos: function (v){ this.Pos = v; } asc_putPos: function (v){ this.Pos = v; }
} };
//{ asc_CParagraphTab export //{ asc_CParagraphTab export
window["Asc"].asc_CParagraphTab = asc_CParagraphTab; window["Asc"].asc_CParagraphTab = asc_CParagraphTab;
...@@ -2278,7 +2276,7 @@ prot["asc_putPos"] = prot.asc_putPos; ...@@ -2278,7 +2276,7 @@ prot["asc_putPos"] = prot.asc_putPos;
//----------------------------------------------------------------------------------- //-----------------------------------------------------------------------------------
// CParagraphTabs // CParagraphTabs
//----------------------------------------------------------------------------------- //-----------------------------------------------------------------------------------
/** @constructor */
function asc_CParagraphTabs(obj) { function asc_CParagraphTabs(obj) {
this.Tabs = []; this.Tabs = [];
...@@ -2297,7 +2295,7 @@ asc_CParagraphTabs.prototype = { ...@@ -2297,7 +2295,7 @@ asc_CParagraphTabs.prototype = {
asc_addTab: function (Tab){ this.Tabs.push(Tab) }, asc_addTab: function (Tab){ this.Tabs.push(Tab) },
asc_clear: function (){ this.Tabs.length = 0; }, asc_clear: function (){ this.Tabs.length = 0; },
add_Tab: function (Tab){ this.Tabs.push(Tab) } add_Tab: function (Tab){ this.Tabs.push(Tab) }
} };
//{ asc_CParagraphTabs export //{ asc_CParagraphTabs export
window["Asc"].asc_CParagraphTabs = asc_CParagraphTabs; window["Asc"].asc_CParagraphTabs = asc_CParagraphTabs;
...@@ -2315,7 +2313,7 @@ prot["add_Tab"] = prot.add_Tab; ...@@ -2315,7 +2313,7 @@ prot["add_Tab"] = prot.add_Tab;
//----------------------------------------------------------------------------------- //-----------------------------------------------------------------------------------
// CParagraphBorders // CParagraphBorders
//----------------------------------------------------------------------------------- //-----------------------------------------------------------------------------------
/** @constructor */
function asc_CParagraphBorders(obj) { function asc_CParagraphBorders(obj) {
if (obj) { if (obj) {
...@@ -2345,7 +2343,7 @@ asc_CParagraphBorders.prototype = { ...@@ -2345,7 +2343,7 @@ asc_CParagraphBorders.prototype = {
asc_putBottom: function(v){this.Bottom = (v) ? new asc_CTextBorder (v) : null;}, asc_putBottom: function(v){this.Bottom = (v) ? new asc_CTextBorder (v) : null;},
asc_getBetween: function(){return this.Between; }, asc_getBetween: function(){return this.Between; },
asc_putBetween: function(v){this.Between = (v) ? new asc_CTextBorder (v) : null;} asc_putBetween: function(v){this.Between = (v) ? new asc_CTextBorder (v) : null;}
} };
//{ asc_CParagraphBorders export //{ asc_CParagraphBorders export
window["Asc"].asc_CParagraphBorders = asc_CParagraphBorders; window["Asc"].asc_CParagraphBorders = asc_CParagraphBorders;
...@@ -2367,7 +2365,7 @@ prot["asc_putBetween"] = prot.asc_putBetween; ...@@ -2367,7 +2365,7 @@ prot["asc_putBetween"] = prot.asc_putBetween;
//----------------------------------------------------------------------------------- //-----------------------------------------------------------------------------------
// CBorder // CBorder
//----------------------------------------------------------------------------------- //-----------------------------------------------------------------------------------
/** @constructor */
function asc_CTextBorder(obj) { function asc_CTextBorder(obj) {
if (obj) { if (obj) {
...@@ -2395,7 +2393,7 @@ asc_CTextBorder.prototype = { ...@@ -2395,7 +2393,7 @@ asc_CTextBorder.prototype = {
asc_putSpace: function(v){this.Space = v;}, asc_putSpace: function(v){this.Space = v;},
asc_getForSelectedCells: function(){return this.ForSelectedCells; }, asc_getForSelectedCells: function(){return this.ForSelectedCells; },
asc_putForSelectedCells: function(v){this.ForSelectedCells = v;} asc_putForSelectedCells: function(v){this.ForSelectedCells = v;}
} };
//{ asc_CTextBorder export //{ asc_CTextBorder export
window["Asc"].asc_CTextBorder = asc_CTextBorder; window["Asc"].asc_CTextBorder = asc_CTextBorder;
...@@ -2417,7 +2415,7 @@ prot["asc_putForSelectedCells"] = prot.asc_putForSelectedCells; ...@@ -2417,7 +2415,7 @@ prot["asc_putForSelectedCells"] = prot.asc_putForSelectedCells;
//----------------------------------------------------------------------------------- //-----------------------------------------------------------------------------------
// CListType // CListType
//----------------------------------------------------------------------------------- //-----------------------------------------------------------------------------------
/** @constructor */
function asc_CListType(obj) { function asc_CListType(obj) {
if (obj) { if (obj) {
...@@ -2433,7 +2431,7 @@ function asc_CListType(obj) { ...@@ -2433,7 +2431,7 @@ function asc_CListType(obj) {
asc_CListType.prototype = { asc_CListType.prototype = {
asc_getListType: function() { return this.Type; }, asc_getListType: function() { return this.Type; },
asc_getListSubType: function() { return this.SubType; } asc_getListSubType: function() { return this.SubType; }
} };
//{ asc_CListType export //{ asc_CListType export
window["Asc"].asc_CListType = asc_CListType; window["Asc"].asc_CListType = asc_CListType;
...@@ -2447,7 +2445,7 @@ prot["asc_getListSubType"] = prot.asc_getListSubType; ...@@ -2447,7 +2445,7 @@ prot["asc_getListSubType"] = prot.asc_getListSubType;
//----------------------------------------------------------------------------------- //-----------------------------------------------------------------------------------
// CTextFontFamily // CTextFontFamily
//----------------------------------------------------------------------------------- //-----------------------------------------------------------------------------------
/** @constructor */
function asc_CTextFontFamily(obj) { function asc_CTextFontFamily(obj) {
if (obj) { if (obj) {
...@@ -2463,7 +2461,7 @@ function asc_CTextFontFamily(obj) { ...@@ -2463,7 +2461,7 @@ function asc_CTextFontFamily(obj) {
asc_CTextFontFamily.prototype = { asc_CTextFontFamily.prototype = {
asc_getName: function () { return this.Name; }, asc_getName: function () { return this.Name; },
asc_getIndex: function () { return this.Index; } asc_getIndex: function () { return this.Index; }
} };
//{ asc_CTextFontFamily export //{ asc_CTextFontFamily export
window["Asc"].asc_CTextFontFamily = asc_CTextFontFamily; window["Asc"].asc_CTextFontFamily = asc_CTextFontFamily;
...@@ -2505,7 +2503,7 @@ function GraphicOption(ws, type, range, aId) { ...@@ -2505,7 +2503,7 @@ function GraphicOption(ws, type, range, aId) {
_this.isScrollType = function() { _this.isScrollType = function() {
return ( (_this.type === c_oAscGraphicOption.ScrollVertical) || (_this.type === c_oAscGraphicOption.ScrollHorizontal) ); return ( (_this.type === c_oAscGraphicOption.ScrollVertical) || (_this.type === c_oAscGraphicOption.ScrollHorizontal) );
} };
_this.getUpdatedRange = function() { _this.getUpdatedRange = function() {
...@@ -2585,12 +2583,12 @@ function DrawingObjects() { ...@@ -2585,12 +2583,12 @@ function DrawingObjects() {
this.getX = function() { this.getX = function() {
return -ptToPx((worksheet.cols[worksheet.getFirstVisibleCol(true)].left - worksheet.cellsLeft)) + worksheet.getCellLeft(0, 0); return -ptToPx((worksheet.cols[worksheet.getFirstVisibleCol(true)].left - worksheet.cellsLeft)) + worksheet.getCellLeft(0, 0);
} };
this.getY = function() { this.getY = function() {
return -ptToPx((worksheet.rows[worksheet.getFirstVisibleRow(true)].top - worksheet.cellsTop)) + worksheet.getCellTop(0, 0); return -ptToPx((worksheet.rows[worksheet.getFirstVisibleRow(true)].top - worksheet.cellsTop)) + worksheet.getCellTop(0, 0);
} }
} };
//----------------------------------------------------------------------------------- //-----------------------------------------------------------------------------------
// Private // Private
...@@ -2682,46 +2680,46 @@ function DrawingObjects() { ...@@ -2682,46 +2680,46 @@ function DrawingObjects() {
DrawingBase.prototype.getAllFonts = function(AllFonts) { DrawingBase.prototype.getAllFonts = function(AllFonts) {
var _t = this; var _t = this;
_t.graphicObject && _t.graphicObject.documentGetAllFontNames && _t.graphicObject.documentGetAllFontNames(AllFonts); _t.graphicObject && _t.graphicObject.documentGetAllFontNames && _t.graphicObject.documentGetAllFontNames(AllFonts);
} };
DrawingBase.prototype.isImage = function() { DrawingBase.prototype.isImage = function() {
var _t = this; var _t = this;
return _t.graphicObject ? _t.graphicObject.isImage() : false; return _t.graphicObject ? _t.graphicObject.isImage() : false;
} };
DrawingBase.prototype.isShape = function() { DrawingBase.prototype.isShape = function() {
var _t = this; var _t = this;
return _t.graphicObject ? _t.graphicObject.isShape() : false; return _t.graphicObject ? _t.graphicObject.isShape() : false;
} };
DrawingBase.prototype.isGroup = function() { DrawingBase.prototype.isGroup = function() {
var _t = this; var _t = this;
return _t.graphicObject ? _t.graphicObject.isGroup() : false; return _t.graphicObject ? _t.graphicObject.isGroup() : false;
} };
DrawingBase.prototype.isChart = function() { DrawingBase.prototype.isChart = function() {
var _t = this; var _t = this;
return _t.graphicObject ? _t.graphicObject.isChart() : false; return _t.graphicObject ? _t.graphicObject.isChart() : false;
} };
DrawingBase.prototype.isGraphicObject = function() { DrawingBase.prototype.isGraphicObject = function() {
var _t = this; var _t = this;
return _t.graphicObject != null; return _t.graphicObject != null;
} };
DrawingBase.prototype.isLocked = function() { DrawingBase.prototype.isLocked = function() {
var _t = this; var _t = this;
return ( (_t.graphicObject.lockType != c_oAscLockTypes.kLockTypeNone) && (_t.graphicObject.lockType != c_oAscLockTypes.kLockTypeMine) ) return ( (_t.graphicObject.lockType != c_oAscLockTypes.kLockTypeNone) && (_t.graphicObject.lockType != c_oAscLockTypes.kLockTypeMine) )
} };
DrawingBase.prototype.getWorkbook = function() { DrawingBase.prototype.getWorkbook = function() {
var _t = this; var _t = this;
return (_t.worksheet ? _t.worksheet.model.workbook : null); return (_t.worksheet ? _t.worksheet.model.workbook : null);
} };
DrawingBase.prototype.getCanvasContext = function() { DrawingBase.prototype.getCanvasContext = function() {
return _this.drawingDocument.CanvasHitContext; return _this.drawingDocument.CanvasHitContext;
} };
// GraphicObject: x, y, extX, extY // GraphicObject: x, y, extX, extY
DrawingBase.prototype.getGraphicObjectMetrics = function() { DrawingBase.prototype.getGraphicObjectMetrics = function() {
...@@ -2737,7 +2735,7 @@ function DrawingObjects() { ...@@ -2737,7 +2735,7 @@ function DrawingObjects() {
metrics.extY = pxToMm( coordsTo.y - coordsFrom.y ); metrics.extY = pxToMm( coordsTo.y - coordsFrom.y );
return metrics; return metrics;
} };
// Считаем From/To исходя из graphicObject // Считаем From/To исходя из graphicObject
DrawingBase.prototype.setGraphicObjectCoords = function() { DrawingBase.prototype.setGraphicObjectCoords = function() {
...@@ -2762,7 +2760,7 @@ function DrawingObjects() { ...@@ -2762,7 +2760,7 @@ function DrawingObjects() {
_t.to.row = toCell.row; _t.to.row = toCell.row;
_t.to.rowOff = toCell.rowOff; _t.to.rowOff = toCell.rowOff;
} }
} };
// Проверяет выход за границы // Проверяет выход за границы
DrawingBase.prototype.inVisibleArea = function(scrollType) { DrawingBase.prototype.inVisibleArea = function(scrollType) {
...@@ -2792,7 +2790,7 @@ function DrawingObjects() { ...@@ -2792,7 +2790,7 @@ function DrawingObjects() {
} }
return result; return result;
} };
DrawingBase.prototype.updateAnchorPosition = function() { DrawingBase.prototype.updateAnchorPosition = function() {
var _t = this; var _t = this;
...@@ -2834,35 +2832,35 @@ function DrawingObjects() { ...@@ -2834,35 +2832,35 @@ function DrawingObjects() {
break; break;
} }
_t.flags.anchorUpdated = true; _t.flags.anchorUpdated = true;
} };
// Реальное смещение по высоте // Реальное смещение по высоте
DrawingBase.prototype.getRealTopOffset = function() { DrawingBase.prototype.getRealTopOffset = function() {
var _t = this; var _t = this;
var val = _t.worksheet.getCellTop(_t.from.row, 0) + mmToPx(_t.from.rowOff); var val = _t.worksheet.getCellTop(_t.from.row, 0) + mmToPx(_t.from.rowOff);
return asc.round(val); return asc.round(val);
} };
// Реальное смещение по ширине // Реальное смещение по ширине
DrawingBase.prototype.getRealLeftOffset = function() { DrawingBase.prototype.getRealLeftOffset = function() {
var _t = this; var _t = this;
var val = _t.worksheet.getCellLeft(_t.from.col, 0) + mmToPx(_t.from.colOff); var val = _t.worksheet.getCellLeft(_t.from.col, 0) + mmToPx(_t.from.colOff);
return asc.round(val); return asc.round(val);
} };
// Ширина по координатам // Ширина по координатам
DrawingBase.prototype.getWidthFromTo = function() { DrawingBase.prototype.getWidthFromTo = function() {
var _t = this; var _t = this;
var val = _t.worksheet.getCellLeft(_t.to.col, 0) + mmToPx(_t.to.colOff) - _t.worksheet.getCellLeft(_t.from.col, 0) - mmToPx(_t.from.colOff); var val = _t.worksheet.getCellLeft(_t.to.col, 0) + mmToPx(_t.to.colOff) - _t.worksheet.getCellLeft(_t.from.col, 0) - mmToPx(_t.from.colOff);
return val; return val;
} };
// Высота по координатам // Высота по координатам
DrawingBase.prototype.getHeightFromTo = function() { DrawingBase.prototype.getHeightFromTo = function() {
var _t = this; var _t = this;
var val = _t.worksheet.getCellTop(_t.to.row, 0) + mmToPx(_t.to.rowOff) - _t.worksheet.getCellTop(_t.from.row, 0) - mmToPx(_t.from.rowOff); var val = _t.worksheet.getCellTop(_t.to.row, 0) + mmToPx(_t.to.rowOff) - _t.worksheet.getCellTop(_t.from.row, 0) - mmToPx(_t.from.rowOff);
return val; return val;
} };
// Видимое смещение объекта от первой видимой строки // Видимое смещение объекта от первой видимой строки
DrawingBase.prototype.getVisibleTopOffset = function(withHeader) { DrawingBase.prototype.getVisibleTopOffset = function(withHeader) {
...@@ -2872,7 +2870,7 @@ function DrawingObjects() { ...@@ -2872,7 +2870,7 @@ function DrawingObjects() {
var off = _t.getRealTopOffset() - fvr; var off = _t.getRealTopOffset() - fvr;
var off = (off > 0) ? off : 0; var off = (off > 0) ? off : 0;
return withHeader ? headerRowOff + off : off; return withHeader ? headerRowOff + off : off;
} };
// Видимое смещение объекта от первой видимой колонки // Видимое смещение объекта от первой видимой колонки
DrawingBase.prototype.getVisibleLeftOffset = function(withHeader) { DrawingBase.prototype.getVisibleLeftOffset = function(withHeader) {
...@@ -2882,7 +2880,7 @@ function DrawingObjects() { ...@@ -2882,7 +2880,7 @@ function DrawingObjects() {
var off = _t.getRealLeftOffset() - fvc; var off = _t.getRealLeftOffset() - fvc;
var off = (off > 0) ? off : 0; var off = (off > 0) ? off : 0;
return withHeader ? headerColOff + off : off; return withHeader ? headerColOff + off : off;
} };
// смещение по высоте внутри объекта // смещение по высоте внутри объекта
DrawingBase.prototype.getInnerOffsetTop = function() { DrawingBase.prototype.getInnerOffsetTop = function() {
...@@ -2890,7 +2888,7 @@ function DrawingObjects() { ...@@ -2890,7 +2888,7 @@ function DrawingObjects() {
var fvr = _t.worksheet.getCellTop(_t.worksheet.getFirstVisibleRow(true), 0); var fvr = _t.worksheet.getCellTop(_t.worksheet.getFirstVisibleRow(true), 0);
var off = _t.getRealTopOffset() - fvr; var off = _t.getRealTopOffset() - fvr;
return (off > 0) ? 0 : asc.round( Math.abs(off) ); return (off > 0) ? 0 : asc.round( Math.abs(off) );
} };
// смещение по ширине внутри объекта // смещение по ширине внутри объекта
DrawingBase.prototype.getInnerOffsetLeft = function() { DrawingBase.prototype.getInnerOffsetLeft = function() {
...@@ -2898,11 +2896,11 @@ function DrawingObjects() { ...@@ -2898,11 +2896,11 @@ function DrawingObjects() {
var fvc = _t.worksheet.getCellLeft(_t.worksheet.getFirstVisibleCol(true), 0); var fvc = _t.worksheet.getCellLeft(_t.worksheet.getFirstVisibleCol(true), 0);
var off = _t.getRealLeftOffset() - fvc; var off = _t.getRealLeftOffset() - fvc;
return (off > 0) ? 0 : asc.round( Math.abs(off) ); return (off > 0) ? 0 : asc.round( Math.abs(off) );
} };
DrawingBase.prototype.getDrawingObjects = function() { DrawingBase.prototype.getDrawingObjects = function() {
return _this; return _this;
} };
//} //}
...@@ -2954,7 +2952,7 @@ function DrawingObjects() { ...@@ -2954,7 +2952,7 @@ function DrawingObjects() {
} }
return copyObject; return copyObject;
} };
//----------------------------------------------------------------------------------- //-----------------------------------------------------------------------------------
// Public methods // Public methods
...@@ -3089,7 +3087,7 @@ function DrawingObjects() { ...@@ -3089,7 +3087,7 @@ function DrawingObjects() {
aBoundsCheckers.push(boundsChecker); aBoundsCheckers.push(boundsChecker);
} }
} }
} };
api.ImageLoader.LoadDocumentImages(aImagesSync, null, _this.asyncImagesDocumentEndLoaded); api.ImageLoader.LoadDocumentImages(aImagesSync, null, _this.asyncImagesDocumentEndLoaded);
...@@ -3101,7 +3099,7 @@ function DrawingObjects() { ...@@ -3101,7 +3099,7 @@ function DrawingObjects() {
_this.shiftMap = {}; _this.shiftMap = {};
worksheet.model.Drawings = aObjects; worksheet.model.Drawings = aObjects;
isInit = true; isInit = true;
} };
_this.preCopy = function() { _this.preCopy = function() {
_this.shiftMap = {}; _this.shiftMap = {};
...@@ -3151,7 +3149,7 @@ function DrawingObjects() { ...@@ -3151,7 +3149,7 @@ function DrawingObjects() {
_this.resizeCanvas(); _this.resizeCanvas();
_this.setScrollOffset(); _this.setScrollOffset();
_this.rebuildChartGraphicObjects(); _this.rebuildChartGraphicObjects();
} };
_this.resizeCanvas = function() { _this.resizeCanvas = function() {
...@@ -3168,23 +3166,23 @@ function DrawingObjects() { ...@@ -3168,23 +3166,23 @@ function DrawingObjects() {
trackOverlay.init( shapeOverlayCtx.m_oContext, "ws-canvas-graphic-overlay", 0, 0, shapeOverlayCtx.m_lWidthPix, shapeOverlayCtx.m_lHeightPix, shapeOverlayCtx.m_dWidthMM, shapeOverlayCtx.m_dHeightMM ); trackOverlay.init( shapeOverlayCtx.m_oContext, "ws-canvas-graphic-overlay", 0, 0, shapeOverlayCtx.m_lWidthPix, shapeOverlayCtx.m_lHeightPix, shapeOverlayCtx.m_dWidthMM, shapeOverlayCtx.m_dHeightMM );
autoShapeTrack.init( trackOverlay, 0, 0, shapeOverlayCtx.m_lWidthPix, shapeOverlayCtx.m_lHeightPix, shapeOverlayCtx.m_dWidthMM, shapeOverlayCtx.m_dHeightMM ); autoShapeTrack.init( trackOverlay, 0, 0, shapeOverlayCtx.m_lWidthPix, shapeOverlayCtx.m_lHeightPix, shapeOverlayCtx.m_dWidthMM, shapeOverlayCtx.m_dHeightMM );
autoShapeTrack.Graphics.CalculateFullTransform(); autoShapeTrack.Graphics.CalculateFullTransform();
} };
_this.getWorkbook = function() { _this.getWorkbook = function() {
return (worksheet ? worksheet.model.workbook : null); return (worksheet ? worksheet.model.workbook : null);
} };
_this.getCanvasContext = function() { _this.getCanvasContext = function() {
return _this.drawingDocument.CanvasHitContext; return _this.drawingDocument.CanvasHitContext;
} };
_this.getDrawingObjects = function() { _this.getDrawingObjects = function() {
return aObjects; return aObjects;
} };
_this.getWorksheet = function() { _this.getWorksheet = function() {
return worksheet; return worksheet;
} };
_this._uploadMessage = function(event) { _this._uploadMessage = function(event) {
if ( null != event && null != event.data ) { if ( null != event && null != event.data ) {
...@@ -3220,12 +3218,12 @@ function DrawingObjects() { ...@@ -3220,12 +3218,12 @@ function DrawingObjects() {
var msg = e.message; var msg = e.message;
} }
} }
} };
_this.callTrigger = function(triggerName, param) { _this.callTrigger = function(triggerName, param) {
if ( triggerName ) if ( triggerName )
worksheet.model.workbook.handlers.trigger(triggerName, param); worksheet.model.workbook.handlers.trigger(triggerName, param);
} };
_this.getBoundsChecker = function(graphicObject) { _this.getBoundsChecker = function(graphicObject) {
if ( graphicObject ) { if ( graphicObject ) {
...@@ -3255,7 +3253,7 @@ function DrawingObjects() { ...@@ -3255,7 +3253,7 @@ function DrawingObjects() {
return boundsChecker; return boundsChecker;
} }
return null; return null;
} };
_this.getBoundsCheckerCoords = function(checker) { _this.getBoundsCheckerCoords = function(checker) {
...@@ -3271,7 +3269,7 @@ function DrawingObjects() { ...@@ -3271,7 +3269,7 @@ function DrawingObjects() {
return coords; return coords;
} }
return null; return null;
} };
_this.clearDrawingObjects = function(graphicOption) { _this.clearDrawingObjects = function(graphicOption) {
...@@ -3295,7 +3293,7 @@ function DrawingObjects() { ...@@ -3295,7 +3293,7 @@ function DrawingObjects() {
var boundsChecker = _this.getBoundsChecker(aObjects[i].graphicObject); var boundsChecker = _this.getBoundsChecker(aObjects[i].graphicObject);
aBoundsCheckers.push(boundsChecker); aBoundsCheckers.push(boundsChecker);
} }
} };
_this.restoreSheetArea = function(checker) { _this.restoreSheetArea = function(checker) {
...@@ -3330,7 +3328,7 @@ function DrawingObjects() { ...@@ -3330,7 +3328,7 @@ function DrawingObjects() {
worksheet._drawCellsBorders(/*drawingCtx*/undefined, r_); worksheet._drawCellsBorders(/*drawingCtx*/undefined, r_);
} }
} }
} };
//----------------------------------------------------------------------------------- //-----------------------------------------------------------------------------------
// Drawing objects // Drawing objects
...@@ -3354,7 +3352,7 @@ function DrawingObjects() { ...@@ -3354,7 +3352,7 @@ function DrawingObjects() {
return; return;
} }
aDrawTasks.push({ time: currTime, params: { clearCanvas: clearCanvas, graphicOption: graphicOption, printOptions: printOptions} }); aDrawTasks.push({ time: currTime, params: { clearCanvas: clearCanvas, graphicOption: graphicOption, printOptions: printOptions} });
} };
_this.showDrawingObjectsEx = function(clearCanvas, graphicOption, printOptions) { _this.showDrawingObjectsEx = function(clearCanvas, graphicOption, printOptions) {
...@@ -3372,7 +3370,7 @@ function DrawingObjects() { ...@@ -3372,7 +3370,7 @@ function DrawingObjects() {
if ( drawingCtx ) { if ( drawingCtx ) {
if ( clearCanvas ) { if ( clearCanvas ) {
} }
this.drawingArea.clear(); _this.drawingArea.clear();
if ( aObjects.length ) { if ( aObjects.length ) {
...@@ -3415,8 +3413,6 @@ function DrawingObjects() { ...@@ -3415,8 +3413,6 @@ function DrawingObjects() {
shapeCtx.updatedRect = null;*/ shapeCtx.updatedRect = null;*/
for (var i = 0; i < aObjects.length; i++) { for (var i = 0; i < aObjects.length; i++) {
var index = i;
var drawingObject = aObjects[i]; var drawingObject = aObjects[i];
if ( !drawingObject.flags.anchorUpdated ) if ( !drawingObject.flags.anchorUpdated )
...@@ -3441,7 +3437,7 @@ function DrawingObjects() { ...@@ -3441,7 +3437,7 @@ function DrawingObjects() {
} }
} }
else { else {
this.drawingArea.drawObject(drawingObject); _this.drawingArea.drawObject(drawingObject);
} }
} }
} }
...@@ -3455,7 +3451,7 @@ function DrawingObjects() { ...@@ -3455,7 +3451,7 @@ function DrawingObjects() {
_this.OnUpdateOverlay(); _this.OnUpdateOverlay();
} }
} }
} };
_this.printGraphicObject = function(graphicObject, ctx, top, left) { _this.printGraphicObject = function(graphicObject, ctx, top, left) {
...@@ -3576,7 +3572,7 @@ function DrawingObjects() { ...@@ -3576,7 +3572,7 @@ function DrawingObjects() {
} }
} }
} }
} };
_this.getDrawingAreaMetrics = function() { _this.getDrawingAreaMetrics = function() {
...@@ -3587,7 +3583,7 @@ function DrawingObjects() { ...@@ -3587,7 +3583,7 @@ function DrawingObjects() {
var metrics = { var metrics = {
maxCol: 0, maxCol: 0,
maxRow: 0 maxRow: 0
} };
for (var i = 0; aObjects && (i < aObjects.length); i++) { for (var i = 0; aObjects && (i < aObjects.length); i++) {
...@@ -3598,7 +3594,7 @@ function DrawingObjects() { ...@@ -3598,7 +3594,7 @@ function DrawingObjects() {
metrics.maxRow = drawingObject.to.row + 1; // учитываем rowOff metrics.maxRow = drawingObject.to.row + 1; // учитываем rowOff
} }
return metrics; return metrics;
} };
_this.clipGraphicsCanvas = function(canvas, graphicOption) { _this.clipGraphicsCanvas = function(canvas, graphicOption) {
if ( canvas instanceof CGraphics ) { if ( canvas instanceof CGraphics ) {
...@@ -3640,7 +3636,7 @@ function DrawingObjects() { ...@@ -3640,7 +3636,7 @@ function DrawingObjects() {
// этот сэйв нужен для восстановления сложных вложенных клипов // этот сэйв нужен для восстановления сложных вложенных клипов
canvas.m_oContext.save(); canvas.m_oContext.save();
} }
} };
_this.restoreGraphicsCanvas = function(canvas) { _this.restoreGraphicsCanvas = function(canvas) {
if ( canvas instanceof CGraphics ) { if ( canvas instanceof CGraphics ) {
...@@ -3649,7 +3645,7 @@ function DrawingObjects() { ...@@ -3649,7 +3645,7 @@ function DrawingObjects() {
// этот рестор нужен для восстановления сложных вложенных клипов // этот рестор нужен для восстановления сложных вложенных клипов
canvas.m_oContext.restore(); canvas.m_oContext.restore();
} }
} };
_this._drawWorksheetLayer = function (range, offsetLeft, offsetTop) { _this._drawWorksheetLayer = function (range, offsetLeft, offsetTop) {
worksheet._drawGrid(/*drawingCtx*/undefined, range, offsetLeft, offsetTop); worksheet._drawGrid(/*drawingCtx*/undefined, range, offsetLeft, offsetTop);
...@@ -3757,7 +3753,7 @@ function DrawingObjects() { ...@@ -3757,7 +3753,7 @@ function DrawingObjects() {
object.to.rowOff = cellTo.rowOff; object.to.rowOff = cellTo.rowOff;
worksheet.handlers.trigger("reinitializeScroll"); worksheet.handlers.trigger("reinitializeScroll");
} };
var addImageObject = function (_image) { var addImageObject = function (_image) {
...@@ -3807,7 +3803,7 @@ function DrawingObjects() { ...@@ -3807,7 +3803,7 @@ function DrawingObjects() {
} }
} }
} }
} };
_this.editImageDrawingObject = function(imageUrl) { _this.editImageDrawingObject = function(imageUrl) {
...@@ -3853,7 +3849,7 @@ function DrawingObjects() { ...@@ -3853,7 +3849,7 @@ function DrawingObjects() {
} }
} }
} }
} };
_this.addChartDrawingObject = function(chart, options) { _this.addChartDrawingObject = function(chart, options) {
...@@ -3873,7 +3869,7 @@ function DrawingObjects() { ...@@ -3873,7 +3869,7 @@ function DrawingObjects() {
chart.worksheet = worksheet; // Для формул серий chart.worksheet = worksheet; // Для формул серий
}, this, []); }, this, []);
return this.controller.addChartDrawingObject(chart, options); return _this.controller.addChartDrawingObject(chart, options);
} }
else if ( isObject(chart) && chart["binary"] ) { else if ( isObject(chart) && chart["binary"] ) {
...@@ -3999,7 +3995,7 @@ function DrawingObjects() { ...@@ -3999,7 +3995,7 @@ function DrawingObjects() {
_this.showDrawingObjects(false); _this.showDrawingObjects(false);
History.TurnOn(); History.TurnOn();
} }
} };
_this.editChartDrawingObject = function(chart) { _this.editChartDrawingObject = function(chart) {
...@@ -4007,7 +4003,7 @@ function DrawingObjects() { ...@@ -4007,7 +4003,7 @@ function DrawingObjects() {
_this.controller.editChartDrawingObjects(chart); _this.controller.editChartDrawingObjects(chart);
_this.showDrawingObjects(false); _this.showDrawingObjects(false);
} }
} };
_this.rebuildChartGraphicObjects = function(range) { _this.rebuildChartGraphicObjects = function(range) {
/*var bRebuild = true; /*var bRebuild = true;
...@@ -4025,7 +4021,7 @@ function DrawingObjects() { ...@@ -4025,7 +4021,7 @@ function DrawingObjects() {
} }
} }
}*/ }*/
} };
_this.updateDrawingObject = function(bInsert, operType, updateRange) { _this.updateDrawingObject = function(bInsert, operType, updateRange) {
...@@ -4391,7 +4387,7 @@ function DrawingObjects() { ...@@ -4391,7 +4387,7 @@ function DrawingObjects() {
} }
} }
} }
} };
_this.moveRangeDrawingObject = function(oBBoxFrom, oBBoxTo, bResize) { _this.moveRangeDrawingObject = function(oBBoxFrom, oBBoxTo, bResize) {
...@@ -4443,14 +4439,14 @@ function DrawingObjects() { ...@@ -4443,14 +4439,14 @@ function DrawingObjects() {
} }
} }
// Проверяем локи // Проверяем локи
this.objectLocker.reset(); _this.objectLocker.reset();
for (var i = 0; i < chartDrawings.length; i++) { for (var i = 0; i < chartDrawings.length; i++) {
this.objectLocker.addObjectId( chartDrawings[i].graphicObject.Get_Id() ); this.objectLocker.addObjectId( chartDrawings[i].graphicObject.Get_Id() );
} }
this.objectLocker.checkObjects(callbackCheck); _this.objectLocker.checkObjects(callbackCheck);
History.EndTransaction(); History.EndTransaction();
} }
} };
//----------------------------------------------------------------------------------- //-----------------------------------------------------------------------------------
// Chart // Chart
...@@ -4464,7 +4460,7 @@ function DrawingObjects() { ...@@ -4464,7 +4460,7 @@ function DrawingObjects() {
result = true; result = true;
} }
return result; return result;
} };
_this.calcChartInterval = function(chart) { _this.calcChartInterval = function(chart) {
if (chart.range.intervalObject) { if (chart.range.intervalObject) {
...@@ -4485,7 +4481,7 @@ function DrawingObjects() { ...@@ -4485,7 +4481,7 @@ function DrawingObjects() {
} }
} }
} }
} };
_this.intervalToIntervalObject = function(chart) { _this.intervalToIntervalObject = function(chart) {
if (chart.range.interval && worksheet) { if (chart.range.interval && worksheet) {
...@@ -4493,7 +4489,7 @@ function DrawingObjects() { ...@@ -4493,7 +4489,7 @@ function DrawingObjects() {
if (_range) if (_range)
chart.range.intervalObject = _range; chart.range.intervalObject = _range;
} }
} };
_this.updateChartReferences = function(oldWorksheet, newWorksheet) { _this.updateChartReferences = function(oldWorksheet, newWorksheet) {
...@@ -4519,7 +4515,7 @@ function DrawingObjects() { ...@@ -4519,7 +4515,7 @@ function DrawingObjects() {
} }
} }
History.EndTransaction(); History.EndTransaction();
} };
//----------------------------------------------------------------------------------- //-----------------------------------------------------------------------------------
// Graphic object // Graphic object
...@@ -4559,7 +4555,7 @@ function DrawingObjects() { ...@@ -4559,7 +4555,7 @@ function DrawingObjects() {
aBoundsCheckers.push(boundsChecker);*/ aBoundsCheckers.push(boundsChecker);*/
return ret; return ret;
} };
_this.groupGraphicObjects = function() { _this.groupGraphicObjects = function() {
...@@ -4567,7 +4563,7 @@ function DrawingObjects() { ...@@ -4567,7 +4563,7 @@ function DrawingObjects() {
_this.controller.createGroup(null); _this.controller.createGroup(null);
worksheet.setSelectionShape(true); worksheet.setSelectionShape(true);
} }
} };
_this.unGroupGraphicObjects = function() { _this.unGroupGraphicObjects = function() {
...@@ -4576,7 +4572,7 @@ function DrawingObjects() { ...@@ -4576,7 +4572,7 @@ function DrawingObjects() {
worksheet.setSelectionShape(true); worksheet.setSelectionShape(true);
api.isStartAddShape = false; api.isStartAddShape = false;
} }
} };
_this.insertUngroupedObjects = function(idGroup, aGraphics) { _this.insertUngroupedObjects = function(idGroup, aGraphics) {
...@@ -4607,7 +4603,7 @@ function DrawingObjects() { ...@@ -4607,7 +4603,7 @@ function DrawingObjects() {
} }
} }
} }
} };
_this.getDrawingBase = function(graphicId) { _this.getDrawingBase = function(graphicId) {
for (var i = 0; i < aObjects.length; i++) { for (var i = 0; i < aObjects.length; i++) {
...@@ -4615,7 +4611,7 @@ function DrawingObjects() { ...@@ -4615,7 +4611,7 @@ function DrawingObjects() {
return aObjects[i]; return aObjects[i];
} }
return null; return null;
} };
_this.deleteDrawingBase = function(graphicId) { _this.deleteDrawingBase = function(graphicId) {
...@@ -4718,7 +4714,7 @@ function DrawingObjects() { ...@@ -4718,7 +4714,7 @@ function DrawingObjects() {
} }
return response; return response;
} };
_this.setGraphicObjectLockState = function(id, state) { _this.setGraphicObjectLockState = function(id, state) {
...@@ -4728,14 +4724,14 @@ function DrawingObjects() { ...@@ -4728,14 +4724,14 @@ function DrawingObjects() {
break; break;
} }
} }
} };
_this.resetLockedGraphicObjects = function() { _this.resetLockedGraphicObjects = function() {
for (var i = 0; i < aObjects.length; i++) { for (var i = 0; i < aObjects.length; i++) {
aObjects[i].graphicObject.lockType = c_oAscLockTypes.kLockTypeNone; aObjects[i].graphicObject.lockType = c_oAscLockTypes.kLockTypeNone;
} }
} };
_this.tryResetLockedGraphicObject = function(id) { _this.tryResetLockedGraphicObject = function(id) {
...@@ -4748,7 +4744,7 @@ function DrawingObjects() { ...@@ -4748,7 +4744,7 @@ function DrawingObjects() {
} }
} }
return bObjectFound; return bObjectFound;
} };
_this.setScrollOffset = function() { _this.setScrollOffset = function() {
/*if ( shapeCtx && shapeOverlayCtx && autoShapeTrack ) { /*if ( shapeCtx && shapeOverlayCtx && autoShapeTrack ) {
...@@ -4756,26 +4752,26 @@ function DrawingObjects() { ...@@ -4756,26 +4752,26 @@ function DrawingObjects() {
_this.drawingArea.frozenPlaces[i].setTransform(shapeCtx, shapeOverlayCtx, autoShapeTrack); _this.drawingArea.frozenPlaces[i].setTransform(shapeCtx, shapeOverlayCtx, autoShapeTrack);
} }
}*/ }*/
} };
_this.getDrawingCanvas = function() { _this.getDrawingCanvas = function() {
return { shapeCtx: shapeCtx, shapeOverlayCtx: shapeOverlayCtx, autoShapeTrack: autoShapeTrack, trackOverlay: trackOverlay }; return { shapeCtx: shapeCtx, shapeOverlayCtx: shapeOverlayCtx, autoShapeTrack: autoShapeTrack, trackOverlay: trackOverlay };
} };
_this.convertMetric = function(val, from, to) { _this.convertMetric = function(val, from, to) {
/* Параметры конвертирования (from/to) /* Параметры конвертирования (from/to)
0 - px, 1 - pt, 2 - in, 3 - mm 0 - px, 1 - pt, 2 - in, 3 - mm
*/ */
return val * ascCvtRatio(from, to); return val * ascCvtRatio(from, to);
} };
_this.getSelectedGraphicObjects = function() { _this.getSelectedGraphicObjects = function() {
return _this.controller.selectedObjects; return _this.controller.selectedObjects;
} };
_this.selectedGraphicObjectsExists = function() { _this.selectedGraphicObjectsExists = function() {
return _this.controller.selectedObjects.length > 0; return _this.controller.selectedObjects.length > 0;
} };
_this.loadImageRedraw = function(imageUrl) { _this.loadImageRedraw = function(imageUrl) {
...@@ -4798,7 +4794,7 @@ function DrawingObjects() { ...@@ -4798,7 +4794,7 @@ function DrawingObjects() {
else else
_this.showDrawingObjects(true); _this.showDrawingObjects(true);
} }
} };
_this.getOriginalImageSize = function() { _this.getOriginalImageSize = function() {
...@@ -4823,12 +4819,12 @@ function DrawingObjects() { ...@@ -4823,12 +4819,12 @@ function DrawingObjects() {
} }
} }
return new asc_CImageSize( 50, 50, false ); return new asc_CImageSize( 50, 50, false );
} };
_this.sendGraphicObjectProps = function() { _this.sendGraphicObjectProps = function() {
if ( worksheet ) if ( worksheet )
worksheet.handlers.trigger("selectionChanged", worksheet.getSelectionInfo()); worksheet.handlers.trigger("selectionChanged", worksheet.getSelectionInfo());
} };
_this.setGraphicObjectProps = function(props) { _this.setGraphicObjectProps = function(props) {
...@@ -4867,16 +4863,16 @@ function DrawingObjects() { ...@@ -4867,16 +4863,16 @@ function DrawingObjects() {
} }
_this.sendGraphicObjectProps(); _this.sendGraphicObjectProps();
} };
_this.showChartSettings = function() { _this.showChartSettings = function() {
api.wb.handlers.trigger("asc_onShowChartDialog", true); api.wb.handlers.trigger("asc_onShowChartDialog", true);
} };
_this.setDrawImagePlaceParagraph = function(element_id, props) { _this.setDrawImagePlaceParagraph = function(element_id, props) {
_this.drawingDocument.InitGuiCanvasTextProps(element_id); _this.drawingDocument.InitGuiCanvasTextProps(element_id);
_this.drawingDocument.DrawGuiCanvasTextProps(props); _this.drawingDocument.DrawGuiCanvasTextProps(props);
} };
//----------------------------------------------------------------------------------- //-----------------------------------------------------------------------------------
// Graphic object mouse & keyboard events // Graphic object mouse & keyboard events
...@@ -4886,7 +4882,7 @@ function DrawingObjects() { ...@@ -4886,7 +4882,7 @@ function DrawingObjects() {
var offsets = _this.drawingArea.getOffsets(x, y); var offsets = _this.drawingArea.getOffsets(x, y);
if ( offsets ) if ( offsets )
_this.controller.onMouseDown( e, pxToMm(x - offsets.x), pxToMm(y - offsets.y) ); _this.controller.onMouseDown( e, pxToMm(x - offsets.x), pxToMm(y - offsets.y) );
} };
_this.graphicObjectMouseMove = function(e, x, y) { _this.graphicObjectMouseMove = function(e, x, y) {
e.IsLocked = e.isLocked; e.IsLocked = e.isLocked;
...@@ -4894,19 +4890,19 @@ function DrawingObjects() { ...@@ -4894,19 +4890,19 @@ function DrawingObjects() {
var offsets = _this.drawingArea.getOffsets(x, y); var offsets = _this.drawingArea.getOffsets(x, y);
if ( offsets ) if ( offsets )
_this.controller.onMouseMove( e, pxToMm(x - offsets.x), pxToMm(y - offsets.y) ); _this.controller.onMouseMove( e, pxToMm(x - offsets.x), pxToMm(y - offsets.y) );
} };
_this.graphicObjectMouseUp = function(e, x, y) { _this.graphicObjectMouseUp = function(e, x, y) {
var offsets = _this.drawingArea.getOffsets(x, y); var offsets = _this.drawingArea.getOffsets(x, y);
if ( offsets ) if ( offsets )
_this.controller.onMouseUp( e, pxToMm(x - offsets.x), pxToMm(y - offsets.y) ); _this.controller.onMouseUp( e, pxToMm(x - offsets.x), pxToMm(y - offsets.y) );
} };
// keyboard // keyboard
_this.graphicObjectKeyDown = function(e) { _this.graphicObjectKeyDown = function(e) {
return _this.controller.onKeyDown( e ); return _this.controller.onKeyDown( e );
} };
_this.graphicObjectKeyPress = function(e) { _this.graphicObjectKeyPress = function(e) {
...@@ -4916,7 +4912,7 @@ function DrawingObjects() { ...@@ -4916,7 +4912,7 @@ function DrawingObjects() {
e.ShiftKey = e.shiftKey; e.ShiftKey = e.shiftKey;
e.Which = e.which; e.Which = e.which;
return _this.controller.onKeyPress( e ); return _this.controller.onKeyPress( e );
} };
//----------------------------------------------------------------------------------- //-----------------------------------------------------------------------------------
// Asc // Asc
...@@ -4949,7 +4945,7 @@ function DrawingObjects() { ...@@ -4949,7 +4945,7 @@ function DrawingObjects() {
shapeOverlayCtx.m_oContext.clearRect(0, 0, shapeOverlayCtx.m_lWidthPix, shapeOverlayCtx.m_lHeightPix); shapeOverlayCtx.m_oContext.clearRect(0, 0, shapeOverlayCtx.m_lWidthPix, shapeOverlayCtx.m_lHeightPix);
_this.OnUpdateOverlay(); _this.OnUpdateOverlay();
History.Clear(); History.Clear();
} };
_this.getWordChartObject = function() { _this.getWordChartObject = function() {
for (var i = 0; i < aObjects.length; i++) { for (var i = 0; i < aObjects.length; i++) {
...@@ -4962,7 +4958,7 @@ function DrawingObjects() { ...@@ -4962,7 +4958,7 @@ function DrawingObjects() {
} }
} }
return null; return null;
} };
_this.getAscChartObject = function() { _this.getAscChartObject = function() {
...@@ -4979,7 +4975,7 @@ function DrawingObjects() { ...@@ -4979,7 +4975,7 @@ function DrawingObjects() {
} }
} }
var chart = this.controller.getAscChartObject(); var chart = _this.controller.getAscChartObject();
if ( !chart ) { if ( !chart ) {
History.Create_NewPoint(); History.Create_NewPoint();
...@@ -5027,7 +5023,7 @@ function DrawingObjects() { ...@@ -5027,7 +5023,7 @@ function DrawingObjects() {
}(); }();
} }
return chart; return chart;
} };
//----------------------------------------------------------------------------------- //-----------------------------------------------------------------------------------
// Selection // Selection
...@@ -5093,7 +5089,7 @@ function DrawingObjects() { ...@@ -5093,7 +5089,7 @@ function DrawingObjects() {
worksheet._drawFormulaRanges(worksheet.arrActiveChartsRanges); worksheet._drawFormulaRanges(worksheet.arrActiveChartsRanges);
} }
} }
} };
_this.unselectDrawingObjects = function() { _this.unselectDrawingObjects = function() {
...@@ -5112,7 +5108,7 @@ function DrawingObjects() { ...@@ -5112,7 +5108,7 @@ function DrawingObjects() {
return aObjects[i]; return aObjects[i];
} }
return null; return null;
} };
_this.getGraphicSelectionType = function(id) { _this.getGraphicSelectionType = function(id) {
...@@ -5136,7 +5132,7 @@ function DrawingObjects() { ...@@ -5136,7 +5132,7 @@ function DrawingObjects() {
} }
} }
return undefined; return undefined;
} };
//----------------------------------------------------------------------------------- //-----------------------------------------------------------------------------------
// Position // Position
...@@ -5144,7 +5140,7 @@ function DrawingObjects() { ...@@ -5144,7 +5140,7 @@ function DrawingObjects() {
_this.setGraphicObjectLayer = function(layerType) { _this.setGraphicObjectLayer = function(layerType) {
_this.controller.setGraphicObjectLayer(layerType); _this.controller.setGraphicObjectLayer(layerType);
} };
_this.saveSizeDrawingObjects = function() { _this.saveSizeDrawingObjects = function() {
...@@ -5154,7 +5150,7 @@ function DrawingObjects() { ...@@ -5154,7 +5150,7 @@ function DrawingObjects() {
obj.size.width = obj.getWidthFromTo(); obj.size.width = obj.getWidthFromTo();
obj.size.height = obj.getHeightFromTo(); obj.size.height = obj.getHeightFromTo();
} }
} };
_this.updateSizeDrawingObjects = function() { _this.updateSizeDrawingObjects = function() {
...@@ -5175,7 +5171,7 @@ function DrawingObjects() { ...@@ -5175,7 +5171,7 @@ function DrawingObjects() {
drawingObject.graphicObject.calculateTransformTextMatrix(); drawingObject.graphicObject.calculateTransformTextMatrix();
} }
_this.showDrawingObjects(true); _this.showDrawingObjects(true);
} };
_this.checkCursorDrawingObject = function(x, y) { _this.checkCursorDrawingObject = function(x, y) {
...@@ -5194,7 +5190,7 @@ function DrawingObjects() { ...@@ -5194,7 +5190,7 @@ function DrawingObjects() {
} }
} }
return null; return null;
} };
_this.getPositionInfo = function(x, y) { _this.getPositionInfo = function(x, y) {
...@@ -5212,7 +5208,7 @@ function DrawingObjects() { ...@@ -5212,7 +5208,7 @@ function DrawingObjects() {
} }
return info; return info;
} };
//----------------------------------------------------------------------------------- //-----------------------------------------------------------------------------------
// File Dialog // File Dialog
...@@ -5248,13 +5244,13 @@ function DrawingObjects() { ...@@ -5248,13 +5244,13 @@ function DrawingObjects() {
worksheet.model.workbook.handlers.trigger("asc_onStartAction", c_oAscAsyncActionType.BlockInteraction, c_oAscAsyncAction.LoadImage); worksheet.model.workbook.handlers.trigger("asc_onStartAction", c_oAscAsyncActionType.BlockInteraction, c_oAscAsyncAction.LoadImage);
fileSubmit.click(); fileSubmit.click();
} }
} };
if (window.opera != undefined) if (window.opera != undefined)
setTimeout(function() { fileName.click(); }, 0); setTimeout(function() { fileName.click(); }, 0);
else else
fileName.click(); fileName.click();
} };
//----------------------------------------------------------------------------------- //-----------------------------------------------------------------------------------
// Shapes controller // Shapes controller
...@@ -5420,7 +5416,7 @@ function ClickCounter() { ...@@ -5420,7 +5416,7 @@ function ClickCounter() {
console.log(""); console.log("");
} }
_this.time = currTime; _this.time = currTime;
} };
_this.mouseMoveEvent = function(x, y) { _this.mouseMoveEvent = function(x, y) {
if ( (_this.x != x) || (_this.y != y) ) { if ( (_this.x != x) || (_this.y != y) ) {
...@@ -5431,7 +5427,7 @@ function ClickCounter() { ...@@ -5431,7 +5427,7 @@ function ClickCounter() {
if ( _this.log ) if ( _this.log )
console.log("Reset counter"); console.log("Reset counter");
} }
} };
_this.getClickCount = function() { _this.getClickCount = function() {
return _this.clickCount; return _this.clickCount;
...@@ -5511,7 +5507,7 @@ function CoordsManager(ws, bLog) { ...@@ -5511,7 +5507,7 @@ function CoordsManager(ws, bLog) {
cell.rowOff = worksheet.objectRender.convertMetric(cell.rowOffPx, 0, 3); cell.rowOff = worksheet.objectRender.convertMetric(cell.rowOffPx, 0, 3);
return cell; return cell;
} };
_t.calculateCoords = function(cell) { _t.calculateCoords = function(cell) {
......
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