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
07820444
Commit
07820444
authored
Apr 27, 2016
by
Alexander.Trofimov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
word/Drawing/ShapeDrawer to function-closure
cell/model/DrawingObjects/ShapeDrawer to function-closure
parent
004947fa
Changes
9
Hide whitespace changes
Inline
Side-by-side
Showing
9 changed files
with
22 additions
and
14 deletions
+22
-14
build/configs/webexcel.json
build/configs/webexcel.json
+1
-1
build/configs/webpowerpoint.json
build/configs/webpowerpoint.json
+1
-1
build/configs/webword.json
build/configs/webword.json
+1
-1
cell/model/DrawingObjects/ShapeDrawer.js
cell/model/DrawingObjects/ShapeDrawer.js
+4
-0
common/Drawings/Format/Shape.js
common/Drawings/Format/Shape.js
+2
-2
common/Native/Wrappers/ShapeDrawer.js
common/Native/Wrappers/ShapeDrawer.js
+3
-2
slide/Editor/Format/Slide.js
slide/Editor/Format/Slide.js
+1
-1
word/Drawing/ShapeDrawer.js
word/Drawing/ShapeDrawer.js
+7
-4
word/Editor/Math.js
word/Editor/Math.js
+2
-2
No files found.
build/configs/webexcel.json
View file @
07820444
...
@@ -112,8 +112,8 @@
...
@@ -112,8 +112,8 @@
"../cell/view/WorksheetView.js"
,
"../cell/view/WorksheetView.js"
,
"../cell/view/DrawingObjectsController.js"
,
"../cell/view/DrawingObjectsController.js"
,
"../cell/model/DrawingObjects/Graphics.js"
,
"../cell/model/DrawingObjects/Graphics.js"
,
"../cell/model/DrawingObjects/ShapeDrawer.js"
,
"../cell/model/DrawingObjects/ShapeDrawer.js"
,
"../cell/model/DrawingObjects/DrawingDocument.js"
,
"../cell/model/DrawingObjects/DrawingDocument.js"
,
"../cell/model/DrawingObjects/Format/ShapePrototype.js"
,
"../cell/model/DrawingObjects/Format/ShapePrototype.js"
,
"../cell/model/DrawingObjects/Format/ImagePrototype.js"
,
"../cell/model/DrawingObjects/Format/ImagePrototype.js"
,
...
...
build/configs/webpowerpoint.json
View file @
07820444
...
@@ -99,8 +99,8 @@
...
@@ -99,8 +99,8 @@
"../word/Editor/Sections.js"
,
"../word/Editor/Sections.js"
,
"../word/Drawing/Graphics.js"
,
"../word/Drawing/Graphics.js"
,
"../word/Drawing/ShapeDrawer.js"
,
"../word/Drawing/ShapeDrawer.js"
,
"../slide/Drawing/Transitions.js"
,
"../slide/Drawing/Transitions.js"
,
"../slide/Drawing/DrawingDocument.js"
,
"../slide/Drawing/DrawingDocument.js"
,
"../slide/Drawing/HtmlPage.js"
,
"../slide/Drawing/HtmlPage.js"
,
...
...
build/configs/webword.json
View file @
07820444
...
@@ -123,8 +123,8 @@
...
@@ -123,8 +123,8 @@
"../word/Editor/Spelling.js"
,
"../word/Editor/Spelling.js"
,
"../word/Drawing/Graphics.js"
,
"../word/Drawing/Graphics.js"
,
"../word/Drawing/ShapeDrawer.js"
,
"../word/Drawing/ShapeDrawer.js"
,
"../word/Drawing/DrawingDocument.js"
,
"../word/Drawing/DrawingDocument.js"
,
"../word/Drawing/GraphicsEvents.js"
,
"../word/Drawing/GraphicsEvents.js"
,
"../word/Drawing/Rulers.js"
,
"../word/Drawing/Rulers.js"
,
...
...
cell/model/DrawingObjects/ShapeDrawer.js
View file @
07820444
"
use strict
"
;
"
use strict
"
;
(
function
(
window
,
undefined
){
// Import
// Import
var
getFullImageSrc2
=
AscCommon
.
getFullImageSrc2
;
var
getFullImageSrc2
=
AscCommon
.
getFullImageSrc2
;
...
@@ -1893,3 +1895,5 @@ function ShapeToImageConverter(shape, pageIndex)
...
@@ -1893,3 +1895,5 @@ function ShapeToImageConverter(shape, pageIndex)
//------------------------------------------------------------export----------------------------------------------------
//------------------------------------------------------------export----------------------------------------------------
window
[
'
AscCommon
'
]
=
window
[
'
AscCommon
'
]
||
{};
window
[
'
AscCommon
'
]
=
window
[
'
AscCommon
'
]
||
{};
window
[
'
AscCommon
'
].
CShapeDrawer
=
CShapeDrawer
;
window
[
'
AscCommon
'
].
CShapeDrawer
=
CShapeDrawer
;
window
[
'
AscCommon
'
].
ShapeToImageConverter
=
ShapeToImageConverter
;
})(
window
);
common/Drawings/Format/Shape.js
View file @
07820444
...
@@ -3886,7 +3886,7 @@ CShape.prototype =
...
@@ -3886,7 +3886,7 @@ CShape.prototype =
}
}
if
(
!
AscFormat
.
isRealNumber
(
this
.
x
)
||
!
AscFormat
.
isRealNumber
(
this
.
y
)
||
!
AscFormat
.
isRealNumber
(
this
.
extX
)
||
!
AscFormat
.
isRealNumber
(
this
.
extY
))
if
(
!
AscFormat
.
isRealNumber
(
this
.
x
)
||
!
AscFormat
.
isRealNumber
(
this
.
y
)
||
!
AscFormat
.
isRealNumber
(
this
.
extX
)
||
!
AscFormat
.
isRealNumber
(
this
.
extY
))
return
""
;
return
""
;
var
img_object
=
ShapeToImageConverter
(
this
,
this
.
pageIndex
);
var
img_object
=
AscCommon
.
ShapeToImageConverter
(
this
,
this
.
pageIndex
);
if
(
img_object
)
if
(
img_object
)
{
{
if
(
img_object
.
ImageNative
)
if
(
img_object
.
ImageNative
)
...
@@ -4143,7 +4143,7 @@ CShape.prototype =
...
@@ -4143,7 +4143,7 @@ CShape.prototype =
if
(
graphics
.
CheckUseFonts2
!==
undefined
)
if
(
graphics
.
CheckUseFonts2
!==
undefined
)
graphics
.
CheckUseFonts2
(
this
.
transformText
);
graphics
.
CheckUseFonts2
(
this
.
transformText
);
if
(
window
.
IsShapeToImageConverter
)
if
(
AscCommon
.
IsShapeToImageConverter
)
{
{
this
.
textBoxContent
.
Set_StartPage
(
0
);
this
.
textBoxContent
.
Set_StartPage
(
0
);
result_page_index
=
0
;
result_page_index
=
0
;
...
...
common/Native/Wrappers/ShapeDrawer.js
View file @
07820444
window
.
IsShapeToImageConverter
=
false
;
function
DrawLineEnd
(
xEnd
,
yEnd
,
xPrev
,
yPrev
,
type
,
w
,
len
,
drawer
,
trans
)
function
DrawLineEnd
(
xEnd
,
yEnd
,
xPrev
,
yPrev
,
type
,
w
,
len
,
drawer
,
trans
)
{
{
switch
(
type
)
switch
(
type
)
...
@@ -1602,4 +1601,6 @@ function ShapeToImageConverter(shape, pageIndex)
...
@@ -1602,4 +1601,6 @@ function ShapeToImageConverter(shape, pageIndex)
//------------------------------------------------------------export----------------------------------------------------
//------------------------------------------------------------export----------------------------------------------------
window
[
'
AscCommon
'
]
=
window
[
'
AscCommon
'
]
||
{};
window
[
'
AscCommon
'
]
=
window
[
'
AscCommon
'
]
||
{};
window
[
'
AscCommon
'
].
CShapeDrawer
=
CShapeDrawer
;
window
[
'
AscCommon
'
].
CShapeDrawer
=
CShapeDrawer
;
\ No newline at end of file
window
[
'
AscCommon
'
].
ShapeToImageConverter
=
ShapeToImageConverter
;
window
[
'
AscCommon
'
].
IsShapeToImageConverter
=
false
;
slide/Editor/Format/Slide.js
View file @
07820444
...
@@ -1253,7 +1253,7 @@ Slide.prototype =
...
@@ -1253,7 +1253,7 @@ Slide.prototype =
{
{
if
(
typeof
this
.
cachedImage
===
"
string
"
&&
this
.
cachedImage
.
length
>
0
)
if
(
typeof
this
.
cachedImage
===
"
string
"
&&
this
.
cachedImage
.
length
>
0
)
return
this
.
cachedImage
;
return
this
.
cachedImage
;
return
ShapeToImageConverter
(
this
,
0
).
ImageUrl
;
return
AscCommon
.
ShapeToImageConverter
(
this
,
0
).
ImageUrl
;
},
},
checkNoTransformPlaceholder
:
function
()
checkNoTransformPlaceholder
:
function
()
...
...
word/Drawing/ShapeDrawer.js
View file @
07820444
"
use strict
"
;
"
use strict
"
;
(
function
(
window
,
undefined
){
// Import
// Import
var
getFullImageSrc2
=
AscCommon
.
getFullImageSrc2
;
var
getFullImageSrc2
=
AscCommon
.
getFullImageSrc2
;
...
@@ -7,8 +9,6 @@ var CShapeColor = AscFormat.CShapeColor;
...
@@ -7,8 +9,6 @@ var CShapeColor = AscFormat.CShapeColor;
var
c_oAscFill
=
Asc
.
c_oAscFill
;
var
c_oAscFill
=
Asc
.
c_oAscFill
;
window
.
IsShapeToImageConverter
=
false
;
window
.
IsShapeToImageConverter
;
function
DrawLineEnd
(
xEnd
,
yEnd
,
xPrev
,
yPrev
,
type
,
w
,
len
,
drawer
,
trans
)
function
DrawLineEnd
(
xEnd
,
yEnd
,
xPrev
,
yPrev
,
type
,
w
,
len
,
drawer
,
trans
)
{
{
switch
(
type
)
switch
(
type
)
...
@@ -1804,7 +1804,7 @@ CShapeDrawer.prototype =
...
@@ -1804,7 +1804,7 @@ CShapeDrawer.prototype =
function
ShapeToImageConverter
(
shape
,
pageIndex
)
function
ShapeToImageConverter
(
shape
,
pageIndex
)
{
{
window
.
IsShapeToImageConverter
=
true
;
AscCommon
.
IsShapeToImageConverter
=
true
;
var
_bounds_cheker
=
new
AscFormat
.
CSlideBoundsChecker
();
var
_bounds_cheker
=
new
AscFormat
.
CSlideBoundsChecker
();
var
dKoef
=
g_dKoef_mm_to_pix
;
var
dKoef
=
g_dKoef_mm_to_pix
;
...
@@ -1857,7 +1857,7 @@ function ShapeToImageConverter(shape, pageIndex)
...
@@ -1857,7 +1857,7 @@ function ShapeToImageConverter(shape, pageIndex)
shape
.
draw
(
g
,
/*pageIndex*/
0
);
shape
.
draw
(
g
,
/*pageIndex*/
0
);
window
.
IsShapeToImageConverter
=
false
;
AscCommon
.
IsShapeToImageConverter
=
false
;
var
_ret
=
{
ImageNative
:
_canvas
,
ImageUrl
:
""
};
var
_ret
=
{
ImageNative
:
_canvas
,
ImageUrl
:
""
};
try
try
...
@@ -1877,3 +1877,6 @@ function ShapeToImageConverter(shape, pageIndex)
...
@@ -1877,3 +1877,6 @@ function ShapeToImageConverter(shape, pageIndex)
//------------------------------------------------------------export----------------------------------------------------
//------------------------------------------------------------export----------------------------------------------------
window
[
'
AscCommon
'
]
=
window
[
'
AscCommon
'
]
||
{};
window
[
'
AscCommon
'
]
=
window
[
'
AscCommon
'
]
||
{};
window
[
'
AscCommon
'
].
CShapeDrawer
=
CShapeDrawer
;
window
[
'
AscCommon
'
].
CShapeDrawer
=
CShapeDrawer
;
window
[
'
AscCommon
'
].
ShapeToImageConverter
=
ShapeToImageConverter
;
window
[
'
AscCommon
'
].
IsShapeToImageConverter
=
false
;
})(
window
);
word/Editor/Math.js
View file @
07820444
...
@@ -2541,7 +2541,7 @@ ParaMath.prototype.MathToImageConverter = function(bCopy, _canvasInput, _widthPx
...
@@ -2541,7 +2541,7 @@ ParaMath.prototype.MathToImageConverter = function(bCopy, _canvasInput, _widthPx
History
.
TurnOn
();
History
.
TurnOn
();
window
.
IsShapeToImageConverter
=
true
;
AscCommon
.
IsShapeToImageConverter
=
true
;
var
dKoef
=
g_dKoef_mm_to_pix
;
var
dKoef
=
g_dKoef_mm_to_pix
;
...
@@ -2600,7 +2600,7 @@ ParaMath.prototype.MathToImageConverter = function(bCopy, _canvasInput, _widthPx
...
@@ -2600,7 +2600,7 @@ ParaMath.prototype.MathToImageConverter = function(bCopy, _canvasInput, _widthPx
if
(
true
===
isShowParaMarks
)
if
(
true
===
isShowParaMarks
)
par
.
LogicDocument
.
Set_ShowParagraphMarks
(
true
,
false
);
par
.
LogicDocument
.
Set_ShowParagraphMarks
(
true
,
false
);
window
.
IsShapeToImageConverter
=
false
;
AscCommon
.
IsShapeToImageConverter
=
false
;
if
(
undefined
===
_canvasInput
)
if
(
undefined
===
_canvasInput
)
{
{
...
...
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