diff options
Diffstat (limited to 'wifi/kcmwifi/wificonfig.cpp')
-rw-r--r-- | wifi/kcmwifi/wificonfig.cpp | 66 |
1 files changed, 33 insertions, 33 deletions
diff --git a/wifi/kcmwifi/wificonfig.cpp b/wifi/kcmwifi/wificonfig.cpp index 5afd041f..53f1c7e0 100644 --- a/wifi/kcmwifi/wificonfig.cpp +++ b/wifi/kcmwifi/wificonfig.cpp @@ -17,7 +17,7 @@ Boston, MA 02110-1301, USA. */ -#include <qfile.h> +#include <tqfile.h> #include <ksimpleconfig.h> #include <kglobal.h> @@ -28,23 +28,23 @@ #include "wificonfig.h" -static QStringList speedList; -static QStringList wifiModeList; -static QStringList cryptoModeList; -static QStringList powerModeList; +static TQStringList speedList; +static TQStringList wifiModeList; +static TQStringList cryptoModeList; +static TQStringList powerModeList; Key::Key() { } -Key::Key( const QString &key ) +Key::Key( const TQString &key ) { setKey( key ); } -QString Key::rawKey() const +TQString Key::rawKey() const { - QString s = m_key; + TQString s = m_key; if ( isValid( m_key ) >= STRING_64 ) s = "s:" + s; @@ -52,12 +52,12 @@ QString Key::rawKey() const return s; } -void Key::setKey( const QString &key ) +void Key::setKey( const TQString &key ) { m_key = key; } -KeyStates Key::isValid ( QString keyCandidate ) +KeyStates Key::isValid ( TQString keyCandidate ) { if (keyCandidate.isEmpty()) { kdDebug() << "Ignoring key: empty.\n"; @@ -117,9 +117,9 @@ IfConfig::IfConfig() void IfConfig::load( KConfig *config, int i ) { - QString entry; + TQString entry; - QString group = QString( "Configuration %1" ).arg( i+1 ); + TQString group = TQString( "Configuration %1" ).arg( i+1 ); config->setGroup( group ); m_networkName = config->readEntry( "NetworkName" ); @@ -150,7 +150,7 @@ void IfConfig::load( KConfig *config, int i ) void IfConfig::save( KConfig *config, int i ) { - QString group = QString( "Configuration %1" ).arg( i+1 ); + TQString group = TQString( "Configuration %1" ).arg( i+1 ); config->setGroup( group ); config->writeEntry( "NetworkName", m_networkName ); @@ -227,11 +227,11 @@ void WifiConfig::save() m_config->sync(); } -QString WifiConfig::autoDetectInterface() +TQString WifiConfig::autoDetectInterface() { m_detectedInterface.truncate( 0 ); - QFile procFile ( "/proc/net/dev" ); + TQFile procFile ( "/proc/net/dev" ); if ( !procFile.open( IO_ReadOnly ) ) { @@ -240,8 +240,8 @@ QString WifiConfig::autoDetectInterface() return m_detectedInterface; } - QStringList list; - QString line; + TQStringList list; + TQString line; while ( !procFile.atEnd() ) { @@ -262,14 +262,14 @@ QString WifiConfig::autoDetectInterface() return m_detectedInterface; } - for ( QStringList::Iterator it = list.begin (); it != list.end (); ++it ) + for ( TQStringList::Iterator it = list.begin (); it != list.end (); ++it ) { if ( ((*it).contains("wifi"))==0 ) { // if the name is wifiX, ignore KProcIO test; test << "iwconfig"; test << *it; - connect( &test, SIGNAL( readReady( KProcIO * ) ), - this, SLOT( slotTestInterface( KProcIO * ) ) ); + connect( &test, TQT_SIGNAL( readReady( KProcIO * ) ), + this, TQT_SLOT( slotTestInterface( KProcIO * ) ) ); test.start ( KProcess::Block ); } } @@ -286,7 +286,7 @@ QString WifiConfig::autoDetectInterface() void WifiConfig::slotTestInterface( KProcIO *proc ) { - QString output; + TQString output; proc->readln( output ); if ( output.find ( "no wireless extensions" ) == -1 ) { @@ -295,22 +295,22 @@ void WifiConfig::slotTestInterface( KProcIO *proc ) } } -QString IfConfig::speedAsString() +TQString IfConfig::speedAsString() { return speedList[ m_speed ]; } -QString IfConfig::wifimodeAsString() +TQString IfConfig::wifimodeAsString() { return wifiModeList[ m_wifiMode ]; } -QString IfConfig::cryptomodeAsString() +TQString IfConfig::cryptomodeAsString() { return cryptoModeList[ m_cryptoMode ]; } -QString IfConfig::powermodeAsString() +TQString IfConfig::powermodeAsString() { return powerModeList[ m_pmMode ]; } @@ -325,42 +325,42 @@ Key IfConfig::activeKey() return m_keys[ m_activeKey-1 ]; } -IfConfig::Speed IfConfig::convertToSpeedFromString( const QString &s ) +IfConfig::Speed IfConfig::convertToSpeedFromString( const TQString &s ) { return ( IfConfig::Speed )speedList.findIndex( s ); } -void IfConfig::speedFromString( const QString &s ) +void IfConfig::speedFromString( const TQString &s ) { m_speed = convertToSpeedFromString( s ); } -IfConfig::WifiMode IfConfig::convertToWifiModeFromString( const QString &s ) +IfConfig::WifiMode IfConfig::convertToWifiModeFromString( const TQString &s ) { return ( IfConfig::WifiMode )wifiModeList.findIndex( s ); } -void IfConfig::wifimodeFromString( const QString &s ) +void IfConfig::wifimodeFromString( const TQString &s ) { m_wifiMode = convertToWifiModeFromString( s ); } -IfConfig::CryptoMode IfConfig::convertToCryptoModeFromString( const QString &s ) +IfConfig::CryptoMode IfConfig::convertToCryptoModeFromString( const TQString &s ) { return ( IfConfig::CryptoMode )cryptoModeList.findIndex( s ); } -void IfConfig::cryptomodeFromString( const QString &s ) +void IfConfig::cryptomodeFromString( const TQString &s ) { m_cryptoMode = convertToCryptoModeFromString( s ); } -IfConfig::PowerMode IfConfig::convertToPowerModeFromString( const QString &s ) +IfConfig::PowerMode IfConfig::convertToPowerModeFromString( const TQString &s ) { return ( IfConfig::PowerMode )powerModeList.findIndex( s ); } -void IfConfig::powermodeFromString( const QString &s ) +void IfConfig::powermodeFromString( const TQString &s ) { m_pmMode = convertToPowerModeFromString( s ); } |