From 7be55ffa061c026e35e2d6a0effe1161ddb0d41f Mon Sep 17 00:00:00 2001 From: tpearson Date: Sat, 31 Jul 2010 19:53:50 +0000 Subject: Trinity Qt initial conversion git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdepim@1157655 283d02a7-25f6-0310-bc7c-ecb5cbfe19da --- kmail/filterlogdlg.cpp | 114 ++++++++++++++++++++++++------------------------- 1 file changed, 57 insertions(+), 57 deletions(-) (limited to 'kmail/filterlogdlg.cpp') diff --git a/kmail/filterlogdlg.cpp b/kmail/filterlogdlg.cpp index a10a056ec..90eb59263 100644 --- a/kmail/filterlogdlg.cpp +++ b/kmail/filterlogdlg.cpp @@ -36,14 +36,14 @@ #include #include -#include -#include -#include -#include -#include -#include -#include -#include +#include +#include +#include +#include +#include +#include +#include +#include #include #include @@ -52,56 +52,56 @@ using namespace KMail; -FilterLogDialog::FilterLogDialog( QWidget * parent ) +FilterLogDialog::FilterLogDialog( TQWidget * parent ) : KDialogBase( parent, "FilterLogDlg", false, i18n( "Filter Log Viewer" ), User1|User2|Close, Close, true, KStdGuiItem::clear(), KStdGuiItem::saveAs() ) { setWFlags( WDestructiveClose ); - QVBox *page = makeVBoxMainWidget(); + TQVBox *page = makeVBoxMainWidget(); - mTextEdit = new QTextEdit( page ); + mTextEdit = new TQTextEdit( page ); mTextEdit->setReadOnly( true ); - mTextEdit->setWordWrap( QTextEdit::NoWrap ); - mTextEdit->setTextFormat( QTextEdit::LogText ); + mTextEdit->setWordWrap( TQTextEdit::NoWrap ); + mTextEdit->setTextFormat( TQTextEdit::LogText ); - QStringList logEntries = FilterLog::instance()->getLogEntries(); - for ( QStringList::Iterator it = logEntries.begin(); + TQStringList logEntries = FilterLog::instance()->getLogEntries(); + for ( TQStringList::Iterator it = logEntries.begin(); it != logEntries.end(); ++it ) { mTextEdit->append( *it ); } - mLogActiveBox = new QCheckBox( i18n("&Log filter activities"), page ); + mLogActiveBox = new TQCheckBox( i18n("&Log filter activities"), page ); mLogActiveBox->setChecked( FilterLog::instance()->isLogging() ); - connect( mLogActiveBox, SIGNAL(clicked()), - this, SLOT(slotSwitchLogState(void)) ); - QWhatsThis::add( mLogActiveBox, + connect( mLogActiveBox, TQT_SIGNAL(clicked()), + this, TQT_SLOT(slotSwitchLogState(void)) ); + TQWhatsThis::add( mLogActiveBox, i18n( "You can turn logging of filter activities on and off here. " "Of course, log data is collected and shown only when logging " "is turned on. " ) ); - mLogDetailsBox = new QVGroupBox( i18n( "Logging Details" ), page ); + mLogDetailsBox = new TQVGroupBox( i18n( "Logging Details" ), page ); mLogDetailsBox->setEnabled( mLogActiveBox->isChecked() ); - connect( mLogActiveBox, SIGNAL( toggled( bool ) ), - mLogDetailsBox, SLOT( setEnabled( bool ) ) ); + connect( mLogActiveBox, TQT_SIGNAL( toggled( bool ) ), + mLogDetailsBox, TQT_SLOT( setEnabled( bool ) ) ); - mLogPatternDescBox = new QCheckBox( i18n("Log pattern description"), + mLogPatternDescBox = new TQCheckBox( i18n("Log pattern description"), mLogDetailsBox ); mLogPatternDescBox->setChecked( FilterLog::instance()->isContentTypeEnabled( FilterLog::patternDesc ) ); - connect( mLogPatternDescBox, SIGNAL(clicked()), - this, SLOT(slotChangeLogDetail(void)) ); + connect( mLogPatternDescBox, TQT_SIGNAL(clicked()), + this, TQT_SLOT(slotChangeLogDetail(void)) ); // TODO - //QWhatsThis::add( mLogPatternDescBox, + //TQWhatsThis::add( mLogPatternDescBox, // i18n( "" ) ); - mLogRuleEvaluationBox = new QCheckBox( i18n("Log filter &rule evaluation"), + mLogRuleEvaluationBox = new TQCheckBox( i18n("Log filter &rule evaluation"), mLogDetailsBox ); mLogRuleEvaluationBox->setChecked( FilterLog::instance()->isContentTypeEnabled( FilterLog::ruleResult ) ); - connect( mLogRuleEvaluationBox, SIGNAL(clicked()), - this, SLOT(slotChangeLogDetail(void)) ); - QWhatsThis::add( mLogRuleEvaluationBox, + connect( mLogRuleEvaluationBox, TQT_SIGNAL(clicked()), + this, TQT_SLOT(slotChangeLogDetail(void)) ); + TQWhatsThis::add( mLogRuleEvaluationBox, i18n( "You can control the feedback in the log concerning the " "evaluation of the filter rules of applied filters: " "having this option checked will give detailed feedback " @@ -109,52 +109,52 @@ FilterLogDialog::FilterLogDialog( QWidget * parent ) "feedback about the result of the evaluation of all rules " "of a single filter will be given." ) ); - mLogPatternResultBox = new QCheckBox( i18n("Log filter pattern evaluation"), + mLogPatternResultBox = new TQCheckBox( i18n("Log filter pattern evaluation"), mLogDetailsBox ); mLogPatternResultBox->setChecked( FilterLog::instance()->isContentTypeEnabled( FilterLog::patternResult ) ); - connect( mLogPatternResultBox, SIGNAL(clicked()), - this, SLOT(slotChangeLogDetail(void)) ); + connect( mLogPatternResultBox, TQT_SIGNAL(clicked()), + this, TQT_SLOT(slotChangeLogDetail(void)) ); // TODO - //QWhatsThis::add( mLogPatternResultBox, + //TQWhatsThis::add( mLogPatternResultBox, // i18n( "" ) ); - mLogFilterActionBox = new QCheckBox( i18n("Log filter actions"), + mLogFilterActionBox = new TQCheckBox( i18n("Log filter actions"), mLogDetailsBox ); mLogFilterActionBox->setChecked( FilterLog::instance()->isContentTypeEnabled( FilterLog::appliedAction ) ); - connect( mLogFilterActionBox, SIGNAL(clicked()), - this, SLOT(slotChangeLogDetail(void)) ); + connect( mLogFilterActionBox, TQT_SIGNAL(clicked()), + this, TQT_SLOT(slotChangeLogDetail(void)) ); // TODO - //QWhatsThis::add( mLogFilterActionBox, + //TQWhatsThis::add( mLogFilterActionBox, // i18n( "" ) ); - QHBox * hbox = new QHBox( page ); - new QLabel( i18n("Log size limit:"), hbox ); - mLogMemLimitSpin = new QSpinBox( hbox ); + TQHBox * hbox = new TQHBox( page ); + new TQLabel( i18n("Log size limit:"), hbox ); + mLogMemLimitSpin = new TQSpinBox( hbox ); mLogMemLimitSpin->setMinValue( 1 ); mLogMemLimitSpin->setMaxValue( 1024 * 256 ); // 256 MB - // value in the QSpinBox is in KB while it's in Byte in the FilterLog + // value in the TQSpinBox is in KB while it's in Byte in the FilterLog mLogMemLimitSpin->setValue( FilterLog::instance()->getMaxLogSize() / 1024 ); mLogMemLimitSpin->setSuffix( " KB" ); mLogMemLimitSpin->setSpecialValueText( i18n("unlimited") ); - connect( mLogMemLimitSpin, SIGNAL(valueChanged(int)), - this, SLOT(slotChangeLogMemLimit(int)) ); - QWhatsThis::add( mLogMemLimitSpin, + connect( mLogMemLimitSpin, TQT_SIGNAL(valueChanged(int)), + this, TQT_SLOT(slotChangeLogMemLimit(int)) ); + TQWhatsThis::add( mLogMemLimitSpin, i18n( "Collecting log data uses memory to temporarily store the " "log data; here you can limit the maximum amount of memory " "to be used: if the size of the collected log data exceeds " "this limit then the oldest data will be discarded until " "the limit is no longer exceeded. " ) ); - connect(FilterLog::instance(), SIGNAL(logEntryAdded(QString)), - this, SLOT(slotLogEntryAdded(QString))); - connect(FilterLog::instance(), SIGNAL(logShrinked(void)), - this, SLOT(slotLogShrinked(void))); - connect(FilterLog::instance(), SIGNAL(logStateChanged(void)), - this, SLOT(slotLogStateChanged(void))); + connect(FilterLog::instance(), TQT_SIGNAL(logEntryAdded(TQString)), + this, TQT_SLOT(slotLogEntryAdded(TQString))); + connect(FilterLog::instance(), TQT_SIGNAL(logShrinked(void)), + this, TQT_SLOT(slotLogShrinked(void))); + connect(FilterLog::instance(), TQT_SIGNAL(logStateChanged(void)), + this, TQT_SLOT(slotLogStateChanged(void))); - setInitialSize( QSize( 500, 500 ) ); + setInitialSize( TQSize( 500, 500 ) ); #if !KDE_IS_VERSION( 3, 2, 91 ) // HACK - KWin keeps all dialogs on top of their mainwindows, but that's probably // wrong (#76026), and should be done only for modals. CVS HEAD should get @@ -164,7 +164,7 @@ FilterLogDialog::FilterLogDialog( QWidget * parent ) } -void FilterLogDialog::slotLogEntryAdded( QString logEntry ) +void FilterLogDialog::slotLogEntryAdded( TQString logEntry ) { mTextEdit->append( logEntry ); } @@ -191,7 +191,7 @@ void FilterLogDialog::slotLogStateChanged() mLogFilterActionBox->setChecked( FilterLog::instance()->isContentTypeEnabled( FilterLog::appliedAction ) ); - // value in the QSpinBox is in KB while it's in Byte in the FilterLog + // value in the TQSpinBox is in KB while it's in Byte in the FilterLog int newLogSize = FilterLog::instance()->getMaxLogSize() / 1024; if ( mLogMemLimitSpin->value() != newLogSize ) mLogMemLimitSpin->setValue( newLogSize ); @@ -243,8 +243,8 @@ void FilterLogDialog::slotUser1() void FilterLogDialog::slotUser2() { - QString fileName; - KFileDialog fdlg( QString::null, QString::null, this, 0, true ); + TQString fileName; + KFileDialog fdlg( TQString::null, TQString::null, this, 0, true ); fdlg.setMode( KFile::File ); fdlg.setSelection( "kmail-filter.log" ); @@ -258,7 +258,7 @@ void FilterLogDialog::slotUser2() i18n( "Could not write the file %1:\n" "\"%2\" is the detailed error description." ) .arg( fileName, - QString::fromLocal8Bit( strerror( errno ) ) ), + TQString::fromLocal8Bit( strerror( errno ) ) ), i18n( "KMail Error" ) ); } } -- cgit v1.2.1