diff options
Diffstat (limited to 'KMFIPTInterface')
-rw-r--r-- | KMFIPTInterface/iptchecker.cpp | 16 | ||||
-rw-r--r-- | KMFIPTInterface/iptchecker.h | 8 | ||||
-rw-r--r-- | KMFIPTInterface/kmfiptinterface.cpp | 22 | ||||
-rw-r--r-- | KMFIPTInterface/kmfiptinterface.h | 24 |
4 files changed, 35 insertions, 35 deletions
diff --git a/KMFIPTInterface/iptchecker.cpp b/KMFIPTInterface/iptchecker.cpp index bf6979d..e69e8b5 100644 --- a/KMFIPTInterface/iptchecker.cpp +++ b/KMFIPTInterface/iptchecker.cpp @@ -100,8 +100,8 @@ int IPTChecker::numRulesInChain( char *tablename, char *chain ) { } return -1; } -QStringList IPTChecker::getRuleProperties( char * table, char *chain, int ruleIndex ) { - QStringList list; +TQStringList IPTChecker::getRuleProperties( char * table, char *chain, int ruleIndex ) { + TQStringList list; int numRules = 0; int found = 0; iptc_handle_t h; @@ -138,7 +138,7 @@ QStringList IPTChecker::getRuleProperties( char * table, char *chain, int ruleIn target_name = iptc_get_target( my_rule, &h ); if ( target_name && (*target_name != '\0') ) { - list << QString("%1").arg(target_name); + list << TQString("%1").tqarg(target_name); } @@ -151,7 +151,7 @@ QStringList IPTChecker::getRuleProperties( char * table, char *chain, int ruleIn } if ( t->u.user.name ) { - list << QString("TARGET2:%1").arg(t->u.user.name); + list << TQString("TARGET2:%1").tqarg(t->u.user.name); struct iptables_target *target = find_target( target_name, TRY_LOAD ); @@ -180,8 +180,8 @@ QStringList IPTChecker::getRuleProperties( char * table, char *chain, int ruleIn return list; } -QStringList IPTChecker::getChainsInTable( char * table ) { - QStringList list; +TQStringList IPTChecker::getChainsInTable( char * table ) { + TQStringList list; int foundRule = 0; iptc_handle_t h; const struct ipt_entry *e; @@ -201,8 +201,8 @@ QStringList IPTChecker::getChainsInTable( char * table ) { } -QString IPTChecker::getChainPolicy( char * table, char *chain ) { - QString policy = ""; +TQString IPTChecker::getChainPolicy( char * table, char *chain ) { + TQString policy = ""; iptc_handle_t h; const struct ipt_entry *e; const char *ch = NULL; diff --git a/KMFIPTInterface/iptchecker.h b/KMFIPTInterface/iptchecker.h index 51369d6..871c300 100644 --- a/KMFIPTInterface/iptchecker.h +++ b/KMFIPTInterface/iptchecker.h @@ -20,7 +20,7 @@ #ifndef IPTCHECKER_H #define IPTCHECKER_H -#include <qstringlist.h> +#include <tqstringlist.h> /** @author Christian Hubinger @@ -33,9 +33,9 @@ public: int numChainsInTable( char *tablename ); int numRulesInChain( char *tablename, char *chain ); - QStringList getChainsInTable( char * table ); - QString getChainPolicy( char * table, char *chain ); - QStringList getRuleProperties( char * table, char *chain, int ruleIndex ); + TQStringList getChainsInTable( char * table ); + TQString getChainPolicy( char * table, char *chain ); + TQStringList getRuleProperties( char * table, char *chain, int ruleIndex ); }; #endif diff --git a/KMFIPTInterface/kmfiptinterface.cpp b/KMFIPTInterface/kmfiptinterface.cpp index e963383..58b2496 100644 --- a/KMFIPTInterface/kmfiptinterface.cpp +++ b/KMFIPTInterface/kmfiptinterface.cpp @@ -34,7 +34,7 @@ KMFIPTInterface::KMFIPTInterface() : DCOPObject("KMFIPTInterface") { kdDebug() << "Starting new service... " << endl; - m_List = QStringList(); + m_List = TQStringList(); } KMFIPTInterface::~KMFIPTInterface() @@ -42,25 +42,25 @@ KMFIPTInterface::~KMFIPTInterface() kdDebug() << "Going away... " << endl; } -QString KMFIPTInterface::string(int idx) +TQString KMFIPTInterface::string(int idx) { return *m_List.at(idx); } -QStringList KMFIPTInterface::list() +TQStringList KMFIPTInterface::list() { return m_List; } -void KMFIPTInterface::add(QString arg) +void KMFIPTInterface::add(TQString arg) { kdDebug() << "Adding " << arg << " to the list" << endl; m_List << arg; } -bool KMFIPTInterface::remove(QString arg) +bool KMFIPTInterface::remove(TQString arg) { - QStringList::Iterator it = m_List.find(arg); + TQStringList::Iterator it = m_List.tqfind(arg); if (it != m_List.end()) { m_List.remove(it); @@ -80,33 +80,33 @@ void KMFIPTInterface::Test() { KMessageBox::information(0 , i18n("Called KMFIPTInterface::Test()") ); } -int KMFIPTInterface::numRulesInChain( QString table , QString chain ) { +int KMFIPTInterface::numRulesInChain( TQString table , TQString chain ) { IPTChecker *chk = new IPTChecker(); char *ctable = strdup(table); char *cchain = strdup(chain); return chk->numRulesInChain( ctable, cchain ); } -int KMFIPTInterface::numChainsInTable( QString table ) { +int KMFIPTInterface::numChainsInTable( TQString table ) { IPTChecker *chk = new IPTChecker(); char *ctable = strdup(table); return chk->numChainsInTable( ctable ); } -QStringList KMFIPTInterface::getChainsInTable( QString table ) { +TQStringList KMFIPTInterface::getChainsInTable( TQString table ) { IPTChecker *chk = new IPTChecker(); char *ctable = strdup(table); return chk->getChainsInTable( ctable ); } -QStringList KMFIPTInterface::getRuleProperties( QString table , QString chain , int index ) { +TQStringList KMFIPTInterface::getRuleProperties( TQString table , TQString chain , int index ) { IPTChecker *chk = new IPTChecker(); char *ctable = strdup(table); char *cchain = strdup(chain); return chk->getRuleProperties( ctable, cchain, index ); } -QString KMFIPTInterface::getChainPolicy( QString table , QString chain ) { +TQString KMFIPTInterface::getChainPolicy( TQString table , TQString chain ) { IPTChecker *chk = new IPTChecker(); char *ctable = strdup(table); char *cchain = strdup(chain); diff --git a/KMFIPTInterface/kmfiptinterface.h b/KMFIPTInterface/kmfiptinterface.h index 512f73b..4f694af 100644 --- a/KMFIPTInterface/kmfiptinterface.h +++ b/KMFIPTInterface/kmfiptinterface.h @@ -22,8 +22,8 @@ #ifndef _kmfiptinterface_H #define _kmfiptinterface_H -#include <qstringlist.h> -#include <qstring.h> +#include <tqstringlist.h> +#include <tqstring.h> #include <dcopobject.h> class KMFIPTInterface : public DCOPObject @@ -31,7 +31,7 @@ class KMFIPTInterface : public DCOPObject K_DCOP private: - QStringList m_List; + TQStringList m_List; public: KMFIPTInterface(); @@ -39,19 +39,19 @@ class KMFIPTInterface : public DCOPObject ~KMFIPTInterface(); k_dcop: - QString string(int); - QStringList list(); + TQString string(int); + TQStringList list(); - void add(QString); - bool remove(QString); + void add(TQString); + bool remove(TQString); bool exit(); void Test(); - int numRulesInChain( QString, QString ); - int numChainsInTable( QString ); - QStringList getChainsInTable( QString ); - QStringList getRuleProperties( QString, QString, int ); + int numRulesInChain( TQString, TQString ); + int numChainsInTable( TQString ); + TQStringList getChainsInTable( TQString ); + TQStringList getRuleProperties( TQString, TQString, int ); - QString getChainPolicy( QString, QString ); + TQString getChainPolicy( TQString, TQString ); }; #endif |