summaryrefslogtreecommitdiffstats
path: root/languages/java/problemreporter.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'languages/java/problemreporter.cpp')
-rw-r--r--languages/java/problemreporter.cpp88
1 files changed, 44 insertions, 44 deletions
diff --git a/languages/java/problemreporter.cpp b/languages/java/problemreporter.cpp
index e7cbbcb5..a5beaaf2 100644
--- a/languages/java/problemreporter.cpp
+++ b/languages/java/problemreporter.cpp
@@ -43,26 +43,26 @@
#include <kconfig.h>
-#include <qtimer.h>
-#include <qregexp.h>
-#include <qvbox.h>
-#include <qfileinfo.h>
-#include <qwhatsthis.h>
-#include <qgroupbox.h>
+#include <tqtimer.h>
+#include <tqregexp.h>
+#include <tqvbox.h>
+#include <tqfileinfo.h>
+#include <tqwhatsthis.h>
+#include <tqgroupbox.h>
class ProblemItem: public KListViewItem
{
public:
- ProblemItem( QListView* parent, const QString& level, const QString& problem,
- const QString& file, const QString& line, const QString& column )
+ ProblemItem( TQListView* parent, const TQString& level, const TQString& problem,
+ const TQString& file, const TQString& line, const TQString& column )
: KListViewItem( parent, level, problem, file, line, column ) {}
- ProblemItem( QListViewItem* parent, const QString& level, const QString& problem,
- const QString& file, const QString& line, const QString& column )
+ ProblemItem( TQListViewItem* parent, const TQString& level, const TQString& problem,
+ const TQString& file, const TQString& line, const TQString& column )
: KListViewItem( parent, level, problem, file, line, column ) {}
- int compare( QListViewItem* item, int column, bool ascending ) const {
+ int compare( TQListViewItem* item, int column, bool ascending ) const {
if( column == 2 || column == 3 ){
int a = text( column ).toInt();
int b = item->text( column ).toInt();
@@ -75,13 +75,13 @@ public:
};
-ProblemReporter::ProblemReporter( JavaSupportPart* part, QWidget* parent, const char* name )
+ProblemReporter::ProblemReporter( JavaSupportPart* part, TQWidget* parent, const char* name )
: KListView( parent, name ? name : "problemreporter" ),
m_javaSupport( part ),
m_document( 0 ),
m_markIface( 0 )
{
- QWhatsThis::add(this, i18n("<b>Problem reporter</b><p>This window shows various \"problems\" in your project. "
+ TQWhatsThis::add(this, i18n("<b>Problem reporter</b><p>This window shows various \"problems\" in your project. "
"It displays TODO entries, FIXME's and errors reported by a language parser. "
"To add a TODO or FIXME entry, just type<br>"
"<tt>//@todo my todo</tt><br>"
@@ -95,19 +95,19 @@ ProblemReporter::ProblemReporter( JavaSupportPart* part, QWidget* parent, const
addColumn( i18n("Problem") );
setAllColumnsShowFocus( TRUE );
- m_timer = new QTimer( this );
+ m_timer = new TQTimer( this );
- connect( part->partController(), SIGNAL(activePartChanged(KParts::Part*)),
- this, SLOT(slotActivePartChanged(KParts::Part*)) );
- connect( part->partController(), SIGNAL(partAdded(KParts::Part*)),
- this, SLOT(slotPartAdded(KParts::Part*)) );
- connect( part->partController(), SIGNAL(partRemoved(KParts::Part*)),
- this, SLOT(slotPartRemoved(KParts::Part*)) );
+ connect( part->partController(), TQT_SIGNAL(activePartChanged(KParts::Part*)),
+ this, TQT_SLOT(slotActivePartChanged(KParts::Part*)) );
+ connect( part->partController(), TQT_SIGNAL(partAdded(KParts::Part*)),
+ this, TQT_SLOT(slotPartAdded(KParts::Part*)) );
+ connect( part->partController(), TQT_SIGNAL(partRemoved(KParts::Part*)),
+ this, TQT_SLOT(slotPartRemoved(KParts::Part*)) );
- connect( m_timer, SIGNAL(timeout()), this, SLOT(reparse()) );
+ connect( m_timer, TQT_SIGNAL(timeout()), this, TQT_SLOT(reparse()) );
- connect( this, SIGNAL(executed(QListViewItem*)),
- this, SLOT(slotSelected(QListViewItem*)) );
+ connect( this, TQT_SIGNAL(executed(TQListViewItem*)),
+ this, TQT_SLOT(slotSelected(TQListViewItem*)) );
configure();
}
@@ -137,7 +137,7 @@ void ProblemReporter::slotActivePartChanged( KParts::Part* part )
if( !m_javaSupport->isValidSource(m_fileName) )
return;
- connect( m_document, SIGNAL(textChanged()), this, SLOT(slotTextChanged()) );
+ connect( m_document, TQT_SIGNAL(textChanged()), this, TQT_SLOT(slotTextChanged()) );
m_markIface = dynamic_cast<KTextEditor::MarkInterface*>( part );
if( !m_javaSupport->backgroundParser() )
@@ -159,11 +159,11 @@ void ProblemReporter::slotTextChanged()
m_timer->changeInterval( m_delay );
}
-void ProblemReporter::removeAllProblems( const QString& filename )
+void ProblemReporter::removeAllProblems( const TQString& filename )
{
- QListViewItem* current = firstChild();
+ TQListViewItem* current = firstChild();
while( current ){
- QListViewItem* i = current;
+ TQListViewItem* i = current;
current = current->nextSibling();
if( i->text(1) == filename )
@@ -171,8 +171,8 @@ void ProblemReporter::removeAllProblems( const QString& filename )
}
if( m_document && m_markIface ){
- QPtrList<KTextEditor::Mark> marks = m_markIface->marks();
- QPtrListIterator<KTextEditor::Mark> it( marks );
+ TQPtrList<KTextEditor::Mark> marks = m_markIface->marks();
+ TQPtrListIterator<KTextEditor::Mark> it( marks );
while( it.current() ){
m_markIface->removeMark( it.current()->line, KTextEditor::MarkInterface::markType07 );
++it;
@@ -197,7 +197,7 @@ void ProblemReporter::reparse()
kdDebug(9013) << "---> file added " << m_fileName << endl;
}
-void ProblemReporter::slotSelected( QListViewItem* item )
+void ProblemReporter::slotSelected( TQListViewItem* item )
{
KURL url( item->text(1) );
int line = item->text( 2 ).toInt();
@@ -206,21 +206,21 @@ void ProblemReporter::slotSelected( QListViewItem* item )
// m_javaSupport->mainWindow()->lowerView( this );
}
-void ProblemReporter::reportProblem( const QString& fileName, const Problem& p )
+void ProblemReporter::reportProblem( const TQString& fileName, const Problem& p )
{
int markType = levelToMarkType( p.level() );
if( markType != -1 && m_document && m_markIface && m_fileName == fileName ){
m_markIface->addMark( p.line(), markType );
}
- QString msg = p.text();
- msg = msg.replace( QRegExp("\n"), "" );
+ TQString msg = p.text();
+ msg = msg.replace( TQRegExp("\n"), "" );
new ProblemItem( this,
levelToString( p.level() ),
fileName,
- QString::number( p.line() + 1 ),
- QString::number( p.column() + 1 ),
+ TQString::number( p.line() + 1 ),
+ TQString::number( p.column() + 1 ),
msg );
}
@@ -235,12 +235,12 @@ void ProblemReporter::configure()
void ProblemReporter::configWidget( KDialogBase* dlg )
{
- QVBox *vbox = dlg->addVBoxPage(i18n("Java Parsing"));
+ TQVBox *vbox = dlg->addVBoxPage(i18n("Java Parsing"));
ConfigureProblemReporter* w = new ConfigureProblemReporter( vbox );
//FIXME adymo: unused functionality
w->groupBox3->hide();
- connect(dlg, SIGNAL(okClicked()), w, SLOT(accept()));
- connect(dlg, SIGNAL(okClicked()), this, SLOT(configure()));
+ connect(dlg, TQT_SIGNAL(okClicked()), w, TQT_SLOT(accept()));
+ connect(dlg, TQT_SIGNAL(okClicked()), this, TQT_SLOT(configure()));
}
void ProblemReporter::slotPartAdded( KParts::Part* part )
@@ -262,20 +262,20 @@ void ProblemReporter::slotPartRemoved( KParts::Part* part )
}
}
-QString ProblemReporter::levelToString( int level ) const
+TQString ProblemReporter::levelToString( int level ) const
{
switch( level )
{
case Problem::Level_Error:
- return QString::fromLatin1( "Error" );
+ return TQString::fromLatin1( "Error" );
case Problem::Level_Warning:
- return QString::fromLatin1( "Warning" );
+ return TQString::fromLatin1( "Warning" );
case Problem::Level_Todo:
- return QString::fromLatin1( "Todo" );
+ return TQString::fromLatin1( "Todo" );
case Problem::Level_Fixme:
- return QString::fromLatin1( "Fixme" );
+ return TQString::fromLatin1( "Fixme" );
default:
- return QString::null;
+ return TQString::null;
}
}