summaryrefslogtreecommitdiffstats
path: root/kdecore/tests/kmdcodectest.cpp
diff options
context:
space:
mode:
authortpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2010-07-31 19:46:43 +0000
committertpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2010-07-31 19:46:43 +0000
commitffe8a83e053396df448e9413828527613ca3bd46 (patch)
treea73d4169e02df4a50f9a12cb165fcd0ab5bac7c6 /kdecore/tests/kmdcodectest.cpp
parent682bf3bfdcbcbb1fca85e8a36ed03e062e0555d5 (diff)
downloadtdelibs-ffe8a83e053396df448e9413828527613ca3bd46.tar.gz
tdelibs-ffe8a83e053396df448e9413828527613ca3bd46.zip
Trinity Qt initial conversion
git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdelibs@1157647 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'kdecore/tests/kmdcodectest.cpp')
-rw-r--r--kdecore/tests/kmdcodectest.cpp26
1 files changed, 13 insertions, 13 deletions
diff --git a/kdecore/tests/kmdcodectest.cpp b/kdecore/tests/kmdcodectest.cpp
index 1156f03f2..243d0d289 100644
--- a/kdecore/tests/kmdcodectest.cpp
+++ b/kdecore/tests/kmdcodectest.cpp
@@ -23,8 +23,8 @@
#include <iostream>
-#include <qbuffer.h>
-#include <qfile.h>
+#include <tqbuffer.h>
+#include <tqfile.h>
#include <kdebug.h>
#include <klocale.h>
@@ -57,7 +57,7 @@ void MD5_verify (const char*, const char*, bool);
void MD5_file (const char * , bool rawOutput = false);
void MD5_string (const char *, const char *expected = 0, bool rawOutput = false);
-long readContent (const QFile& f, long count, QByteArray& buf)
+long readContent (const TQFile& f, long count, TQByteArray& buf)
{
long result;
int old_size;
@@ -85,14 +85,14 @@ long readContent (const QFile& f, long count, QByteArray& buf)
void testCodec (const char* msg, Codec type, bool isFile)
{
- QByteArray output;
+ TQByteArray output;
if ( isFile )
{
int count;
- QByteArray data;
+ TQByteArray data;
- QFile f (QFile::encodeName(msg));
+ TQFile f (TQFile::encodeName(msg));
if (!f.exists())
{
@@ -147,12 +147,12 @@ void testCodec (const char* msg, Codec type, bool isFile)
break;
}
- QCString result (output.data(), output.size()+1);
+ TQCString result (output.data(), output.size()+1);
cout << "Result: " << endl << result << endl;
}
else
{
- QCString result;
+ TQCString result;
const size_t len = strlen(msg);
output.resize(len);
@@ -246,13 +246,13 @@ void MD5_verify( const char *input, const char *digest, bool isFile )
if ( !isFile )
{
- context.update (QCString(input));
+ context.update (TQCString(input));
result = context.verify( digest );
cout << "Input string: " << input << endl;
}
else
{
- QFile f (input);
+ TQFile f (input);
if (!f.open (IO_ReadOnly))
{
@@ -273,7 +273,7 @@ void MD5_verify( const char *input, const char *digest, bool isFile )
void MD5_file (const char *filename, bool rawOutput )
{
- QFile f (QFile::encodeName(filename));
+ TQFile f (TQFile::encodeName(filename));
if (!f.open(IO_ReadOnly))
{
@@ -296,7 +296,7 @@ void MD5_file (const char *filename, bool rawOutput )
void MD5_string (const char *input, const char* expected, bool rawOutput )
{
KMD5 context;
- context.update (QCString(input));
+ context.update (TQCString(input));
cout << "Checking MD5 for: " << input << endl;
@@ -372,7 +372,7 @@ int main (int argc, char *argv[])
{
const char* opt = args->getOption( "c" ).data();
for ( int i=0 ; i < count; i++ )
- MD5_verify ( QCString(args->arg(i)), opt, (isString || !isFile) );
+ MD5_verify ( TQCString(args->arg(i)), opt, (isString || !isFile) );
}
else
{