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
78fd3f89
Commit
78fd3f89
authored
7 years ago
by
Alexey.Musinov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ios fixed styles for charts
parent
356b0379
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
32 additions
and
44 deletions
+32
-44
common/Native/Wrappers/api.js
common/Native/Wrappers/api.js
+32
-44
No files found.
common/Native/Wrappers/api.js
View file @
78fd3f89
...
...
@@ -5740,34 +5740,20 @@ AscCommon.ChartPreviewManager.prototype.clearPreviews = function()
{
window
[
"
native
"
][
"
DD_ClearCacheChartStyles
"
]();
};
AscCommon
.
ChartPreviewManager
.
prototype
.
createChartPreview
=
function
(
_graphics
,
type
,
styleIndex
)
{
return
AscFormat
.
ExecuteNoHistory
(
function
(){
if
(
!
this
.
chartsByTypes
[
type
])
this
.
chartsByTypes
[
type
]
=
this
.
getChartByType
(
type
);
var
chart_space
=
this
.
chartsByTypes
[
type
];
if
(
chart_space
.
style
!==
styleIndex
)
{
chart_space
.
style
=
styleIndex
;
chart_space
.
recalculateMarkers
();
chart_space
.
recalculateSeriesColors
();
chart_space
.
recalculatePlotAreaChartBrush
();
chart_space
.
recalculatePlotAreaChartPen
();
chart_space
.
recalculateChartBrush
();
chart_space
.
recalculateChartPen
();
chart_space
.
recalculateUpDownBars
();
}
chart_space
.
recalculatePenBrush
();
var
_width_px
=
this
.
CHART_PREVIEW_WIDTH_PIX
;
var
_height_px
=
this
.
CHART_PREVIEW_WIDTH_PIX
;
if
(
AscCommon
.
AscBrowser
.
isRetina
)
{
_width_px
<<=
1
;
_height_px
<<=
1
;
}
var
chart_space
=
this
.
chartsByTypes
[
type
];
AscFormat
.
ApplyPresetToChartSpace
(
chart_space
,
AscCommon
.
g_oChartPresets
[
type
][
styleIndex
]);
chart_space
.
recalcInfo
.
recalculateReferences
=
false
;
chart_space
.
recalculate
();
window
[
"
native
"
][
"
DD_StartNativeDraw
"
](
_width_px
,
_height_px
,
50
,
50
);
// sizes for imageView
window
[
"
native
"
][
"
DD_StartNativeDraw
"
](
85
*
2
,
85
*
2
,
75
,
75
);
var
dKoefToMM
=
AscCommon
.
g_dKoef_pix_to_mm
;
if
(
this
.
IsRetinaEnabled
)
...
...
@@ -5784,7 +5770,6 @@ AscCommon.ChartPreviewManager.prototype.createChartPreview = function(_graphics,
window
[
"
native
"
][
"
DD_EndNativeDraw
"
](
_stream
);
},
this
,
[]);
};
AscCommon
.
ChartPreviewManager
.
prototype
.
getChartPreviews
=
function
(
chartType
)
...
...
@@ -5798,8 +5783,11 @@ AscCommon.ChartPreviewManager.prototype.getChartPreviews = function(chartType)
var
_graphics
=
new
CDrawingStream
();
for
(
var
i
=
1
;
i
<
49
;
++
i
)
if
(
AscCommon
.
g_oChartPresets
[
chartType
]){
var
nStylesCount
=
AscCommon
.
g_oChartPresets
[
chartType
].
length
;
for
(
var
i
=
0
;
i
<
nStylesCount
;
++
i
)
this
.
createChartPreview
(
_graphics
,
chartType
,
i
);
}
var
_stream
=
global_memory_stream_menu
;
_stream
[
"
ClearNoAttack
"
]();
...
...
This diff is collapsed.
Click to expand it.
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