[Libreoffice-commits] .: 2 commits - chart2/source sc/source

Markus Mohrhard mmohrhard at kemper.freedesktop.org
Sun Mar 4 08:15:08 PST 2012


 chart2/source/view/axes/VCartesianAxis.cxx |    2 +-
 sc/source/ui/unoobj/chart2uno.cxx          |    2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

New commits:
commit a769fd1ec076b61c1ce2f84da87283cc637dd5d5
Author: Markus Mohrhard <markus.mohrhard at googlemail.com>
Date:   Sun Mar 4 17:06:49 2012 +0100

    correctly set the position of the axis labels, related fdo#44832
    
    There are still some more issues but at least they are now correctly
    located in the right position
    
    All advanced attributes are not yet applied.

diff --git a/chart2/source/view/axes/VCartesianAxis.cxx b/chart2/source/view/axes/VCartesianAxis.cxx
index fa20c2e..a6547ef 100644
--- a/chart2/source/view/axes/VCartesianAxis.cxx
+++ b/chart2/source/view/axes/VCartesianAxis.cxx
@@ -473,11 +473,11 @@ void VCartesianAxis::createAllTickInfosFromComplexCategories( ::std::vector< ::s
         rAllTickInfos.clear();
         sal_Int32 nLevel=0;
         sal_Int32 nLevelCount = m_aAxisProperties.m_pExplicitCategoriesProvider->getCategoryLevelCount();
+        sal_Int32 nCatIndex = 0;
         for( ; nLevel<nLevelCount; nLevel++ )
         {
             ::std::vector< TickInfo > aTickInfoVector;
             std::vector< ComplexCategory > aComplexCategories( m_aAxisProperties.m_pExplicitCategoriesProvider->getCategoriesByLevel( nLevel ) );
-            sal_Int32 nCatIndex = 0;
             std::vector< ComplexCategory >::const_iterator aIt(aComplexCategories.begin());
             std::vector< ComplexCategory >::const_iterator aEnd(aComplexCategories.end());
             for(;aIt!=aEnd;++aIt)
commit 6ba126ce26c83a0e6766e8dc8c38202d2a2ab238
Author: Markus Mohrhard <markus.mohrhard at googlemail.com>
Date:   Sun Mar 4 00:05:33 2012 +0100

    don't crash for empty input data in charts, fdo#46885

diff --git a/sc/source/ui/unoobj/chart2uno.cxx b/sc/source/ui/unoobj/chart2uno.cxx
index 90d1b07..034d261 100644
--- a/sc/source/ui/unoobj/chart2uno.cxx
+++ b/sc/source/ui/unoobj/chart2uno.cxx
@@ -1560,7 +1560,7 @@ ScChart2DataProvider::createDataSource(
         }
         Reference< chart2::data::XLabeledDataSequence > xChartSeries = lcl_createLabeledDataSequenceFromTokens(
             pValueTokens, pLabelTokens, m_pDocument, this, m_bIncludeHiddenCells ); //ownership of pointers is transfered!
-        if ( xChartSeries.is() && xChartSeries->getValues()->getData().getLength() )
+        if ( xChartSeries.is() && xChartSeries->getValues().is() && xChartSeries->getValues()->getData().getLength() )
         {
             aSeqs.push_back( xChartSeries );
         }


More information about the Libreoffice-commits mailing list