summaryrefslogtreecommitdiffstats
path: root/parts/documentation/protocols/chm/chmfile.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'parts/documentation/protocols/chm/chmfile.cpp')
-rw-r--r--parts/documentation/protocols/chm/chmfile.cpp20
1 files changed, 10 insertions, 10 deletions
diff --git a/parts/documentation/protocols/chm/chmfile.cpp b/parts/documentation/protocols/chm/chmfile.cpp
index 6106d83d..43ae8877 100644
--- a/parts/documentation/protocols/chm/chmfile.cpp
+++ b/parts/documentation/protocols/chm/chmfile.cpp
@@ -14,11 +14,11 @@
Boston, MA 02110-1301, USA.
*/
-#include <qfile.h>
+#include <tqfile.h>
#include "chmfile.h"
#include "decompress.h"
-uint Chm::getEncInt(QFile& f, uint &value) const
+uint Chm::getEncInt(TQFile& f, uint &value) const
{
int c;
uint result = 0;
@@ -36,32 +36,32 @@ uint Chm::getEncInt(QFile& f, uint &value) const
return count;
}
-uint Chm::getName(QFile& f, QString& name) const
+uint Chm::getName(TQFile& f, TQString& name) const
{
int len = f.getch();
char *buf = new char[len];
f.readBlock(buf, len);
- name = QString::fromUtf8(buf, len);
+ name = TQString::fromUtf8(buf, len);
if (name.startsWith("/"))
name = name.lower();
delete [] buf;
return len + 1;
}
-uint Chm::getIntel32(QFile& f) const
+uint Chm::getIntel32(TQFile& f) const
{
uint value = f.getch() | f.getch() << 8 | f.getch() << 16 | f.getch() << 24;
return value;
}
-uint Chm::getIntel64(QFile& f) const
+uint Chm::getIntel64(TQFile& f) const
{
uint value = getIntel32(f);
f.at(f.at() + 4);
return value;
}
-bool Chm::getChunk(QFile& f, uint chunkSize, ChmDirectoryMap& directoryMap) const
+bool Chm::getChunk(TQFile& f, uint chunkSize, ChmDirectoryMap& directoryMap) const
{
char tag[4];
if (f.readBlock(tag, 4) != 4) return false;
@@ -75,7 +75,7 @@ bool Chm::getChunk(QFile& f, uint chunkSize, ChmDirectoryMap& directoryMap) cons
while (pos < chunkSize - quickref_length)
{
uint section, offset, length;
- QString name;
+ TQString name;
pos += getName(f, name);
pos += getEncInt(f, section);
pos += getEncInt(f, offset);
@@ -98,9 +98,9 @@ bool Chm::getChunk(QFile& f, uint chunkSize, ChmDirectoryMap& directoryMap) cons
}
}
-bool Chm::read(const QString& fileSpec, ChmDirectoryMap& dirMap, QByteArray& contents) const
+bool Chm::read(const TQString& fileSpec, ChmDirectoryMap& dirMap, TQByteArray& contents) const
{
- QFile f(fileSpec);
+ TQFile f(fileSpec);
if (!f.open(IO_ReadOnly)) return false;
// read CHM file header