Skip to content
Projeler
Gruplar
Parçacıklar
Yardım
Yükleniyor...
Oturum aç / Kaydol
Gezinmeyi değiştir
C
core
Proje
Proje
Ayrıntılar
Etkinlik
Cycle Analytics
Depo (repository)
Depo (repository)
Dosyalar
Kayıtlar (commit)
Dallar (branch)
Etiketler
Katkıda bulunanlar
Grafik
Karşılaştır
Grafikler
Konular (issue)
0
Konular (issue)
0
Liste
Pano
Etiketler
Kilometre Taşları
Birleştirme (merge) Talepleri
0
Birleştirme (merge) Talepleri
0
CI / CD
CI / CD
İş akışları (pipeline)
İşler
Zamanlamalar
Grafikler
Paketler
Paketler
Wiki
Wiki
Parçacıklar
Parçacıklar
Üyeler
Üyeler
Collapse sidebar
Close sidebar
Etkinlik
Grafik
Grafikler
Yeni bir konu (issue) oluştur
İşler
Kayıtlar (commit)
Konu (issue) Panoları
Kenar çubuğunu aç
LibreOffice
core
Commits
7b4d5369
Kaydet (Commit)
7b4d5369
authored
Mar 07, 2014
tarafından
Norbert Thiebaud
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
coverity#704566 Unchecked dynamic cast
Change-Id: I13ecfc6cd816a1653a292d00de348ca7683783f1
üst
57b89ea1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
26 additions
and
10 deletions
+26
-10
BarChart.cxx
chart2/source/view/charttypes/BarChart.cxx
+26
-10
No files found.
chart2/source/view/charttypes/BarChart.cxx
Dosyayı görüntüle @
7b4d5369
...
...
@@ -86,23 +86,39 @@ drawing::Direction3D BarChart::getPreferredDiagramAspectRatio() const
if
(
m_nDimension
==
3
)
{
aRet
=
drawing
::
Direction3D
(
1.0
,
-
1.0
,
1.0
);
BarPositionHelper
*
pPosHelper
=
dynamic_cast
<
BarPositionHelper
*>
(
&
(
this
->
getPlottingPositionHelper
(
MAIN_AXIS_INDEX
)
)
);
drawing
::
Direction3D
aScale
(
pPosHelper
->
getScaledLogicWidth
()
);
if
(
aScale
.
DirectionX
!=
0.0
)
BarPositionHelper
*
pPosHelper
=
dynamic_cast
<
BarPositionHelper
*>
(
&
(
this
->
getPlottingPositionHelper
(
MAIN_AXIS_INDEX
)
)
);
assert
(
pPosHelper
);
if
(
pPosHelper
)
{
double
fXSlotCount
=
1.0
;
if
(
!
m_aZSlots
.
empty
())
fXSlotCount
=
m_aZSlots
.
begin
()
->
size
();
aRet
.
DirectionZ
=
aScale
.
DirectionZ
/
(
aScale
.
DirectionX
+
aScale
.
DirectionX
*
(
fXSlotCount
-
1.0
)
*
pPosHelper
->
getScaledSlotWidth
());
drawing
::
Direction3D
aScale
(
pPosHelper
->
getScaledLogicWidth
()
);
if
(
aScale
.
DirectionX
!=
0.0
)
{
double
fXSlotCount
=
1.0
;
if
(
!
m_aZSlots
.
empty
())
{
fXSlotCount
=
m_aZSlots
.
begin
()
->
size
();
}
aRet
.
DirectionZ
=
aScale
.
DirectionZ
/
(
aScale
.
DirectionX
+
aScale
.
DirectionX
*
(
fXSlotCount
-
1.0
)
*
pPosHelper
->
getScaledSlotWidth
());
}
else
{
return
VSeriesPlotter
::
getPreferredDiagramAspectRatio
();
}
}
else
{
return
VSeriesPlotter
::
getPreferredDiagramAspectRatio
();
}
if
(
aRet
.
DirectionZ
<
0.05
)
{
aRet
.
DirectionZ
=
0.05
;
if
(
aRet
.
DirectionZ
>
10
)
}
else
if
(
aRet
.
DirectionZ
>
10
)
{
aRet
.
DirectionZ
=
10
;
}
if
(
m_pMainPosHelper
&&
m_pMainPosHelper
->
isSwapXAndY
()
)
{
double
fTemp
=
aRet
.
DirectionX
;
...
...
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