diff options
Diffstat (limited to 'vcs/perforce')
-rw-r--r-- | vcs/perforce/commitdlg.cpp | 64 | ||||
-rw-r--r-- | vcs/perforce/commitdlg.h | 26 | ||||
-rw-r--r-- | vcs/perforce/integrator/perforceintegrator.cpp | 8 | ||||
-rw-r--r-- | vcs/perforce/integrator/perforceintegrator.h | 8 | ||||
-rw-r--r-- | vcs/perforce/integrator/pfintegratordlg.cpp | 6 | ||||
-rw-r--r-- | vcs/perforce/integrator/pfintegratordlg.h | 6 | ||||
-rw-r--r-- | vcs/perforce/perforcepart.cpp | 112 | ||||
-rw-r--r-- | vcs/perforce/perforcepart.h | 32 |
8 files changed, 131 insertions, 131 deletions
diff --git a/vcs/perforce/commitdlg.cpp b/vcs/perforce/commitdlg.cpp index 8a9be561..a6aa98b9 100644 --- a/vcs/perforce/commitdlg.cpp +++ b/vcs/perforce/commitdlg.cpp @@ -12,11 +12,11 @@ #include "commitdlg.h" -#include <qlayout.h> -#include <qlabel.h> -#include <qtextedit.h> -#include <qpushbutton.h> -#include <qregexp.h> +#include <tqlayout.h> +#include <tqlabel.h> +#include <tqtextedit.h> +#include <tqpushbutton.h> +#include <tqregexp.h> #include <kprocess.h> #include <kapplication.h> #include <klocale.h> @@ -28,38 +28,38 @@ #include "execcommand.h" -CommitDialog::CommitDialog( QWidget *parent, const char *name ) +CommitDialog::CommitDialog( TQWidget *parent, const char *name ) : KDialogBase( parent, name, true, i18n("Perforce Submit"), Ok|Cancel|Details ) { - QWidget *w = new QWidget( this, "main widget" ); + TQWidget *w = new TQWidget( this, "main widget" ); setMainWidget( w ); - edit = new QTextEdit( w ); - QFontMetrics fm(edit->fontMetrics()); + edit = new TQTextEdit( w ); + TQFontMetrics fm(edit->fontMetrics()); edit->setMinimumSize(fm.width("0")*40, fm.lineSpacing()*3); - QVBoxLayout *layout = new QVBoxLayout( w, 0, spacingHint() ); - QLabel *editLabel = new QLabel(i18n("&Enter description:"), w); + TQVBoxLayout *layout = new TQVBoxLayout( w, 0, spacingHint() ); + TQLabel *editLabel = new TQLabel(i18n("&Enter description:"), w); editLabel->setBuddy(edit); layout->addWidget(editLabel); layout->addWidget(edit); - w = new QWidget( this, "details widget" ); + w = new TQWidget( this, "details widget" ); clientEdit = new KLineEdit( w ); userEdit = new KLineEdit( w ); filesBox = new KListBox( w ); - layout = new QVBoxLayout( w, 0, spacingHint() ); - QLabel *clientLabel = new QLabel(i18n("C&lient:"), w); + layout = new TQVBoxLayout( w, 0, spacingHint() ); + TQLabel *clientLabel = new TQLabel(i18n("C&lient:"), w); clientLabel->setBuddy(clientEdit); layout->addWidget(clientLabel); layout->addWidget( clientEdit ); - QLabel *userLabel = new QLabel(i18n("&User:"), w); + TQLabel *userLabel = new TQLabel(i18n("&User:"), w); userLabel->setBuddy(userEdit); layout->addWidget( userLabel ); layout->addWidget( userEdit ); - QLabel *filesLabel = new QLabel(i18n("&File(s):"), w); + TQLabel *filesLabel = new TQLabel(i18n("&File(s):"), w); filesLabel->setBuddy(filesBox); layout->addWidget( filesLabel ); layout->addWidget( filesBox ); @@ -79,49 +79,49 @@ void CommitDialog::autoGuess() cenv = getenv( "P4USER" ); if ( cenv ) { - setUser( QString::fromLocal8Bit( cenv ) ); + setUser( TQString::fromLocal8Bit( cenv ) ); } cenv = getenv( "P4CLIENT" ); if ( cenv ) { - setClient( QString::fromLocal8Bit( cenv ) ); + setClient( TQString::fromLocal8Bit( cenv ) ); } } -void CommitDialog::setFiles( const QStringList& lst ) +void CommitDialog::setFiles( const TQStringList& lst ) { filesBox->clear(); setDepotFiles( lst ); } -void CommitDialog::setDepotFiles( const QStringList& lst ) +void CommitDialog::setDepotFiles( const TQStringList& lst ) { - QStringList args; + TQStringList args; args << "files"; - for ( QStringList::ConstIterator it = lst.begin(); it != lst.end(); ++it ) { + for ( TQStringList::ConstIterator it = lst.begin(); it != lst.end(); ++it ) { args << (*it); } - ExecCommand* cmd = new ExecCommand( "p4", args, QString::null, QStringList(), this ); - connect( cmd, SIGNAL(finished( const QString&, const QString& )), - this, SLOT(getFilesFinished( const QString&, const QString& )) ); + ExecCommand* cmd = new ExecCommand( "p4", args, TQString::null, TQStringList(), this ); + connect( cmd, TQT_SIGNAL(finished( const TQString&, const TQString& )), + this, TQT_SLOT(getFilesFinished( const TQString&, const TQString& )) ); } -void CommitDialog::getFilesFinished( const QString& out, const QString& /* err */ ) +void CommitDialog::getFilesFinished( const TQString& out, const TQString& /* err */ ) { - QStringList lst = QStringList::split( QChar('\n'), out ); - for ( QStringList::ConstIterator it = lst.begin(); it != lst.end(); ++it ) { - int pos = (*it).find( QChar('#') ); + TQStringList lst = TQStringList::split( TQChar('\n'), out ); + for ( TQStringList::ConstIterator it = lst.begin(); it != lst.end(); ++it ) { + int pos = (*it).find( TQChar('#') ); if ( pos > 1 && (*it).startsWith( "//" ) ) { filesBox->insertItem( (*it).left( pos ) ); } } } -QString CommitDialog::changeList() const +TQString CommitDialog::changeList() const { - QString lst; + TQString lst; lst += "Change: new\n" "Client: " + client() + "\n" @@ -129,7 +129,7 @@ QString CommitDialog::changeList() const "Status: new\n" "Description:\n "; - lst += logMessage().replace(QRegExp("\n"), "\n ") + "\n\n"; + lst += logMessage().replace(TQRegExp("\n"), "\n ") + "\n\n"; lst += "Files:\n"; diff --git a/vcs/perforce/commitdlg.h b/vcs/perforce/commitdlg.h index 390681fd..09a9c72f 100644 --- a/vcs/perforce/commitdlg.h +++ b/vcs/perforce/commitdlg.h @@ -13,8 +13,8 @@ #ifndef _COMMITDIALOG_H_ #define _COMMITDIALOG_H_ -#include <qstringlist.h> -#include <qtextedit.h> +#include <tqstringlist.h> +#include <tqtextedit.h> #include <klineedit.h> #include <klistbox.h> #include <kdialogbase.h> @@ -25,17 +25,17 @@ class CommitDialog : public KDialogBase { Q_OBJECT public: - CommitDialog( QWidget *parent = 0, const char *name = 0 ); + CommitDialog( TQWidget *parent = 0, const char *name = 0 ); ~CommitDialog(); - QString logMessage() const { return edit->text(); } - QString user() const { return userEdit->text(); } - QString client() const { return clientEdit->text(); } - QString changeList() const; + TQString logMessage() const { return edit->text(); } + TQString user() const { return userEdit->text(); } + TQString client() const { return clientEdit->text(); } + TQString changeList() const; - void setUser( const QString& usr ) { userEdit->setText( usr ); } - void setClient( const QString& clnt ) { clientEdit->setText( clnt ); } - void setFiles( const QStringList& lst ); + void setUser( const TQString& usr ) { userEdit->setText( usr ); } + void setClient( const TQString& clnt ) { clientEdit->setText( clnt ); } + void setFiles( const TQStringList& lst ); /** tries to fill out user and client */ void autoGuess(); @@ -44,11 +44,11 @@ protected slots: void accept(); private slots: - void getFilesFinished( const QString& out, const QString& err ); + void getFilesFinished( const TQString& out, const TQString& err ); private: - void setDepotFiles( const QStringList& lst ); - QTextEdit *edit; + void setDepotFiles( const TQStringList& lst ); + TQTextEdit *edit; KLineEdit *clientEdit, *userEdit; KListBox *filesBox; }; diff --git a/vcs/perforce/integrator/perforceintegrator.cpp b/vcs/perforce/integrator/perforceintegrator.cpp index 74964edb..bc7c0988 100644 --- a/vcs/perforce/integrator/perforceintegrator.cpp +++ b/vcs/perforce/integrator/perforceintegrator.cpp @@ -28,8 +28,8 @@ static const KDevPluginInfo data("kdevperforceintegrator"); typedef KDevGenericFactory<PerforceIntegrator> PerforceIntegratorFactory; K_EXPORT_COMPONENT_FACTORY( libperforceintegrator, PerforceIntegratorFactory(data) ) -PerforceIntegrator::PerforceIntegrator(QObject* parent, const char* name, - const QStringList // args +PerforceIntegrator::PerforceIntegrator(TQObject* parent, const char* name, + const TQStringList // args ) :KDevVCSIntegrator(parent, name) { @@ -39,13 +39,13 @@ PerforceIntegrator::~PerforceIntegrator() { } -VCSDialog* PerforceIntegrator::fetcher(QWidget* // parent +VCSDialog* PerforceIntegrator::fetcher(TQWidget* // parent ) { return 0; } -VCSDialog* PerforceIntegrator::integrator(QWidget* parent) +VCSDialog* PerforceIntegrator::integrator(TQWidget* parent) { PFIntegratorDlg *dlg = new PFIntegratorDlg(parent); return dlg; diff --git a/vcs/perforce/integrator/perforceintegrator.h b/vcs/perforce/integrator/perforceintegrator.h index a47c7ee7..1d047826 100644 --- a/vcs/perforce/integrator/perforceintegrator.h +++ b/vcs/perforce/integrator/perforceintegrator.h @@ -22,17 +22,17 @@ #include <kdevvcsintegrator.h> -#include <qstringlist.h> +#include <tqstringlist.h> class PerforceIntegrator : public KDevVCSIntegrator { Q_OBJECT public: - PerforceIntegrator(QObject* parent, const char* name, const QStringList args = QStringList()); + PerforceIntegrator(TQObject* parent, const char* name, const TQStringList args = TQStringList()); ~PerforceIntegrator(); - virtual VCSDialog* fetcher(QWidget* parent); - virtual VCSDialog* integrator(QWidget* parent); + virtual VCSDialog* fetcher(TQWidget* parent); + virtual VCSDialog* integrator(TQWidget* parent); }; diff --git a/vcs/perforce/integrator/pfintegratordlg.cpp b/vcs/perforce/integrator/pfintegratordlg.cpp index e93e8b3e..8685b2f4 100644 --- a/vcs/perforce/integrator/pfintegratordlg.cpp +++ b/vcs/perforce/integrator/pfintegratordlg.cpp @@ -19,7 +19,7 @@ ***************************************************************************/ #include "pfintegratordlg.h" -PFIntegratorDlg::PFIntegratorDlg(QWidget *parent, const char *name) +PFIntegratorDlg::PFIntegratorDlg(TQWidget *parent, const char *name) :PFIntegratorDlgBase(parent, name) { } @@ -28,11 +28,11 @@ void PFIntegratorDlg::accept() { } -void PFIntegratorDlg::init(const QString &/*projectName*/, const QString &/*projectLocation*/) +void PFIntegratorDlg::init(const TQString &/*projectName*/, const TQString &/*projectLocation*/) { } -QWidget *PFIntegratorDlg::self() +TQWidget *PFIntegratorDlg::self() { return const_cast<PFIntegratorDlg*>(this); } diff --git a/vcs/perforce/integrator/pfintegratordlg.h b/vcs/perforce/integrator/pfintegratordlg.h index 2389c826..750795b6 100644 --- a/vcs/perforce/integrator/pfintegratordlg.h +++ b/vcs/perforce/integrator/pfintegratordlg.h @@ -26,11 +26,11 @@ class PFIntegratorDlg: public PFIntegratorDlgBase, public VCSDialog { Q_OBJECT public: - PFIntegratorDlg(QWidget *parent = 0, const char *name = 0); + PFIntegratorDlg(TQWidget *parent = 0, const char *name = 0); virtual void accept(); - virtual void init(const QString &projectName, const QString &projectLocation); - virtual QWidget *self(); + virtual void init(const TQString &projectName, const TQString &projectLocation); + virtual TQWidget *self(); }; #endif diff --git a/vcs/perforce/perforcepart.cpp b/vcs/perforce/perforcepart.cpp index 9aeadc6f..cb3d7ba9 100644 --- a/vcs/perforce/perforcepart.cpp +++ b/vcs/perforce/perforcepart.cpp @@ -12,9 +12,9 @@ #include "perforcepart.h" -#include <qfileinfo.h> -#include <qpopupmenu.h> -#include <qregexp.h> +#include <tqfileinfo.h> +#include <tqpopupmenu.h> +#include <tqregexp.h> #include <kpopupmenu.h> #include <kdebug.h> #include <kdevgenericfactory.h> @@ -38,14 +38,14 @@ static const KDevPluginInfo data("kdevperforce"); typedef KDevGenericFactory<PerforcePart> PerforceFactory; K_EXPORT_COMPONENT_FACTORY( libkdevperforce, PerforceFactory( data ) ) -PerforcePart::PerforcePart( QObject *parent, const char *name, const QStringList & ) +PerforcePart::PerforcePart( TQObject *parent, const char *name, const TQStringList & ) : KDevVersionControl( &data, parent, name ? name : "PerforcePart" ) { setInstance(PerforceFactory::instance()); setupActions(); - connect( core(), SIGNAL(contextMenu(QPopupMenu *, const Context *)), - this, SLOT(contextMenu(QPopupMenu *, const Context *)) ); + connect( core(), TQT_SIGNAL(contextMenu(TQPopupMenu *, const Context *)), + this, TQT_SLOT(contextMenu(TQPopupMenu *, const Context *)) ); } @@ -54,88 +54,88 @@ PerforcePart::~PerforcePart() void PerforcePart::setupActions() { - actionEdit = new KAction( i18n("Edit"), 0, this, SLOT(slotActionEdit()), + actionEdit = new KAction( i18n("Edit"), 0, this, TQT_SLOT(slotActionEdit()), actionCollection(), "perforce_edit" ); actionEdit->setToolTip(i18n("Edit")); actionEdit->setWhatsThis(i18n("<b>Edit</b><p>Opens file(s) in a client workspace for edit.")); - actionRevert = new KAction( i18n("Revert"), 0, this, SLOT(slotActionRevert()), + actionRevert = new KAction( i18n("Revert"), 0, this, TQT_SLOT(slotActionRevert()), actionCollection(), "perforce_revert" ); actionRevert->setToolTip(i18n("Revert")); actionRevert->setWhatsThis(i18n("<b>Revert</b><p>Discards changes made to open files.")); - actionSubmit = new KAction( i18n("Submit"), 0, this, SLOT(slotActionCommit()), + actionSubmit = new KAction( i18n("Submit"), 0, this, TQT_SLOT(slotActionCommit()), actionCollection(), "perforce_submit" ); actionSubmit->setToolTip(i18n("Submit")); actionSubmit->setWhatsThis(i18n("<b>Submit</b><p>Sends changes made to open files to the depot.")); - actionSync = new KAction( i18n("Sync"), 0, this, SLOT(slotActionUpdate()), + actionSync = new KAction( i18n("Sync"), 0, this, TQT_SLOT(slotActionUpdate()), actionCollection(), "perforce_sync" ); actionSync->setToolTip(i18n("Sync")); actionSync->setWhatsThis(i18n("<b>Sync</b><p>Copies files from the depot into the workspace.")); - actionDiff = new KAction( i18n("Diff Against Repository"), 0, this, SLOT(slotActionDiff()), + actionDiff = new KAction( i18n("Diff Against Repository"), 0, this, TQT_SLOT(slotActionDiff()), actionCollection(), "perforce_diff" ); actionDiff->setToolTip(i18n("Diff against repository")); actionDiff->setWhatsThis(i18n("<b>Diff against repository</b><p>Compares a client workspace file to a revision in the depot.")); - actionAdd = new KAction( i18n("Add to Repository"), 0, this, SLOT(slotActionAdd()), + actionAdd = new KAction( i18n("Add to Repository"), 0, this, TQT_SLOT(slotActionAdd()), actionCollection(), "perforce_add" ); actionAdd->setToolTip(i18n("Add to repository")); actionAdd->setWhatsThis(i18n("<b>Add to repository</b><p>Open file(s) in a client workspace for addition to the depot.")); - actionRemove = new KAction( i18n("Remove From Repository"), 0, this, SLOT(slotActionRemove()), + actionRemove = new KAction( i18n("Remove From Repository"), 0, this, TQT_SLOT(slotActionRemove()), actionCollection(), "perforce_remove" ); actionRemove->setToolTip(i18n("Remove from repository")); actionRemove->setWhatsThis(i18n("<b>Remove from repository</b><p>Open file(s) in a client workspace for deletion from the depot.")); } -void PerforcePart::contextMenu(QPopupMenu *popup, const Context *context) +void PerforcePart::contextMenu(TQPopupMenu *popup, const Context *context) { if (context->hasType( Context::FileContext )) { const FileContext *fcontext = static_cast<const FileContext*>(context); popupfile = fcontext->urls().first().path(); - QFileInfo fi( popupfile ); + TQFileInfo fi( popupfile ); popup->insertSeparator(); KPopupMenu *sub = new KPopupMenu(popup); - QString name = fi.fileName(); + TQString name = fi.fileName(); sub->insertTitle( i18n("Actions for %1").arg(name) ); int id = sub->insertItem( i18n("Edit"), - this, SLOT(slotEdit()) ); + this, TQT_SLOT(slotEdit()) ); sub->setWhatsThis(id, i18n("<b>Edit</b><p>Opens file(s) in a client workspace for edit.")); id = sub->insertItem( i18n("Revert"), - this, SLOT(slotRevert()) ); + this, TQT_SLOT(slotRevert()) ); sub->setWhatsThis(id, i18n("<b>Revert</b><p>Discards changes made to open files.")); id = sub->insertItem( i18n("Submit"), - this, SLOT(slotCommit()) ); + this, TQT_SLOT(slotCommit()) ); sub->setWhatsThis(id, i18n("<b>Submit</b><p>Sends changes made to open files to the depot.")); id = sub->insertItem( i18n("Sync"), - this, SLOT(slotUpdate()) ); + this, TQT_SLOT(slotUpdate()) ); sub->setWhatsThis(id, i18n("<b>Sync</b><p>Copies files from the depot into the workspace.")); sub->insertSeparator(); id = sub->insertItem( i18n("Diff Against Repository"), - this, SLOT(slotDiff()) ); + this, TQT_SLOT(slotDiff()) ); sub->setWhatsThis(id, i18n("<b>Diff against repository</b><p>Compares a client workspace file to a revision in the depot.")); id = sub->insertItem( i18n("Add to Repository"), - this, SLOT(slotAdd()) ); + this, TQT_SLOT(slotAdd()) ); sub->setWhatsThis(id, i18n("<b>Add to repository</b><p>Open file(s) in a client workspace for addition to the depot.")); id = sub->insertItem( i18n("Remove From Repository"), - this, SLOT(slotRemove()) ); + this, TQT_SLOT(slotRemove()) ); sub->setWhatsThis(id, i18n("<b>Remove from repository</b><p>Open file(s) in a client workspace for deletion from the depot.")); id = popup->insertItem(i18n("Perforce"), sub); } } -void PerforcePart::execCommand( const QString& cmd, const QString& filename ) +void PerforcePart::execCommand( const TQString& cmd, const TQString& filename ) { if ( filename.isEmpty() ) return; - QFileInfo fi( filename ); + TQFileInfo fi( filename ); if (fi.isDir()) { KMessageBox::error( 0, i18n("Cannot handle directories, please select single files") ); return; } - QString dir = fi.dirPath(); - QString name = fi.fileName(); + TQString dir = fi.dirPath(); + TQString name = fi.fileName(); - QString command("cd "); + TQString command("cd "); command += KProcess::quote(dir); command += " && p4 " + cmd + " "; command += name; @@ -144,43 +144,43 @@ void PerforcePart::execCommand( const QString& cmd, const QString& filename ) makeFrontend->queueCommand(dir, command); } -void PerforcePart::edit( const QString& filename ) +void PerforcePart::edit( const TQString& filename ) { execCommand( "edit", filename ); } -void PerforcePart::revert( const QString& filename ) +void PerforcePart::revert( const TQString& filename ) { if ( KMessageBox::questionYesNo( 0, i18n("Do you really want to revert " - "the file %1 and lose all your changes?").arg( filename ), QString::null, i18n("Revert"), i18n("Do Not Revert") ) == KMessageBox::Yes ) { + "the file %1 and lose all your changes?").arg( filename ), TQString::null, i18n("Revert"), i18n("Do Not Revert") ) == KMessageBox::Yes ) { execCommand( "revert", filename ); } } -void PerforcePart::commit( const QString& filename ) +void PerforcePart::commit( const TQString& filename ) { if ( filename.isEmpty() ) return; - QFileInfo fi( filename ); + TQFileInfo fi( filename ); if ( fi.isDir() ) { KMessageBox::error( 0, i18n("Submitting of subdirectories is not supported") ); return; } CommitDialog d; - QStringList lst; + TQStringList lst; lst << filename; d.setFiles( lst ); - if (d.exec() == QDialog::Rejected) + if (d.exec() == TQDialog::Rejected) return; - QString message = d.changeList(); + TQString message = d.changeList(); if (!message.isEmpty()) message = KShellProcess::quote(message); - QString command("echo " + message); + TQString command("echo " + message); command += " | p4 submit -i"; if (KDevMakeFrontend *makeFrontend = extension<KDevMakeFrontend>("KDevelop/MakeFrontend")) @@ -188,13 +188,13 @@ void PerforcePart::commit( const QString& filename ) } -void PerforcePart::update( const QString& filename ) +void PerforcePart::update( const TQString& filename ) { if ( filename.isEmpty() ) return; - QString dir, name; - QFileInfo fi( filename ); + TQString dir, name; + TQFileInfo fi( filename ); if (fi.isDir()) { dir = fi.absFilePath(); name = "..."; // three dots means "recoursive" @@ -203,7 +203,7 @@ void PerforcePart::update( const QString& filename ) name = fi.fileName(); } - QString command("cd "); + TQString command("cd "); command += KProcess::quote(dir); command += " && p4 sync "; command += name; @@ -213,41 +213,41 @@ void PerforcePart::update( const QString& filename ) } -void PerforcePart::add( const QString& filename ) +void PerforcePart::add( const TQString& filename ) { execCommand( "add", filename ); } -void PerforcePart::remove( const QString& filename ) +void PerforcePart::remove( const TQString& filename ) { execCommand( "delete", filename ); } -void PerforcePart::diff( const QString& filename ) +void PerforcePart::diff( const TQString& filename ) { if ( filename.isEmpty() ) return; - QString name; - QFileInfo fi( filename ); + TQString name; + TQFileInfo fi( filename ); if ( fi.isDir() ) { name = fi.absFilePath() + "..."; } else { name = filename; } - QStringList args; + TQStringList args; args << "diff"; args << "-du"; args << name; - ExecCommand* cmv = new ExecCommand( "p4", args, QString::null, QStringList(), this ); - connect( cmv, SIGNAL(finished( const QString&, const QString& )), - this, SLOT(slotDiffFinished( const QString&, const QString& )) ); + ExecCommand* cmv = new ExecCommand( "p4", args, TQString::null, TQStringList(), this ); + connect( cmv, TQT_SIGNAL(finished( const TQString&, const TQString& )), + this, TQT_SLOT(slotDiffFinished( const TQString&, const TQString& )) ); } -void PerforcePart::slotDiffFinished( const QString& diff, const QString& err ) +void PerforcePart::slotDiffFinished( const TQString& diff, const TQString& err ) { if ( diff.isNull() && err.isNull() ) { kdDebug(9000) << "p4 diff cancelled" << endl; @@ -261,7 +261,7 @@ void PerforcePart::slotDiffFinished( const QString& diff, const QString& err ) if ( !err.isEmpty() ) { int s = KMessageBox::warningContinueCancelList( 0, i18n("P4 output errors during diff. Do you still want to continue?"), - QStringList::split( "\n", err, false ), i18n("Errors During Diff") ); + TQStringList::split( "\n", err, false ), i18n("Errors During Diff") ); if ( s != KMessageBox::Continue ) return; } @@ -272,16 +272,16 @@ void PerforcePart::slotDiffFinished( const QString& diff, const QString& err ) } // strip the ==== headers - static QRegExp rx( "(^|\\n)==== ([^ ]+) -.*====\\n" ); + static TQRegExp rx( "(^|\\n)==== ([^ ]+) -.*====\\n" ); rx.setMinimal( true ); - QString strippedDiff = diff; + TQString strippedDiff = diff; strippedDiff.replace( rx, "--- \\2\n+++ \\2\n" ); if (KDevDiffFrontend *diffFrontend = extension<KDevDiffFrontend>("KDevelop/DiffFrontend")) diffFrontend->showDiff( strippedDiff ); } -QString PerforcePart::currentFile() +TQString PerforcePart::currentFile() { KParts::ReadOnlyPart *part = dynamic_cast<KParts::ReadOnlyPart*>( partController()->activePart() ); if ( part ) { @@ -289,7 +289,7 @@ QString PerforcePart::currentFile() if ( url.isLocalFile() ) return url.path(); } - return QString::null; + return TQString::null; } void PerforcePart::slotActionCommit() diff --git a/vcs/perforce/perforcepart.h b/vcs/perforce/perforcepart.h index 5a50871c..073a14ce 100644 --- a/vcs/perforce/perforcepart.h +++ b/vcs/perforce/perforcepart.h @@ -25,20 +25,20 @@ class PerforcePart : public KDevVersionControl Q_OBJECT public: - PerforcePart( QObject *parent, const char *name, const QStringList & ); + PerforcePart( TQObject *parent, const char *name, const TQStringList & ); ~PerforcePart(); - virtual QString shortDescription() const + virtual TQString shortDescription() const { return i18n( "Perforce is a version control system" ); } - virtual void createNewProject(const QString& /* dir */) {} + virtual void createNewProject(const TQString& /* dir */) {} virtual bool fetchFromRepository() { return true; } virtual KDevVCSFileInfoProvider *fileInfoProvider() const { return 0; } - virtual bool isValidDirectory(const QString& /* dirPath*/) const + virtual bool isValidDirectory(const TQString& /* dirPath*/) const { return true; } private slots: - void contextMenu(QPopupMenu *popup, const Context *context); + void contextMenu(TQPopupMenu *popup, const Context *context); void slotCommit(); void slotUpdate(); void slotAdd(); @@ -55,22 +55,22 @@ private slots: void slotActionRevert(); void slotActionDiff(); - void slotDiffFinished( const QString&, const QString& ); + void slotDiffFinished( const TQString&, const TQString& ); private: - void commit( const QString& filename ); - void update( const QString& filename ); - void add( const QString& filename ); - void remove( const QString& filename ); - void edit( const QString& filename ); - void revert( const QString& filename ); - void diff( const QString& filename ); - QString currentFile(); + void commit( const TQString& filename ); + void update( const TQString& filename ); + void add( const TQString& filename ); + void remove( const TQString& filename ); + void edit( const TQString& filename ); + void revert( const TQString& filename ); + void diff( const TQString& filename ); + TQString currentFile(); /** calls p4 with the command cmd and appends the filename */ - void execCommand( const QString& cmd, const QString& filename ); + void execCommand( const TQString& cmd, const TQString& filename ); void setupActions(); - QString popupfile; + TQString popupfile; KAction *actionEdit, *actionRevert, *actionSubmit, *actionSync, *actionDiff, *actionAdd, *actionRemove; |