summaryrefslogtreecommitdiffstats
path: root/kbabel/catalogmanager/catalogmanagerview.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'kbabel/catalogmanager/catalogmanagerview.cpp')
-rw-r--r--kbabel/catalogmanager/catalogmanagerview.cpp532
1 files changed, 266 insertions, 266 deletions
diff --git a/kbabel/catalogmanager/catalogmanagerview.cpp b/kbabel/catalogmanager/catalogmanagerview.cpp
index 6bb4c88f..991e1899 100644
--- a/kbabel/catalogmanager/catalogmanagerview.cpp
+++ b/kbabel/catalogmanager/catalogmanagerview.cpp
@@ -50,10 +50,10 @@
#include "markpatterndialog.h"
#include "validationoptions.h"
-#include <qcheckbox.h>
-#include <qpopupmenu.h>
-#include <qlabel.h>
-#include <qpainter.h>
+#include <tqcheckbox.h>
+#include <tqpopupmenu.h>
+#include <tqlabel.h>
+#include <tqpainter.h>
#include <kcmenumngr.h>
#include <kcursor.h>
@@ -73,15 +73,15 @@
#include <kdeversion.h>
#include <ktempfile.h>
-#include <qfileinfo.h>
-#include <qdir.h>
-#include <qtimer.h>
-#include <qbitmap.h>
-#include <qwhatsthis.h>
-#include <qheader.h>
-#include <qdragobject.h>
-#include <qlayout.h>
-#include <qtextedit.h>
+#include <tqfileinfo.h>
+#include <tqdir.h>
+#include <tqtimer.h>
+#include <tqbitmap.h>
+#include <tqwhatsthis.h>
+#include <tqheader.h>
+#include <tqdragobject.h>
+#include <tqlayout.h>
+#include <tqtextedit.h>
using namespace KBabel;
@@ -98,8 +98,8 @@ const char* columnNames[] = {
#define COLTEXT(a) (i18n(columnNames[a]))
-CatalogManagerView::CatalogManagerView(KBabel::Project::Ptr project, QWidget* parent,const char* name)
- : QListView(parent,name)
+CatalogManagerView::CatalogManagerView(KBabel::Project::Ptr project, TQWidget* parent,const char* name)
+ : TQListView(parent,name)
, _dirWatch(0)
, _readInfoCount(0)
, _active(false)
@@ -131,8 +131,8 @@ CatalogManagerView::CatalogManagerView(KBabel::Project::Ptr project, QWidget* pa
_dictBox = new KBabelDictBox(this, "dictbox");
_dictBox->hide();
- _updateTimer = new QTimer(this);
- connect(_updateTimer,SIGNAL(timeout()),this,SLOT(checkUpdate()));
+ _updateTimer = new TQTimer(this);
+ connect(_updateTimer,TQT_SIGNAL(timeout()),this,TQT_SLOT(checkUpdate()));
addColumn(COLTEXT(COL_NAME));
addColumn(COLTEXT(COL_MARKER),25);
@@ -143,7 +143,7 @@ CatalogManagerView::CatalogManagerView(KBabel::Project::Ptr project, QWidget* pa
setColumnAlignment(2,AlignCenter);
addColumn(COLTEXT(COL_TOTAL));
setColumnAlignment(3,AlignCenter);
- addColumn(QString::null); // CVS/SVN column, header is set later
+ addColumn(TQString::null); // CVS/SVN column, header is set later
addColumn(COLTEXT(COL_REVISION));
addColumn(COLTEXT(COL_TRANSLATOR));
@@ -154,21 +154,21 @@ CatalogManagerView::CatalogManagerView(KBabel::Project::Ptr project, QWidget* pa
if(KContextMenuManager::showOnButtonPress())
{
- connect(this,SIGNAL(rightButtonPressed(QListViewItem*,const QPoint &, int))
- ,this, SLOT(showContentsMenu(QListViewItem*,const QPoint &, int)));
+ connect(this,TQT_SIGNAL(rightButtonPressed(TQListViewItem*,const TQPoint &, int))
+ ,this, TQT_SLOT(showContentsMenu(TQListViewItem*,const TQPoint &, int)));
}
else
{
- connect(this,SIGNAL(rightButtonClicked(QListViewItem*,const QPoint &, int))
- ,this, SLOT(showContentsMenu(QListViewItem*,const QPoint &, int)));
+ connect(this,TQT_SIGNAL(rightButtonClicked(TQListViewItem*,const TQPoint &, int))
+ ,this, TQT_SLOT(showContentsMenu(TQListViewItem*,const TQPoint &, int)));
}
- connect(this, SIGNAL(returnPressed(QListViewItem*))
- ,this, SLOT(activateItem(QListViewItem*)));
- connect(this, SIGNAL(doubleClicked(QListViewItem*))
- ,this, SLOT(activateItem(QListViewItem*)));
- connect(this,SIGNAL(selectionChanged()),this,SLOT(checkSelected()));
- connect( this, SIGNAL( clicked(QListViewItem *, const QPoint &, int)),
- this, SLOT( columnClicked(QListViewItem *, const QPoint &, int)));
+ connect(this, TQT_SIGNAL(returnPressed(TQListViewItem*))
+ ,this, TQT_SLOT(activateItem(TQListViewItem*)));
+ connect(this, TQT_SIGNAL(doubleClicked(TQListViewItem*))
+ ,this, TQT_SLOT(activateItem(TQListViewItem*)));
+ connect(this,TQT_SIGNAL(selectionChanged()),this,TQT_SLOT(checkSelected()));
+ connect( this, TQT_SIGNAL( clicked(TQListViewItem *, const TQPoint &, int)),
+ this, TQT_SLOT( columnClicked(TQListViewItem *, const TQPoint &, int)));
_dirCommandsMenu = 0;
_fileCommandsMenu = 0;
@@ -178,20 +178,20 @@ CatalogManagerView::CatalogManagerView(KBabel::Project::Ptr project, QWidget* pa
_logWindow = new KDialogBase(0,"log window",false,i18n("Log Window")
,KDialogBase::Close | KDialogBase::User1,KDialogBase::Close);
_logWindow->setButtonText(KDialogBase::User1,i18n("C&lear"));
- _logWindow->setInitialSize(QSize(300,200));
+ _logWindow->setInitialSize(TQSize(300,200));
- QWhatsThis::add(_logWindow,i18n("<qt><p><b>Log window</b></p>\n"
+ TQWhatsThis::add(_logWindow,i18n("<qt><p><b>Log window</b></p>\n"
"<p>In this window the output of "
"the executed commands are shown.</p></qt>"));
- _logView = new QTextEdit(_logWindow);
+ _logView = new TQTextEdit(_logWindow);
_logView->setReadOnly(true);
_logWindow->setMainWidget(_logView);
- connect(_logWindow,SIGNAL(user1Clicked()),_logView,SLOT(clear()));
+ connect(_logWindow,TQT_SIGNAL(user1Clicked()),_logView,TQT_SLOT(clear()));
- QWhatsThis::add(this,i18n("<qt><p><b>Catalog Manager</b></p>\n"
+ TQWhatsThis::add(this,i18n("<qt><p><b>Catalog Manager</b></p>\n"
"<p>The Catalog Manager merges two folders into one tree and displays all\n"
"PO and POT files in these folders. This way you can easily see if a\n"
"template has been added or removed. Also some information about the files\n"
@@ -205,21 +205,21 @@ CatalogManagerView::CatalogManagerView(KBabel::Project::Ptr project, QWidget* pa
// CVS
cvshandler = new CVSHandler( );
- connect( cvshandler, SIGNAL( signalIsPORepository( bool ) ),
- this, SLOT( slotValidPOCVSRepository( bool ) ) );
- connect( cvshandler, SIGNAL( signalIsPOTRepository( bool ) ),
- this, SLOT( slotValidPOTCVSRepository( bool ) ) );
- connect( cvshandler, SIGNAL( signalFilesCommitted( const QStringList& ) ),
- this, SLOT( updateFiles( const QStringList& ) ) );
+ connect( cvshandler, TQT_SIGNAL( signalIsPORepository( bool ) ),
+ this, TQT_SLOT( slotValidPOCVSRepository( bool ) ) );
+ connect( cvshandler, TQT_SIGNAL( signalIsPOTRepository( bool ) ),
+ this, TQT_SLOT( slotValidPOTCVSRepository( bool ) ) );
+ connect( cvshandler, TQT_SIGNAL( signalFilesCommitted( const TQStringList& ) ),
+ this, TQT_SLOT( updateFiles( const TQStringList& ) ) );
// SVN
svnhandler = new SVNHandler( );
- connect( svnhandler, SIGNAL( signalIsPORepository( bool ) ),
- this, SLOT( slotValidPOSVNRepository( bool ) ) );
- connect( svnhandler, SIGNAL( signalIsPOTRepository( bool ) ),
- this, SLOT( slotValidPOTSVNRepository( bool ) ) );
- connect( svnhandler, SIGNAL( signalFilesCommitted( const QStringList& ) ),
- this, SLOT( updateFiles( const QStringList& ) ) );
+ connect( svnhandler, TQT_SIGNAL( signalIsPORepository( bool ) ),
+ this, TQT_SLOT( slotValidPOSVNRepository( bool ) ) );
+ connect( svnhandler, TQT_SIGNAL( signalIsPOTRepository( bool ) ),
+ this, TQT_SLOT( slotValidPOTSVNRepository( bool ) ) );
+ connect( svnhandler, TQT_SIGNAL( signalFilesCommitted( const TQStringList& ) ),
+ this, TQT_SLOT( updateFiles( const TQStringList& ) ) );
KConfig *config = KGlobal::config();
restoreView(config);
@@ -271,26 +271,26 @@ void CatalogManagerView::restoreView( KConfig *config)
_ignoreFuzzy = config->readBoolEntry( "ValidateIgnoreFuzzy", false );
}
-void CatalogManagerView::setRMBMenuFile( QPopupMenu *m )
+void CatalogManagerView::setRMBMenuFile( TQPopupMenu *m )
{
_fileContentsMenu = m;
}
-void CatalogManagerView::setRMBMenuDir( QPopupMenu *m )
+void CatalogManagerView::setRMBMenuDir( TQPopupMenu *m )
{
_dirContentsMenu = m;
}
-void CatalogManagerView::setDirCommandsMenu( QPopupMenu *m )
+void CatalogManagerView::setDirCommandsMenu( TQPopupMenu *m )
{
_dirCommandsMenu = m;
- connect(_dirCommandsMenu,SIGNAL(activated(int)),this,SLOT(slotDirCommand(int)));
+ connect(_dirCommandsMenu,TQT_SIGNAL(activated(int)),this,TQT_SLOT(slotDirCommand(int)));
}
-void CatalogManagerView::setFileCommandsMenu( QPopupMenu *m )
+void CatalogManagerView::setFileCommandsMenu( TQPopupMenu *m )
{
_fileCommandsMenu = m;
- connect(_fileCommandsMenu,SIGNAL(activated(int)),this,SLOT(slotFileCommand(int)));
+ connect(_fileCommandsMenu,TQT_SIGNAL(activated(int)),this,TQT_SLOT(slotFileCommand(int)));
}
void CatalogManagerView::checkUpdate()
@@ -298,7 +298,7 @@ void CatalogManagerView::checkUpdate()
_updateNesting++;
pause(true);
- QDictIterator<CatManListItem> it( _fileList ); // iterator for dict
+ TQDictIterator<CatManListItem> it( _fileList ); // iterator for dict
while ( it.current() && !_stop)
{
@@ -353,24 +353,24 @@ void CatalogManagerView::clear()
delete _dirWatch;
_dirWatch= new KDirWatch();
- connect(_dirWatch,SIGNAL(deleted(const QString&)),this
- ,SLOT(directoryDeleted(const QString&)));
- connect(_dirWatch,SIGNAL(dirty(const QString&)),this
- ,SLOT(directoryChanged(const QString&)));
- connect(_dirWatch,SIGNAL(created(const QString&)),this
- ,SLOT(directoryChanged(const QString&)));
+ connect(_dirWatch,TQT_SIGNAL(deleted(const TQString&)),this
+ ,TQT_SLOT(directoryDeleted(const TQString&)));
+ connect(_dirWatch,TQT_SIGNAL(dirty(const TQString&)),this
+ ,TQT_SLOT(directoryChanged(const TQString&)));
+ connect(_dirWatch,TQT_SIGNAL(created(const TQString&)),this
+ ,TQT_SLOT(directoryChanged(const TQString&)));
_dirList.clear();
_fileList.clear();
- QListView::clear();
+ TQListView::clear();
}
void CatalogManagerView::toggleAllMarks()
{
_markerList.clear();
- QListViewItemIterator it( this );
+ TQListViewItemIterator it( this );
CatManListItem* item;
for ( ; it.current(); ++it )
@@ -397,7 +397,7 @@ void CatalogManagerView::toggleAllMarks()
void CatalogManagerView::clearAllMarks()
{
_markerList.clear();
- QDictIterator<CatManListItem> it( _fileList ); // iterator for dict
+ TQDictIterator<CatManListItem> it( _fileList ); // iterator for dict
while ( it.current() )
{
@@ -415,7 +415,7 @@ void CatalogManagerView::clearAllMarks()
void CatalogManagerView::markModifiedFiles()
{
- QDictIterator<CatManListItem> it( _fileList );
+ TQDictIterator<CatManListItem> it( _fileList );
while ( it.current() )
{
CatManListItem* item=it.current();
@@ -434,10 +434,10 @@ void CatalogManagerView::markModifiedFiles()
void CatalogManagerView::loadMarks()
{
- const KURL url = KFileDialog::getOpenURL( QString(),"*.marklist", this );
+ const KURL url = KFileDialog::getOpenURL( TQString(),"*.marklist", this );
if( url.isEmpty() ) return;
- QString filename;
+ TQString filename;
#if KDE_IS_VERSION( 3, 2, 90 )
if (!KIO::NetAccess::download( url, filename, this ) )
#else
@@ -450,13 +450,13 @@ void CatalogManagerView::loadMarks()
}
// now load from file
- QStringList newMarkerList; // better create new list in case of problems
- QFile f( filename );
+ TQStringList newMarkerList; // better create new list in case of problems
+ TQFile f( filename );
if( f.open( IO_ReadOnly) )
{
- QTextStream s(&f);
+ TQTextStream s(&f);
- QString input;
+ TQString input;
s >> input ;
if( input == "[Markers]" )
@@ -486,8 +486,8 @@ void CatalogManagerView::loadMarks()
KIO::NetAccess::removeTempFile( filename );
// test validity of list items
- QStringList testedList;
- QStringList::const_iterator it;
+ TQStringList testedList;
+ TQStringList::const_iterator it;
for( it=newMarkerList.constBegin() ; it!=newMarkerList.constEnd() ; ++it )
if( _fileList[(*it)] != 0 ) testedList.append( (*it) );
@@ -510,13 +510,13 @@ void CatalogManagerView::loadMarks()
void CatalogManagerView::saveMarks()
{
- const KURL url2 = KFileDialog::getSaveURL( QString(), "*.marklist", this );
+ const KURL url2 = KFileDialog::getSaveURL( TQString(), "*.marklist", this );
if( url2.isEmpty() ) return;
// ### FIXME: why is the file dialog not doing this?
if ( KIO::NetAccess::exists( url2, false, this ) )
{
- if(KMessageBox::warningContinueCancel(this,QString("<qt>%1</qt>").arg(i18n("The file %1 already exists. "
+ if(KMessageBox::warningContinueCancel(this,TQString("<qt>%1</qt>").arg(i18n("The file %1 already exists. "
"Do you want to overwrite it?").arg(url2.prettyURL())),i18n("Warning"),i18n("&Overwrite"))==KMessageBox::Cancel)
{
return;
@@ -531,19 +531,19 @@ void CatalogManagerView::saveMarks()
#endif
kdDebug() << "Saving marks: " << url2.prettyURL() << " most-local: " << url.prettyURL() << endl;
- QFile* file = 0;
+ TQFile* file = 0;
KTempFile* tempFile = 0;
- QTextStream* stream = 0;
+ TQTextStream* stream = 0;
bool error = false;
const bool localFile = url.isLocalFile();
if ( localFile )
{
// We have a local file
- file = new QFile( url.path() );
+ file = new TQFile( url.path() );
if ( file->open (IO_WriteOnly) )
{
- stream = new QTextStream( file );
+ stream = new TQTextStream( file );
}
else
{
@@ -561,7 +561,7 @@ void CatalogManagerView::saveMarks()
{
// ### TODO: try to get a better file format for KDE4 (XML?), one working with real relative paths (no / at start) and working with UTF-8
*stream << "[Markers]" << endl;
- for( QStringList::const_iterator it = _markerList.constBegin(); it!=_markerList.constEnd() ; ++it )
+ for( TQStringList::const_iterator it = _markerList.constBegin(); it!=_markerList.constEnd() ; ++it )
*stream << (*it) << endl;
}
if ( error )
@@ -622,20 +622,20 @@ void CatalogManagerView::setPatternMarks(bool mark)
if (markPatternDialog->exec( ) != KDialog::Accepted)
return;
- QRegExp rx(markPatternDialog->pattern( ));
+ TQRegExp rx(markPatternDialog->pattern( ));
rx.setWildcard(!markPatternDialog->useRegExp( ));
rx.setCaseSensitive(markPatternDialog->isCaseSensitive( ));
- QStringList fileList = item->allChildrenList(true);
- for (QStringList::const_iterator it = fileList.constBegin( ); it != fileList.constEnd( ); ++it) {
+ TQStringList fileList = item->allChildrenList(true);
+ for (TQStringList::const_iterator it = fileList.constBegin( ); it != fileList.constEnd( ); ++it) {
CatManListItem * i = _fileList[*it];
- QString matchName;
+ TQString matchName;
if (i->hasPo( ))
matchName = i->poFile( );
else if (i->hasPot( ) && markPatternDialog->includeTemplates( ))
matchName = i->potFile( );
- matchName = QFileInfo(matchName).baseName( );
+ matchName = TQFileInfo(matchName).baseName( );
if (mark) {
if (!matchName.isEmpty( ) && rx.exactMatch(matchName) && !i->marked( )) {
@@ -670,7 +670,7 @@ void CatalogManagerView::statistics()
}
}
- QStringList doList;
+ TQStringList doList;
if( i->isFile() ) doList.append(i->package());
else doList = i->allChildrenList(true);
@@ -697,13 +697,13 @@ void CatalogManagerView::markedStatistics()
}
}
- QStringList doList;
+ TQStringList doList;
if( i->isFile() ) doList.append(i->package());
else doList = i->allChildrenList(true);
- QStringList markedDoList;
- QStringList::const_iterator it;
+ TQStringList markedDoList;
+ TQStringList::const_iterator it;
for( it = doList.constBegin(); it != doList.constEnd(); ++it )
{
CatManListItem* item = _fileList[(*it)];
@@ -713,11 +713,11 @@ void CatalogManagerView::markedStatistics()
showStatistics( i, markedDoList );
}
-void CatalogManagerView::showStatistics( CatManListItem *i, QStringList &childrenList )
+void CatalogManagerView::showStatistics( CatManListItem *i, TQStringList &childrenList )
{
KLocale *locale = KGlobal::locale();
- QString msg;
+ TQString msg;
int totalPackages=0;
int totalPo=0;
int totalNoPot=0;
@@ -726,7 +726,7 @@ void CatalogManagerView::showStatistics( CatManListItem *i, QStringList &childr
int totalFuzzy=0;
int totalUntranslated=0;
- QStringList::const_iterator it;
+ TQStringList::const_iterator it;
for( it = childrenList.constBegin(); it != childrenList.constEnd(); ++it )
{
CatManListItem* item = _fileList[(*it)];
@@ -764,7 +764,7 @@ void CatalogManagerView::showStatistics( CatManListItem *i, QStringList &childr
double percent;
- const QString name=i->package(false);
+ const TQString name=i->package(false);
if(name.isEmpty())
msg = i18n("Statistics for all:\n");
else
@@ -808,7 +808,7 @@ void CatalogManagerView::checkSyntax()
return;
Msgfmt::Status status;
- QString output;
+ TQString output;
Msgfmt msgfmt;
status=msgfmt.checkSyntax(item->poFile(),output);
@@ -851,18 +851,18 @@ void CatalogManagerView::checkSyntax()
else
{
Msgfmt::Status status;
- QString output;
+ TQString output;
Msgfmt msgfmt;
status=msgfmt.checkSyntaxInDir(item->poFile(), "*.po", output);
- QString name=item->package(false);
+ TQString name=item->package(false);
switch(status)
{
case Msgfmt::Ok:
{
- QString msg;
+ TQString msg;
if(!name.isEmpty())
{
msg=i18n("All files in folder %1 are syntactically correct.\n"
@@ -878,7 +878,7 @@ void CatalogManagerView::checkSyntax()
}
case Msgfmt::SyntaxError:
{
- QString msg;
+ TQString msg;
if(!name.isEmpty())
{
msg=i18n("At least one file in folder %1 has syntax errors.\n"
@@ -894,7 +894,7 @@ void CatalogManagerView::checkSyntax()
}
case Msgfmt::HeaderError:
{
- QString msg;
+ TQString msg;
if(!name.isEmpty())
{
msg=i18n("At least one file in folder %1 has header syntax errors.\n"
@@ -910,7 +910,7 @@ void CatalogManagerView::checkSyntax()
}
case Msgfmt::Error:
{
- QString msg;
+ TQString msg;
if(!name.isEmpty())
{
msg=i18n("An error occurred while processing \"msgfmt --statistics *.po\" "
@@ -940,12 +940,12 @@ void CatalogManagerView::checkSyntax()
void CatalogManagerView::roughTranslation()
{
- QPtrList<CatManListItem> result;
+ TQPtrList<CatManListItem> result;
CatManListItem *current = static_cast<CatManListItem *>(currentItem());
if( current->isDir() )
{
- QStringList s = current->allChildrenList(true);
- QStringList::const_iterator it;
+ TQStringList s = current->allChildrenList(true);
+ TQStringList::const_iterator it;
for( it = s.constBegin() ; it != s.constEnd(); ++it )
{
CatManListItem *item = _fileList[(*it)];
@@ -966,9 +966,9 @@ void CatalogManagerView::markedRoughTranslation()
{
if( _markerList.count() == 0 ) return;
- QPtrList<CatManListItem> result;
+ TQPtrList<CatManListItem> result;
- QStringList::const_iterator it;
+ TQStringList::const_iterator it;
for( it = _markerList.constBegin() ; it != _markerList.constEnd(); ++it )
{
CatManListItem *item = _fileList[(*it)];
@@ -984,10 +984,10 @@ void CatalogManagerView::mailFiles()
{
CatManListItem* item = (CatManListItem*)currentItem();
if(item->isDir()) {
- QStringList filesToSend;
- QStringList childrenList = item->allChildrenList(true);
+ TQStringList filesToSend;
+ TQStringList childrenList = item->allChildrenList(true);
- QStringList::const_iterator it;
+ TQStringList::const_iterator it;
for (it = childrenList.constBegin(); it != childrenList.constEnd(); ++it) {
CatManListItem* i = _fileList[(*it)];
if (i->hasPo()) {
@@ -1007,8 +1007,8 @@ void CatalogManagerView::mailMarkedFiles()
if (_markerList.count() == 0)
return;
- QStringList filesToSend;
- QStringList::const_iterator it;
+ TQStringList filesToSend;
+ TQStringList::const_iterator it;
for (it = _markerList.constBegin(); it != _markerList.constEnd(); ++it) {
CatManListItem* i = _fileList[(*it)];
if (i->hasPo()) {
@@ -1022,24 +1022,24 @@ void CatalogManagerView::packageFiles( )
{
CatManListItem* item = (CatManListItem*)currentItem();
if(item->isDir()) {
- QStringList filesToPackage;
- QStringList childrenList = item->allChildrenList(true);
+ TQStringList filesToPackage;
+ TQStringList childrenList = item->allChildrenList(true);
- QStringList::const_iterator it;
+ TQStringList::const_iterator it;
for (it = childrenList.constBegin(); it != childrenList.constEnd(); ++it) {
CatManListItem* i = _fileList[(*it)];
if (i->hasPo()) {
filesToPackage << i->poFile();
}
}
- QString packageFileName = KFileDialog::getSaveFileName(QString::null,"*.tar.bz2\n*.tar.gz",this);
- mailer->buildArchive( filesToPackage, packageFileName, QString::null, false );
+ TQString packageFileName = KFileDialog::getSaveFileName(TQString::null,"*.tar.bz2\n*.tar.gz",this);
+ mailer->buildArchive( filesToPackage, packageFileName, TQString::null, false );
}
else {
if (item->hasPo()) {
- QStringList fileToPackage(item->poFile());
- QString packageFileName = KFileDialog::getSaveFileName(QString::null,"*.tar.bz2\n*.tar.gz",this);
- mailer->buildArchive( fileToPackage, packageFileName, QString::null, false );
+ TQStringList fileToPackage(item->poFile());
+ TQString packageFileName = KFileDialog::getSaveFileName(TQString::null,"*.tar.bz2\n*.tar.gz",this);
+ mailer->buildArchive( fileToPackage, packageFileName, TQString::null, false );
}
}
}
@@ -1048,8 +1048,8 @@ void CatalogManagerView::packageMarkedFiles( )
if (_markerList.count() == 0)
return;
- QStringList filesToPackage;
- QStringList::const_iterator it;
+ TQStringList filesToPackage;
+ TQStringList::const_iterator it;
for (it = _markerList.constBegin(); it != _markerList.constEnd(); ++it) {
CatManListItem* i = _fileList[(*it)];
if (i->hasPo()) {
@@ -1057,8 +1057,8 @@ void CatalogManagerView::packageMarkedFiles( )
}
}
- QString packageFileName = KFileDialog::getSaveFileName(QString::null,"*.tar.bz2\n*.tar.gz",this);
- mailer->buildArchive( filesToPackage, packageFileName, QString::null, false );
+ TQString packageFileName = KFileDialog::getSaveFileName(TQString::null,"*.tar.bz2\n*.tar.gz",this);
+ mailer->buildArchive( filesToPackage, packageFileName, TQString::null, false );
}
// CVS
@@ -1122,8 +1122,8 @@ void CatalogManagerView::doCVSCommand( CVS::Command cmd, bool marked, bool templ
KSharedConfig* config = _project->sharedConfig();
if ( marked ) {
if ( _markerList.isEmpty() ) return;
- QStringList fileList;
- QStringList::const_iterator it;
+ TQStringList fileList;
+ TQStringList::const_iterator it;
for ( it = _markerList.constBegin( ); it != _markerList.constEnd( ); ++it ) {
CatManListItem * i = _fileList[(*it)];
if ( templates && i->hasPot( ) )
@@ -1133,12 +1133,12 @@ void CatalogManagerView::doCVSCommand( CVS::Command cmd, bool marked, bool templ
}
cvshandler->execCVSCommand( this, cmd, fileList, templates, config );
} else {
- const QString basedir = ( templates ? _settings.potBaseDir : _settings.poBaseDir );
- QString cvsItem;
+ const TQString basedir = ( templates ? _settings.potBaseDir : _settings.poBaseDir );
+ TQString cvsItem;
CatManListItem * item = (CatManListItem*)currentItem( );
if ( ( cmd == CVS::Commit || cmd == CVS::Diff ) && item->isDir( ) ) {
// all children including directories
- QStringList cvsItems = item->allChildrenFileList (true, false, true);
+ TQStringList cvsItems = item->allChildrenFileList (true, false, true);
if ( !cvsItems.isEmpty( ) )
cvshandler->execCVSCommand( this, cmd, cvsItems, templates, config );
} else {
@@ -1234,8 +1234,8 @@ void CatalogManagerView::doSVNCommand( SVN::Command cmd, bool marked, bool templ
KSharedConfig* config = _project->sharedConfig();
if ( marked ) {
if ( _markerList.isEmpty() ) return;
- QStringList fileList;
- QStringList::const_iterator it;
+ TQStringList fileList;
+ TQStringList::const_iterator it;
for ( it = _markerList.constBegin( ); it != _markerList.constEnd( ); ++it ) {
CatManListItem * i = _fileList[(*it)];
if ( templates && i->hasPot( ) )
@@ -1245,12 +1245,12 @@ void CatalogManagerView::doSVNCommand( SVN::Command cmd, bool marked, bool templ
}
svnhandler->execSVNCommand( this, cmd, fileList, templates, config );
} else {
- const QString basedir = ( templates ? _settings.potBaseDir : _settings.poBaseDir );
- QString svnItem;
+ const TQString basedir = ( templates ? _settings.potBaseDir : _settings.poBaseDir );
+ TQString svnItem;
CatManListItem * item = (CatManListItem*)currentItem( );
if ( ( cmd == SVN::Commit || cmd == SVN::Diff ) && item->isDir( ) ) {
// all children including directories
- QStringList svnItems = item->allChildrenFileList (true, false, true);
+ TQStringList svnItems = item->allChildrenFileList (true, false, true);
if ( !svnItems.isEmpty( ) )
svnhandler->execSVNCommand( this, cmd, svnItems, templates, config );
} else {
@@ -1270,26 +1270,26 @@ void CatalogManagerView::showLog()
_logWindow->show();
}
-QString CatalogManagerView::find( FindOptions &options, QStringList &rest )
+TQString CatalogManagerView::find( FindOptions &options, TQStringList &rest )
{
CatManListItem* i=(CatManListItem*) currentItem();
if(!i || options.inAllFiles)
i=(CatManListItem*)_dirList["/"];
- QValueList<QString> foundFiles;
+ TQValueList<TQString> foundFiles;
_stopSearch = false;
- const QString search = options.findStr.lower().simplifyWhiteSpace();
- QStringList searchWords = QStringList::split(' ', search);
+ const TQString search = options.findStr.lower().simplifyWhiteSpace();
+ TQStringList searchWords = TQStringList::split(' ', search);
- QStringList childrenList;
+ TQStringList childrenList;
if( i->isFile() ) childrenList.append(i->name());
else childrenList =i->allChildrenList(true);
emit prepareFindProgressBar(childrenList.size());
- QStringList::const_iterator it;
+ TQStringList::const_iterator it;
for( it = childrenList.constBegin(); it != childrenList.constEnd(); ++it )
{
CatManListItem* item = _fileList[(*it)];
@@ -1314,7 +1314,7 @@ QString CatalogManagerView::find( FindOptions &options, QStringList &rest )
else doSearch = true; // we do not have index, we need to search
if( doSearch )
{
- QString itemFile;
+ TQString itemFile;
if( options.inTemplates )
{
if( item->hasPot() ) itemFile=item->potFile();
@@ -1338,14 +1338,14 @@ QString CatalogManagerView::find( FindOptions &options, QStringList &rest )
_stopSearch = false;
return itemFile;
}
- const QString foundItemFile = itemFile;
+ const TQString foundItemFile = itemFile;
it++;
while( it != childrenList.constEnd() )
{
CatManListItem *item = _fileList[(*it)];
- itemFile = QString::null;
+ itemFile = TQString::null;
if( options.inTemplates )
{
if( item->hasPot() ) itemFile=item->potFile();
@@ -1353,7 +1353,7 @@ QString CatalogManagerView::find( FindOptions &options, QStringList &rest )
if( item->hasPo() )itemFile=item->poFile();
}
if( options.inMarkedFiles && !item->marked() )
- itemFile=QString::null;
+ itemFile=TQString::null;
if( !itemFile.isNull())
{
@@ -1380,23 +1380,23 @@ QString CatalogManagerView::find( FindOptions &options, QStringList &rest )
_stopSearch = false;
rest.clear();
if( _updateNesting == 0 && !_stop ) emit updateFinished();
- return QString::null;
+ return TQString::null;
}
}
- return QString::null;
+ return TQString::null;
}
-bool CatalogManagerView::hasMatchingWords( QStringList &itemWords, QStringList &searchWords)
+bool CatalogManagerView::hasMatchingWords( TQStringList &itemWords, TQStringList &searchWords)
{
- for( QStringList::const_iterator it1 = searchWords.constBegin() ; it1 != searchWords.constEnd() ; ++it1 )
- for( QStringList::const_iterator it2 = itemWords.constBegin() ; it2 != itemWords.constEnd() ; ++it2 )
+ for( TQStringList::const_iterator it1 = searchWords.constBegin() ; it1 != searchWords.constEnd() ; ++it1 )
+ for( TQStringList::const_iterator it2 = itemWords.constBegin() ; it2 != itemWords.constEnd() ; ++it2 )
if( *it1 == *it2
|| (*it1).contains(*it2)
|| (*it2).contains(*it1) ) return true;
return false;
}
-void CatalogManagerView::showContentsMenu(QListViewItem *i, const QPoint &point, int)
+void CatalogManagerView::showContentsMenu(TQListViewItem *i, const TQPoint &point, int)
{
CatManListItem* item = (CatManListItem*) i;
@@ -1427,7 +1427,7 @@ void CatalogManagerView::checkSelected()
emit selectedChanged(actionValue);
}
-void CatalogManagerView::activateItem(QListViewItem *)
+void CatalogManagerView::activateItem(TQListViewItem *)
{
CatManListItem* item=(CatManListItem*) currentItem();
@@ -1471,7 +1471,7 @@ void CatalogManagerView::slotOpenFileInNewWindow()
if(item && item->isFile())
{
- QString filename;
+ TQString filename;
if(item->hasPo())
{
emit openFileInNewWindow(item->poFile(),item->package());
@@ -1499,10 +1499,10 @@ void CatalogManagerView::slotDeleteFile()
if(item && item->isFile() && item->hasPo() && !item->hasPot())
{
- const QString msg=i18n("Do you really want to delete the file %1?").arg(item->poFile());
+ const TQString msg=i18n("Do you really want to delete the file %1?").arg(item->poFile());
if(KMessageBox::warningContinueCancel(this,msg,i18n("Warning"),KGuiItem( i18n("Delete"), "editdelete"))== KMessageBox::Continue)
{
- if(!QFile::remove(item->poFile()))
+ if(!TQFile::remove(item->poFile()))
{
KMessageBox::sorry(this,i18n("Was not able to delete the file %1!").arg(item->poFile()));
}
@@ -1545,9 +1545,9 @@ void CatalogManagerView::slotToggleMarksInDir()
if(i && i->isDir())
{
- const QStringList contentList = i->allChildrenList(true);
+ const TQStringList contentList = i->allChildrenList(true);
- QStringList::const_iterator it;
+ TQStringList::const_iterator it;
for( it = contentList.constBegin(); it != contentList.constEnd(); ++it )
{
CatManListItem* item = _fileList[(*it)];
@@ -1579,9 +1579,9 @@ void CatalogManagerView::slotClearMarksInDir()
if(i && i->isDir())
{
- const QStringList contentList=i->contentsList(true);
+ const TQStringList contentList=i->contentsList(true);
- QStringList::const_iterator it;
+ TQStringList::const_iterator it;
for( it = contentList.constBegin(); it != contentList.constEnd(); ++it )
{
CatManListItem* item = _fileList[(*it)];
@@ -1608,7 +1608,7 @@ void CatalogManagerView::slotDirCommand(int index)
if(index>=0 && item && item->isDir())
{
- QString cmd=*(_settings.dirCommands).at(index);
+ TQString cmd=*(_settings.dirCommands).at(index);
cmd.replace("@PACKAGE@",item->name());
cmd.replace("@PODIR@",item->poFile());
cmd.replace("@POTDIR@",item->potFile());
@@ -1620,12 +1620,12 @@ void CatalogManagerView::slotDirCommand(int index)
KProcess* proc = new KShellProcess();
_pendingProcesses.append(proc);
- connect( proc,SIGNAL( processExited(KProcess *) ), this
- ,SLOT( processEnded(KProcess*) ) );
- connect( proc,SIGNAL( receivedStdout(KProcess*,char*,int) ), this
- ,SLOT( showOutput(KProcess*,char*,int) ) );
- connect( proc,SIGNAL( receivedStderr(KProcess*,char*,int) ), this
- ,SLOT( showOutput(KProcess*,char*,int) ) );
+ connect( proc,TQT_SIGNAL( processExited(KProcess *) ), this
+ ,TQT_SLOT( processEnded(KProcess*) ) );
+ connect( proc,TQT_SIGNAL( receivedStdout(KProcess*,char*,int) ), this
+ ,TQT_SLOT( showOutput(KProcess*,char*,int) ) );
+ connect( proc,TQT_SIGNAL( receivedStderr(KProcess*,char*,int) ), this
+ ,TQT_SLOT( showOutput(KProcess*,char*,int) ) );
*proc << "cd" << item->poFile() << ";" << cmd;
proc->start(KProcess::NotifyOnExit,KProcess::AllOutput);
@@ -1640,7 +1640,7 @@ void CatalogManagerView::slotFileCommand(int index)
{
CatManListItem* parent = (CatManListItem*)item->parent();
- QString cmd=*(_settings.fileCommands).at(index);
+ TQString cmd=*(_settings.fileCommands).at(index);
cmd.replace("@PACKAGE@",item->name());
cmd.replace("@POFILE@",item->poFile());
cmd.replace("@POTFILE@",item->potFile());
@@ -1653,12 +1653,12 @@ void CatalogManagerView::slotFileCommand(int index)
KProcess* proc = new KShellProcess();
_pendingProcesses.append(proc);
- connect( proc,SIGNAL( processExited(KProcess *) ), this
- ,SLOT( processEnded(KProcess*) ) );
- connect( proc,SIGNAL( receivedStdout(KProcess*,char*,int) ), this
- ,SLOT( showOutput(KProcess*,char*,int) ) );
- connect( proc,SIGNAL( receivedStderr(KProcess*,char*,int) ), this
- ,SLOT( showOutput(KProcess*,char*,int) ) );
+ connect( proc,TQT_SIGNAL( processExited(KProcess *) ), this
+ ,TQT_SLOT( processEnded(KProcess*) ) );
+ connect( proc,TQT_SIGNAL( receivedStdout(KProcess*,char*,int) ), this
+ ,TQT_SLOT( showOutput(KProcess*,char*,int) ) );
+ connect( proc,TQT_SIGNAL( receivedStderr(KProcess*,char*,int) ), this
+ ,TQT_SLOT( showOutput(KProcess*,char*,int) ) );
*proc << "cd" << parent->poFile() << ";" << cmd;
proc->start(KProcess::NotifyOnExit,KProcess::AllOutput);
@@ -1667,9 +1667,9 @@ void CatalogManagerView::slotFileCommand(int index)
}
-void CatalogManagerView::updateFile(QString fileWithPath, bool force)
+void CatalogManagerView::updateFile(TQString fileWithPath, bool force)
{
- QString relFile;
+ TQString relFile;
if(fileWithPath.startsWith(_settings.poBaseDir))
{
relFile=fileWithPath.mid(_settings.poBaseDir.length());
@@ -1704,9 +1704,9 @@ void CatalogManagerView::updateFile(QString fileWithPath, bool force)
}
-void CatalogManagerView::updateAfterSave(QString fileWithPath, PoInfo &newInfo)
+void CatalogManagerView::updateAfterSave(TQString fileWithPath, PoInfo &newInfo)
{
- QString relFile;
+ TQString relFile;
if(fileWithPath.startsWith(_settings.poBaseDir))
{
relFile=fileWithPath.mid(_settings.poBaseDir.length());
@@ -1741,7 +1741,7 @@ void CatalogManagerView::updateAfterSave(QString fileWithPath, PoInfo &newInfo)
void CatalogManagerView::buildTree()
{
// in case we were called after settings update
- disconnect( this, SIGNAL( updateFinished() ), this, SLOT(buildTree() ) );
+ disconnect( this, TQT_SIGNAL( updateFinished() ), this, TQT_SLOT(buildTree() ) );
emit signalBuildTree(false); // announce start of building
@@ -1760,7 +1760,7 @@ void CatalogManagerView::buildTree()
_dirList.insert("/",root);
//root->setSelectable(false);
- QFileInfo fileInfo(_settings.poBaseDir);
+ TQFileInfo fileInfo(_settings.poBaseDir);
if(!fileInfo.isDir())
{
KMessageBox::error(this,i18n("You have not specified a valid folder "
@@ -1833,7 +1833,7 @@ void CatalogManagerView::buildTree()
}
// first read information about the files...
- QDictIterator<CatManListItem> it( _fileList ); // iterator for dict
+ TQDictIterator<CatManListItem> it( _fileList ); // iterator for dict
int i=0;
while ( it.current() && !_stop)
@@ -1844,7 +1844,7 @@ void CatalogManagerView::buildTree()
}
// ...then update directories
- QDictIterator<CatManListItem> dit( _dirList ); // iterator for dict
+ TQDictIterator<CatManListItem> dit( _dirList ); // iterator for dict
while ( dit.current() && !_stop)
{
@@ -1868,12 +1868,12 @@ void CatalogManagerView::buildTree()
}
}
-bool CatalogManagerView::buildDir(QString relDir,bool fast)
+bool CatalogManagerView::buildDir(TQString relDir,bool fast)
{
if( _stop ) return false;
bool haveTemplateDir=true;
- QFileInfo fileInfo;
+ TQFileInfo fileInfo;
fileInfo.setFile(_settings.potBaseDir);
if(!fileInfo.isDir())
@@ -1891,8 +1891,8 @@ bool CatalogManagerView::buildDir(QString relDir,bool fast)
}
-bool CatalogManagerView::buildDir(const QString& baseDir,const QString& relDir
- , const QString extension , bool fast)
+bool CatalogManagerView::buildDir(const TQString& baseDir,const TQString& relDir
+ , const TQString extension , bool fast)
{
if( _stop ) return false;
@@ -1905,14 +1905,14 @@ bool CatalogManagerView::buildDir(const QString& baseDir,const QString& relDir
return false;
}
- const QString poBaseDir=_settings.poBaseDir;
- const QString potBaseDir=_settings.potBaseDir;
+ const TQString poBaseDir=_settings.poBaseDir;
+ const TQString potBaseDir=_settings.potBaseDir;
// traverse directory in poBaseDir
- QDir dir(baseDir+relDir);
- QStringList entryList=dir.entryList("*"+extension,QDir::Files,QDir::Name);
+ TQDir dir(baseDir+relDir);
+ TQStringList entryList=dir.entryList("*"+extension,TQDir::Files,TQDir::Name);
- QStringList::const_iterator it;
+ TQStringList::const_iterator it;
for ( it = entryList.constBegin(); it != entryList.constEnd() && !_stop ; ++it )
{
@@ -1920,8 +1920,8 @@ bool CatalogManagerView::buildDir(const QString& baseDir,const QString& relDir
havePoFiles=true;
- QString file=relDir+(*it);
- file.remove(QRegExp(extension+"$"));
+ TQString file=relDir+(*it);
+ file.remove(TQRegExp(extension+"$"));
CatManListItem* item = _fileList[file];
if(!item)
{
@@ -1941,7 +1941,7 @@ bool CatalogManagerView::buildDir(const QString& baseDir,const QString& relDir
}
}
- entryList=dir.entryList(QDir::Dirs,QDir::Name);
+ entryList=dir.entryList(TQDir::Dirs,TQDir::Name);
for ( it = entryList.constBegin(); it != entryList.constEnd() && !_stop ; ++it )
{
@@ -1952,7 +1952,7 @@ bool CatalogManagerView::buildDir(const QString& baseDir,const QString& relDir
continue;
}
- QString subDir=relDir+(*it)+"/";
+ TQString subDir=relDir+(*it)+"/";
if(!_dirWatch->contains(baseDir+subDir))
{
_dirWatch->addDir(baseDir+subDir);
@@ -1987,7 +1987,7 @@ bool CatalogManagerView::buildDir(const QString& baseDir,const QString& relDir
}
-void CatalogManagerView::updateDir(QString relDir)
+void CatalogManagerView::updateDir(TQString relDir)
{
if( _stop ) return;
@@ -2002,16 +2002,16 @@ void CatalogManagerView::updateDir(QString relDir)
return;
}
- QStringList contentList = thisItem->contentsList(true);
+ TQStringList contentList = thisItem->contentsList(true);
- const QString poBaseDir=_settings.poBaseDir;
- const QString potBaseDir=_settings.potBaseDir;
+ const TQString poBaseDir=_settings.poBaseDir;
+ const TQString potBaseDir=_settings.potBaseDir;
// first lookup template directory
- QDir dir(potBaseDir+relDir);
- QStringList entryList=dir.entryList("*.pot",QDir::Files,QDir::Name);
+ TQDir dir(potBaseDir+relDir);
+ TQStringList entryList=dir.entryList("*.pot",TQDir::Files,TQDir::Name);
- QStringList::const_iterator it;
+ TQStringList::const_iterator it;
for ( it = entryList.constBegin(); it != entryList.constEnd(); ++it )
{
@@ -2019,8 +2019,8 @@ void CatalogManagerView::updateDir(QString relDir)
havePoFiles=true;
- QString file=relDir+(*it);
- file.remove(QRegExp(".pot$"));
+ TQString file=relDir+(*it);
+ file.remove(TQRegExp(".pot$"));
CatManListItem* item = _fileList[file];
if(!item)
{
@@ -2042,7 +2042,7 @@ void CatalogManagerView::updateDir(QString relDir)
contentList.remove(file);
}
- entryList=dir.entryList(QDir::Dirs,QDir::Name);
+ entryList=dir.entryList(TQDir::Dirs,TQDir::Name);
for ( it = entryList.constBegin(); it != entryList.constEnd(); ++it )
{
@@ -2055,7 +2055,7 @@ void CatalogManagerView::updateDir(QString relDir)
bool newDirAdded=false;
- QString subDir=relDir+(*it)+"/";
+ TQString subDir=relDir+(*it)+"/";
if(!_dirWatch->contains(potBaseDir+subDir))
{
_dirWatch->addDir(potBaseDir+subDir);
@@ -2093,7 +2093,7 @@ void CatalogManagerView::updateDir(QString relDir)
// now traverse directory in poBaseDir
dir.setPath(poBaseDir+relDir);
- entryList=dir.entryList("*.po",QDir::Files,QDir::Name);
+ entryList=dir.entryList("*.po",TQDir::Files,TQDir::Name);
for ( it = entryList.constBegin(); it != entryList.constEnd(); ++it )
{
@@ -2101,8 +2101,8 @@ void CatalogManagerView::updateDir(QString relDir)
if( _stop ) return;
- QString file=relDir+(*it);
- file.remove(QRegExp(".po$"));
+ TQString file=relDir+(*it);
+ file.remove(TQRegExp(".po$"));
CatManListItem* item = _fileList[file];
if(!item)
{
@@ -2124,7 +2124,7 @@ void CatalogManagerView::updateDir(QString relDir)
contentList.remove(file);
}
- entryList=dir.entryList(QDir::Dirs,QDir::Name);
+ entryList=dir.entryList(TQDir::Dirs,TQDir::Name);
for ( it = entryList.constBegin(); it != entryList.constEnd(); ++it )
{
@@ -2137,7 +2137,7 @@ void CatalogManagerView::updateDir(QString relDir)
bool newDirAdded=false;
- QString subDir=relDir+(*it)+"/";
+ TQString subDir=relDir+(*it)+"/";
if(!_dirWatch->contains(poBaseDir+subDir))
{
_dirWatch->addDir(poBaseDir+subDir);
@@ -2180,11 +2180,11 @@ void CatalogManagerView::updateDir(QString relDir)
// but only if we traversed also the template directory
if(contentList.count()>0)
{
- QStringList::const_iterator it;
+ TQStringList::const_iterator it;
for( it = contentList.constBegin(); it != contentList.constEnd(); ++it )
{
- QFileInfo po(poBaseDir+(*it));
- QFileInfo pot(potBaseDir+(*it));
+ TQFileInfo po(poBaseDir+(*it));
+ TQFileInfo pot(potBaseDir+(*it));
if(!po.exists() && !pot.exists())
{
@@ -2217,11 +2217,11 @@ void CatalogManagerView::updateDir(QString relDir)
}
}
-void CatalogManagerView::directoryChanged(const QString& dir)
+void CatalogManagerView::directoryChanged(const TQString& dir)
{
pause(true);
- QString relDir, relDirPo, relDirPot;
+ TQString relDir, relDirPo, relDirPot;
if(dir.startsWith(_settings.poBaseDir))
{
relDirPo=dir.mid(_settings.poBaseDir.length());
@@ -2261,13 +2261,13 @@ void CatalogManagerView::directoryChanged(const QString& dir)
kdDebug(KBABEL_CATMAN) << "directory changed: " << relDir << endl;
- QFileInfo fileInfo(_settings.potBaseDir);
+ TQFileInfo fileInfo(_settings.potBaseDir);
CatManListItem* thisItem=_dirList[relDir];
if(!thisItem)
{
// if this item is not in the list search for next existing parent item
- QString prevRelDir;
+ TQString prevRelDir;
do
{
prevRelDir=relDir;
@@ -2312,11 +2312,11 @@ void CatalogManagerView::directoryChanged(const QString& dir)
}
-void CatalogManagerView::directoryDeleted(const QString& dir)
+void CatalogManagerView::directoryDeleted(const TQString& dir)
{
pause(true);
- QString relDir, relDirPo, relDirPot;
+ TQString relDir, relDirPo, relDirPot;
if(dir.startsWith(_settings.poBaseDir))
{
relDirPo=dir.mid(_settings.poBaseDir.length());
@@ -2371,10 +2371,10 @@ void CatalogManagerView::directoryDeleted(const QString& dir)
}
else
{
- QStringList childList = thisItem->contentsList();
+ TQStringList childList = thisItem->contentsList();
CatManListItem* item;
- QStringList::const_iterator it;
+ TQStringList::const_iterator it;
for( it = childList.constBegin();it != childList.constEnd(); ++it )
{
item=_fileList[(*it)];
@@ -2415,7 +2415,7 @@ void CatalogManagerView::directoryDeleted(const QString& dir)
pause(false);
}
-void CatalogManagerView::fileInfoRead( QString filename )
+void CatalogManagerView::fileInfoRead( TQString filename )
{
if( _readInfoFileList.find( filename ) != _readInfoFileList.end() ) {
emit progress( ++_readInfoCount);
@@ -2437,25 +2437,25 @@ void CatalogManagerView::setSettings(CatManSettings newSettings)
_dirCommandsMenu->clear();
int counter=0;
- for ( QStringList::const_iterator it = _settings.dirCommandNames.constBegin()
+ for ( TQStringList::const_iterator it = _settings.dirCommandNames.constBegin()
; it != _settings.dirCommandNames.constEnd(); ++it )
{
_dirCommandsMenu->insertItem((*it),counter);
counter++;
}
_dirCommandsMenu->insertSeparator();
- _dirCommandsMenu->insertItem(i18n("Log Window"),this,SLOT(showLog()));
+ _dirCommandsMenu->insertItem(i18n("Log Window"),this,TQT_SLOT(showLog()));
_fileCommandsMenu->clear();
counter=0;
- for ( QStringList::const_iterator it = _settings.fileCommandNames.constBegin()
+ for ( TQStringList::const_iterator it = _settings.fileCommandNames.constBegin()
; it != _settings.fileCommandNames.constEnd(); ++it )
{
_fileCommandsMenu->insertItem((*it),counter);
counter++;
}
_fileCommandsMenu->insertSeparator();
- _fileCommandsMenu->insertItem(i18n("Log Window"),this,SLOT(showLog()));
+ _fileCommandsMenu->insertItem(i18n("Log Window"),this,TQT_SLOT(showLog()));
const bool pathChanged = (oldSettings.poBaseDir!=_settings.poBaseDir)
|| (oldSettings.potBaseDir!=_settings.potBaseDir);
@@ -2463,10 +2463,10 @@ void CatalogManagerView::setSettings(CatManSettings newSettings)
if(pathChanged)
{
if( !isActive() ) {
- QTimer::singleShot(100,this,SLOT(buildTree()));
+ TQTimer::singleShot(100,this,TQT_SLOT(buildTree()));
} else {
stop();
- connect( this, SIGNAL( updateFinished() ), this, SLOT(buildTree() ) );
+ connect( this, TQT_SIGNAL( updateFinished() ), this, TQT_SLOT(buildTree() ) );
}
}
@@ -2487,7 +2487,7 @@ CatManSettings CatalogManagerView::settings() const
}
-void CatalogManagerView::hideEvent(QHideEvent*)
+void CatalogManagerView::hideEvent(TQHideEvent*)
{
pause(true);
@@ -2495,9 +2495,9 @@ void CatalogManagerView::hideEvent(QHideEvent*)
_dirWatch->stopScan();
}
-void CatalogManagerView::showEvent(QShowEvent*)
+void CatalogManagerView::showEvent(TQShowEvent*)
{
- QTimer::singleShot(1,this,SLOT(checkUpdate()));
+ TQTimer::singleShot(1,this,TQT_SLOT(checkUpdate()));
pause(false);
@@ -2505,15 +2505,15 @@ void CatalogManagerView::showEvent(QShowEvent*)
_dirWatch->startScan(true);
}
-void CatalogManagerView::contentsMousePressEvent(QMouseEvent* event)
+void CatalogManagerView::contentsMousePressEvent(TQMouseEvent* event)
{
if(event->button() == LeftButton)
_pressPos=event->pos();
- QListView::contentsMousePressEvent( event );
+ TQListView::contentsMousePressEvent( event );
}
-void CatalogManagerView::contentsMouseMoveEvent(QMouseEvent* event)
+void CatalogManagerView::contentsMouseMoveEvent(TQMouseEvent* event)
{
if(event->state() & LeftButton)
{
@@ -2526,29 +2526,29 @@ void CatalogManagerView::contentsMouseMoveEvent(QMouseEvent* event)
{
// always add the po-file and if existing the pot-file to the drag and
// let the user decide what to do, when dropping into kbabel
- QStrList uri;
- uri.append(QUriDrag::localFileToUri(item->poFile()));
+ TQStrList uri;
+ uri.append(TQUriDrag::localFileToUri(item->poFile()));
if(item->hasPot())
- uri.append(QUriDrag::localFileToUri(item->potFile()));
+ uri.append(TQUriDrag::localFileToUri(item->potFile()));
- QUriDrag* drag = new QUriDrag(uri,this);
- QPixmap icon=KGlobal::iconLoader()->loadIcon("txt",KIcon::Desktop);
- drag->setPixmap(icon,QPoint(icon.width()/2,icon.height()/2));
+ TQUriDrag* drag = new TQUriDrag(uri,this);
+ TQPixmap icon=KGlobal::iconLoader()->loadIcon("txt",KIcon::Desktop);
+ drag->setPixmap(icon,TQPoint(icon.width()/2,icon.height()/2));
drag->drag();
}
else
{
- QListView::contentsMouseMoveEvent(event);
+ TQListView::contentsMouseMoveEvent(event);
}
}
else
{
- QListView::contentsMouseMoveEvent(event);
+ TQListView::contentsMouseMoveEvent(event);
}
}
else
{
- QListView::contentsMouseMoveEvent(event);
+ TQListView::contentsMouseMoveEvent(event);
}
}
@@ -2568,7 +2568,7 @@ void CatalogManagerView::saveMarker( KConfig* config) const
}
-void CatalogManagerView::deleteDirItem(QString relDir)
+void CatalogManagerView::deleteDirItem(TQString relDir)
{
CatManListItem* thisItem=_dirList[relDir];
@@ -2577,9 +2577,9 @@ void CatalogManagerView::deleteDirItem(QString relDir)
_dirList.remove(relDir);
- QStringList childList = thisItem->allChildrenList();
+ TQStringList childList = thisItem->allChildrenList();
- QStringList::const_iterator it;
+ TQStringList::const_iterator it;
for( it = childList.constBegin();it != childList.constEnd(); ++it )
{
if(!_fileList.remove((*it)))
@@ -2601,12 +2601,12 @@ void CatalogManagerView::processEnded(KProcess* proc)
void CatalogManagerView::showOutput(KProcess*, char *buffer, int buflen)
{
- const QCString output(buffer,buflen+1);
+ const TQCString output(buffer,buflen+1);
_logView->insert(output);
}
-void CatalogManagerView::columnClicked(QListViewItem * item, const QPoint &, int c)
+void CatalogManagerView::columnClicked(TQListViewItem * item, const TQPoint &, int c)
{
if( item && c == COL_MARKER )
{
@@ -2878,14 +2878,14 @@ void CatalogManagerView::gotoPreviousMarked()
}
}
-QStringList CatalogManagerView::current()
+TQStringList CatalogManagerView::current()
{
- QStringList result;
+ TQStringList result;
CatManListItem *current = static_cast<CatManListItem *>(currentItem());
if( current->isDir() )
{
- QStringList s = current->allChildrenList(true);
- QStringList::const_iterator it;
+ TQStringList s = current->allChildrenList(true);
+ TQStringList::const_iterator it;
for( it = s.constBegin() ; it != s.constEnd(); ++it )
{
CatManListItem *item = _fileList[(*it)];
@@ -2899,11 +2899,11 @@ QStringList CatalogManagerView::current()
return result;
}
-QStringList CatalogManagerView::marked()
+TQStringList CatalogManagerView::marked()
{
- QStringList result;
+ TQStringList result;
- QStringList::const_iterator it;
+ TQStringList::const_iterator it;
for( it = _markerList.constBegin() ; it != _markerList.constEnd(); ++it )
{
CatManListItem *item = _fileList[(*it)];
@@ -2943,9 +2943,9 @@ void CatalogManagerView::updateCurrent()
}
}
-void CatalogManagerView::updateFiles( const QStringList& files )
+void CatalogManagerView::updateFiles( const TQStringList& files )
{
- QStringList::ConstIterator it;
+ TQStringList::ConstIterator it;
for ( it = files.constBegin( ); it != files.constEnd( ); ++it ) {
updateFile( *it, true );
}
@@ -2961,14 +2961,14 @@ SVNHandler * CatalogManagerView::svnHandler( )
return svnhandler;
}
-void CatalogManagerView::validateUsingTool( const KDataToolInfo &tool, const QString& command )
+void CatalogManagerView::validateUsingTool( const KDataToolInfo &tool, const TQString& command )
{
- QStringList result;
+ TQStringList result;
CatManListItem *current = static_cast<CatManListItem *>(currentItem());
if( current->isDir() )
{
- const QStringList s = current->allChildrenList(true);
- QStringList::const_iterator it;
+ const TQStringList s = current->allChildrenList(true);
+ TQStringList::const_iterator it;
for( it = s.constBegin() ; it != s.constEnd(); ++it )
{
CatManListItem *item = _fileList[(*it)];
@@ -2983,12 +2983,12 @@ void CatalogManagerView::validateUsingTool( const KDataToolInfo &tool, const QSt
validate_internal( result, tool, command );
}
-void CatalogManagerView::validateMarkedUsingTool( const KDataToolInfo &tool, const QString& command )
+void CatalogManagerView::validateMarkedUsingTool( const KDataToolInfo &tool, const TQString& command )
{
validate_internal( _markerList, tool, command );
}
-void CatalogManagerView::validate_internal( const QStringList& files, const KDataToolInfo &tool, const QString& )
+void CatalogManagerView::validate_internal( const TQStringList& files, const KDataToolInfo &tool, const TQString& )
{
if( files.isEmpty() ) return;
@@ -3015,7 +3015,7 @@ void CatalogManagerView::validate_internal( const QStringList& files, const KDat
_validateOptions->ignoreFuzzy->setChecked( _ignoreFuzzy );
}
- if( _validateOptionsDlg->exec() != QDialog::Accepted )
+ if( _validateOptionsDlg->exec() != TQDialog::Accepted )
{
delete t;
@@ -3025,8 +3025,8 @@ void CatalogManagerView::validate_internal( const QStringList& files, const KDat
if( !_validateDialog )
{
_validateDialog = new ValidateProgressDialog(_settings.ignoreURL, this);
- connect( _validateDialog, SIGNAL( errorDoubleClicked(const QString,const int)),
- this, SLOT(showError( const QString, const int )));
+ connect( _validateDialog, TQT_SIGNAL( errorDoubleClicked(const TQString,const int)),
+ this, TQT_SLOT(showError( const TQString, const int )));
}
_markAsFuzzy = _validateOptions->markAsFuzzy->isChecked();
@@ -3035,9 +3035,9 @@ void CatalogManagerView::validate_internal( const QStringList& files, const KDat
_validateDialog->setMarkAsFuzzy(_markAsFuzzy);
_validateDialog->setIgnoreFuzzy(_ignoreFuzzy);
- QPtrList<CatManListItem> fileitems;
+ TQPtrList<CatManListItem> fileitems;
- for( QValueListConstIterator<QString> it=files.begin() ; it!=files.end() ; ++it )
+ for( TQValueListConstIterator<TQString> it=files.begin() ; it!=files.end() ; ++it )
{
CatManListItem* item=_fileList[ (*it) ];
if( item ) {
@@ -3050,7 +3050,7 @@ void CatalogManagerView::validate_internal( const QStringList& files, const KDat
delete t;
}
-void CatalogManagerView::showError( const QString package, const int num )
+void CatalogManagerView::showError( const TQString package, const int num )
{
CatManListItem* item = _fileList[ package];
if( !item )
@@ -3064,9 +3064,9 @@ void CatalogManagerView::showError( const QString package, const int num )
void CatalogManagerView::updateMarkerList()
{
- QStringList newMarkers;
+ TQStringList newMarkers;
- for( QStringList::const_iterator it = _markerList.constBegin(); it != _markerList.constEnd(); ++it ) {
+ for( TQStringList::const_iterator it = _markerList.constBegin(); it != _markerList.constEnd(); ++it ) {
if( _fileList[ (*it) ] )
newMarkers.append( (*it) );
}