summaryrefslogtreecommitdiffstats
path: root/korn/kmail_proto.cpp
diff options
context:
space:
mode:
authortpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2010-07-31 19:53:50 +0000
committertpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2010-07-31 19:53:50 +0000
commit7be55ffa061c026e35e2d6a0effe1161ddb0d41f (patch)
tree8474f9b444b2756228600050f07a7ff25de532b2 /korn/kmail_proto.cpp
parentf587f20a6d09f1729dd0a8c1cd8ee0110aec7451 (diff)
downloadtdepim-7be55ffa061c026e35e2d6a0effe1161ddb0d41f.tar.gz
tdepim-7be55ffa061c026e35e2d6a0effe1161ddb0d41f.zip
Trinity Qt initial conversion
git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdepim@1157655 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'korn/kmail_proto.cpp')
-rw-r--r--korn/kmail_proto.cpp62
1 files changed, 31 insertions, 31 deletions
diff --git a/korn/kmail_proto.cpp b/korn/kmail_proto.cpp
index 15b228f39..b0b65233c 100644
--- a/korn/kmail_proto.cpp
+++ b/korn/kmail_proto.cpp
@@ -28,10 +28,10 @@
#include <kdebug.h>
#include <klocale.h>
-#include <qmap.h>
-#include <qobject.h>
-#include <qptrvector.h>
-#include <qstringlist.h>
+#include <tqmap.h>
+#include <tqobject.h>
+#include <tqptrvector.h>
+#include <tqstringlist.h>
const char* KMail_Protocol::kmailGroupName = "Account %1";
const char* KMail_Protocol::kmailKeyType = "Type";
@@ -55,7 +55,7 @@ const Protocol* KMail_Protocol::getProtocol( KConfigGroup* config ) const
{
KConfig kmailconfig( "kmailrc", true, false );
int id;
- QString type = getTypeAndConfig( config->readEntry( "kmailname" ), kmailconfig, id );
+ TQString type = getTypeAndConfig( config->readEntry( "kmailname" ), kmailconfig, id );
if( type == "imap" )
return Protocols::getProto( "imap" );
@@ -77,7 +77,7 @@ KMailDrop* KMail_Protocol::createMaildrop( KConfigGroup *config ) const
{
int id;
KConfig kmailconfig( "kmailrc", true, false );
- QString type = getTypeAndConfig( config->readEntry( "kmailname" ), kmailconfig, id );
+ TQString type = getTypeAndConfig( config->readEntry( "kmailname" ), kmailconfig, id );
if( type == "imap" || type == "cachedimap" || type == "pop" || type == "local" || type == "maildir" )
return new KKioDrop();
@@ -86,20 +86,20 @@ KMailDrop* KMail_Protocol::createMaildrop( KConfigGroup *config ) const
return 0;
}
-QMap< QString, QString > * KMail_Protocol::createConfig( KConfigGroup* config, const QString& ) const
+TQMap< TQString, TQString > * KMail_Protocol::createConfig( KConfigGroup* config, const TQString& ) const
{
- QMap< QString, QString > *result = new QMap<QString, QString>;
+ TQMap< TQString, TQString > *result = new TQMap<TQString, TQString>;
int id;
KConfig kmailconfig( "kmailrc", true, false );
//First: find the account in the configuration and get the type and id out of it.
- QString type = getTypeAndConfig( config->readEntry( "kmailname" ), kmailconfig, id );
- QString metadata;
+ TQString type = getTypeAndConfig( config->readEntry( "kmailname" ), kmailconfig, id );
+ TQString metadata;
if( type == "imap" || type == "cachedimap" )
{
//Construct metadata
if( kmailconfig.hasKey( "auth" ) )
- metadata += QString( "auth=%1," ).arg( kmailconfig.readEntry( "auth" ) );
+ metadata += TQString( "auth=%1," ).arg( kmailconfig.readEntry( "auth" ) );
if( !kmailconfig.hasKey( "use-tls" ) )
metadata += "tls=auto";
else
@@ -124,7 +124,7 @@ QMap< QString, QString > * KMail_Protocol::createConfig( KConfigGroup* config, c
{
//Constructing metadata
if( kmailconfig.hasKey( "auth" ) )
- metadata += QString( "auth=%1," ).arg( kmailconfig.readEntry( "auth" ) );
+ metadata += TQString( "auth=%1," ).arg( kmailconfig.readEntry( "auth" ) );
if( !kmailconfig.hasKey( "use-tls" ) )
metadata += "tls=auto";
else
@@ -172,44 +172,44 @@ QMap< QString, QString > * KMail_Protocol::createConfig( KConfigGroup* config, c
return result;
}
-void KMail_Protocol::configFillGroupBoxes( QStringList* lijst ) const
+void KMail_Protocol::configFillGroupBoxes( TQStringList* lijst ) const
{
lijst->append( "KMail" );
}
-void KMail_Protocol::configFields( QPtrVector< QWidget >* vector, const QObject*, QPtrList< AccountInput >* result ) const
+void KMail_Protocol::configFields( TQPtrVector< TQWidget >* vector, const TQObject*, TQPtrList< AccountInput >* result ) const
{
- QMap< QString, QString > accountList;
- QString type;
- QString name;
+ TQMap< TQString, TQString > accountList;
+ TQString type;
+ TQString name;
int nummer = kmailFirstGroup - 1;
KConfig kmailconfig( "kmailrc", true, false );
- while( kmailconfig.hasGroup( QString( kmailGroupName ).arg( ++nummer ) ) )
+ while( kmailconfig.hasGroup( TQString( kmailGroupName ).arg( ++nummer ) ) )
{
- kmailconfig.setGroup( QString( kmailGroupName ).arg( nummer ) );
- type = kmailconfig.readEntry( kmailKeyType, QString::null );
- name = kmailconfig.readEntry( kmailKeyName, QString::null );
+ kmailconfig.setGroup( TQString( kmailGroupName ).arg( nummer ) );
+ type = kmailconfig.readEntry( kmailKeyType, TQString::null );
+ name = kmailconfig.readEntry( kmailKeyName, TQString::null );
if( type == "imap" || type == "cachedimap" || type == "pop" || type == "local" )
{
accountList.insert( name, name );
}
}
- result->append( new ComboInput( (QWidget*)vector->at( 0 ), i18n( "KMail name" ), accountList, *accountList.begin(), "kmailname" ) );
+ result->append( new ComboInput( (TQWidget*)vector->at( 0 ), i18n( "KMail name" ), accountList, *accountList.begin(), "kmailname" ) );
}
-void KMail_Protocol::readEntries( QMap< QString, QString >* ) const
+void KMail_Protocol::readEntries( TQMap< TQString, TQString >* ) const
{
//The configuartion is read out on the right way
}
-void KMail_Protocol::writeEntries( QMap< QString, QString >* ) const
+void KMail_Protocol::writeEntries( TQMap< TQString, TQString >* ) const
{
//The configuartion is read out on the right way
}
-QString KMail_Protocol::readPassword( bool store, const KConfigBase& config, int id ) const
+TQString KMail_Protocol::readPassword( bool store, const KConfigBase& config, int id ) const
{
if( !store )
return "";
@@ -217,17 +217,17 @@ QString KMail_Protocol::readPassword( bool store, const KConfigBase& config, int
return KOrnPassword::readKMailPassword( id, config );
}
-QString KMail_Protocol::getTypeAndConfig( const QString& kmailname, KConfig &kmailconfig, int &id ) const
+TQString KMail_Protocol::getTypeAndConfig( const TQString& kmailname, KConfig &kmailconfig, int &id ) const
{
int nummer = kmailFirstGroup - 1;
bool found = false;
id = -1;
- while( kmailconfig.hasGroup( QString( kmailGroupName ).arg( ++nummer ) ) )
+ while( kmailconfig.hasGroup( TQString( kmailGroupName ).arg( ++nummer ) ) )
{
- kmailconfig.setGroup( QString( kmailGroupName ).arg( nummer ) );
- if( kmailconfig.readEntry( kmailKeyName, QString::null ) == kmailname )
+ kmailconfig.setGroup( TQString( kmailGroupName ).arg( nummer ) );
+ if( kmailconfig.readEntry( kmailKeyName, TQString::null ) == kmailname )
{
id = kmailconfig.readNumEntry( kmailKeyId, 0 );
found = true;
@@ -237,10 +237,10 @@ QString KMail_Protocol::getTypeAndConfig( const QString& kmailname, KConfig &kma
if( !found )
{
nummer = -1;
- return QString::null;
+ return TQString::null;
}
//The correct group is found, and kmailconfig.setGroup() is already called for the right group.
- return kmailconfig.readEntry( kmailKeyType, QString::null );
+ return kmailconfig.readEntry( kmailKeyType, TQString::null );
}