diff options
author | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2011-02-15 19:15:16 +0000 |
---|---|---|
committer | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2011-02-15 19:15:16 +0000 |
commit | cc0ad49c75d6cf6b4e63eb8c6012afe55c1589f9 (patch) | |
tree | 2a29ccab4d3cea34b87bfcbc38e64a8e25d25bb0 /ksysguard/gui/SensorDisplayLib/FancyPlotter.cc | |
parent | 107dd1f98367d07df7cbe2042786511e44706d3a (diff) | |
download | tdebase-cc0ad49c75d6cf6b4e63eb8c6012afe55c1589f9.tar.gz tdebase-cc0ad49c75d6cf6b4e63eb8c6012afe55c1589f9.zip |
Allow kdebase to (mostly) function correctly with TQt for Qt4
Fix kicker tackbar handling under Classic mode (thanks to Ilya Chernykh for the patch)
Fix a newly invalidated section of code under GCC 4.5.2 (http://gcc.gnu.org/bugzilla/show_bug.cgi?id=47723#c6)
git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdebase@1220927 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'ksysguard/gui/SensorDisplayLib/FancyPlotter.cc')
-rw-r--r-- | ksysguard/gui/SensorDisplayLib/FancyPlotter.cc | 28 |
1 files changed, 14 insertions, 14 deletions
diff --git a/ksysguard/gui/SensorDisplayLib/FancyPlotter.cc b/ksysguard/gui/SensorDisplayLib/FancyPlotter.cc index 65a9ec809..09a6e7a94 100644 --- a/ksysguard/gui/SensorDisplayLib/FancyPlotter.cc +++ b/ksysguard/gui/SensorDisplayLib/FancyPlotter.cc @@ -101,10 +101,10 @@ void FancyPlotter::configureSettings() for ( uint i = 0; i < mBeams; ++i ) { TQStringList entry; entry << TQString::number(i); - entry << sensors().at( i )->hostName(); - entry << KSGRD::SensorMgr->translateSensor( sensors().at( i )->name() ); - entry << KSGRD::SensorMgr->translateUnit( sensors().at( i )->unit() ); - entry << ( sensors().at( i )->isOk() ? i18n( "OK" ) : i18n( "Error" ) ); + entry << sensors().tqat( i )->hostName(); + entry << KSGRD::SensorMgr->translateSensor( sensors().tqat( i )->name() ); + entry << KSGRD::SensorMgr->translateUnit( sensors().tqat( i )->unit() ); + entry << ( sensors().tqat( i )->isOk() ? i18n( "OK" ) : i18n( "Error" ) ); entry << ( mPlotter->beamColors()[ i ].name() ); list.append( entry ); @@ -214,10 +214,10 @@ bool FancyPlotter::addSensor( const TQString &hostName, const TQString &name, if ( type != "integer" && type != "float" ) return false; - if ( mBeams > 0 && hostName != sensors().at( 0 )->hostName() ) { + if ( mBeams > 0 && hostName != sensors().tqat( 0 )->hostName() ) { KMessageBox::sorry( this, TQString( "All sensors of this display need " "to be from the host %1!" ) - .arg( sensors().at( 0 )->hostName() ) ); + .arg( sensors().tqat( 0 )->hostName() ) ); /* We have to enforce this since the answers to value requests * need to be received in order. */ @@ -238,8 +238,8 @@ bool FancyPlotter::addSensor( const TQString &hostName, const TQString &name, TQString tooltip; for ( uint i = 0; i < mBeams; ++i ) { tooltip += TQString( "%1%2:%3" ).arg( i != 0 ? "\n" : "" ) - .arg( sensors().at( mBeams - i - 1 )->hostName() ) - .arg( sensors().at( mBeams - i - 1 )->name() ); + .arg( sensors().tqat( mBeams - i - 1 )->hostName() ) + .arg( sensors().tqat( mBeams - i - 1 )->name() ); } TQToolTip::remove( TQT_TQWIDGET(mPlotter) ); @@ -263,8 +263,8 @@ bool FancyPlotter::removeSensor( uint pos ) TQString tooltip; for ( uint i = 0; i < mBeams; ++i ) { tooltip += TQString( "%1%2:%3" ).arg( i != 0 ? "\n" : "" ) - .arg( sensors().at( mBeams - i - 1 )->hostName() ) - .arg( sensors().at( mBeams - i - 1 )->name() ); + .arg( sensors().tqat( mBeams - i - 1 )->hostName() ) + .arg( sensors().tqat( mBeams - i - 1 )->name() ); } TQToolTip::remove( TQT_TQWIDGET(mPlotter) ); @@ -319,7 +319,7 @@ void FancyPlotter::answerReceived( int id, const TQString &answer ) if ( info.min() == 0.0 && info.max() == 0.0 ) mPlotter->setUseAutoRange( true ); } - sensors().at( id - 100 )->setUnit( info.unit() ); + sensors().tqat( id - 100 )->setUnit( info.unit() ); } } @@ -405,9 +405,9 @@ bool FancyPlotter::saveSettings( TQDomDocument &doc, TQDomElement &element, for ( uint i = 0; i < mBeams; ++i ) { TQDomElement beam = doc.createElement( "beam" ); element.appendChild( beam ); - beam.setAttribute( "hostName", sensors().at( i )->hostName() ); - beam.setAttribute( "sensorName", sensors().at( i )->name() ); - beam.setAttribute( "sensorType", sensors().at( i )->type() ); + beam.setAttribute( "hostName", sensors().tqat( i )->hostName() ); + beam.setAttribute( "sensorName", sensors().tqat( i )->name() ); + beam.setAttribute( "sensorType", sensors().tqat( i )->type() ); saveColor( beam, "color", mPlotter->beamColors()[ i ] ); } |