summaryrefslogtreecommitdiffstats
path: root/kmail/filterlog.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'kmail/filterlog.cpp')
-rw-r--r--kmail/filterlog.cpp28
1 files changed, 14 insertions, 14 deletions
diff --git a/kmail/filterlog.cpp b/kmail/filterlog.cpp
index 23848dfb..7415c10d 100644
--- a/kmail/filterlog.cpp
+++ b/kmail/filterlog.cpp
@@ -31,8 +31,8 @@
#include <kdebug.h>
-#include <qdatetime.h>
-#include <qfile.h>
+#include <tqdatetime.h>
+#include <tqfile.h>
#include <sys/stat.h>
@@ -68,11 +68,11 @@ FilterLog * FilterLog::instance()
}
-void FilterLog::add( QString logEntry, ContentType contentType )
+void FilterLog::add( TQString logEntry, ContentType contentType )
{
if ( isLogging() && ( mAllowedTypes & contentType ) )
{
- QString timedLog = "[" + QTime::currentTime().toString() + "] ";
+ TQString timedLog = "[" + TQTime::currentTime().toString() + "] ";
if ( contentType & ~meta )
timedLog += logEntry;
else
@@ -102,7 +102,7 @@ void FilterLog::dump()
{
#ifndef NDEBUG
kdDebug(5006) << "----- starting filter log -----" << endl;
- for ( QStringList::Iterator it = mLogEntries.begin();
+ for ( TQStringList::Iterator it = mLogEntries.begin();
it != mLogEntries.end(); ++it )
{
kdDebug(5006) << *it << endl;
@@ -117,17 +117,17 @@ void FilterLog::checkLogSize()
if ( mCurrentLogSize > mMaxLogSize && mMaxLogSize > -1 )
{
kdDebug(5006) << "Filter log: memory limit reached, starting to discard old items, size = "
- << QString::number( mCurrentLogSize ) << endl;
+ << TQString::number( mCurrentLogSize ) << endl;
// avoid some kind of hysteresis, shrink the log to 90% of its maximum
while ( mCurrentLogSize > ( mMaxLogSize * 0.9 ) )
{
- QValueListIterator<QString> it = mLogEntries.begin();
+ TQValueListIterator<TQString> it = mLogEntries.begin();
if ( it != mLogEntries.end())
{
mCurrentLogSize -= (*it).length();
mLogEntries.remove( it );
kdDebug(5006) << "Filter log: new size = "
- << QString::number( mCurrentLogSize ) << endl;
+ << TQString::number( mCurrentLogSize ) << endl;
}
else
{
@@ -140,18 +140,18 @@ void FilterLog::checkLogSize()
}
-bool FilterLog::saveToFile( QString fileName )
+bool FilterLog::saveToFile( TQString fileName )
{
- QFile file( fileName );
+ TQFile file( fileName );
if( file.open( IO_WriteOnly ) ) {
fchmod( file.handle(), S_IRUSR | S_IWUSR );
{
- QDataStream ds( &file );
- for ( QStringList::Iterator it = mLogEntries.begin();
+ TQDataStream ds( &file );
+ for ( TQStringList::Iterator it = mLogEntries.begin();
it != mLogEntries.end(); ++it )
{
- QString tmpString = *it + '\n';
- QCString cstr( tmpString.local8Bit() );
+ TQString tmpString = *it + '\n';
+ TQCString cstr( tmpString.local8Bit() );
ds.writeRawBytes( cstr, cstr.size() );
}
}