diff options
author | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2010-07-31 19:56:07 +0000 |
---|---|---|
committer | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2010-07-31 19:56:07 +0000 |
commit | d6f8bbb45b267065a6907e71ff9c98bb6d161241 (patch) | |
tree | d109539636691d7b03036ca1c0ed29dbae6577cf /vcs/cvsservice/annotatepage.cpp | |
parent | 3331a47a9cad24795c7440ee8107143ce444ef34 (diff) | |
download | tdevelop-d6f8bbb45b267065a6907e71ff9c98bb6d161241.tar.gz tdevelop-d6f8bbb45b267065a6907e71ff9c98bb6d161241.zip |
Trinity Qt initial conversion
git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdevelop@1157658 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'vcs/cvsservice/annotatepage.cpp')
-rw-r--r-- | vcs/cvsservice/annotatepage.cpp | 68 |
1 files changed, 34 insertions, 34 deletions
diff --git a/vcs/cvsservice/annotatepage.cpp b/vcs/cvsservice/annotatepage.cpp index fea16ece..71918304 100644 --- a/vcs/cvsservice/annotatepage.cpp +++ b/vcs/cvsservice/annotatepage.cpp @@ -9,11 +9,11 @@ * * ***************************************************************************/ -#include <qlayout.h> -#include <qregexp.h> -#include <qstringlist.h> -#include <qdatetime.h> -#include <qlabel.h> +#include <tqlayout.h> +#include <tqregexp.h> +#include <tqstringlist.h> +#include <tqdatetime.h> +#include <tqlabel.h> #include <kmessagebox.h> #include <kcursor.h> @@ -32,20 +32,20 @@ #include "annotatepage.h" #include "annotateview.h" -AnnotatePage::AnnotatePage( CvsService_stub *cvsService, QWidget *parent, const char *name, int ) +AnnotatePage::AnnotatePage( CvsService_stub *cvsService, TQWidget *parent, const char *name, int ) : DCOPObject( "CvsAnnotatePageDCOPIface" ), - QWidget( parent, name? name : "annotateformpage" ), + TQWidget( parent, name? name : "annotateformpage" ), m_cvsService( cvsService ), m_cvsAnnotateJob( 0 ) { kdDebug(9006) << "AnnotatePage::AnnotatePage()" << endl; - QLayout *dialogLayout = new QVBoxLayout( this ); + TQLayout *dialogLayout = new TQVBoxLayout( this ); //First create the top-line where user can choose a revision - QWidget * LayoutWidget = new QWidget( this ); - QHBoxLayout * AnnotateLayout = new QHBoxLayout( LayoutWidget ); + TQWidget * LayoutWidget = new TQWidget( this ); + TQHBoxLayout * AnnotateLayout = new TQHBoxLayout( LayoutWidget ); - QLabel * lblRevision = new QLabel( LayoutWidget ); + TQLabel * lblRevision = new TQLabel( LayoutWidget ); AnnotateLayout->addWidget( lblRevision ); lblRevision->setText( tr( "Revision:" ) ); @@ -55,14 +55,14 @@ AnnotatePage::AnnotatePage( CvsService_stub *cvsService, QWidget *parent, const m_btnAnnotate = new KPushButton( LayoutWidget ); AnnotateLayout->addWidget( m_btnAnnotate ); m_btnAnnotate->setText( tr( "&Annotate" ) ); - m_btnAnnotate->setAccel( QKeySequence( tr( "Alt+A" ) ) ); + m_btnAnnotate->setAccel( TQKeySequence( tr( "Alt+A" ) ) ); dialogLayout->add( LayoutWidget ); - connect( m_btnAnnotate, SIGNAL(clicked()), - this, SLOT(slotNewAnnotate()) ); - connect( m_leRevision, SIGNAL( returnPressed() ), - m_btnAnnotate, SLOT( setFocus() ) ); + connect( m_btnAnnotate, TQT_SIGNAL(clicked()), + this, TQT_SLOT(slotNewAnnotate()) ); + connect( m_leRevision, TQT_SIGNAL( returnPressed() ), + m_btnAnnotate, TQT_SLOT( setFocus() ) ); //Nest create the AnnotateView; it will do the actual displaying m_annotateView = new AnnotateView(this, "annotateview"); @@ -76,7 +76,7 @@ AnnotatePage::~AnnotatePage() delete m_cvsAnnotateJob; } -void AnnotatePage::startAnnotate( const QString pathName, const QString revision ) +void AnnotatePage::startAnnotate( const TQString pathName, const TQString revision ) { kdDebug(9006) << "AnnotatePage::startAnnotate() pathName = " << pathName << "revision = " << revision << endl; @@ -90,7 +90,7 @@ void AnnotatePage::startAnnotate( const QString pathName, const QString revision // establish connections to the signals of the cvs m_job connectDCOPSignal( job.app(), job.obj(), "jobExited(bool, int)", "slotJobExited(bool, int)", true ); - connectDCOPSignal( job.app(), job.obj(), "receivedStdout(QString)", "slotReceivedOutput(QString)", true ); + connectDCOPSignal( job.app(), job.obj(), "receivedStdout(TQString)", "slotReceivedOutput(TQString)", true ); //clear both the outputbuffer and the AnnotateView m_output = ""; @@ -111,19 +111,19 @@ void AnnotatePage::slotJobExited( bool normalExit, int exitStatus ) } //split the collected output and pass the lines to the parser function - QStringList lines = QStringList::split("\n", m_output); + TQStringList lines = TQStringList::split("\n", m_output); parseAnnotateOutput(lines); } -void AnnotatePage::slotReceivedOutput( QString someOutput ) +void AnnotatePage::slotReceivedOutput( TQString someOutput ) { - kdDebug(9006) << "AnnotatePage::slotReceivedOutput(QString)" << endl; + kdDebug(9006) << "AnnotatePage::slotReceivedOutput(TQString)" << endl; m_output += someOutput; } -void AnnotatePage::slotReceivedErrors( QString ) +void AnnotatePage::slotReceivedErrors( TQString ) { - kdDebug(9006) << "AnnotatePage::slotReceivedErrors(QString)" << endl; + kdDebug(9006) << "AnnotatePage::slotReceivedErrors(TQString)" << endl; } void AnnotatePage::cancel() @@ -132,22 +132,22 @@ void AnnotatePage::cancel() m_cvsAnnotateJob->cancel(); } -void AnnotatePage::parseAnnotateOutput(QStringList& lines) +void AnnotatePage::parseAnnotateOutput(TQStringList& lines) { - kdDebug(9006) << "AnnotatePage::parseAnnotateOutput(QStringList)" << endl; + kdDebug(9006) << "AnnotatePage::parseAnnotateOutput(TQStringList)" << endl; /** * First we need to parse the output of "cvs log" which the dcop-interface delivers * everytime annotate is requested. - * The QMap m_comments stores the revisions together with the matching comments. + * The TQMap m_comments stores the revisions together with the matching comments. * The comments will be passed to the AnnotateView in order to display them as QToolTip */ - QString line, comment, rev; + TQString line, comment, rev; enum { Begin, Tags, Admin, Revision, Author, Branches, Comment, Finished } state; - QStringList::Iterator it = lines.begin(); + TQStringList::Iterator it = lines.begin(); state = Begin; do { @@ -187,7 +187,7 @@ void AnnotatePage::parseAnnotateOutput(QStringList& lines) else if( line == "=============================================================================" ) state = Finished; if( state == Comment ) - comment += QString("\n") + line; + comment += TQString("\n") + line; else m_comments[rev] = comment; break; @@ -214,18 +214,18 @@ void AnnotatePage::parseAnnotateOutput(QStringList& lines) } ++it; - QString author, content; - QString oldRevision = ""; //we always store the last revision to recognice... + TQString author, content; + TQString oldRevision = ""; //we always store the last revision to recognice... bool changeColor = false; //...when the AnnotateView needs to change the coloring - QDateTime logDate; + TQDateTime logDate; do { line = *it; //the log date should be printed according to the user's global setting - //so we pass it as QDateTime to the AnnotateView below - QString dateString = line.mid(23, 9); + //so we pass it as TQDateTime to the AnnotateView below + TQString dateString = line.mid(23, 9); if( !dateString.isEmpty() ) logDate.setTime_t(KRFCDate::parseDate(dateString), Qt::UTC); |