summaryrefslogtreecommitdiffstats
path: root/buildtools/autotools/addexistingdirectoriesdlg.cpp
diff options
context:
space:
mode:
authortpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2010-07-31 19:56:07 +0000
committertpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2010-07-31 19:56:07 +0000
commitd6f8bbb45b267065a6907e71ff9c98bb6d161241 (patch)
treed109539636691d7b03036ca1c0ed29dbae6577cf /buildtools/autotools/addexistingdirectoriesdlg.cpp
parent3331a47a9cad24795c7440ee8107143ce444ef34 (diff)
downloadtdevelop-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 'buildtools/autotools/addexistingdirectoriesdlg.cpp')
-rw-r--r--buildtools/autotools/addexistingdirectoriesdlg.cpp76
1 files changed, 38 insertions, 38 deletions
diff --git a/buildtools/autotools/addexistingdirectoriesdlg.cpp b/buildtools/autotools/addexistingdirectoriesdlg.cpp
index 625d6af1..912edc52 100644
--- a/buildtools/autotools/addexistingdirectoriesdlg.cpp
+++ b/buildtools/autotools/addexistingdirectoriesdlg.cpp
@@ -14,8 +14,8 @@
* *
***************************************************************************/
-#include <qgroupbox.h>
-#include <qlayout.h>
+#include <tqgroupbox.h>
+#include <tqlayout.h>
#include <kprogress.h>
#include <klocale.h>
@@ -34,7 +34,7 @@
#include "addexistingdirectoriesdlg.h"
-AddExistingDirectoriesDialog::AddExistingDirectoriesDialog ( AutoProjectPart* part, AutoProjectWidget *widget, SubprojectItem* spitem, QWidget* parent, const char* name, bool modal, WFlags fl )
+AddExistingDirectoriesDialog::AddExistingDirectoriesDialog ( AutoProjectPart* part, AutoProjectWidget *widget, SubprojectItem* spitem, TQWidget* parent, const char* name, bool modal, WFlags fl )
: AddExistingDlgBase ( parent, name, modal, fl )
{
setIcon ( SmallIcon ( "fileimport.png" ) );
@@ -62,13 +62,13 @@ AddExistingDirectoriesDialog::AddExistingDirectoriesDialog ( AutoProjectPart* pa
setIcon ( SmallIcon ( "fileimport.png" ) );
- QWidget::setTabOrder(sourceSelector, addAllButton);
- QWidget::setTabOrder(addAllButton, addSelectedButton);
- QWidget::setTabOrder(addSelectedButton, importView);
- QWidget::setTabOrder(importView, removeAllButton);
- QWidget::setTabOrder(removeAllButton, removeSelectedButton);
- QWidget::setTabOrder(removeSelectedButton, okButton);
- QWidget::setTabOrder(okButton, cancelButton);
+ TQWidget::setTabOrder(sourceSelector, addAllButton);
+ TQWidget::setTabOrder(addAllButton, addSelectedButton);
+ TQWidget::setTabOrder(addSelectedButton, importView);
+ TQWidget::setTabOrder(importView, removeAllButton);
+ TQWidget::setTabOrder(removeAllButton, removeSelectedButton);
+ TQWidget::setTabOrder(removeSelectedButton, okButton);
+ TQWidget::setTabOrder(okButton, cancelButton);
sourceSelector->setFocus();
@@ -87,14 +87,14 @@ void AddExistingDirectoriesDialog::init()
importView->setMode ( KIconView::Select );
importView->setItemsMovable ( false );
- connect ( okButton, SIGNAL ( clicked () ), this, SLOT ( slotOk () ) );
+ connect ( okButton, TQT_SIGNAL ( clicked () ), this, TQT_SLOT ( slotOk () ) );
- connect ( addSelectedButton, SIGNAL ( clicked () ), this, SLOT ( slotAddSelected() ) );
- connect ( addAllButton, SIGNAL ( clicked () ), this, SLOT ( slotAddAll() ) );
- connect ( removeSelectedButton, SIGNAL ( clicked () ), this, SLOT ( slotRemoveSelected() ) );
- connect ( removeAllButton, SIGNAL ( clicked () ), this, SLOT ( slotRemoveAll() ) );
+ connect ( addSelectedButton, TQT_SIGNAL ( clicked () ), this, TQT_SLOT ( slotAddSelected() ) );
+ connect ( addAllButton, TQT_SIGNAL ( clicked () ), this, TQT_SLOT ( slotAddAll() ) );
+ connect ( removeSelectedButton, TQT_SIGNAL ( clicked () ), this, TQT_SLOT ( slotRemoveSelected() ) );
+ connect ( removeAllButton, TQT_SIGNAL ( clicked () ), this, TQT_SLOT ( slotRemoveAll() ) );
- connect ( importView, SIGNAL ( dropped( QDropEvent* ) ), this, SLOT ( slotDropped ( QDropEvent* ) ) );
+ connect ( importView, TQT_SIGNAL ( dropped( TQDropEvent* ) ), this, TQT_SLOT ( slotDropped ( TQDropEvent* ) ) );
importView->setSelectionMode ( KFile::Multi );
@@ -112,7 +112,7 @@ void AddExistingDirectoriesDialog::importItems()
// items already added to the importView
KFileItemListIterator importedList ( *importView->items() );
- QStringList duplicateList;
+ TQStringList duplicateList;
importedList.toFirst();
@@ -156,11 +156,11 @@ void AddExistingDirectoriesDialog::importItems()
void AddExistingDirectoriesDialog::slotOk()
{
- if ( importView->items()->count() == 0 ) QDialog::reject();
+ if ( importView->items()->count() == 0 ) TQDialog::reject();
KFileItemListIterator items ( *importView->items() );
- QStringList dirs;
+ TQStringList dirs;
for ( ; items.current(); ++items )
{
@@ -181,17 +181,17 @@ void AddExistingDirectoriesDialog::slotOk()
dirs << items.current()->name();
}
- for (QStringList::const_iterator it = dirs.begin(); it != dirs.end(); ++it)
+ for (TQStringList::const_iterator it = dirs.begin(); it != dirs.end(); ++it)
{
- QString name = *it;
+ TQString name = *it;
// Adjust SUBDIRS variable in containing Makefile.am
if (m_spitem->variables["SUBDIRS"].find("$(TOPSUBDIRS)") != -1)
{
- QFile subdirsfile( m_spitem->path + "/subdirs" );
+ TQFile subdirsfile( m_spitem->path + "/subdirs" );
if ( subdirsfile.open( IO_WriteOnly | IO_Append ) )
{
- QTextStream subdirsstream( &subdirsfile );
+ TQTextStream subdirsstream( &subdirsfile );
subdirsstream << name << endl;
subdirsfile.close();
}
@@ -202,7 +202,7 @@ void AddExistingDirectoriesDialog::slotOk()
else
{
m_spitem->variables["SUBDIRS"] += (" " + name);
- QMap<QString,QString> replaceMap;
+ TQMap<TQString,TQString> replaceMap;
replaceMap.insert("SUBDIRS", m_spitem->variables["SUBDIRS"]);
AutoProjectTool::addToMakefileam(m_spitem->path + "/Makefile.am", replaceMap);
}
@@ -215,7 +215,7 @@ void AddExistingDirectoriesDialog::slotOk()
newitem->setOpen(true);
// Move to the bottom of the list
- QListViewItem *lastItem = m_spitem->firstChild();
+ TQListViewItem *lastItem = m_spitem->firstChild();
while (lastItem->nextSibling())
lastItem = lastItem->nextSibling();
if (lastItem != newitem)
@@ -223,8 +223,8 @@ void AddExistingDirectoriesDialog::slotOk()
// Create a Makefile in the new subdirectory
- QDir dir( m_spitem->path + "/" + name );
- QFile f( dir.filePath("Makefile.am") );
+ TQDir dir( m_spitem->path + "/" + name );
+ TQFile f( dir.filePath("Makefile.am") );
if (f.exists()) {
m_widget->getSubprojectView()->parse( newitem );
} else {
@@ -232,7 +232,7 @@ void AddExistingDirectoriesDialog::slotOk()
// KMessageBox::sorry(this, i18n("Could not create Makefile.am in subdirectory %1.").arg(name));
continue;
}
- QTextStream stream(&f);
+ TQTextStream stream(&f);
stream << "INCLUDES = " << newitem->variables["INCLUDES"] << endl << "METASOURCES = AUTO" << endl;
f.close();
}
@@ -241,13 +241,13 @@ void AddExistingDirectoriesDialog::slotOk()
// if !isKDE: add the new sub-proj to configure.in or configure.ac
if ( !m_part->isKDE() ) {
- QString projroot = m_part->projectDirectory() + "/";
- QString subdirectory = dir.path();
- QString relpath = subdirectory.replace(0, projroot.length(),"");
+ TQString projroot = m_part->projectDirectory() + "/";
+ TQString subdirectory = dir.path();
+ TQString relpath = subdirectory.replace(0, projroot.length(),"");
- QString configureFile = m_part->getAutoConfFile(projroot);
+ TQString configureFile = m_part->getAutoConfFile(projroot);
- QStringList list = AutoProjectTool::configureinLoadMakefiles(configureFile);
+ TQStringList list = AutoProjectTool::configureinLoadMakefiles(configureFile);
if ( !list.isEmpty() )
{
list.push_back( relpath + "/Makefile" );
@@ -258,7 +258,7 @@ void AddExistingDirectoriesDialog::slotOk()
m_part->needMakefileCvs();
}
- QDialog::accept();
+ TQDialog::accept();
}
void AddExistingDirectoriesDialog::slotAddSelected()
@@ -267,7 +267,7 @@ void AddExistingDirectoriesDialog::slotAddSelected()
for ( ; it.current(); ++it )
{
- QString relPath = URLUtil::extractPathNameRelative(m_part->projectDirectory(), ( *it )->url());
+ TQString relPath = URLUtil::extractPathNameRelative(m_part->projectDirectory(), ( *it )->url());
if (relPath[relPath.length()-1] == '/')
relPath = relPath.left(relPath.length()-1);
if ( (relPath.isEmpty()) || (! m_widget->allSubprojects().contains( relPath )) )
@@ -285,7 +285,7 @@ void AddExistingDirectoriesDialog::slotAddAll()
for ( ; it.current(); ++it )
{
- QString relPath = URLUtil::extractPathNameRelative(m_part->projectDirectory(), ( *it )->url());
+ TQString relPath = URLUtil::extractPathNameRelative(m_part->projectDirectory(), ( *it )->url());
if (relPath[relPath.length()-1] == '/')
relPath = relPath.left(relPath.length()-1);
if ( (relPath.isEmpty()) || ( ! m_widget->allSubprojects().contains( relPath )) )
@@ -345,7 +345,7 @@ void AddExistingDirectoriesDialog::slotRemoveSelected()
importView->viewport()->update();
}
-void AddExistingDirectoriesDialog::slotDropped ( QDropEvent* ev )
+void AddExistingDirectoriesDialog::slotDropped ( TQDropEvent* ev )
{
kdDebug ( 9020 ) << "AddExistingDirectoriesDialog::dropped()" << endl;
@@ -360,7 +360,7 @@ void AddExistingDirectoriesDialog::slotDropped ( QDropEvent* ev )
for ( KURL::List::Iterator it = urls.begin(); it != urls.end(); ++it )
{
//check if this subproject is already in project
- QString relPath = URLUtil::extractPathNameRelative(m_part->projectDirectory(), *it);
+ TQString relPath = URLUtil::extractPathNameRelative(m_part->projectDirectory(), *it);
if (relPath[relPath.length()-1] == '/')
relPath = relPath.left(relPath.length()-1);
if ( (relPath.isEmpty()) || ( ! m_widget->allSubprojects().contains( relPath )) )