summaryrefslogtreecommitdiffstats
path: root/libktorrent/util/file.cpp
diff options
context:
space:
mode:
authortpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2011-06-28 20:34:15 +0000
committertpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2011-06-28 20:34:15 +0000
commit1c1403293485f35fd53db45aaa77a01cdd9627e7 (patch)
tree38559cd68cd4f63023fb5f6375def9db3b8b491e /libktorrent/util/file.cpp
parent894f94545727610df22c4f73911d62d58266f695 (diff)
downloadktorrent-1c1403293485f35fd53db45aaa77a01cdd9627e7.tar.gz
ktorrent-1c1403293485f35fd53db45aaa77a01cdd9627e7.zip
TQt4 port ktorrent
This enables compilation under both Qt3 and Qt4 git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/applications/ktorrent@1238733 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'libktorrent/util/file.cpp')
-rw-r--r--libktorrent/util/file.cpp16
1 files changed, 8 insertions, 8 deletions
diff --git a/libktorrent/util/file.cpp b/libktorrent/util/file.cpp
index b898e07..f757142 100644
--- a/libktorrent/util/file.cpp
+++ b/libktorrent/util/file.cpp
@@ -22,7 +22,7 @@
#include <config.h>
#endif
-#include <qfile.h>
+#include <tqfile.h>
#include "config.h"
#include <klocale.h>
#include <string.h>
@@ -45,15 +45,15 @@ namespace bt
close();
}
- bool File::open(const QString & file,const QString & mode)
+ bool File::open(const TQString & file,const TQString & mode)
{
this->file = file;
if (fptr)
close();
#if HAVE_FOPEN64
- fptr = fopen64(QFile::encodeName(file),mode.ascii());
+ fptr = fopen64(TQFile::encodeName(file),mode.ascii());
#else
- fptr = fopen(QFile::encodeName(file),mode.ascii());
+ fptr = fopen(TQFile::encodeName(file),mode.ascii());
#endif
return fptr != 0;
}
@@ -84,7 +84,7 @@ namespace bt
if (errno == ENOSPC)
Out() << "Disk full !" << endl;
- throw Error(i18n("Cannot write to %1 : %2").arg(file).arg(strerror(errno)));
+ throw Error(i18n("Cannot write to %1 : %2").tqarg(file).tqarg(strerror(errno)));
}
return ret;
}
@@ -98,7 +98,7 @@ namespace bt
if (ferror(fptr))
{
clearerr(fptr);
- throw Error(i18n("Cannot read from %1").arg(file));
+ throw Error(i18n("Cannot read from %1").tqarg(file));
}
return ret;
}
@@ -143,8 +143,8 @@ namespace bt
return ftello(fptr);
}
- QString File::errorString() const
+ TQString File::errorString() const
{
- return QString(strerror(errno));
+ return TQString(strerror(errno));
}
}