summaryrefslogtreecommitdiffstats
path: root/libk3b/cddb/k3bcddblocalsubmit.cpp
diff options
context:
space:
mode:
authortpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2011-05-27 19:21:21 +0000
committertpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2011-05-27 19:21:21 +0000
commitd8cc8bdfa7fa624a526d5aa1626974e1444cb799 (patch)
treef295f1c545b319963d5357af79fe08991d8141d9 /libk3b/cddb/k3bcddblocalsubmit.cpp
parent2a39a080579fb52a2599c02b2939795385b89093 (diff)
downloadk3b-d8cc8bdfa7fa624a526d5aa1626974e1444cb799.tar.gz
k3b-d8cc8bdfa7fa624a526d5aa1626974e1444cb799.zip
TQt4 port k3b
This enables compilation under both Qt3 and Qt4 git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/applications/k3b@1233803 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'libk3b/cddb/k3bcddblocalsubmit.cpp')
-rw-r--r--libk3b/cddb/k3bcddblocalsubmit.cpp32
1 files changed, 16 insertions, 16 deletions
diff --git a/libk3b/cddb/k3bcddblocalsubmit.cpp b/libk3b/cddb/k3bcddblocalsubmit.cpp
index f2d1e69..ed1fdcb 100644
--- a/libk3b/cddb/k3bcddblocalsubmit.cpp
+++ b/libk3b/cddb/k3bcddblocalsubmit.cpp
@@ -17,16 +17,16 @@
#include "k3bcddblocalsubmit.h"
-#include <qdir.h>
-#include <qfile.h>
-#include <qtextstream.h>
+#include <tqdir.h>
+#include <tqfile.h>
+#include <tqtextstream.h>
#include <kdebug.h>
#include <klocale.h>
-K3bCddbLocalSubmit::K3bCddbLocalSubmit( QObject* parent, const char* name )
- : K3bCddbSubmit( parent, name )
+K3bCddbLocalSubmit::K3bCddbLocalSubmit( TQObject* tqparent, const char* name )
+ : K3bCddbSubmit( tqparent, name )
{
}
@@ -38,29 +38,29 @@ K3bCddbLocalSubmit::~K3bCddbLocalSubmit()
void K3bCddbLocalSubmit::doSubmit()
{
- QString path = m_cddbDir;
+ TQString path = m_cddbDir;
if( path.startsWith( "~" ) )
- path.replace( 0, 1, QDir::homeDirPath() + "/" );
+ path.tqreplace( 0, 1, TQDir::homeDirPath() + "/" );
else if( !path.startsWith( "/" ) )
- path.prepend( QDir::homeDirPath() + "/" );
+ path.prepend( TQDir::homeDirPath() + "/" );
if( path[path.length()-1] != '/' )
path.append( "/" );
- if( !QFile::exists( path ) && !QDir().mkdir( path ) ) {
+ if( !TQFile::exists( path ) && !TQDir().mkdir( path ) ) {
kdDebug() << "(K3bCddbLocalSubmit) could not create directory: " << path << endl;
setError( IO_ERROR );
emit submitFinished( this );
return;
}
- if( QFile::exists( path ) ) {
+ if( TQFile::exists( path ) ) {
// if the category dir does not exists
// create it
path += resultEntry().category;
- if( !QFile::exists( path ) ) {
- if( !QDir().mkdir( path ) ) {
+ if( !TQFile::exists( path ) ) {
+ if( !TQDir().mkdir( path ) ) {
kdDebug() << "(K3bCddbLocalSubmit) could not create directory: " << path << endl;
setError( IO_ERROR );
emit submitFinished( this );
@@ -70,7 +70,7 @@ void K3bCddbLocalSubmit::doSubmit()
// we always overwrite existing entries
path += "/" + resultEntry().discid;
- QFile entryFile( path );
+ TQFile entryFile( path );
if( entryFile.exists() ) {
kdDebug() << "(K3bCddbLocalSubmit) file already exists: " << path << endl;
}
@@ -82,8 +82,8 @@ void K3bCddbLocalSubmit::doSubmit()
}
else {
kdDebug() << "(K3bCddbLocalSubmit) creating file: " << path << endl;
- QTextStream entryStream( &entryFile );
- entryStream.setEncoding( QTextStream::UnicodeUTF8 );
+ TQTextStream entryStream( &entryFile );
+ entryStream.setEncoding( TQTextStream::UnicodeUTF8 );
entryStream << resultEntry().rawData;
entryFile.close();
@@ -94,7 +94,7 @@ void K3bCddbLocalSubmit::doSubmit()
else {
kdDebug() << "(K3bCddbLocalSubmit) could not find directory: " << path << endl;
setError( IO_ERROR );
- emit infoMessage( i18n("Could not find directory: %1").arg(path) );
+ emit infoMessage( i18n("Could not find directory: %1").tqarg(path) );
emit submitFinished( this );
}
}