Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
S
sdkjs
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Boris Kocherov
sdkjs
Commits
b0047d71
Commit
b0047d71
authored
Apr 28, 2016
by
Alexander.Trofimov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
cell/model/DrawingObjects/Format/ to function-closure
parent
83b7a1f0
Changes
9
Hide whitespace changes
Inline
Side-by-side
Showing
9 changed files
with
48 additions
and
35 deletions
+48
-35
build/configs/webexcel.json
build/configs/webexcel.json
+1
-1
cell/model/DrawingObjects/Format/ChartSpacePrototype.js
cell/model/DrawingObjects/Format/ChartSpacePrototype.js
+9
-1
cell/model/DrawingObjects/Format/GroupPrototype.js
cell/model/DrawingObjects/Format/GroupPrototype.js
+3
-0
cell/model/DrawingObjects/Format/ImagePrototype.js
cell/model/DrawingObjects/Format/ImagePrototype.js
+3
-0
common/Charts/charts.js
common/Charts/charts.js
+18
-28
common/Drawings/Format/ChartFormat.js
common/Drawings/Format/ChartFormat.js
+4
-4
common/apiBase.js
common/apiBase.js
+4
-0
slide/Editor/Format/ChartSpacePrototype.js
slide/Editor/Format/ChartSpacePrototype.js
+5
-1
word/Editor/GraphicObjects/Format/ChartSpacePrototype.js
word/Editor/GraphicObjects/Format/ChartSpacePrototype.js
+1
-0
No files found.
build/configs/webexcel.json
View file @
b0047d71
...
...
@@ -116,10 +116,10 @@
"../cell/model/DrawingObjects/DrawingDocument.js"
,
"../cell/model/DrawingObjects/GlobalCounters.js"
,
"../cell/model/DrawingObjects/Format/ShapePrototype.js"
,
"../cell/model/DrawingObjects/Format/ImagePrototype.js"
,
"../cell/model/DrawingObjects/Format/GroupPrototype.js"
,
"../cell/model/DrawingObjects/Format/ChartSpacePrototype.js"
,
"../slide/Editor/Format/GraphicFrame.js"
,
"../word/Editor/Comments.js"
,
"../word/Editor/Styles.js"
,
...
...
cell/model/DrawingObjects/Format/ChartSpacePrototype.js
View file @
b0047d71
"
use strict
"
;
(
function
(
window
,
undefined
){
// Import
var
CShape
=
AscFormat
.
CShape
;
var
CChartSpace
=
AscFormat
.
CChartSpace
;
// ToDo перенести в один файл!
function
getChartTranslateManager
()
{
return
window
[
"
Asc
"
][
"
editor
"
].
chartTranslate
;
...
...
@@ -482,4 +485,9 @@ CChartSpace.prototype.getDrawingDocument = CShape.prototype.getDrawingDocument;
CChartSpace
.
prototype
.
recalculateLocalTransform
=
CShape
.
prototype
.
recalculateLocalTransform
;
CChartSpace
.
prototype
.
Get_Theme
=
CShape
.
prototype
.
Get_Theme
;
CChartSpace
.
prototype
.
Get_ColorMap
=
CShape
.
prototype
.
Get_ColorMap
;
\ No newline at end of file
CChartSpace
.
prototype
.
Get_ColorMap
=
CShape
.
prototype
.
Get_ColorMap
;
//----------------------------------------------------------export----------------------------------------------------
window
[
'
AscFormat
'
]
=
window
[
'
AscFormat
'
]
||
{};
window
[
'
AscFormat
'
].
getChartTranslateManager
=
getChartTranslateManager
;
})(
window
);
cell/model/DrawingObjects/Format/GroupPrototype.js
View file @
b0047d71
"
use strict
"
;
(
function
(
window
,
undefined
){
// Import
var
CShape
=
AscFormat
.
CShape
;
var
CGroupShape
=
AscFormat
.
CGroupShape
;
...
...
@@ -226,3 +228,4 @@ CGroupShape.prototype.recalculate = function()
}
},
this
,
[]);
};
})(
window
);
cell/model/DrawingObjects/Format/ImagePrototype.js
View file @
b0047d71
"
use strict
"
;
(
function
(
window
,
undefined
){
// Import
var
CShape
=
AscFormat
.
CShape
;
var
CImageShape
=
AscFormat
.
CImageShape
;
...
...
@@ -168,3 +170,4 @@ CImageShape.prototype.getCardDirectionByNum = CShape.prototype.getCardDirectionB
CImageShape
.
prototype
.
getResizeCoefficients
=
CShape
.
prototype
.
getResizeCoefficients
;
CImageShape
.
prototype
.
check_bounds
=
CShape
.
prototype
.
check_bounds
;
CImageShape
.
prototype
.
normalize
=
CShape
.
prototype
.
normalize
;
})(
window
);
common/Charts/charts.js
View file @
b0047d71
...
...
@@ -269,18 +269,15 @@ ChartPreviewManager.prototype.getChartByType = function(type)
var
chartSeries
=
{
series
:
this
.
getAscChartSeriesDefault
(
type
),
parsedHeaders
:
{
bLeft
:
true
,
bTop
:
true
}};
var
chart_space
=
AscFormat
.
DrawingObjectsController
.
prototype
.
_getChartSpace
(
chartSeries
,
settings
,
true
);
chart_space
.
bPreview
=
true
;
if
(
window
[
"
Asc
"
][
"
editor
"
])
{
var
api_sheet
=
window
[
"
Asc
"
][
"
editor
"
];
if
(
Asc
.
editor
&&
AscCommon
.
c_oEditorId
.
Spreadsheet
===
Asc
.
editor
.
getEditorId
())
{
var
api_sheet
=
Asc
.
editor
;
chart_space
.
setWorksheet
(
api_sheet
.
wb
.
getWorksheet
().
model
);
}
else
{
if
(
editor
&&
editor
.
WordControl
&&
editor
.
WordControl
.
m_oLogicDocument
.
Slides
&&
editor
.
WordControl
.
m_oLogicDocument
.
Slides
[
editor
.
WordControl
.
m_oLogicDocument
.
CurPage
])
{
chart_space
.
setParent
(
editor
.
WordControl
.
m_oLogicDocument
.
Slides
[
editor
.
WordControl
.
m_oLogicDocument
.
CurPage
]);
}
}
else
{
if
(
editor
&&
editor
.
WordControl
&&
editor
.
WordControl
.
m_oLogicDocument
.
Slides
&&
editor
.
WordControl
.
m_oLogicDocument
.
Slides
[
editor
.
WordControl
.
m_oLogicDocument
.
CurPage
])
{
chart_space
.
setParent
(
editor
.
WordControl
.
m_oLogicDocument
.
Slides
[
editor
.
WordControl
.
m_oLogicDocument
.
CurPage
]);
}
}
AscFormat
.
CheckSpPrXfrm
(
chart_space
);
chart_space
.
spPr
.
xfrm
.
setOffX
(
0
);
chart_space
.
spPr
.
xfrm
.
setOffY
(
0
);
...
...
@@ -828,27 +825,20 @@ TextArtPreviewManager.prototype.getShape = function()
var
oShape
=
new
AscFormat
.
CShape
();
var
oParent
=
null
,
oWorkSheet
=
null
;
var
bWord
=
true
;
if
(
window
[
"
Asc
"
][
"
editor
"
])
{
var
api_sheet
=
window
[
"
Asc
"
][
"
editor
"
];
if
(
Asc
.
editor
&&
AscCommon
.
c_oEditorId
.
Spreadsheet
===
Asc
.
editor
.
getEditorId
())
{
var
api_sheet
=
Asc
.
editor
;
oShape
.
setWorksheet
(
api_sheet
.
wb
.
getWorksheet
().
model
);
oWorkSheet
=
api_sheet
.
wb
.
getWorksheet
().
model
;
bWord
=
false
;
}
else
{
if
(
editor
&&
editor
.
WordControl
&&
Array
.
isArray
(
editor
.
WordControl
.
m_oLogicDocument
.
Slides
))
{
if
(
editor
.
WordControl
.
m_oLogicDocument
.
Slides
[
editor
.
WordControl
.
m_oLogicDocument
.
CurPage
])
{
oShape
.
setParent
(
editor
.
WordControl
.
m_oLogicDocument
.
Slides
[
editor
.
WordControl
.
m_oLogicDocument
.
CurPage
]);
oParent
=
editor
.
WordControl
.
m_oLogicDocument
.
Slides
[
editor
.
WordControl
.
m_oLogicDocument
.
CurPage
];
bWord
=
false
;
}
else
{
return
null
;
}
}
else
{
if
(
editor
&&
editor
.
WordControl
&&
Array
.
isArray
(
editor
.
WordControl
.
m_oLogicDocument
.
Slides
))
{
if
(
editor
.
WordControl
.
m_oLogicDocument
.
Slides
[
editor
.
WordControl
.
m_oLogicDocument
.
CurPage
])
{
oShape
.
setParent
(
editor
.
WordControl
.
m_oLogicDocument
.
Slides
[
editor
.
WordControl
.
m_oLogicDocument
.
CurPage
]);
oParent
=
editor
.
WordControl
.
m_oLogicDocument
.
Slides
[
editor
.
WordControl
.
m_oLogicDocument
.
CurPage
];
bWord
=
false
;
}
else
{
return
null
;
}
}
}
var
oParentObjects
=
oShape
.
getParentObjects
();
...
...
common/Drawings/Format/ChartFormat.js
View file @
b0047d71
...
...
@@ -3706,7 +3706,7 @@ CAreaSeries.prototype =
return
this
.
tx
.
strRef
.
strCache
.
pt
[
0
].
val
;
}
}
return
getChartTranslateManager
().
asc_getSeries
()
+
"
"
+
(
this
.
idx
+
1
)
;
return
AscFormat
.
getChartTranslateManager
().
asc_getSeries
()
+
"
"
+
(
this
.
idx
+
1
)
;
},
getCatName
:
function
(
idx
)
...
...
@@ -23421,17 +23421,17 @@ CTitle.prototype =
return
oTx
.
strRef
.
strCache
.
pt
[
0
].
val
;
}
}
return
getChartTranslateManager
().
asc_getTitle
();
return
AscFormat
.
getChartTranslateManager
().
asc_getTitle
();
}
else
{
if
(
this
.
parent
.
axPos
===
AX_POS_B
||
this
.
parent
.
axPos
===
AX_POS_T
)
{
return
getChartTranslateManager
().
asc_getXAxis
();
return
AscFormat
.
getChartTranslateManager
().
asc_getXAxis
();
}
else
{
return
getChartTranslateManager
().
asc_getYAxis
();
return
AscFormat
.
getChartTranslateManager
().
asc_getYAxis
();
}
}
}
...
...
common/apiBase.js
View file @
b0047d71
...
...
@@ -115,6 +115,7 @@ function baseEditorsApi(name) {
}
baseEditorsApi
.
prototype
.
_baseInit
=
function
()
{
var
t
=
this
;
//Asc.editor = Asc['editor'] = AscCommon['editor'] = AscCommon.editor = this; // ToDo сделать это!
this
.
HtmlElement
=
document
.
getElementById
(
this
.
HtmlElementName
);
// init OnMessage
...
...
@@ -149,6 +150,9 @@ baseEditorsApi.prototype._editorNameById = function() {
}
return
res
;
};
baseEditorsApi
.
prototype
.
getEditorId
=
function
()
{
return
this
.
editorId
;
};
baseEditorsApi
.
prototype
.
asc_GetFontThumbnailsPath
=
function
()
{
return
'
../Common/Images/
'
;
};
...
...
slide/Editor/Format/ChartSpacePrototype.js
View file @
b0047d71
...
...
@@ -707,4 +707,8 @@ CTablePr.prototype.Init_Default = function()
this
.
TableInd
=
0
;
this
.
TableW
=
new
CTableMeasurement
(
tblwidth_Auto
,
0
);
this
.
TableLayout
=
tbllayout_AutoFit
;
};
\ No newline at end of file
};
//----------------------------------------------------------export----------------------------------------------------
window
[
'
AscFormat
'
]
=
window
[
'
AscFormat
'
]
||
{};
window
[
'
AscFormat
'
].
getChartTranslateManager
=
getChartTranslateManager
;
\ No newline at end of file
word/Editor/GraphicObjects/Format/ChartSpacePrototype.js
View file @
b0047d71
...
...
@@ -621,3 +621,4 @@ function CreateNoFillUniFill()
window
[
'
AscFormat
'
].
CreateUnifillSolidFillSchemeColor
=
CreateUnifillSolidFillSchemeColor
;
window
[
'
AscFormat
'
].
CreateNoFillLine
=
CreateNoFillLine
;
window
[
'
AscFormat
'
].
CreateNoFillUniFill
=
CreateNoFillUniFill
;
window
[
'
AscFormat
'
].
getChartTranslateManager
=
getChartTranslateManager
;
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment