summaryrefslogtreecommitdiffstats
path: root/libkcddb
diff options
context:
space:
mode:
authortpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2010-07-31 19:43:15 +0000
committertpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2010-07-31 19:43:15 +0000
commite654398e46e37abf457b2b1122ab898d2c51c49f (patch)
treed39ee6440f3c3663c3ead84a2d4cc2d034667e96 /libkcddb
parente4f29b18e19394b9352f52a6c0d0d0e3932cf511 (diff)
downloadtdemultimedia-e654398e46e37abf457b2b1122ab898d2c51c49f.tar.gz
tdemultimedia-e654398e46e37abf457b2b1122ab898d2c51c49f.zip
Trinity Qt initial conversion
git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdemultimedia@1157644 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'libkcddb')
-rw-r--r--libkcddb/asynccddbplookup.cpp20
-rw-r--r--libkcddb/asynccddbplookup.h14
-rw-r--r--libkcddb/asynchttplookup.cpp26
-rw-r--r--libkcddb/asynchttplookup.h4
-rw-r--r--libkcddb/asynchttpsubmit.cpp4
-rw-r--r--libkcddb/asynchttpsubmit.h2
-rw-r--r--libkcddb/asyncsmtpsubmit.cpp10
-rw-r--r--libkcddb/asyncsmtpsubmit.h4
-rw-r--r--libkcddb/cache.cpp46
-rw-r--r--libkcddb/cache.h8
-rw-r--r--libkcddb/categories.cpp4
-rw-r--r--libkcddb/categories.h16
-rw-r--r--libkcddb/cddb.cpp24
-rw-r--r--libkcddb/cddb.h30
-rw-r--r--libkcddb/cddbplookup.cpp12
-rw-r--r--libkcddb/cddbplookup.h2
-rw-r--r--libkcddb/cdinfo.cpp60
-rw-r--r--libkcddb/cdinfo.h42
-rw-r--r--libkcddb/cdinfodialogbase.ui.h52
-rw-r--r--libkcddb/cdinfoencodingwidget.cpp26
-rw-r--r--libkcddb/cdinfoencodingwidget.h12
-rw-r--r--libkcddb/client.cpp28
-rw-r--r--libkcddb/client.h2
-rw-r--r--libkcddb/config.h2
-rw-r--r--libkcddb/genres.cpp8
-rw-r--r--libkcddb/genres.h16
-rw-r--r--libkcddb/httplookup.cpp24
-rw-r--r--libkcddb/httplookup.h6
-rw-r--r--libkcddb/httpsubmit.cpp4
-rw-r--r--libkcddb/httpsubmit.h4
-rw-r--r--libkcddb/kcmcddb/cddbconfigwidget.cpp30
-rw-r--r--libkcddb/kcmcddb/cddbconfigwidget.h2
-rw-r--r--libkcddb/kcmcddb/kcmcddb.cpp24
-rw-r--r--libkcddb/kcmcddb/kcmcddb.h2
-rw-r--r--libkcddb/lookup.cpp10
-rw-r--r--libkcddb/lookup.h16
-rw-r--r--libkcddb/sites.cpp30
-rw-r--r--libkcddb/sites.h12
-rw-r--r--libkcddb/smtpsubmit.cpp6
-rw-r--r--libkcddb/smtpsubmit.h4
-rw-r--r--libkcddb/submit.cpp10
-rw-r--r--libkcddb/submit.h8
-rw-r--r--libkcddb/synccddbplookup.cpp20
-rw-r--r--libkcddb/synccddbplookup.h4
-rw-r--r--libkcddb/synchttplookup.cpp10
-rw-r--r--libkcddb/synchttplookup.h2
-rw-r--r--libkcddb/synchttpsubmit.cpp2
-rw-r--r--libkcddb/synchttpsubmit.h2
-rw-r--r--libkcddb/syncsmtpsubmit.cpp4
-rw-r--r--libkcddb/syncsmtpsubmit.h4
-rw-r--r--libkcddb/test/asynccddblookuptest.cpp6
-rw-r--r--libkcddb/test/asynccddblookuptest.h2
-rw-r--r--libkcddb/test/asynchttplookuptest.cpp6
-rw-r--r--libkcddb/test/asynchttplookuptest.h2
-rw-r--r--libkcddb/test/asynchttpsubmittest.cpp10
-rw-r--r--libkcddb/test/asynchttpsubmittest.h2
-rw-r--r--libkcddb/test/asyncsmtpsubmittest.cpp10
-rw-r--r--libkcddb/test/asyncsmtpsubmittest.h2
-rw-r--r--libkcddb/test/sitestest.cpp4
-rw-r--r--libkcddb/test/synchttpsubmittest.cpp4
-rw-r--r--libkcddb/test/syncsmtpsubmittest.cpp4
61 files changed, 383 insertions, 383 deletions
diff --git a/libkcddb/asynccddbplookup.cpp b/libkcddb/asynccddbplookup.cpp
index 27454298..d2584adf 100644
--- a/libkcddb/asynccddbplookup.cpp
+++ b/libkcddb/asynccddbplookup.cpp
@@ -39,21 +39,21 @@ namespace KCDDB
CDDB::Result
AsyncCDDBPLookup::lookup
(
- const QString & hostname,
+ const TQString & hostname,
uint port,
const TrackOffsetList & trackOffsetList
)
{
- socket_ = new KNetwork::KBufferedSocket(hostname,QString::number(port));
+ socket_ = new KNetwork::KBufferedSocket(hostname,TQString::number(port));
socket_->setBlocking( false );
- connect (socket_, SIGNAL(gotError(int)), SLOT(slotGotError(int)));
+ connect (socket_, TQT_SIGNAL(gotError(int)), TQT_SLOT(slotGotError(int)));
- connect (socket_, SIGNAL( connected(const KResolverEntry &) ),
- SLOT( slotConnectionSuccess() ) );
+ connect (socket_, TQT_SIGNAL( connected(const KResolverEntry &) ),
+ TQT_SLOT( slotConnectionSuccess() ) );
- connect (socket_, SIGNAL( readyRead() ), SLOT( slotReadyRead() ) );
+ connect (socket_, TQT_SIGNAL( readyRead() ), TQT_SLOT( slotReadyRead() ) );
if ( trackOffsetList.count() < 3 )
return UnknownError;
@@ -62,7 +62,7 @@ namespace KCDDB
state_ = WaitingForConnection;
- if ( !socket_->connect(hostname, QString::number(port)) )
+ if ( !socket_->connect(hostname, TQString::number(port)) )
{
state_ = Idle;
emit finished( NoResponse );
@@ -164,7 +164,7 @@ namespace KCDDB
case WaitingForMoreMatches:
{
- QString line = readLine();
+ TQString line = readLine();
if (line.startsWith("."))
requestCDInfoForMatch();
@@ -192,7 +192,7 @@ namespace KCDDB
case WaitingForCDInfoData:
{
- QString line = readLine();
+ TQString line = readLine();
if (line.startsWith("."))
{
@@ -227,7 +227,7 @@ namespace KCDDB
QString
AsyncCDDBPLookup::readLine()
{
- return QString::fromUtf8(socket_->readLine());
+ return TQString::fromUtf8(socket_->readLine());
}
void
diff --git a/libkcddb/asynccddbplookup.h b/libkcddb/asynccddbplookup.h
index 661c76f7..17b72f48 100644
--- a/libkcddb/asynccddbplookup.h
+++ b/libkcddb/asynccddbplookup.h
@@ -21,7 +21,7 @@
#ifndef KCDDB_ASYNC_CDDBP_LOOKUP_H
#define KCDDB_ASYNC_CDDBP_LOOKUP_H
-#include <qobject.h>
+#include <tqobject.h>
#include "cddbplookup.h"
@@ -51,7 +51,7 @@ namespace KCDDB
virtual ~AsyncCDDBPLookup();
- Result lookup( const QString &, uint, const TrackOffsetList & );
+ Result lookup( const TQString &, uint, const TrackOffsetList & );
signals:
@@ -71,22 +71,22 @@ namespace KCDDB
void doQuery();
void doQuit();
- bool parseQueryResponse( const QString & );
+ bool parseQueryResponse( const TQString & );
void requestCDInfoForMatch();
- bool parseCDInfoResponse( const QString & );
+ bool parseCDInfoResponse( const TQString & );
void parseCDInfoData();
void read();
- QString readLine();
+ TQString readLine();
- QString stateToString() const;
+ TQString stateToString() const;
private:
State state_;
Result result_;
- QStringList cdInfoBuffer_;
+ TQStringList cdInfoBuffer_;
};
}
diff --git a/libkcddb/asynchttplookup.cpp b/libkcddb/asynchttplookup.cpp
index 97a91e5d..45eb4353 100644
--- a/libkcddb/asynchttplookup.cpp
+++ b/libkcddb/asynchttplookup.cpp
@@ -18,8 +18,8 @@
Boston, MA 02110-1301, USA.
*/
-#include <qstringlist.h>
-#include <qapplication.h>
+#include <tqstringlist.h>
+#include <tqapplication.h>
#include <kdebug.h>
#include <kio/job.h>
@@ -42,7 +42,7 @@ namespace KCDDB
CDDB::Result
AsyncHTTPLookup::lookup
(
- const QString & hostName,
+ const TQString & hostName,
uint port,
const TrackOffsetList & trackOffsetList
)
@@ -52,8 +52,8 @@ namespace KCDDB
trackOffsetList_ = trackOffsetList;
- connect( this, SIGNAL( queryReady() ), SLOT( slotQueryReady() ) );
- connect( this, SIGNAL( readReady() ), SLOT( requestCDInfoForMatch() ) );
+ connect( this, TQT_SIGNAL( queryReady() ), TQT_SLOT( slotQueryReady() ) );
+ connect( this, TQT_SIGNAL( readReady() ), TQT_SLOT( requestCDInfoForMatch() ) );
initURL( hostName, port );
@@ -66,7 +66,7 @@ namespace KCDDB
CDDB::Result
AsyncHTTPLookup::runQuery()
{
- data_ = QByteArray();
+ data_ = TQByteArray();
state_ = WaitingForQueryResponse;
result_ = sendQuery();
@@ -101,7 +101,7 @@ namespace KCDDB
CDDBMatch match = matchList_.first();
matchList_.remove( match );
- data_ = QByteArray();
+ data_ = TQByteArray();
state_ = WaitingForReadResponse;
result_ = sendRead( match );
@@ -111,11 +111,11 @@ namespace KCDDB
}
void
- AsyncHTTPLookup::slotData( KIO::Job *, const QByteArray &data )
+ AsyncHTTPLookup::slotData( KIO::Job *, const TQByteArray &data )
{
if (data.size() > 0)
{
- QDataStream stream(data_, IO_WriteOnly | IO_Append);
+ TQDataStream stream(data_, IO_WriteOnly | IO_Append);
stream.writeRawBytes(data.data(), data.size());
}
}
@@ -144,10 +144,10 @@ namespace KCDDB
if ( 0 == job )
return ServerError;
- connect( job, SIGNAL( data( KIO::Job *, const QByteArray & ) ),
- SLOT( slotData( KIO::Job *, const QByteArray & ) ) );
- connect( job, SIGNAL( result( KIO::Job * ) ),
- SLOT( slotResult( KIO::Job * ) ) );
+ connect( job, TQT_SIGNAL( data( KIO::Job *, const TQByteArray & ) ),
+ TQT_SLOT( slotData( KIO::Job *, const TQByteArray & ) ) );
+ connect( job, TQT_SIGNAL( result( KIO::Job * ) ),
+ TQT_SLOT( slotResult( KIO::Job * ) ) );
return Success;
}
diff --git a/libkcddb/asynchttplookup.h b/libkcddb/asynchttplookup.h
index 4826dbf9..80926211 100644
--- a/libkcddb/asynchttplookup.h
+++ b/libkcddb/asynchttplookup.h
@@ -35,7 +35,7 @@ namespace KCDDB
AsyncHTTPLookup();
virtual ~AsyncHTTPLookup();
- Result lookup( const QString &, uint, const TrackOffsetList & );
+ Result lookup( const TQString &, uint, const TrackOffsetList & );
CDInfoList lookupResponse() const;
@@ -47,7 +47,7 @@ namespace KCDDB
void slotQueryReady();
void requestCDInfoForMatch();
- void slotData( KIO::Job *, const QByteArray & );
+ void slotData( KIO::Job *, const TQByteArray & );
void slotResult( KIO::Job * );
protected:
diff --git a/libkcddb/asynchttpsubmit.cpp b/libkcddb/asynchttpsubmit.cpp
index cea272cf..6932b49b 100644
--- a/libkcddb/asynchttpsubmit.cpp
+++ b/libkcddb/asynchttpsubmit.cpp
@@ -23,7 +23,7 @@
namespace KCDDB
{
- AsyncHTTPSubmit::AsyncHTTPSubmit(const QString& from, const QString& hostname, uint port)
+ AsyncHTTPSubmit::AsyncHTTPSubmit(const TQString& from, const TQString& hostname, uint port)
: HTTPSubmit(from, hostname, port)
{
@@ -36,7 +36,7 @@ namespace KCDDB
CDDB::Result AsyncHTTPSubmit::runJob(KIO::Job* job)
{
- connect(job, SIGNAL(result(KIO::Job *)), SLOT(slotFinished(KIO::Job *)));
+ connect(job, TQT_SIGNAL(result(KIO::Job *)), TQT_SLOT(slotFinished(KIO::Job *)));
return CDDB::Success;
}
diff --git a/libkcddb/asynchttpsubmit.h b/libkcddb/asynchttpsubmit.h
index 9c50c670..89ab8313 100644
--- a/libkcddb/asynchttpsubmit.h
+++ b/libkcddb/asynchttpsubmit.h
@@ -27,7 +27,7 @@ namespace KCDDB
{
Q_OBJECT
public:
- AsyncHTTPSubmit(const QString& from, const QString& hostname, uint port);
+ AsyncHTTPSubmit(const TQString& from, const TQString& hostname, uint port);
virtual ~AsyncHTTPSubmit();
signals:
diff --git a/libkcddb/asyncsmtpsubmit.cpp b/libkcddb/asyncsmtpsubmit.cpp
index 484a0fc2..ff120fac 100644
--- a/libkcddb/asyncsmtpsubmit.cpp
+++ b/libkcddb/asyncsmtpsubmit.cpp
@@ -19,13 +19,13 @@
#include "asyncsmtpsubmit.h"
#include "cdinfo.h"
-#include <qdatastream.h>
+#include <tqdatastream.h>
#include <kdebug.h>
namespace KCDDB
{
- AsyncSMTPSubmit::AsyncSMTPSubmit(const QString& hostname, uint port,
- const QString& username, const QString& from, const QString& to )
+ AsyncSMTPSubmit::AsyncSMTPSubmit(const TQString& hostname, uint port,
+ const TQString& username, const TQString& from, const TQString& to )
: SMTPSubmit( hostname, port, username, from, to )
{
@@ -38,8 +38,8 @@ namespace KCDDB
CDDB::Result AsyncSMTPSubmit::runJob(KIO::Job* job)
{
- connect( job, SIGNAL( result( KIO::Job* ) ),
- this, SLOT(slotDone( KIO::Job* ) ) );
+ connect( job, TQT_SIGNAL( result( KIO::Job* ) ),
+ this, TQT_SLOT(slotDone( KIO::Job* ) ) );
return Success;
}
diff --git a/libkcddb/asyncsmtpsubmit.h b/libkcddb/asyncsmtpsubmit.h
index 57f87302..9bcf84eb 100644
--- a/libkcddb/asyncsmtpsubmit.h
+++ b/libkcddb/asyncsmtpsubmit.h
@@ -29,8 +29,8 @@ namespace KCDDB
Q_OBJECT
public:
- AsyncSMTPSubmit(const QString& hostname, uint port, const QString& username,
- const QString& from, const QString& to);
+ AsyncSMTPSubmit(const TQString& hostname, uint port, const TQString& username,
+ const TQString& from, const TQString& to);
virtual ~AsyncSMTPSubmit();
signals:
diff --git a/libkcddb/cache.cpp b/libkcddb/cache.cpp
index 3c2d778e..01c5dec0 100644
--- a/libkcddb/cache.cpp
+++ b/libkcddb/cache.cpp
@@ -22,8 +22,8 @@
#include <kdebug.h>
#include <kstandarddirs.h>
-#include <qfile.h>
-#include <qdir.h>
+#include <tqfile.h>
+#include <tqdir.h>
#include "cache.h"
#include "config.h"
@@ -31,9 +31,9 @@
namespace KCDDB
{
QString
- Cache::fileName( const QString &category, const QString &discid, const QString &cacheDir )
+ Cache::fileName( const TQString &category, const TQString &discid, const TQString &cacheDir )
{
- QDir dir( cacheDir );
+ TQDir dir( cacheDir );
if ( !dir.exists( category ) )
dir.mkdir( category );
@@ -41,34 +41,34 @@ namespace KCDDB
}
CDInfoList
- Cache::lookup( const QString &cddbId )
+ Cache::lookup( const TQString &cddbId )
{
kdDebug(60010) << "Looking up " << cddbId << " in CDDB cache" << endl;
CDInfoList infoList;
Config c;
c.readConfig();
- QStringList cddbCacheDirs = c.cacheLocations();
+ TQStringList cddbCacheDirs = c.cacheLocations();
- for (QStringList::Iterator cddbCacheDir = cddbCacheDirs.begin();
+ for (TQStringList::Iterator cddbCacheDir = cddbCacheDirs.begin();
cddbCacheDir != cddbCacheDirs.end(); ++cddbCacheDir)
{
- QDir dir( *cddbCacheDir );
- QStringList dirList = dir.entryList( QDir::Dirs );
+ TQDir dir( *cddbCacheDir );
+ TQStringList dirList = dir.entryList( TQDir::Dirs );
- QStringList::ConstIterator it = dirList.begin();
+ TQStringList::ConstIterator it = dirList.begin();
while ( it != dirList.end() )
{
- QString category( *it );
+ TQString category( *it );
if ( category[ 0 ] != '.' )
{
- QFile f( *cddbCacheDir + "/" + category + "/" + cddbId );
+ TQFile f( *cddbCacheDir + "/" + category + "/" + cddbId );
if ( f.exists() && f.open(IO_ReadOnly) )
{
- QTextStream ts(&f);
- ts.setEncoding(QTextStream::UnicodeUTF8);
- QString cddbData = ts.read();
+ TQTextStream ts(&f);
+ ts.setEncoding(TQTextStream::UnicodeUTF8);
+ TQString cddbData = ts.read();
f.close();
CDInfo info;
info.load(cddbData);
@@ -102,25 +102,25 @@ namespace KCDDB
Config c;
c.readConfig();
- QString cacheDir = c.cacheLocations().first();
- QDir d(cacheDir);
+ TQString cacheDir = c.cacheLocations().first();
+ TQDir d(cacheDir);
if (!d.exists())
d.mkdir(cacheDir);
// The same entry can contain several discids (separated by a ','),
// so we save the entry to all of them
- QStringList discids = QStringList::split(',', info.id);
- for (QStringList::Iterator it = discids.begin(); it != discids.end(); ++it)
+ TQStringList discids = TQStringList::split(',', info.id);
+ for (TQStringList::Iterator it = discids.begin(); it != discids.end(); ++it)
{
- QString cacheFile = fileName(info.category, *it, cacheDir);
+ TQString cacheFile = fileName(info.category, *it, cacheDir);
kdDebug(60010) << "Storing " << cacheFile << " in CDDB cache" << endl;
- QFile f(cacheFile);
+ TQFile f(cacheFile);
if ( f.open(IO_WriteOnly) )
{
- QTextStream ts(&f);
- ts.setEncoding(QTextStream::UnicodeUTF8);
+ TQTextStream ts(&f);
+ ts.setEncoding(TQTextStream::UnicodeUTF8);
ts << info.toString();
f.close();
}
diff --git a/libkcddb/cache.h b/libkcddb/cache.h
index 4a3a7cfe..5ccf3775 100644
--- a/libkcddb/cache.h
+++ b/libkcddb/cache.h
@@ -22,8 +22,8 @@
#ifndef KCDDB_CACHE_H
#define KCDDB_CACHE_H
-#include <qpair.h>
-#include <qstring.h>
+#include <tqpair.h>
+#include <tqstring.h>
#include "cdinfo.h"
#include <kdemacros.h>
@@ -40,7 +40,7 @@ namespace KCDDB
Ignore
};
- static CDInfoList lookup( const QString & );
+ static CDInfoList lookup( const TQString & );
static void store( const CDInfoList & );
// KDE4: Should probably take a TrackOffsetList too, so
// the list can be stored in the file, and we can make
@@ -49,7 +49,7 @@ namespace KCDDB
static void store( const CDInfo & );
private:
- static QString fileName( const QString &category, const QString& discid, const QString &cacheDir );
+ static TQString fileName( const TQString &category, const TQString& discid, const TQString &cacheDir );
};
}
diff --git a/libkcddb/categories.cpp b/libkcddb/categories.cpp
index 522da81b..5b86a5f5 100644
--- a/libkcddb/categories.cpp
+++ b/libkcddb/categories.cpp
@@ -23,7 +23,7 @@ KCDDB::Categories::Categories()
i18n("New Age") << i18n("Reggae") << i18n("Rock") << i18n("Soundtrack");
}
-const QString KCDDB::Categories::cddb2i18n(const QString &category) const
+const TQString KCDDB::Categories::cddb2i18n(const TQString &category) const
{
int index = m_cddb.findIndex(category.stripWhiteSpace());
if (index != -1)
@@ -36,7 +36,7 @@ const QString KCDDB::Categories::cddb2i18n(const QString &category) const
}
}
-const QString KCDDB::Categories::i18n2cddb(const QString &category) const
+const TQString KCDDB::Categories::i18n2cddb(const TQString &category) const
{
int index = m_i18n.findIndex(category.stripWhiteSpace());
if (index != -1)
diff --git a/libkcddb/categories.h b/libkcddb/categories.h
index 01147111..547e5570 100644
--- a/libkcddb/categories.h
+++ b/libkcddb/categories.h
@@ -8,8 +8,8 @@
#ifndef KCDDB_CATEGORIES_H
#define KCDDB_CATEGORIES_H
-#include <qstring.h>
-#include <qstringlist.h>
+#include <tqstring.h>
+#include <tqstringlist.h>
namespace KCDDB
{
@@ -21,21 +21,21 @@ namespace KCDDB
public:
Categories();
- const QStringList &cddbList() const { return m_cddb; };
- const QStringList &i18nList() const { return m_i18n; };
+ const TQStringList &cddbList() const { return m_cddb; };
+ const TQStringList &i18nList() const { return m_i18n; };
/**
* Lookup the CDDB category, and return the i18n'd version.
*/
- const QString cddb2i18n(const QString &category) const;
+ const TQString cddb2i18n(const TQString &category) const;
/**
* Lookup the i18n category, and return the CDDB version.
*/
- const QString i18n2cddb(const QString &category) const;
+ const TQString i18n2cddb(const TQString &category) const;
private:
- QStringList m_cddb;
- QStringList m_i18n;
+ TQStringList m_cddb;
+ TQStringList m_i18n;
};
}
diff --git a/libkcddb/cddb.cpp b/libkcddb/cddb.cpp
index f1933cd5..f0ee84e0 100644
--- a/libkcddb/cddb.cpp
+++ b/libkcddb/cddb.cpp
@@ -19,8 +19,8 @@
Boston, MA 02110-1301, USA.
*/
-#include <qregexp.h>
-#include <qstringlist.h>
+#include <tqregexp.h>
+#include <tqstringlist.h>
#include <kdebug.h>
#include <kstringhandler.h>
@@ -71,34 +71,34 @@ namespace KCDDB
id = ( ( id % 255 ) << 24 ) | ( l << 8 ) | numTracks;
- return QString::number( id, 16 ).rightJustify( 8, '0' );
+ return TQString::number( id, 16 ).rightJustify( 8, '0' );
}
QString
CDDB::trackOffsetListToString()
{
- QString ret;
+ TQString ret;
uint numTracks = trackOffsetList_.count()-2;
// Disc start.
- ret.append( QString::number( numTracks ) );
+ ret.append( TQString::number( numTracks ) );
ret.append( " " );
for ( uint i = 0; i < numTracks; i++ )
{
- ret.append( QString::number( trackOffsetList_[ i ] ) );
+ ret.append( TQString::number( trackOffsetList_[ i ] ) );
ret.append( " " );
}
unsigned int discLengthInSec = ( trackOffsetList_[ numTracks+1 ] ) / 75;
- ret.append( QString::number( discLengthInSec ) );
+ ret.append( TQString::number( discLengthInSec ) );
return ret;
}
bool
- CDDB::parseGreeting( const QString & line )
+ CDDB::parseGreeting( const TQString & line )
{
uint serverStatus = statusCode( line );
@@ -121,7 +121,7 @@ namespace KCDDB
}
bool
- CDDB::parseHandshake( const QString & line )
+ CDDB::parseHandshake( const TQString & line )
{
uint serverStatus = statusCode( line );
@@ -137,9 +137,9 @@ namespace KCDDB
}
uint
- CDDB::statusCode( const QString & line )
+ CDDB::statusCode( const TQString & line )
{
- QStringList tokenList = QStringList::split( ' ', line );
+ TQStringList tokenList = TQStringList::split( ' ', line );
uint serverStatus = tokenList[ 0 ].toUInt();
@@ -147,7 +147,7 @@ namespace KCDDB
}
/* CDDB::Transport
- CDDB::stringToTransport(const QString & s)
+ CDDB::stringToTransport(const TQString & s)
{
if ("HTTP" == s )
return HTTP;
diff --git a/libkcddb/cddb.h b/libkcddb/cddb.h
index d0031ebe..04d754c0 100644
--- a/libkcddb/cddb.h
+++ b/libkcddb/cddb.h
@@ -22,9 +22,9 @@
#ifndef KCDDB_CDDB_H
#define KCDDB_CDDB_H
-#include <qstring.h>
-#include <qpair.h>
-#include <qvaluelist.h>
+#include <tqstring.h>
+#include <tqpair.h>
+#include <tqvaluelist.h>
#include <kdelibs_export.h>
@@ -38,7 +38,7 @@ namespace KCDDB
as the first frame of the first track, the
last one is the start frame of the leadout track.
*/
- typedef QValueList<uint> TrackOffsetList;
+ typedef TQValueList<uint> TrackOffsetList;
/** This is just a container class used for interpreting results
of CDDB queries.
@@ -63,23 +63,23 @@ namespace KCDDB
CDDB();
virtual ~CDDB();
- static QString resultToString(Result);
- static QString trackOffsetListToId( const TrackOffsetList & );
+ static TQString resultToString(Result);
+ static TQString trackOffsetListToId( const TrackOffsetList & );
- static QString clientName() { return QString::fromLatin1("libkcddb"); }
- static QString clientVersion() { return QString::fromLatin1("0.31"); }
+ static TQString clientName() { return TQString::fromLatin1("libkcddb"); }
+ static TQString clientVersion() { return TQString::fromLatin1("0.31"); }
protected:
- bool parseGreeting( const QString & );
- bool parseHandshake( const QString & );
+ bool parseGreeting( const TQString & );
+ bool parseHandshake( const TQString & );
- uint statusCode( const QString & );
+ uint statusCode( const TQString & );
- QString trackOffsetListToId();
- QString trackOffsetListToString();
+ TQString trackOffsetListToId();
+ TQString trackOffsetListToString();
- QString user_;
- QString localHostName_;
+ TQString user_;
+ TQString localHostName_;
bool readOnly_;
diff --git a/libkcddb/cddbplookup.cpp b/libkcddb/cddbplookup.cpp
index b07d7346..cd287b99 100644
--- a/libkcddb/cddbplookup.cpp
+++ b/libkcddb/cddbplookup.cpp
@@ -39,7 +39,7 @@ namespace KCDDB
void
CDDBPLookup::sendHandshake()
{
- QString handshake = QString( "cddb hello %1 %2 %3 %4" )
+ TQString handshake = TQString( "cddb hello %1 %2 %3 %4" )
.arg( user_ )
.arg( localHostName_ )
.arg( clientName() )
@@ -57,7 +57,7 @@ namespace KCDDB
void
CDDBPLookup::sendQuery()
{
- QString query = QString( "cddb query %1 %2" )
+ TQString query = TQString( "cddb query %1 %2" )
.arg( trackOffsetListToId() )
.arg( trackOffsetListToString() );
@@ -68,9 +68,9 @@ namespace KCDDB
CDDBPLookup::sendRead( const CDDBMatch & match )
{
category_ = match.first;
- QString discid = match.second;
+ TQString discid = match.second;
- QString readRequest = QString( "cddb read %1 %2" )
+ TQString readRequest = TQString( "cddb read %1 %2" )
.arg( category_ )
.arg( discid );
@@ -94,7 +94,7 @@ namespace KCDDB
}
Q_LONG
- CDDBPLookup::writeLine( const QString & line )
+ CDDBPLookup::writeLine( const TQString & line )
{
if ( !isConnected() )
{
@@ -103,7 +103,7 @@ namespace KCDDB
}
kdDebug(60010) << "WRITE: [" << line << "]" << endl;
- QCString buf = line.utf8();
+ TQCString buf = line.utf8();
buf.append( "\n" );
return socket_->writeBlock( buf.data(), buf.length() );
diff --git a/libkcddb/cddbplookup.h b/libkcddb/cddbplookup.h
index fa44ff05..c7983cde 100644
--- a/libkcddb/cddbplookup.h
+++ b/libkcddb/cddbplookup.h
@@ -42,7 +42,7 @@ namespace KCDDB
void close();
protected:
- Q_LONG writeLine( const QString & );
+ Q_LONG writeLine( const TQString & );
bool isConnected()
{ return KNetwork::KClientSocketBase::Connected == socket_->state(); }
diff --git a/libkcddb/cdinfo.cpp b/libkcddb/cdinfo.cpp
index 12009cb8..bf69f853 100644
--- a/libkcddb/cdinfo.cpp
+++ b/libkcddb/cdinfo.cpp
@@ -90,38 +90,38 @@ namespace KCDDB
return *this;
}
- QVariant TrackInfo::get(const QString &type) const {
+ TQVariant TrackInfo::get(const TQString &type) const {
if(type == "title")
return title;
if(type == "extt")
return extt;
- return QVariant();
+ return TQVariant();
}
bool
- CDInfo::load(const QString & s)
+ CDInfo::load(const TQString & s)
{
- return load(QStringList::split('\n', s));
+ return load(TQStringList::split('\n', s));
}
bool
- CDInfo::load(const QStringList & lineList)
+ CDInfo::load(const TQStringList & lineList)
{
clear();
// We'll append to this until we've seen all the lines, then parse it after.
- QString dtitle;
+ TQString dtitle;
- QStringList::ConstIterator it = lineList.begin();
+ TQStringList::ConstIterator it = lineList.begin();
- QRegExp rev("# Revision: (\\d+)");
+ TQRegExp rev("# Revision: (\\d+)");
while ( it != lineList.end() )
{
- QString line(*it);
+ TQString line(*it);
++it;
- QStringList tokenList = KStringHandler::perlSplit('=', line, 2);
+ TQStringList tokenList = KStringHandler::perlSplit('=', line, 2);
if (rev.search(line) != -1)
{
@@ -129,8 +129,8 @@ namespace KCDDB
continue;
}
- QString key = tokenList[0].stripWhiteSpace();
- QString value;
+ TQString key = tokenList[0].stripWhiteSpace();
+ TQString value;
if (2 != tokenList.count())
{
if (!key.startsWith("EXT"))
@@ -201,26 +201,26 @@ namespace KCDDB
QString
CDInfo::toString(bool submit) const
{
- QString s;
+ TQString s;
if (revision != 0)
- s += "# Revision: " + QString::number(revision) + "\n";
+ s += "# Revision: " + TQString::number(revision) + "\n";
if (submit)
{
s += "#\n";
- s += QString("# Submitted via: %1 %2\n").arg(CDDB::clientName(),
+ s += TQString("# Submitted via: %1 %2\n").arg(CDDB::clientName(),
CDDB::clientVersion());
}
s += "DISCID=" + escape( id ) + "\n";
s += createLine("DTITLE",escape( artist ) + " / " + escape( title ));
- s += "DYEAR=" + (0 == year ? QString::null : QString::number(year)) + "\n";
+ s += "DYEAR=" + (0 == year ? TQString::null : TQString::number(year)) + "\n";
s += createLine("DGENRE",escape( genre ));
for (uint i = 0; i < trackInfoList.count(); ++i)
{
- s += createLine(QString("TTITLE%1").arg(i),
+ s += createLine(TQString("TTITLE%1").arg(i),
escape( trackInfoList[ i ].title));
}
@@ -228,7 +228,7 @@ namespace KCDDB
for (uint i = 0; i < trackInfoList.count(); ++i)
{
- s += createLine(QString("EXTT%1").arg(i), escape(trackInfoList[i].extt));
+ s += createLine(TQString("EXTT%1").arg(i), escape(trackInfoList[i].extt));
}
s +="PLAYORDER=\n";
@@ -239,23 +239,23 @@ namespace KCDDB
// Creates a line in the form NAME=VALUE, and splits it into several
// lines if the line gets longer than 256 chars
QString
- CDInfo::createLine(const QString& name, const QString& value) const
+ CDInfo::createLine(const TQString& name, const TQString& value) const
{
Q_ASSERT(name.length() < 254);
uint maxLength = 256 - name.length() - 2;
- QString tmpValue = value;
+ TQString tmpValue = value;
- QString lines;
+ TQString lines;
while (tmpValue.length() > maxLength)
{
- lines += QString("%1=%2\n").arg(name,tmpValue.left(maxLength));
+ lines += TQString("%1=%2\n").arg(name,tmpValue.left(maxLength));
tmpValue = tmpValue.mid(maxLength);
}
- lines += QString("%1=%2\n").arg(name,tmpValue);
+ lines += TQString("%1=%2\n").arg(name,tmpValue);
return lines;
}
@@ -271,9 +271,9 @@ namespace KCDDB
}
QString
- CDInfo::escape( const QString& value )
+ CDInfo::escape( const TQString& value )
{
- QString s = value;
+ TQString s = value;
s.replace( "\\", "\\\\" );
s.replace( "\n", "\\n" );
s.replace( "\t", "\\t" );
@@ -282,9 +282,9 @@ namespace KCDDB
}
QString
- CDInfo::unescape( const QString& value )
+ CDInfo::unescape( const TQString& value )
{
- QString s = value;
+ TQString s = value;
s.replace( "\\n", "\n" );
s.replace( "\\t", "\t" );
@@ -296,7 +296,7 @@ namespace KCDDB
void
CDInfo::clear()
{
- id = artist = title = genre = extd = QString::null;
+ id = artist = title = genre = extd = TQString::null;
length = year = revision = 0;
trackInfoList.clear();
}
@@ -313,7 +313,7 @@ namespace KCDDB
return true;
}
- QVariant CDInfo::get(const QString &type) const {
+ TQVariant CDInfo::get(const TQString &type) const {
if(type == "id")
return id;
if(type == "artist")
@@ -332,7 +332,7 @@ namespace KCDDB
return length;
if(type == "revision")
return revision;
- return QVariant();
+ return TQVariant();
}
}
diff --git a/libkcddb/cdinfo.h b/libkcddb/cdinfo.h
index fb547672..afa66adc 100644
--- a/libkcddb/cdinfo.h
+++ b/libkcddb/cdinfo.h
@@ -22,10 +22,10 @@
#ifndef KCDDB_CDINFO_H
#define KCDDB_CDINFO_H
-#include <qstringlist.h>
-#include <qvaluelist.h>
+#include <tqstringlist.h>
+#include <tqvaluelist.h>
#include <kdemacros.h>
-#include <qvariant.h>
+#include <tqvariant.h>
namespace KCDDB
{
@@ -46,16 +46,16 @@ namespace KCDDB
* @p type is case insensitive.
* For example <code>get("title")</code>
*/
- QVariant get(const QString &type) const;
+ TQVariant get(const TQString &type) const;
#ifndef KDE_NO_COMPAT
// Use get("title");
- QString title;
+ TQString title;
// Use get("extt");
- QString extt;
+ TQString extt;
#endif
};
- typedef QValueList<TrackInfo> TrackInfoList;
+ typedef TQValueList<TrackInfo> TrackInfoList;
/**
* Information about a CD
@@ -78,12 +78,12 @@ namespace KCDDB
* Load CDInfo from a string that is CDDB compatible
* @return true if successful
*/
- bool load(const QString &);
+ bool load(const TQString &);
/**
* Load CDInfo from a stringList that is CDDB compatible
* @return true if successful
*/
- bool load(const QStringList &);
+ bool load(const TQStringList &);
/**
* Clear all information, setting this to invalid
@@ -99,21 +99,21 @@ namespace KCDDB
* @param submit If submit is true only returns CDDB compatible information
* @return a string containing all of the CD's information.
*/
- QString toString(bool submit=false) const;
+ TQString toString(bool submit=false) const;
/**
* Get data for type that has been assigned to this disc.
* @p type is case insensitive.
* For example <code>get("title")</code>
*/
- QVariant get(const QString &type) const;
+ TQVariant get(const TQString &type) const;
// Use get(...)
- QString id;
- QString artist;
- QString title;
- QString genre;
- QString category;
- QString extd;
+ TQString id;
+ TQString artist;
+ TQString title;
+ TQString genre;
+ TQString category;
+ TQString extd;
uint year;
uint length; // in milliseconds
uint revision;
@@ -124,7 +124,7 @@ namespace KCDDB
/**
* @returns a valid CDDB line made up of name and value
*/
- QString createLine(const QString& name, const QString& value) const;
+ TQString createLine(const TQString& name, const TQString& value) const;
/**
* Checks to make sure that trackNumber exists
*/
@@ -132,14 +132,14 @@ namespace KCDDB
/**
* escape's string for CDDB processing
*/
- static QString escape( const QString & );
+ static TQString escape( const TQString & );
/**
* fixes an escaped string that has been CDDB processed
*/
- static QString unescape( const QString & );
+ static TQString unescape( const TQString & );
};
- typedef QValueList<CDInfo> CDInfoList;
+ typedef TQValueList<CDInfo> CDInfoList;
}
#endif // KCDDB_CDINFO_H
diff --git a/libkcddb/cdinfodialogbase.ui.h b/libkcddb/cdinfodialogbase.ui.h
index 1291010a..e33ad487 100644
--- a/libkcddb/cdinfodialogbase.ui.h
+++ b/libkcddb/cdinfodialogbase.ui.h
@@ -7,7 +7,7 @@
** place of a destructor.
*****************************************************************************/
-#include <qtextcodec.h>
+#include <tqtextcodec.h>
#include <kdebug.h>
#include <kdialogbase.h>
#include <kglobal.h>
@@ -25,7 +25,7 @@ void CDInfoDialogBase::init()
m_genre->insertStringList(m_genres.i18nList());
// We want control over the visibility of this column. See artistChanged().
- m_trackList->setColumnWidthMode(TRACK_ARTIST, QListView::Manual);
+ m_trackList->setColumnWidthMode(TRACK_ARTIST, TQListView::Manual);
// Make the user-definable values in-place editable.
m_trackList->setRenameable(TRACK_NUMBER, false);
@@ -39,7 +39,7 @@ void CDInfoDialogBase::destroy()
{
}
-void CDInfoDialogBase::slotTrackSelected( QListViewItem *item )
+void CDInfoDialogBase::slotTrackSelected( TQListViewItem *item )
{
emit play(item->text(0).toUInt()-1);
}
@@ -48,13 +48,13 @@ void CDInfoDialogBase::slotNextTrack()
{
if (m_trackList->currentItem())
{
- QListViewItem *item = m_trackList->currentItem()->nextSibling();
+ TQListViewItem *item = m_trackList->currentItem()->nextSibling();
m_trackList->setSelected(item, true);
m_trackList->ensureItemVisible(item);
}
}
-void CDInfoDialogBase::slotTrackDoubleClicked( QListViewItem *item, const QPoint &, int column)
+void CDInfoDialogBase::slotTrackDoubleClicked( TQListViewItem *item, const TQPoint &, int column)
{
m_trackList->rename(item, column);
}
@@ -66,7 +66,7 @@ void CDInfoDialogBase::setInfo( const KCDDB::CDInfo &info, KCDDB::TrackOffsetLis
m_category->setCurrentText(m_categories.cddb2i18n(info.category));
// Make sure the revision is set before the genre to allow the genreChanged() handler to fire.
- m_revision->setText(QString::number(info.revision));
+ m_revision->setText(TQString::number(info.revision));
m_genre->setCurrentText(m_genres.cddb2i18n(info.genre));
m_year->setValue(info.year);
m_comment->setText(info.extd.stripWhiteSpace());
@@ -78,11 +78,11 @@ void CDInfoDialogBase::setInfo( const KCDDB::CDInfo &info, KCDDB::TrackOffsetLis
m_trackList->clear();
for (unsigned i = 0; i < tracks; i++)
{
- QListViewItem *item = new QListViewItem(m_trackList, 0);
+ TQListViewItem *item = new TQListViewItem(m_trackList, 0);
- item->setText(TRACK_NUMBER, QString().sprintf("%02d", i + 1));
+ item->setText(TRACK_NUMBER, TQString().sprintf("%02d", i + 1));
item->setText(TRACK_TIME, framesTime(trackStartFrames[i + ((i + 1 < tracks) ? 1 : 2)] - trackStartFrames[i]));
- QString title = info.trackInfoList[i].title;
+ TQString title = info.trackInfoList[i].title;
int separator = title.find(SEPARATOR);
if (info.artist != "Various" || separator == -1 || !m_multiple->isChecked() )
{
@@ -104,16 +104,16 @@ void CDInfoDialogBase::setInfo( const KCDDB::CDInfo &info, KCDDB::TrackOffsetLis
}
}
-QString CDInfoDialogBase::framesTime(unsigned frames)
+TQString CDInfoDialogBase::framesTime(unsigned frames)
{
- QTime time;
+ TQTime time;
double ms;
ms = frames * 1000 / 75.0;
time = time.addMSecs((int)ms);
// Use ".zzz" for milliseconds...
- QString temp2;
+ TQString temp2;
if (time.hour() > 0)
temp2 = time.toString("hh:mm:ss");
else
@@ -134,10 +134,10 @@ KCDDB::CDInfo CDInfoDialogBase::info() const
info.extd = m_comment->text().stripWhiteSpace();
info.revision = m_revision->text().stripWhiteSpace().toUInt();
info.id = m_id->text().stripWhiteSpace();
- for (QListViewItem *item = m_trackList->firstChild(); item; item=item->nextSibling())
+ for (TQListViewItem *item = m_trackList->firstChild(); item; item=item->nextSibling())
{
// Combine the track artist if present with the title.
- QString trackArtist = item->text(TRACK_ARTIST).stripWhiteSpace();
+ TQString trackArtist = item->text(TRACK_ARTIST).stripWhiteSpace();
track.title = trackArtist;
if (!trackArtist.isEmpty())
{
@@ -153,7 +153,7 @@ KCDDB::CDInfo CDInfoDialogBase::info() const
}
-void CDInfoDialogBase::artistChanged( const QString &newArtist )
+void CDInfoDialogBase::artistChanged( const TQString &newArtist )
{
// Enable special handling of compilations.
if (newArtist.stripWhiteSpace().compare("Various")) {
@@ -163,7 +163,7 @@ void CDInfoDialogBase::artistChanged( const QString &newArtist )
}
}
-void CDInfoDialogBase::genreChanged( const QString &newGenre )
+void CDInfoDialogBase::genreChanged( const TQString &newGenre )
{
// Disable changes to category if the version number indicates that a record
// is already in the database, or if the genre is poorly set. The latter
@@ -176,9 +176,9 @@ void CDInfoDialogBase::genreChanged( const QString &newGenre )
void CDInfoDialogBase::slotMultipleArtists( bool hasMultipleArtist)
{
if(hasMultipleArtist){
- for (QListViewItem *item = m_trackList->firstChild(); item; item=item->nextSibling())
+ for (TQListViewItem *item = m_trackList->firstChild(); item; item=item->nextSibling())
{
- QString title = item->text(TRACK_TITLE);
+ TQString title = item->text(TRACK_TITLE);
int separator = title.find(SEPARATOR);
if (separator != -1)
{
@@ -191,12 +191,12 @@ void CDInfoDialogBase::slotMultipleArtists( bool hasMultipleArtist)
m_trackList->adjustColumn(TRACK_TITLE);
}
else{
- for (QListViewItem *item = m_trackList->firstChild(); item; item=item->nextSibling())
+ for (TQListViewItem *item = m_trackList->firstChild(); item; item=item->nextSibling())
{
- QString artist = item->text(TRACK_ARTIST);
+ TQString artist = item->text(TRACK_ARTIST);
if (!artist.isEmpty())
{
- item->setText(TRACK_ARTIST, QString::null);
+ item->setText(TRACK_ARTIST, TQString::null);
item->setText(TRACK_TITLE, artist + SEPARATOR + item->text(TRACK_TITLE));
}
}
@@ -213,10 +213,10 @@ void CDInfoDialogBase::slotChangeEncoding()
KDialogBase* dialog = new KDialogBase(this, 0, true, i18n("Change Encoding"),
KDialogBase::Ok | KDialogBase::Cancel);
- QStringList songTitles;
- for (QListViewItem *item = m_trackList->firstChild(); item; item=item->nextSibling())
+ TQStringList songTitles;
+ for (TQListViewItem *item = m_trackList->firstChild(); item; item=item->nextSibling())
{
- QString title = item->text(TRACK_ARTIST).stripWhiteSpace();
+ TQString title = item->text(TRACK_ARTIST).stripWhiteSpace();
if (!title.isEmpty())
title.append(SEPARATOR);
title.append(item->text(TRACK_TITLE).stripWhiteSpace());
@@ -231,14 +231,14 @@ void CDInfoDialogBase::slotChangeEncoding()
if (dialog->exec())
{
KCharsets* charsets = KGlobal::charsets();
- QTextCodec* codec = charsets->codecForName(charsets->encodingForName(encWidget->selectedEncoding()));
+ TQTextCodec* codec = charsets->codecForName(charsets->encodingForName(encWidget->selectedEncoding()));
m_artist->setText(codec->toUnicode(m_artist->text().latin1()));
m_title->setText(codec->toUnicode(m_title->text().latin1()));
m_genre->setCurrentText(codec->toUnicode(m_genre->currentText().latin1()));
m_comment->setText(codec->toUnicode(m_comment->text().latin1()));
- for (QListViewItem *item = m_trackList->firstChild(); item; item=item->nextSibling())
+ for (TQListViewItem *item = m_trackList->firstChild(); item; item=item->nextSibling())
{
item->setText(TRACK_ARTIST,codec->toUnicode(item->text(TRACK_ARTIST).latin1()));
item->setText(TRACK_TITLE,codec->toUnicode(item->text(TRACK_TITLE).latin1()));
diff --git a/libkcddb/cdinfoencodingwidget.cpp b/libkcddb/cdinfoencodingwidget.cpp
index 434d1169..42d0e506 100644
--- a/libkcddb/cdinfoencodingwidget.cpp
+++ b/libkcddb/cdinfoencodingwidget.cpp
@@ -17,10 +17,10 @@
Boston, MA 02110-1301, USA.
*/
-#include <qcombobox.h>
-#include <qlistbox.h>
-#include <qlabel.h>
-#include <qtextcodec.h>
+#include <tqcombobox.h>
+#include <tqlistbox.h>
+#include <tqlabel.h>
+#include <tqtextcodec.h>
#include <klocale.h>
#include <kglobal.h>
#include <kcharsets.h>
@@ -28,8 +28,8 @@
namespace KCDDB
{
- CDInfoEncodingWidget::CDInfoEncodingWidget(QWidget* parent, const QString& artist,
- const QString& title, const QStringList& songTitles)
+ CDInfoEncodingWidget::CDInfoEncodingWidget(TQWidget* parent, const TQString& artist,
+ const TQString& title, const TQStringList& songTitles)
: CDInfoEncodingWidgetBase(parent), m_artist(artist), m_title(title),
m_songTitles(songTitles)
{
@@ -37,25 +37,25 @@ namespace KCDDB
slotEncodingChanged(encodingCombo->currentText());
- connect(encodingCombo,SIGNAL(activated(const QString&)),
- this,SLOT(slotEncodingChanged(const QString&)));
+ connect(encodingCombo,TQT_SIGNAL(activated(const TQString&)),
+ this,TQT_SLOT(slotEncodingChanged(const TQString&)));
}
- QString CDInfoEncodingWidget::selectedEncoding()
+ TQString CDInfoEncodingWidget::selectedEncoding()
{
return encodingCombo->currentText();
}
- void CDInfoEncodingWidget::slotEncodingChanged(const QString& encoding)
+ void CDInfoEncodingWidget::slotEncodingChanged(const TQString& encoding)
{
KCharsets* charsets = KGlobal::charsets();
- QTextCodec* codec = charsets->codecForName(charsets->encodingForName(encoding));
+ TQTextCodec* codec = charsets->codecForName(charsets->encodingForName(encoding));
songsBox->clear();
- QStringList newTitles;
+ TQStringList newTitles;
- for (QStringList::const_iterator it = m_songTitles.begin();
+ for (TQStringList::const_iterator it = m_songTitles.begin();
it != m_songTitles.end(); ++it)
newTitles << codec->toUnicode((*it).latin1());
diff --git a/libkcddb/cdinfoencodingwidget.h b/libkcddb/cdinfoencodingwidget.h
index 010767ea..7182b44f 100644
--- a/libkcddb/cdinfoencodingwidget.h
+++ b/libkcddb/cdinfoencodingwidget.h
@@ -28,17 +28,17 @@ namespace KCDDB
{
Q_OBJECT
public:
- CDInfoEncodingWidget(QWidget* parent, const QString& artist, const QString& title,
- const QStringList& songTitles);
+ CDInfoEncodingWidget(TQWidget* parent, const TQString& artist, const TQString& title,
+ const TQStringList& songTitles);
- QString selectedEncoding();
+ TQString selectedEncoding();
private slots:
- void slotEncodingChanged(const QString &);
+ void slotEncodingChanged(const TQString &);
private:
- QString m_artist, m_title;
- QStringList m_songTitles;
+ TQString m_artist, m_title;
+ TQStringList m_songTitles;
} ;
}
diff --git a/libkcddb/client.cpp b/libkcddb/client.cpp
index 1e0b982c..9a06f04d 100644
--- a/libkcddb/client.cpp
+++ b/libkcddb/client.cpp
@@ -49,7 +49,7 @@ namespace KCDDB
};
Client::Client()
- : QObject(),
+ : TQObject(),
cdInfoLookup(0),
cdInfoSubmit(0)
{
@@ -113,7 +113,7 @@ namespace KCDDB
{
d->cdInfoList.clear();
- QString cddbId = Lookup::trackOffsetListToId( trackOffsetList );
+ TQString cddbId = Lookup::trackOffsetListToId( trackOffsetList );
if ( cddbId.isNull() )
{
@@ -177,16 +177,16 @@ namespace KCDDB
cdInfoLookup = new AsyncCDDBPLookup();
connect( static_cast<AsyncCDDBPLookup *>( cdInfoLookup ),
- SIGNAL( finished( CDDB::Result ) ),
- SLOT( slotFinished( CDDB::Result ) ) );
+ TQT_SIGNAL( finished( CDDB::Result ) ),
+ TQT_SLOT( slotFinished( CDDB::Result ) ) );
}
else
{
cdInfoLookup = new AsyncHTTPLookup();
connect( static_cast<AsyncHTTPLookup *>( cdInfoLookup ),
- SIGNAL( finished( CDDB::Result ) ),
- SLOT( slotFinished( CDDB::Result ) ) );
+ TQT_SIGNAL( finished( CDDB::Result ) ),
+ TQT_SLOT( slotFinished( CDDB::Result ) ) );
}
r = cdInfoLookup->lookup( d->config.hostname(),
@@ -252,13 +252,13 @@ namespace KCDDB
// just in case we have a cdInfoSubmit, prevent memory leakage
delete cdInfoSubmit;
- QString from = d->config.emailAddress();
+ TQString from = d->config.emailAddress();
switch (d->config.submitTransport())
{
case Submit::HTTP:
{
- QString hostname = d->config.httpSubmitServer();
+ TQString hostname = d->config.httpSubmitServer();
uint port = d->config.httpSubmitPort();
if ( blockingMode() )
@@ -267,17 +267,17 @@ namespace KCDDB
{
cdInfoSubmit = new AsyncHTTPSubmit(from, hostname, port);
connect( static_cast<AsyncHTTPSubmit *>( cdInfoSubmit ),
- SIGNAL(finished( CDDB::Result ) ),
- SLOT( slotSubmitFinished( CDDB::Result ) ) );
+ TQT_SIGNAL(finished( CDDB::Result ) ),
+ TQT_SLOT( slotSubmitFinished( CDDB::Result ) ) );
}
break;
}
case Submit::SMTP:
{
- QString hostname = d->config.smtpHostname();
+ TQString hostname = d->config.smtpHostname();
uint port = d->config.smtpPort();
- QString username = d->config.smtpUsername();
+ TQString username = d->config.smtpUsername();
if ( blockingMode() )
cdInfoSubmit = new SyncSMTPSubmit( hostname, port, username, from, d->config.submitAddress() );
@@ -285,8 +285,8 @@ namespace KCDDB
{
cdInfoSubmit = new AsyncSMTPSubmit( hostname, port, username, from, d->config.submitAddress() );
connect( static_cast<AsyncSMTPSubmit *>( cdInfoSubmit ),
- SIGNAL( finished( CDDB::Result ) ),
- SLOT( slotSubmitFinished( CDDB::Result ) ) );
+ TQT_SIGNAL( finished( CDDB::Result ) ),
+ TQT_SLOT( slotSubmitFinished( CDDB::Result ) ) );
}
break;
}
diff --git a/libkcddb/client.h b/libkcddb/client.h
index 6f58cec2..3aeb3bd6 100644
--- a/libkcddb/client.h
+++ b/libkcddb/client.h
@@ -23,7 +23,7 @@
#include "config.h"
#include "cdinfo.h"
-#include <qobject.h>
+#include <tqobject.h>
#include "cddb.h"
#include <kdemacros.h>
diff --git a/libkcddb/config.h b/libkcddb/config.h
index 3fd11f75..65bd492e 100644
--- a/libkcddb/config.h
+++ b/libkcddb/config.h
@@ -26,7 +26,7 @@
#include "cache.h"
#include "cddb.h"
#include "configbase.h"
-#include <qstring.h>
+#include <tqstring.h>
#include <kdelibs_export.h>
namespace KCDDB
{
diff --git a/libkcddb/genres.cpp b/libkcddb/genres.cpp
index 1eeee324..423e80fc 100644
--- a/libkcddb/genres.cpp
+++ b/libkcddb/genres.cpp
@@ -94,9 +94,9 @@ KCDDB::Genres::Genres()
i18n("Vocal");
}
-const QString KCDDB::Genres::cddb2i18n(const QString &genre) const
+const TQString KCDDB::Genres::cddb2i18n(const TQString &genre) const
{
- QString userDefinedGenre = genre.stripWhiteSpace();
+ TQString userDefinedGenre = genre.stripWhiteSpace();
int index = m_cddb.findIndex(userDefinedGenre);
if (index != -1)
{
@@ -108,9 +108,9 @@ const QString KCDDB::Genres::cddb2i18n(const QString &genre) const
}
}
-const QString KCDDB::Genres::i18n2cddb(const QString &genre) const
+const TQString KCDDB::Genres::i18n2cddb(const TQString &genre) const
{
- QString userDefinedGenre = genre.stripWhiteSpace();
+ TQString userDefinedGenre = genre.stripWhiteSpace();
int index = m_i18n.findIndex(userDefinedGenre);
if (index != -1)
{
diff --git a/libkcddb/genres.h b/libkcddb/genres.h
index 4456f894..1e7cab81 100644
--- a/libkcddb/genres.h
+++ b/libkcddb/genres.h
@@ -8,8 +8,8 @@
#ifndef KCDDB_GENRES_H
#define KCDDB_GENRES_H
-#include <qstring.h>
-#include <qstringlist.h>
+#include <tqstring.h>
+#include <tqstringlist.h>
namespace KCDDB
{
@@ -22,21 +22,21 @@ namespace KCDDB
public:
Genres();
- const QStringList &cddbList() const { return m_cddb; };
- const QStringList &i18nList() const { return m_i18n; };
+ const TQStringList &cddbList() const { return m_cddb; };
+ const TQStringList &i18nList() const { return m_i18n; };
/**
* Lookup the CDDB genre, and return the i18n'd version.
*/
- const QString cddb2i18n(const QString &genre) const;
+ const TQString cddb2i18n(const TQString &genre) const;
/**
* Lookup the i18n genre, and return the CDDB version if we can.
*/
- const QString i18n2cddb(const QString &genre) const;
+ const TQString i18n2cddb(const TQString &genre) const;
private:
- QStringList m_cddb;
- QStringList m_i18n;
+ TQStringList m_cddb;
+ TQStringList m_i18n;
};
}
diff --git a/libkcddb/httplookup.cpp b/libkcddb/httplookup.cpp
index db72d23b..c360c423 100644
--- a/libkcddb/httplookup.cpp
+++ b/libkcddb/httplookup.cpp
@@ -39,7 +39,7 @@ namespace KCDDB
CDDB::Result
HTTPLookup::sendQuery()
{
- QString cmd = QString( "cddb query %1 %2" )
+ TQString cmd = TQString( "cddb query %1 %2" )
.arg( trackOffsetListToId(), trackOffsetListToString() ) ;
makeURL( cmd );
@@ -52,9 +52,9 @@ namespace KCDDB
HTTPLookup::sendRead( const CDDBMatch & match )
{
category_ = match.first;
- QString discid = match.second;
+ TQString discid = match.second;
- QString cmd = QString( "cddb read %1 %2" )
+ TQString cmd = TQString( "cddb read %1 %2" )
.arg( category_, discid );
makeURL( cmd );
@@ -64,7 +64,7 @@ namespace KCDDB
}
void
- HTTPLookup::initURL( const QString & hostName, uint port )
+ HTTPLookup::initURL( const TQString & hostName, uint port )
{
cgiURL_.setProtocol( "http" );
cgiURL_.setHost( hostName );
@@ -75,14 +75,14 @@ namespace KCDDB
}
void
- HTTPLookup::makeURL( const QString & cmd )
+ HTTPLookup::makeURL( const TQString & cmd )
{
// The whole query has to constructed each time as the
// CDDB CGI script expects the parameters in strict order
- cgiURL_.setQuery( QString::null );
+ cgiURL_.setQuery( TQString::null );
- QString hello = QString("%1 %2 %3 %4")
+ TQString hello = TQString("%1 %2 %3 %4")
.arg(user_, localHostName_, clientName(), clientVersion());
cgiURL_.addQueryItem( "cmd", cmd );
@@ -93,8 +93,8 @@ namespace KCDDB
void
HTTPLookup::jobFinished()
{
- QStringList lineList = QStringList::split( "\n", QString::fromUtf8(data_, data_.size()) );
- QStringList::ConstIterator it = lineList.begin();
+ TQStringList lineList = TQStringList::split( "\n", TQString::fromUtf8(data_, data_.size()) );
+ TQStringList::ConstIterator it = lineList.begin();
switch ( state_ )
{
@@ -102,7 +102,7 @@ namespace KCDDB
if ( it != lineList.end() )
{
- QString line( *it );
+ TQString line( *it );
result_ = parseQuery( line );
@@ -119,7 +119,7 @@ namespace KCDDB
++it;
while ( it != lineList.end() )
{
- QString line( *it );
+ TQString line( *it );
if ( '.' == line[ 0 ] )
{
@@ -158,7 +158,7 @@ namespace KCDDB
{
CDInfo info;
- if ( info.load( QString::fromUtf8(data_,data_.size()) ) )
+ if ( info.load( TQString::fromUtf8(data_,data_.size()) ) )
{
info.category = category_;
cdInfoList_.append( info );
diff --git a/libkcddb/httplookup.h b/libkcddb/httplookup.h
index 8b6066e6..b8f9c179 100644
--- a/libkcddb/httplookup.h
+++ b/libkcddb/httplookup.h
@@ -53,8 +53,8 @@ namespace KCDDB
protected:
- void initURL( const QString &, uint );
- void makeURL( const QString & );
+ void initURL( const TQString &, uint );
+ void makeURL( const TQString & );
virtual Result fetchURL() = 0;
void jobFinished();
@@ -71,7 +71,7 @@ namespace KCDDB
bool block_;
KURL cgiURL_;
- QByteArray data_;
+ TQByteArray data_;
State state_;
Result result_;
};
diff --git a/libkcddb/httpsubmit.cpp b/libkcddb/httpsubmit.cpp
index 91c7f3a0..fa4c2d98 100644
--- a/libkcddb/httpsubmit.cpp
+++ b/libkcddb/httpsubmit.cpp
@@ -23,7 +23,7 @@
namespace KCDDB
{
- HTTPSubmit::HTTPSubmit(const QString& from, const QString& hostname, uint port)
+ HTTPSubmit::HTTPSubmit(const TQString& from, const TQString& hostname, uint port)
: Submit(), from_(from)
{
url_.setProtocol("http");
@@ -42,7 +42,7 @@ namespace KCDDB
KIO::TransferJob* job = KIO::http_post(url_, diskData_.utf8(), false);
job->addMetaData("content-type", "Content-Type: text/plain");
- QString header;
+ TQString header;
header += "Content-Type: text/plain\n";
diff --git a/libkcddb/httpsubmit.h b/libkcddb/httpsubmit.h
index 63d837b0..40131ea4 100644
--- a/libkcddb/httpsubmit.h
+++ b/libkcddb/httpsubmit.h
@@ -27,14 +27,14 @@ namespace KCDDB
class HTTPSubmit : public Submit
{
public:
- HTTPSubmit(const QString& from, const QString& hostname, uint port);
+ HTTPSubmit(const TQString& from, const TQString& hostname, uint port);
virtual ~HTTPSubmit();
protected:
virtual KIO::Job* createJob(const CDInfo& cdInfo);
KURL url_;
- QString from_;
+ TQString from_;
} ;
}
diff --git a/libkcddb/kcmcddb/cddbconfigwidget.cpp b/libkcddb/kcmcddb/cddbconfigwidget.cpp
index 70c5e1e9..442efd12 100644
--- a/libkcddb/kcmcddb/cddbconfigwidget.cpp
+++ b/libkcddb/kcmcddb/cddbconfigwidget.cpp
@@ -23,22 +23,22 @@
#include "libkcddb/sites.h"
#include "libkcddb/lookup.h"
-#include <qlistbox.h>
-#include <qcombobox.h>
-#include <qspinbox.h>
-#include <qlineedit.h>
+#include <tqlistbox.h>
+#include <tqcombobox.h>
+#include <tqspinbox.h>
+#include <tqlineedit.h>
#include <kfiledialog.h>
#include <kapplication.h>
#include <klocale.h>
#include <kinputdialog.h>
#include <kmessagebox.h>
#include <keditlistbox.h>
-#include <qwidgetstack.h>
+#include <tqwidgetstack.h>
#include <kurlrequester.h>
-#include <qbuttongroup.h>
-#include <qcheckbox.h>
+#include <tqbuttongroup.h>
+#include <tqcheckbox.h>
-CDDBConfigWidget::CDDBConfigWidget(QWidget * parent, const char * name)
+CDDBConfigWidget::CDDBConfigWidget(TQWidget * parent, const char * name)
: CDDBConfigWidgetBase(parent, name)
{
// Connections from widgets are made in designer.
@@ -56,13 +56,13 @@ void CDDBConfigWidget::showMirrorList()
{
KCDDB::Sites s;
- QValueList<KCDDB::Mirror> sites = s.siteList();
- QMap<QString, KCDDB::Mirror> keys;
- for (QValueList<KCDDB::Mirror>::Iterator it = sites.begin(); it != sites.end(); ++it)
+ TQValueList<KCDDB::Mirror> sites = s.siteList();
+ TQMap<TQString, KCDDB::Mirror> keys;
+ for (TQValueList<KCDDB::Mirror>::Iterator it = sites.begin(); it != sites.end(); ++it)
if ((*it).transport == KCDDB::Lookup::CDDBP)
- keys[(*it).address + "(CDDBP, " + QString::number((*it).port) + ") " + (*it).description] = *it;
+ keys[(*it).address + "(CDDBP, " + TQString::number((*it).port) + ") " + (*it).description] = *it;
else
- keys[(*it).address + "(HTTP, " + QString::number((*it).port) + ") " + (*it).description] = *it;
+ keys[(*it).address + "(HTTP, " + TQString::number((*it).port) + ") " + (*it).description] = *it;
bool ok;
@@ -72,9 +72,9 @@ void CDDBConfigWidget::showMirrorList()
return;
}
- QStringList result = KInputDialog::getItemList(i18n("Select mirror"),
+ TQStringList result = KInputDialog::getItemList(i18n("Select mirror"),
i18n("Select one of these mirrors"), keys.keys(),
- QStringList(), false, &ok, this);
+ TQStringList(), false, &ok, this);
if (ok && result.count() == 1)
{
diff --git a/libkcddb/kcmcddb/cddbconfigwidget.h b/libkcddb/kcmcddb/cddbconfigwidget.h
index fafeaffa..2f0363d7 100644
--- a/libkcddb/kcmcddb/cddbconfigwidget.h
+++ b/libkcddb/kcmcddb/cddbconfigwidget.h
@@ -28,7 +28,7 @@ class CDDBConfigWidget : public CDDBConfigWidgetBase
public:
- CDDBConfigWidget(QWidget * parent = 0, const char * name = 0);
+ CDDBConfigWidget(TQWidget * parent = 0, const char * name = 0);
protected slots:
diff --git a/libkcddb/kcmcddb/kcmcddb.cpp b/libkcddb/kcmcddb/kcmcddb.cpp
index 851b7cb1..3688ba6a 100644
--- a/libkcddb/kcmcddb/kcmcddb.cpp
+++ b/libkcddb/kcmcddb/kcmcddb.cpp
@@ -18,15 +18,15 @@
Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
*/
-#include <qlayout.h>
-#include <qcheckbox.h>
-#include <qcombobox.h>
-#include <qspinbox.h>
-#include <qlineedit.h>
-#include <qradiobutton.h>
-#include <qlistbox.h>
-#include <qlabel.h>
-#include <qbuttongroup.h>
+#include <tqlayout.h>
+#include <tqcheckbox.h>
+#include <tqcombobox.h>
+#include <tqspinbox.h>
+#include <tqlineedit.h>
+#include <tqradiobutton.h>
+#include <tqlistbox.h>
+#include <tqlabel.h>
+#include <tqbuttongroup.h>
#include <kconfig.h>
#include <klocale.h>
@@ -42,10 +42,10 @@
#include "libkcddb/cache.h"
#include "libkcddb/submit.h"
-typedef KGenericFactory<CDDBModule, QWidget> KCDDBFactory;
+typedef KGenericFactory<CDDBModule, TQWidget> KCDDBFactory;
K_EXPORT_COMPONENT_FACTORY ( kcm_cddb, KCDDBFactory( "kcmcddb" ) )
-CDDBModule::CDDBModule(QWidget *parent, const char *name, const QStringList &)
+CDDBModule::CDDBModule(TQWidget *parent, const char *name, const TQStringList &)
: KCModule(parent, name)
{
KGlobal::locale()->insertCatalogue("libkcddb");
@@ -58,7 +58,7 @@ CDDBModule::CDDBModule(QWidget *parent, const char *name, const QStringList &)
addConfig(cfg, widget_);
- QVBoxLayout * layout = new QVBoxLayout(this, 0);
+ TQVBoxLayout * layout = new TQVBoxLayout(this, 0);
layout->addWidget(widget_);
layout->addStretch();
diff --git a/libkcddb/kcmcddb/kcmcddb.h b/libkcddb/kcmcddb/kcmcddb.h
index dd22f0a5..36d42e6f 100644
--- a/libkcddb/kcmcddb/kcmcddb.h
+++ b/libkcddb/kcmcddb/kcmcddb.h
@@ -33,7 +33,7 @@ class CDDBModule : public KCModule
public:
- CDDBModule(QWidget * parent, const char *name, const QStringList &);
+ CDDBModule(TQWidget * parent, const char *name, const TQStringList &);
public slots:
diff --git a/libkcddb/lookup.cpp b/libkcddb/lookup.cpp
index efd7de72..d7c15956 100644
--- a/libkcddb/lookup.cpp
+++ b/libkcddb/lookup.cpp
@@ -36,13 +36,13 @@ namespace KCDDB
}
CDDB::Result
- Lookup::parseQuery( const QString & line )
+ Lookup::parseQuery( const TQString & line )
{
uint serverStatus = statusCode( line );
if ( 200 == serverStatus )
{
- QStringList tokenList = QStringList::split( ' ', line );
+ TQStringList tokenList = TQStringList::split( ' ', line );
matchList_.append( qMakePair( tokenList[ 1 ], tokenList[ 2 ] ) );
return Success;
}
@@ -59,14 +59,14 @@ namespace KCDDB
}
void
- Lookup::parseExtraMatch( const QString & line )
+ Lookup::parseExtraMatch( const TQString & line )
{
- QStringList tokenList = QStringList::split( ' ', line );
+ TQStringList tokenList = TQStringList::split( ' ', line );
matchList_.append( qMakePair( tokenList[ 0 ], tokenList[ 1 ] ) );
}
CDDB::Result
- Lookup::parseRead( const QString & line )
+ Lookup::parseRead( const TQString & line )
{
uint serverStatus = statusCode( line );
diff --git a/libkcddb/lookup.h b/libkcddb/lookup.h
index 07575bc2..96538ac5 100644
--- a/libkcddb/lookup.h
+++ b/libkcddb/lookup.h
@@ -24,12 +24,12 @@
#include "cddb.h"
#include "cdinfo.h"
-#include <qobject.h>
+#include <tqobject.h>
namespace KCDDB
{
- typedef QPair<QString, QString> CDDBMatch;
- typedef QValueList<CDDBMatch> CDDBMatchList;
+ typedef QPair<TQString, TQString> CDDBMatch;
+ typedef TQValueList<CDDBMatch> CDDBMatchList;
class Lookup : public CDDB, public QObject
{
@@ -45,19 +45,19 @@ namespace KCDDB
Lookup();
virtual ~Lookup();
- virtual Result lookup( const QString &, uint, const TrackOffsetList & ) = 0;
+ virtual Result lookup( const TQString &, uint, const TrackOffsetList & ) = 0;
CDInfoList lookupResponse() const;
protected:
- void parseExtraMatch( const QString & );
- Result parseQuery( const QString & );
- Result parseRead( const QString & );
+ void parseExtraMatch( const TQString & );
+ Result parseQuery( const TQString & );
+ Result parseRead( const TQString & );
CDInfoList cdInfoList_;
CDDBMatchList matchList_;
- QString category_;
+ TQString category_;
};
}
diff --git a/libkcddb/sites.cpp b/libkcddb/sites.cpp
index 5980ce89..393740fe 100644
--- a/libkcddb/sites.cpp
+++ b/libkcddb/sites.cpp
@@ -20,9 +20,9 @@
#include "sites.h"
#include <kurl.h>
#include <kio/netaccess.h>
-#include <qfile.h>
+#include <tqfile.h>
#include <kdebug.h>
-#include <qregexp.h>
+#include <tqregexp.h>
namespace KCDDB
{
@@ -32,7 +32,7 @@ namespace KCDDB
}
- QValueList<Mirror>
+ TQValueList<Mirror>
Sites::siteList()
{
KURL url;
@@ -41,18 +41,18 @@ namespace KCDDB
url.setPort( 80 );
url.setPath( "/~cddb/cddb.cgi" );
- url.setQuery( QString::null );
+ url.setQuery( TQString::null );
- QString hello = QString("%1 %2 %3 %4")
+ TQString hello = TQString("%1 %2 %3 %4")
.arg(user_, localHostName_, clientName(), clientVersion());
url.addQueryItem( "cmd", "sites" );
url.addQueryItem( "hello", hello );
url.addQueryItem( "proto", "5" );
- QValueList<Mirror> result;
+ TQValueList<Mirror> result;
- QString tmpFile;
+ TQString tmpFile;
if( KIO::NetAccess::download( url, tmpFile, 0 ) )
{
result = readFile( tmpFile );
@@ -62,26 +62,26 @@ namespace KCDDB
return result;
}
- QValueList<Mirror>
- Sites::readFile(const QString& fileName)
+ TQValueList<Mirror>
+ Sites::readFile(const TQString& fileName)
{
- QValueList<Mirror> result;
+ TQValueList<Mirror> result;
- QFile f(fileName);
+ TQFile f(fileName);
if (!f.open(IO_ReadOnly))
{
kdDebug(60010) << "Couldn't read: " << fileName << endl;
return result;
}
- QTextStream ts(&f);
+ TQTextStream ts(&f);
if (statusCode(ts.readLine()) != 210)
return result;
while (!ts.atEnd())
{
- QString line = ts.readLine();
+ TQString line = ts.readLine();
if (line == ".")
break;
result << parseLine(line);
@@ -91,11 +91,11 @@ namespace KCDDB
}
Mirror
- Sites::parseLine(const QString& line)
+ Sites::parseLine(const TQString& line)
{
Mirror m;
- QRegExp rexp("([^ ]+) (cddbp|http) (\\d+) ([^ ]+) [N|S]\\d{3}.\\d{2} [E|W]\\d{3}.\\d{2} (.*)");
+ TQRegExp rexp("([^ ]+) (cddbp|http) (\\d+) ([^ ]+) [N|S]\\d{3}.\\d{2} [E|W]\\d{3}.\\d{2} (.*)");
if (rexp.search(line) != -1)
{
diff --git a/libkcddb/sites.h b/libkcddb/sites.h
index bdd9ca28..65b184aa 100644
--- a/libkcddb/sites.h
+++ b/libkcddb/sites.h
@@ -20,7 +20,7 @@
#ifndef KCDDB_SITES_H
#define KCDDB_SITES_H
-#include <qvaluelist.h>
+#include <tqvaluelist.h>
#include "cddb.h"
#include "lookup.h"
#include <kdelibs_export.h>
@@ -30,10 +30,10 @@ namespace KCDDB
class Mirror
{
public:
- QString address;
+ TQString address;
Lookup::Transport transport;
uint port;
- QString description;
+ TQString description;
} ;
class KDE_EXPORT Sites : public CDDB
@@ -41,10 +41,10 @@ namespace KCDDB
public:
Sites();
- QValueList<Mirror> siteList();
+ TQValueList<Mirror> siteList();
private:
- QValueList<Mirror> readFile(const QString& fileName);
- Mirror parseLine(const QString& line);
+ TQValueList<Mirror> readFile(const TQString& fileName);
+ Mirror parseLine(const TQString& line);
} ;
}
diff --git a/libkcddb/smtpsubmit.cpp b/libkcddb/smtpsubmit.cpp
index d714251e..07f34b61 100644
--- a/libkcddb/smtpsubmit.cpp
+++ b/libkcddb/smtpsubmit.cpp
@@ -23,8 +23,8 @@
namespace KCDDB
{
- SMTPSubmit::SMTPSubmit(const QString& hostname, uint port, const QString& username,
- const QString& from, const QString& to)
+ SMTPSubmit::SMTPSubmit(const TQString& hostname, uint port, const TQString& username,
+ const TQString& from, const TQString& to)
: Submit(), from_(from), to_(to)
{
url_.setProtocol("smtp");
@@ -42,7 +42,7 @@ namespace KCDDB
KIO::Job* SMTPSubmit::createJob(const CDInfo& cdInfo)
{
- url_.setQuery(QString("to=%1&subject=cddb %2 %3&from=%4")
+ url_.setQuery(TQString("to=%1&subject=cddb %2 %3&from=%4")
.arg(to_, cdInfo.category, cdInfo.id, from_));
kdDebug(60010) << "Url is: " << url_.prettyURL() << endl;
diff --git a/libkcddb/smtpsubmit.h b/libkcddb/smtpsubmit.h
index 08cc3049..b2c4eaf1 100644
--- a/libkcddb/smtpsubmit.h
+++ b/libkcddb/smtpsubmit.h
@@ -27,7 +27,7 @@ namespace KCDDB
class SMTPSubmit : public Submit
{
public:
- SMTPSubmit(const QString& hostname, uint port, const QString& username, const QString& from, const QString& to);
+ SMTPSubmit(const TQString& hostname, uint port, const TQString& username, const TQString& from, const TQString& to);
virtual ~SMTPSubmit();
protected:
@@ -36,7 +36,7 @@ namespace KCDDB
virtual KIO::Job* createJob(const CDInfo& cdInfo);
KURL url_;
- QString from_, to_;
+ TQString from_, to_;
} ;
}
diff --git a/libkcddb/submit.cpp b/libkcddb/submit.cpp
index d88672af..63a0951b 100644
--- a/libkcddb/submit.cpp
+++ b/libkcddb/submit.cpp
@@ -55,7 +55,7 @@ namespace KCDDB
}
CDDB::Result
- Submit::parseWrite( const QString & line )
+ Submit::parseWrite( const TQString & line )
{
uint serverStatus = statusCode( line );
@@ -74,19 +74,19 @@ namespace KCDDB
diskData_ += "# Track frame offsets:\n";
for (uint i=0; i < numTracks; i++)
- diskData_ += QString("#\t%1\n").arg(offsetList[i]);
+ diskData_ += TQString("#\t%1\n").arg(offsetList[i]);
int l = offsetList[numTracks+1]/75;
- diskData_ += QString("# Disc length: %1 seconds\n").arg(l);
+ diskData_ += TQString("# Disc length: %1 seconds\n").arg(l);
diskData_ += cdInfo.toString(true);
kdDebug(60010) << "diskData_ == " << diskData_ << endl;
}
- bool Submit::validCategory( const QString& c )
+ bool Submit::validCategory( const TQString& c )
{
- QStringList validCategories;
+ TQStringList validCategories;
validCategories << "blues" << "classical" << "country"
<< "data" << "folk" << "jazz" << "misc" << "newage" << "reggae"
<< "rock" << "soundtrack";
diff --git a/libkcddb/submit.h b/libkcddb/submit.h
index 7f4bd29c..877b499a 100644
--- a/libkcddb/submit.h
+++ b/libkcddb/submit.h
@@ -25,7 +25,7 @@
#include "cddb.h"
#include "cdinfo.h"
-#include <qobject.h>
+#include <tqobject.h>
namespace KIO
{
@@ -53,11 +53,11 @@ namespace KCDDB
virtual KIO::Job* createJob(const CDInfo& cdInfo) = 0;
virtual Result runJob(KIO::Job* job) = 0;
- bool validCategory(const QString&);
+ bool validCategory(const TQString&);
- Result parseWrite( const QString & );
+ Result parseWrite( const TQString & );
virtual void makeDiskData( const CDInfo&, const TrackOffsetList& );
- QString diskData_;
+ TQString diskData_;
};
}
diff --git a/libkcddb/synccddbplookup.cpp b/libkcddb/synccddbplookup.cpp
index 6e769d48..b2be7618 100644
--- a/libkcddb/synccddbplookup.cpp
+++ b/libkcddb/synccddbplookup.cpp
@@ -19,7 +19,7 @@
Boston, MA 02110-1301, USA.
*/
-#include <qstringlist.h>
+#include <tqstringlist.h>
#include <kdebug.h>
#include "synccddbplookup.h"
@@ -39,7 +39,7 @@ namespace KCDDB
CDDB::Result
SyncCDDBPLookup::lookup
(
- const QString & hostName,
+ const TQString & hostName,
uint port,
const TrackOffsetList & trackOffsetList
)
@@ -49,7 +49,7 @@ namespace KCDDB
trackOffsetList_ = trackOffsetList;
- socket_ = new KNetwork::KBufferedSocket(hostName, QString::number(port));
+ socket_ = new KNetwork::KBufferedSocket(hostName, TQString::number(port));
socket_->setTimeout( 30000 );
socket_->setOutputBuffering(false);
@@ -117,7 +117,7 @@ namespace KCDDB
CDDB::Result
SyncCDDBPLookup::shakeHands()
{
- QString line = readLine();
+ TQString line = readLine();
if ( !parseGreeting( line ) )
return ServerError;
@@ -144,7 +144,7 @@ namespace KCDDB
sendQuery();
- QString line = readLine();
+ TQString line = readLine();
result = parseQuery( line );
if ( ServerError == result )
@@ -170,13 +170,13 @@ namespace KCDDB
{
sendRead( match );
- QString line = readLine();
+ TQString line = readLine();
Result result = parseRead( line );
if ( Success != result )
return result;
- QStringList lineList;
+ TQStringList lineList;
line = readLine();
while ( !line.startsWith(".") && !line.isNull() )
@@ -202,7 +202,7 @@ namespace KCDDB
if ( !isConnected() )
{
kdDebug(60010) << "socket status: " << socket_->state() << endl;
- return QString::null;
+ return TQString::null;
}
if (!socket_->canReadLine())
@@ -212,10 +212,10 @@ namespace KCDDB
socket_->waitForMore(-1,&timeout);
if (timeout)
- return QString::null;
+ return TQString::null;
}
- return QString::fromUtf8(socket_->readLine());
+ return TQString::fromUtf8(socket_->readLine());
}
}
diff --git a/libkcddb/synccddbplookup.h b/libkcddb/synccddbplookup.h
index e81ed881..75395813 100644
--- a/libkcddb/synccddbplookup.h
+++ b/libkcddb/synccddbplookup.h
@@ -33,7 +33,7 @@ namespace KCDDB
SyncCDDBPLookup();
virtual ~SyncCDDBPLookup();
- Result lookup( const QString &, uint, const TrackOffsetList & );
+ Result lookup( const TQString &, uint, const TrackOffsetList & );
CDInfoList lookupResponse() const;
@@ -43,7 +43,7 @@ namespace KCDDB
Result runQuery();
Result matchToCDInfo( const CDDBMatch & );
- QString readLine();
+ TQString readLine();
};
}
diff --git a/libkcddb/synchttplookup.cpp b/libkcddb/synchttplookup.cpp
index f086de73..fb2c90d7 100644
--- a/libkcddb/synchttplookup.cpp
+++ b/libkcddb/synchttplookup.cpp
@@ -18,8 +18,8 @@
Boston, MA 02110-1301, USA.
*/
-#include <qstringlist.h>
-#include <qapplication.h>
+#include <tqstringlist.h>
+#include <tqapplication.h>
#include <kdebug.h>
#include <kio/job.h>
@@ -42,7 +42,7 @@ namespace KCDDB
CDDB::Result
SyncHTTPLookup::lookup
(
- const QString & hostName,
+ const TQString & hostName,
uint port,
const TrackOffsetList & trackOffsetList
)
@@ -82,7 +82,7 @@ namespace KCDDB
CDDB::Result
SyncHTTPLookup::runQuery()
{
- data_ = QByteArray();
+ data_ = TQByteArray();
state_ = WaitingForQueryResponse;
result_ = sendQuery();
@@ -98,7 +98,7 @@ namespace KCDDB
CDDB::Result
SyncHTTPLookup::matchToCDInfo( const CDDBMatch & match )
{
- data_ = QByteArray();
+ data_ = TQByteArray();
state_ = WaitingForReadResponse;
result_ = sendRead( match );
diff --git a/libkcddb/synchttplookup.h b/libkcddb/synchttplookup.h
index 3c89078a..937a1aa9 100644
--- a/libkcddb/synchttplookup.h
+++ b/libkcddb/synchttplookup.h
@@ -32,7 +32,7 @@ namespace KCDDB
SyncHTTPLookup();
virtual ~SyncHTTPLookup();
- Result lookup( const QString &, uint, const TrackOffsetList & );
+ Result lookup( const TQString &, uint, const TrackOffsetList & );
CDInfoList lookupResponse() const;
diff --git a/libkcddb/synchttpsubmit.cpp b/libkcddb/synchttpsubmit.cpp
index 661382b6..8be4c60b 100644
--- a/libkcddb/synchttpsubmit.cpp
+++ b/libkcddb/synchttpsubmit.cpp
@@ -23,7 +23,7 @@
namespace KCDDB
{
- SyncHTTPSubmit::SyncHTTPSubmit(const QString& from, const QString& hostname, uint port)
+ SyncHTTPSubmit::SyncHTTPSubmit(const TQString& from, const TQString& hostname, uint port)
: HTTPSubmit(from, hostname, port)
{
diff --git a/libkcddb/synchttpsubmit.h b/libkcddb/synchttpsubmit.h
index a88b2895..bd2974ac 100644
--- a/libkcddb/synchttpsubmit.h
+++ b/libkcddb/synchttpsubmit.h
@@ -26,7 +26,7 @@ namespace KCDDB
class SyncHTTPSubmit : public HTTPSubmit
{
public:
- SyncHTTPSubmit(const QString& from, const QString& hostname, uint port);
+ SyncHTTPSubmit(const TQString& from, const TQString& hostname, uint port);
virtual ~SyncHTTPSubmit();
protected:
diff --git a/libkcddb/syncsmtpsubmit.cpp b/libkcddb/syncsmtpsubmit.cpp
index 400aa0c5..717c77a5 100644
--- a/libkcddb/syncsmtpsubmit.cpp
+++ b/libkcddb/syncsmtpsubmit.cpp
@@ -24,8 +24,8 @@
namespace KCDDB
{
- SyncSMTPSubmit::SyncSMTPSubmit(const QString& hostname, uint port,
- const QString& username, const QString& from, const QString& to)
+ SyncSMTPSubmit::SyncSMTPSubmit(const TQString& hostname, uint port,
+ const TQString& username, const TQString& from, const TQString& to)
: SMTPSubmit( hostname, port, username, from, to )
{
diff --git a/libkcddb/syncsmtpsubmit.h b/libkcddb/syncsmtpsubmit.h
index b2ff98e0..57c660f7 100644
--- a/libkcddb/syncsmtpsubmit.h
+++ b/libkcddb/syncsmtpsubmit.h
@@ -26,8 +26,8 @@ namespace KCDDB
class SyncSMTPSubmit : public SMTPSubmit
{
public:
- SyncSMTPSubmit(const QString& hostname, uint port, const QString& username,
- const QString& from, const QString& to);
+ SyncSMTPSubmit(const TQString& hostname, uint port, const TQString& username,
+ const TQString& from, const TQString& to);
virtual ~SyncSMTPSubmit();
protected:
virtual Result runJob(KIO::Job* job);
diff --git a/libkcddb/test/asynccddblookuptest.cpp b/libkcddb/test/asynccddblookuptest.cpp
index afbd326a..ff8c34bb 100644
--- a/libkcddb/test/asynccddblookuptest.cpp
+++ b/libkcddb/test/asynccddblookuptest.cpp
@@ -8,7 +8,7 @@
#include "libkcddb/lookup.h"
AsyncCDDBLookupTest::AsyncCDDBLookupTest()
- : QObject()
+ : TQObject()
{
using namespace KCDDB;
@@ -22,8 +22,8 @@ AsyncCDDBLookupTest::AsyncCDDBLookupTest()
connect
(
client_,
- SIGNAL(finished(CDDB::Result)),
- SLOT(slotFinished(CDDB::Result))
+ TQT_SIGNAL(finished(CDDB::Result)),
+ TQT_SLOT(slotFinished(CDDB::Result))
);
TrackOffsetList list;
diff --git a/libkcddb/test/asynccddblookuptest.h b/libkcddb/test/asynccddblookuptest.h
index 5e0a3efb..db4436e4 100644
--- a/libkcddb/test/asynccddblookuptest.h
+++ b/libkcddb/test/asynccddblookuptest.h
@@ -1,7 +1,7 @@
#ifndef TEST_H
#define TEST_H
-#include <qobject.h>
+#include <tqobject.h>
#include <libkcddb/client.h>
using namespace KCDDB;
diff --git a/libkcddb/test/asynchttplookuptest.cpp b/libkcddb/test/asynchttplookuptest.cpp
index 610d9fab..174525bb 100644
--- a/libkcddb/test/asynchttplookuptest.cpp
+++ b/libkcddb/test/asynchttplookuptest.cpp
@@ -7,7 +7,7 @@
#include "libkcddb/lookup.h"
AsyncHTTPLookupTest::AsyncHTTPLookupTest()
- : QObject()
+ : TQObject()
{
using namespace KCDDB;
@@ -21,8 +21,8 @@ AsyncHTTPLookupTest::AsyncHTTPLookupTest()
connect
(
client_,
- SIGNAL(finished(CDDB::Result)),
- SLOT(slotFinished(CDDB::Result))
+ TQT_SIGNAL(finished(CDDB::Result)),
+ TQT_SLOT(slotFinished(CDDB::Result))
);
TrackOffsetList list;
diff --git a/libkcddb/test/asynchttplookuptest.h b/libkcddb/test/asynchttplookuptest.h
index c8e3e86c..7649f204 100644
--- a/libkcddb/test/asynchttplookuptest.h
+++ b/libkcddb/test/asynchttplookuptest.h
@@ -1,7 +1,7 @@
#ifndef TEST_H
#define TEST_H
-#include <qobject.h>
+#include <tqobject.h>
#include <libkcddb/client.h>
using namespace KCDDB;
diff --git a/libkcddb/test/asynchttpsubmittest.cpp b/libkcddb/test/asynchttpsubmittest.cpp
index 9981f8a7..d0923b27 100644
--- a/libkcddb/test/asynchttpsubmittest.cpp
+++ b/libkcddb/test/asynchttpsubmittest.cpp
@@ -6,7 +6,7 @@
#include "libkcddb/submit.h"
AsyncHTTPSubmitTest::AsyncHTTPSubmitTest()
- : QObject()
+ : TQObject()
{
using namespace KCDDB;
@@ -34,7 +34,7 @@ AsyncHTTPSubmitTest::AsyncHTTPSubmitTest()
cdInfo.year = 2001;
cdInfo.category = "misc";
cdInfo.genre = "Barnsaga";
- cdInfo.extd = QString::fromUtf8("Berättare: Olof Thunberg");
+ cdInfo.extd = TQString::fromUtf8("Berättare: Olof Thunberg");
TrackInfo info;
info.title = "Bamses signaturmelodi";
@@ -45,14 +45,14 @@ AsyncHTTPSubmitTest::AsyncHTTPSubmitTest()
cdInfo.trackInfoList.append(info);
info.title = "*";
cdInfo.trackInfoList.append(info);
- info.title = QString::fromUtf8("Jätteödlan Bronto");
+ info.title = TQString::fromUtf8("Jätteödlan Bronto");
cdInfo.trackInfoList.append(info);
connect
(
client_,
- SIGNAL(finished(CDDB::Result)),
- SLOT(slotFinished(CDDB::Result))
+ TQT_SIGNAL(finished(CDDB::Result)),
+ TQT_SLOT(slotFinished(CDDB::Result))
);
client_->submit(cdInfo, list);
diff --git a/libkcddb/test/asynchttpsubmittest.h b/libkcddb/test/asynchttpsubmittest.h
index 27053836..6cce8ed2 100644
--- a/libkcddb/test/asynchttpsubmittest.h
+++ b/libkcddb/test/asynchttpsubmittest.h
@@ -1,7 +1,7 @@
#ifndef TEST_H
#define TEST_H
-#include <qobject.h>
+#include <tqobject.h>
#include <libkcddb/client.h>
using namespace KCDDB;
diff --git a/libkcddb/test/asyncsmtpsubmittest.cpp b/libkcddb/test/asyncsmtpsubmittest.cpp
index 224288e3..89c0ad50 100644
--- a/libkcddb/test/asyncsmtpsubmittest.cpp
+++ b/libkcddb/test/asyncsmtpsubmittest.cpp
@@ -6,7 +6,7 @@
#include "libkcddb/submit.h"
AsyncSMTPSubmitTest::AsyncSMTPSubmitTest()
- : QObject()
+ : TQObject()
{
using namespace KCDDB;
@@ -35,7 +35,7 @@ AsyncSMTPSubmitTest::AsyncSMTPSubmitTest()
cdInfo.year = 2001;
cdInfo.category = "misc";
cdInfo.genre = "Barnsaga";
- cdInfo.extd = QString::fromUtf8("Berättare: Olof Thunberg");
+ cdInfo.extd = TQString::fromUtf8("Berättare: Olof Thunberg");
TrackInfo info;
info.title = "Bamses signaturmelodi";
@@ -46,14 +46,14 @@ AsyncSMTPSubmitTest::AsyncSMTPSubmitTest()
cdInfo.trackInfoList.append(info);
info.title = "*";
cdInfo.trackInfoList.append(info);
- info.title = QString::fromUtf8("Jätteödlan Bronto");
+ info.title = TQString::fromUtf8("Jätteödlan Bronto");
cdInfo.trackInfoList.append(info);
connect
(
client_,
- SIGNAL(finished(CDDB::Result)),
- SLOT(slotFinished(CDDB::Result))
+ TQT_SIGNAL(finished(CDDB::Result)),
+ TQT_SLOT(slotFinished(CDDB::Result))
);
client_->submit(cdInfo, list);
diff --git a/libkcddb/test/asyncsmtpsubmittest.h b/libkcddb/test/asyncsmtpsubmittest.h
index 3528798d..0e6f445e 100644
--- a/libkcddb/test/asyncsmtpsubmittest.h
+++ b/libkcddb/test/asyncsmtpsubmittest.h
@@ -1,7 +1,7 @@
#ifndef TEST_H
#define TEST_H
-#include <qobject.h>
+#include <tqobject.h>
#include <libkcddb/client.h>
using namespace KCDDB;
diff --git a/libkcddb/test/sitestest.cpp b/libkcddb/test/sitestest.cpp
index cd2faaca..6188665d 100644
--- a/libkcddb/test/sitestest.cpp
+++ b/libkcddb/test/sitestest.cpp
@@ -36,8 +36,8 @@ main(int argc, char ** argv)
kdDebug() << "Sites: " << endl;
- QValueList<Mirror> sites = s.siteList();
- for (QValueList<Mirror>::Iterator it = sites.begin(); it != sites.end(); ++it)
+ TQValueList<Mirror> sites = s.siteList();
+ for (TQValueList<Mirror>::Iterator it = sites.begin(); it != sites.end(); ++it)
if ((*it).transport == Lookup::CDDBP)
kdDebug() << (*it).address << " CDDBP " << (*it).port << " " << (*it).description << endl;
else
diff --git a/libkcddb/test/synchttpsubmittest.cpp b/libkcddb/test/synchttpsubmittest.cpp
index 79fab86c..d6c17eaf 100644
--- a/libkcddb/test/synchttpsubmittest.cpp
+++ b/libkcddb/test/synchttpsubmittest.cpp
@@ -54,7 +54,7 @@ main(int argc, char ** argv)
cdInfo.year = 2001;
cdInfo.category = "misc";
cdInfo.genre = "Barnsaga";
- cdInfo.extd = QString::fromUtf8("Berättare: Olof Thunberg");
+ cdInfo.extd = TQString::fromUtf8("Berättare: Olof Thunberg");
TrackInfo info;
info.title = "Bamses signaturmelodi";
@@ -65,7 +65,7 @@ main(int argc, char ** argv)
cdInfo.trackInfoList.append(info);
info.title = "*";
cdInfo.trackInfoList.append(info);
- info.title = QString::fromUtf8("Jätteödlan Bronto");
+ info.title = TQString::fromUtf8("Jätteödlan Bronto");
cdInfo.trackInfoList.append(info);
Client c;
diff --git a/libkcddb/test/syncsmtpsubmittest.cpp b/libkcddb/test/syncsmtpsubmittest.cpp
index 75935848..4af365bb 100644
--- a/libkcddb/test/syncsmtpsubmittest.cpp
+++ b/libkcddb/test/syncsmtpsubmittest.cpp
@@ -54,7 +54,7 @@ main(int argc, char ** argv)
cdInfo.year = 2001;
cdInfo.category = "misc";
cdInfo.genre = "Barnsaga";
- cdInfo.extd = QString::fromUtf8("Berättare: Olof Thunberg");
+ cdInfo.extd = TQString::fromUtf8("Berättare: Olof Thunberg");
TrackInfo info;
info.title = "Bamses signaturmelodi";
@@ -65,7 +65,7 @@ main(int argc, char ** argv)
cdInfo.trackInfoList.append(info);
info.title = "*";
cdInfo.trackInfoList.append(info);
- info.title = QString::fromUtf8("Jätteödlan Bronto");
+ info.title = TQString::fromUtf8("Jätteödlan Bronto");
cdInfo.trackInfoList.append(info);
Client c;