diff options
author | Carsten Driesner <cd@openoffice.org> | 2011-02-07 13:06:08 +0100 |
---|---|---|
committer | Carsten Driesner <cd@openoffice.org> | 2011-02-07 13:06:08 +0100 |
commit | e1d7ba29323a12fe05f5bf2aa40a822055f7d065 (patch) | |
tree | c0f51103406b519dd6c72f471cbaec03ff9addbe /chart2/source/tools/InternalData.cxx | |
parent | 8e46bfdceff41c73cff49e9365a9e1ebaa97bb7a (diff) | |
parent | 0ceb085ea2b49234664765161095f2e5911e2b3b (diff) |
removetooltypes01: Rebase to DEV300m99
Diffstat (limited to 'chart2/source/tools/InternalData.cxx')
-rwxr-xr-x | chart2/source/tools/InternalData.cxx | 42 |
1 files changed, 21 insertions, 21 deletions
diff --git a/chart2/source/tools/InternalData.cxx b/chart2/source/tools/InternalData.cxx index 65fc97a04b38..e9b0cf689768 100755 --- a/chart2/source/tools/InternalData.cxx +++ b/chart2/source/tools/InternalData.cxx @@ -38,6 +38,7 @@ using ::com::sun::star::uno::Sequence; using ::rtl::OUString; +using namespace ::com::sun::star; using namespace ::std; namespace chart @@ -55,10 +56,10 @@ struct lcl_NumberedStringGenerator m_nWildcardLength( rWildcard.getLength()) { } - vector< OUString > operator()() + vector< uno::Any > operator()() { - vector< OUString > aRet(1); - aRet[0] = m_aStub.replaceAt( m_nStubStartIndex, m_nWildcardLength, OUString::valueOf( ++m_nCounter )); + vector< uno::Any > aRet(1); + aRet[0] = uno::makeAny( m_aStub.replaceAt( m_nStubStartIndex, m_nWildcardLength, OUString::valueOf( ++m_nCounter )) ); return aRet; } private: @@ -113,12 +114,12 @@ void InternalData::createDefaultData() m_aRowLabels.clear(); m_aRowLabels.reserve( m_nRowCount ); generate_n( back_inserter( m_aRowLabels ), m_nRowCount, - lcl_NumberedStringGenerator( aRowName, C2U("%ROWNUMBER") )); + lcl_NumberedStringGenerator( aRowName, C2U("%ROWNUMBER") )); m_aColumnLabels.clear(); m_aColumnLabels.reserve( m_nColumnCount ); generate_n( back_inserter( m_aColumnLabels ), m_nColumnCount, - lcl_NumberedStringGenerator( aColName, C2U("%COLUMNNUMBER") )); + lcl_NumberedStringGenerator( aColName, C2U("%COLUMNNUMBER") )); } void InternalData::setData( const Sequence< Sequence< double > >& rDataInRows ) @@ -199,7 +200,7 @@ void InternalData::setRowValues( sal_Int32 nRowIndex, const vector< double > & r m_aData[ ::std::slice( nRowIndex*m_nColumnCount, m_nColumnCount, 1 ) ]= aSlice; } -void InternalData::setComplexColumnLabel( sal_Int32 nColumnIndex, const vector< OUString >& rComplexLabel ) +void InternalData::setComplexColumnLabel( sal_Int32 nColumnIndex, const vector< uno::Any >& rComplexLabel ) { if( nColumnIndex < 0 ) return; @@ -208,10 +209,10 @@ void InternalData::setComplexColumnLabel( sal_Int32 nColumnIndex, const vector< m_aColumnLabels.resize(nColumnIndex+1); enlargeData( nColumnIndex+1, 0 ); } - m_aColumnLabels[nColumnIndex]=rComplexLabel; } -void InternalData::setComplexRowLabel( sal_Int32 nRowIndex, const vector< OUString >& rComplexLabel ) + +void InternalData::setComplexRowLabel( sal_Int32 nRowIndex, const vector< uno::Any >& rComplexLabel ) { if( nRowIndex < 0 ) return; @@ -220,23 +221,22 @@ void InternalData::setComplexRowLabel( sal_Int32 nRowIndex, const vector< OUStri m_aRowLabels.resize(nRowIndex+1); enlargeData( 0, nRowIndex+1 ); } - m_aRowLabels[nRowIndex] = rComplexLabel; } -vector< OUString > InternalData::getComplexColumnLabel( sal_Int32 nColumnIndex ) const +vector< uno::Any > InternalData::getComplexColumnLabel( sal_Int32 nColumnIndex ) const { if( nColumnIndex < static_cast< sal_Int32 >( m_aColumnLabels.size() ) ) return m_aColumnLabels[nColumnIndex]; else - return vector< OUString >(); + return vector< uno::Any >(); } -vector< OUString > InternalData::getComplexRowLabel( sal_Int32 nRowIndex ) const +vector< uno::Any > InternalData::getComplexRowLabel( sal_Int32 nRowIndex ) const { if( nRowIndex < static_cast< sal_Int32 >( m_aRowLabels.size() ) ) return m_aRowLabels[nRowIndex]; else - return vector< OUString >(); + return vector< uno::Any >(); } void InternalData::swapRowWithNext( sal_Int32 nRowIndex ) @@ -253,7 +253,7 @@ void InternalData::swapRowWithNext( sal_Int32 nRowIndex ) m_aData[nIndex2] = fTemp; } - vector< OUString > aTemp( m_aRowLabels[nRowIndex] ); + vector< uno::Any > aTemp( m_aRowLabels[nRowIndex] ); m_aRowLabels[nRowIndex] = m_aRowLabels[nRowIndex + 1]; m_aRowLabels[nRowIndex + 1] = aTemp; } @@ -273,7 +273,7 @@ void InternalData::swapColumnWithNext( sal_Int32 nColumnIndex ) m_aData[nIndex2] = fTemp; } - vector< OUString > aTemp( m_aColumnLabels[nColumnIndex] ); + vector< uno::Any > aTemp( m_aColumnLabels[nColumnIndex] ); m_aColumnLabels[nColumnIndex] = m_aColumnLabels[nColumnIndex + 1]; m_aColumnLabels[nColumnIndex + 1] = aTemp; } @@ -336,7 +336,7 @@ void InternalData::insertColumn( sal_Int32 nAfterIndex ) // labels if( nAfterIndex < static_cast< sal_Int32 >( m_aColumnLabels.size())) - m_aColumnLabels.insert( m_aColumnLabels.begin() + (nAfterIndex + 1), vector< OUString >(1) ); + m_aColumnLabels.insert( m_aColumnLabels.begin() + (nAfterIndex + 1), vector< uno::Any >(1) ); #if OSL_DEBUG_LEVEL > 2 traceData(); @@ -388,7 +388,7 @@ void InternalData::insertRow( sal_Int32 nAfterIndex ) // labels if( nAfterIndex < static_cast< sal_Int32 >( m_aRowLabels.size())) - m_aRowLabels.insert( m_aRowLabels.begin() + nIndex, vector< OUString> (1)); + m_aRowLabels.insert( m_aRowLabels.begin() + nIndex, vector< uno::Any > (1)); #if OSL_DEBUG_LEVEL > 2 traceData(); @@ -481,7 +481,7 @@ sal_Int32 InternalData::getColumnCount() const return m_nColumnCount; } -void InternalData::setComplexRowLabels( const vector< vector< OUString > >& rNewRowLabels ) +void InternalData::setComplexRowLabels( const vector< vector< uno::Any > >& rNewRowLabels ) { m_aRowLabels = rNewRowLabels; sal_Int32 nNewRowCount = static_cast< sal_Int32 >( m_aRowLabels.size() ); @@ -491,12 +491,12 @@ void InternalData::setComplexRowLabels( const vector< vector< OUString > >& rNew enlargeData( 0, nNewRowCount ); } -vector< vector< OUString > > InternalData::getComplexRowLabels() const +vector< vector< uno::Any > > InternalData::getComplexRowLabels() const { return m_aRowLabels; } -void InternalData::setComplexColumnLabels( const vector< vector< OUString > >& rNewColumnLabels ) +void InternalData::setComplexColumnLabels( const vector< vector< uno::Any > >& rNewColumnLabels ) { m_aColumnLabels = rNewColumnLabels; sal_Int32 nNewColumnCount = static_cast< sal_Int32 >( m_aColumnLabels.size() ); @@ -506,7 +506,7 @@ void InternalData::setComplexColumnLabels( const vector< vector< OUString > >& r enlargeData( nNewColumnCount, 0 ); } -vector< vector< OUString > > InternalData::getComplexColumnLabels() const +vector< vector< uno::Any > > InternalData::getComplexColumnLabels() const { return m_aColumnLabels; } |