diff options
author | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2011-06-25 05:28:35 +0000 |
---|---|---|
committer | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2011-06-25 05:28:35 +0000 |
commit | f008adb5a77e094eaf6abf3fc0f36958e66896a5 (patch) | |
tree | 8e9244c4d4957c36be81e15b566b4aa5ea26c982 /kchart/kdchart/KDChartVectorTable.h | |
parent | 1210f27b660efb7b37ff43ec68763e85a403471f (diff) | |
download | koffice-f008adb5a77e094eaf6abf3fc0f36958e66896a5.tar.gz koffice-f008adb5a77e094eaf6abf3fc0f36958e66896a5.zip |
TQt4 port koffice
This should enable compilation under both Qt3 and Qt4; fixes for any missed components will be forthcoming
git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/applications/koffice@1238284 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'kchart/kdchart/KDChartVectorTable.h')
-rw-r--r-- | kchart/kdchart/KDChartVectorTable.h | 45 |
1 files changed, 23 insertions, 22 deletions
diff --git a/kchart/kdchart/KDChartVectorTable.h b/kchart/kdchart/KDChartVectorTable.h index b31b0811..7ba0b9ac 100644 --- a/kchart/kdchart/KDChartVectorTable.h +++ b/kchart/kdchart/KDChartVectorTable.h @@ -29,29 +29,29 @@ #ifndef __KDCHARTVECTORTABLE_H__ #define __KDCHARTVECTORTABLE_H__ -#include <qvaluevector.h> -#include <qshared.h> -#include <qtable.h> +#include <tqvaluevector.h> +#include <tqshared.h> +#include <tqtable.h> #include <KDChartDataIntern.h> #include <KDChartTableBase.h> -class KDCHART_EXPORT KDChartVectorTablePrivate : public QShared +class KDCHART_EXPORT KDChartVectorTablePrivate : public TQShared { public: - KDChartVectorTablePrivate() : QShared() { + KDChartVectorTablePrivate() : TQShared() { row_count = 0; col_count = 0; } - KDChartVectorTablePrivate( uint _rows, uint _cols ) : QShared() { + KDChartVectorTablePrivate( uint _rows, uint _cols ) : TQShared() { matrix.resize( _rows * _cols, KDChartData() ); col_count = _cols; row_count = _rows; } KDChartVectorTablePrivate( const KDChartVectorTablePrivate& _t ) : - QShared(), + TQShared(), matrix( _t.matrix ), col_count( _t.col_count ), row_count( _t.row_count ) {} @@ -60,15 +60,15 @@ public: void expand( uint _rows, uint _cols ) { // Save the old table - QValueVector<KDChartData> save( matrix ); + TQValueVector<KDChartData> save( matrix ); // Delete old data, then resize matrix.resize( 0 ); matrix.resize( _rows * _cols, KDChartData() ); // Copy over the old data - for( uint row = 0; row < QMIN( row_count, _rows ); row++ ) - for( uint col = 0; col < QMIN( col_count, _cols ); col++ ) + for( uint row = 0; row < TQMIN( row_count, _rows ); row++ ) + for( uint col = 0; col < TQMIN( col_count, _cols ); col++ ) matrix[ row * _cols + col ].setAll( save[ row * col_count + col ] ); // set the new counts @@ -104,7 +104,7 @@ public: matrix[ r * col_count + c ].clearValue(); } - QValueVector<KDChartData> matrix; + TQValueVector<KDChartData> matrix; uint col_count; uint row_count; @@ -114,6 +114,7 @@ public: class KDCHART_EXPORT KDChartVectorTableData : public KDChartTableDataBase { Q_OBJECT + TQ_OBJECT private: typedef KDChartVectorTablePrivate Priv; @@ -123,14 +124,14 @@ public: /** * Typedefs */ - typedef QValueVector<KDChartData>::iterator Iterator; - typedef QValueVector<KDChartData>::const_iterator ConstIterator; + typedef TQValueVector<KDChartData>::iterator Iterator; + typedef TQValueVector<KDChartData>::const_iterator ConstIterator; - typedef QValueVector<int>::iterator RowIterator; - typedef QValueVector<int>::const_iterator ConstRowIterator; + typedef TQValueVector<int>::iterator RowIterator; + typedef TQValueVector<int>::const_iterator ConstRowIterator; - typedef QValueVector<int>::iterator ColIterator; - typedef QValueVector<int>::const_iterator ConstColIterator; + typedef TQValueVector<int>::iterator ColIterator; + typedef TQValueVector<int>::const_iterator ConstColIterator; /** * API @@ -220,7 +221,7 @@ public slots: } */ virtual bool cellCoord( uint _row, uint _col, - QVariant& _value, + TQVariant& _value, int coordinate=1 ) const { if( _row >= sh->row_count || _col >= sh->col_count ) @@ -239,8 +240,8 @@ public slots: } virtual void setCell( uint _row, uint _col, - const QVariant& _value1, - const QVariant& _value2=QVariant() ) { + const TQVariant& _value1, + const TQVariant& _value2=TQVariant() ) { detach(); const KDChartData element( _value1, _value2 ); sh->setCell( _row, _col, element ); @@ -267,9 +268,9 @@ public slots: sh->expand( _rows, _cols ); // adjust the usedRows / usedCols, if they had been set before if( _useUsedCols ) - setUsedCols( QMIN( _usedCols, _cols ) ); + setUsedCols( TQMIN( _usedCols, _cols ) ); if( _useUsedRows ) - setUsedRows( QMIN( _usedRows, _rows ) ); + setUsedRows( TQMIN( _usedRows, _rows ) ); } void setUsedRows( uint _rows ) { |