From 48d4a26399959121f33d2bc3bfe51c7827b654fc Mon Sep 17 00:00:00 2001 From: tpearson Date: Tue, 14 Jun 2011 16:45:05 +0000 Subject: TQt4 port kdevelop This enables compilation under both Qt3 and Qt4 git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdevelop@1236710 283d02a7-25f6-0310-bc7c-ecb5cbfe19da --- parts/filecreate/addglobaldlg.cpp | 14 +++--- parts/filecreate/addglobaldlg.h | 5 ++- parts/filecreate/fcconfigwidget.cpp | 62 +++++++++++++------------- parts/filecreate/fcconfigwidget.h | 3 +- parts/filecreate/fcconfigwidgetbase.ui | 62 +++++++++++++------------- parts/filecreate/fctemplateedit.cpp | 4 +- parts/filecreate/fctemplateedit.h | 3 +- parts/filecreate/fctemplateeditbase.ui | 38 ++++++++-------- parts/filecreate/fctemplateeditbase.ui.h | 4 +- parts/filecreate/fctypeedit.cpp | 4 +- parts/filecreate/fctypeedit.h | 3 +- parts/filecreate/fctypeeditbase.ui | 62 +++++++++++++------------- parts/filecreate/fctypeeditbase.ui.h | 4 +- parts/filecreate/file-templates/ui | 4 +- parts/filecreate/file-templates/ui-confdialog | 22 ++++----- parts/filecreate/file-templates/ui-dialog | 4 +- parts/filecreate/file-templates/ui-dialog-qt4 | 2 +- parts/filecreate/file-templates/ui-dialogb | 14 +++--- parts/filecreate/file-templates/ui-dialogb-qt4 | 14 +++--- parts/filecreate/file-templates/ui-dialogr | 14 +++--- parts/filecreate/file-templates/ui-dialogr-qt4 | 14 +++--- parts/filecreate/file-templates/ui-mainwin | 8 ++-- parts/filecreate/file-templates/ui-mainwin-qt4 | 6 +-- parts/filecreate/file-templates/ui-tabdialog | 20 ++++----- parts/filecreate/file-templates/ui-widget | 4 +- parts/filecreate/file-templates/ui-widget-qt4 | 2 +- parts/filecreate/file-templates/ui-wizard | 6 +-- parts/filecreate/filecreate_filedialog.cpp | 4 +- parts/filecreate/filecreate_filedialog.h | 3 +- parts/filecreate/filecreate_listitem.cpp | 2 +- parts/filecreate/filecreate_newfile.cpp | 4 +- parts/filecreate/filecreate_newfile.h | 3 +- parts/filecreate/filecreate_part.cpp | 30 ++++++------- parts/filecreate/filecreate_part.h | 17 +++---- parts/filecreate/filecreate_typechoosersig.h | 1 + parts/filecreate/filecreate_widget2.cpp | 10 ++--- parts/filecreate/filecreate_widget2.h | 5 +-- parts/filecreate/filecreate_widget3.cpp | 2 +- parts/filecreate/filecreate_widget3.h | 1 + 39 files changed, 245 insertions(+), 239 deletions(-) (limited to 'parts/filecreate') diff --git a/parts/filecreate/addglobaldlg.cpp b/parts/filecreate/addglobaldlg.cpp index 11a0f2a6..ca31669f 100644 --- a/parts/filecreate/addglobaldlg.cpp +++ b/parts/filecreate/addglobaldlg.cpp @@ -21,14 +21,14 @@ #include /* - * Constructs a AddGlobalDlg as a child of 'parent', with the + * Constructs a AddGlobalDlg as a child of 'tqparent', with the * name 'name' and widget flags set to 'f'. * * The dialog will by default be modeless, unless you set 'modal' to * TRUE to construct a modal dialog. */ -AddGlobalDlg::AddGlobalDlg( TQWidget* parent, const char* name, bool modal, WFlags fl ) - : TQDialog( parent, name, modal, fl ) +AddGlobalDlg::AddGlobalDlg( TQWidget* tqparent, const char* name, bool modal, WFlags fl ) + : TQDialog( tqparent, name, modal, fl ) { if ( !name ) @@ -68,7 +68,7 @@ AddGlobalDlg::AddGlobalDlg( TQWidget* parent, const char* name, bool modal, WFla AddGlobalDlgLayout->addWidget( fcglobal_view, 0, 0 ); languageChange(); - resize( TQSize(511, 282).expandedTo(minimumSizeHint()) ); + resize( TQSize(511, 282).expandedTo(tqminimumSizeHint()) ); // signals and slots connections connect( buttonOk, TQT_SIGNAL( clicked() ), this, TQT_SLOT( accept() ) ); @@ -80,7 +80,7 @@ AddGlobalDlg::AddGlobalDlg( TQWidget* parent, const char* name, bool modal, WFla */ AddGlobalDlg::~AddGlobalDlg() { - // no need to delete child widgets, Qt does it all for us + // no need to delete child widgets, TQt does it all for us } /* @@ -93,9 +93,9 @@ void AddGlobalDlg::languageChange() buttonHelp->setGuiItem( KStdGuiItem::help() ); buttonHelp->setAccel( TQKeySequence( tr2i18n( "F1" ) ) ); buttonOk->setGuiItem( KStdGuiItem::ok() ); - buttonOk->setAccel( TQKeySequence( TQString::null ) ); + buttonOk->setAccel( TQKeySequence( TQString() ) ); buttonCancel->setGuiItem( KStdGuiItem::cancel() ); - buttonCancel->setAccel( TQKeySequence( TQString::null ) ); + buttonCancel->setAccel( TQKeySequence( TQString() ) ); fcglobal_view->header()->setLabel( 0, i18n( "Type extension:" ) ); fcglobal_view->header()->setLabel( 1, i18n( "Type name:" ) ); fcglobal_view->header()->setLabel( 2, i18n( "Template location:" ) ); diff --git a/parts/filecreate/addglobaldlg.h b/parts/filecreate/addglobaldlg.h index 481309e7..2e7435dc 100644 --- a/parts/filecreate/addglobaldlg.h +++ b/parts/filecreate/addglobaldlg.h @@ -20,12 +20,13 @@ class TQListView; class TQListViewItem; class TQPushButton; -class AddGlobalDlg : public QDialog +class AddGlobalDlg : public TQDialog { Q_OBJECT + TQ_OBJECT public: - AddGlobalDlg( TQWidget* parent = 0, const char* name = 0, bool modal = FALSE, WFlags fl = 0 ); + AddGlobalDlg( TQWidget* tqparent = 0, const char* name = 0, bool modal = FALSE, WFlags fl = 0 ); ~AddGlobalDlg(); TQPushButton* buttonHelp; diff --git a/parts/filecreate/fcconfigwidget.cpp b/parts/filecreate/fcconfigwidget.cpp index df4963fa..6a1dc7e6 100644 --- a/parts/filecreate/fcconfigwidget.cpp +++ b/parts/filecreate/fcconfigwidget.cpp @@ -39,8 +39,8 @@ #include "kdevpartcontroller.h" -FCConfigWidget::FCConfigWidget(FileCreatePart * part, bool global, TQWidget *parent, const char *name): - FCConfigWidgetBase(parent, name), m_part(part), m_global(global) +FCConfigWidget::FCConfigWidget(FileCreatePart * part, bool global, TQWidget *tqparent, const char *name): + FCConfigWidgetBase(tqparent, name), m_part(part), m_global(global) { fc_view->setSorting(-1, FALSE); fcglobal_view->setSorting(-1, FALSE); @@ -113,7 +113,7 @@ void FCConfigWidget::loadGlobalConfig(TQListView *view, bool checkmarks) TQString subtyperef = element.attribute("subtyperef"); if (subtyperef.isNull()) { - TQListViewItem *it = view->findItem(ext, 0); + TQListViewItem *it = view->tqfindItem(ext, 0); if (it) { ((TQCheckListItem*)it)->setOn(true); @@ -128,7 +128,7 @@ void FCConfigWidget::loadGlobalConfig(TQListView *view, bool checkmarks) } else { - TQListViewItem *it = view->findItem(subtyperef, 0); + TQListViewItem *it = view->tqfindItem(subtyperef, 0); if (it) ((TQCheckListItem*)it)->setOn(true); } @@ -147,9 +147,9 @@ void FCConfigWidget::loadProjectTemplates(TQListView *view) { TQDir templDir( m_part->project()->projectDirectory() + "/templates/" ); templDir.setFilter( TQDir::Files ); - const QFileInfoList * list = templDir.entryInfoList(); + const TQFileInfoList * list = templDir.entryInfoList(); if( list ){ - QFileInfoListIterator it( *list ); + TQFileInfoListIterator it( *list ); TQFileInfo *fi; while ( (fi = it.current()) != 0 ) { FileType * filetype; @@ -217,7 +217,7 @@ void FCConfigWidget::saveProjectConfig() TQListViewItemIterator it( fcglobal_view ); for( ; it.current( ); ++it ){ - if (!it.current()->parent()) + if (!it.current()->tqparent()) { TQCheckListItem *chit = dynamic_cast(it.current()); if ( !chit ) continue; @@ -259,7 +259,7 @@ void FCConfigWidget::saveProjectConfig() TQString dest; dest = m_part->project()->projectDirectory() + "/templates/"; if (it2.current()->text(1) == "create") - copyTemplate(TQString::null, dest, it2.current()->text(0)); + copyTemplate(TQString(), dest, it2.current()->text(0)); else copyTemplate(it2.current()->text(1), dest, it2.current()->text(0)); } @@ -271,7 +271,7 @@ void FCConfigWidget::saveConfiguration(TQDomDocument &dom, TQDomElement &element { TQListViewItemIterator it( fc_view ); for( ; it.current( ); ++it ){ - if (!it.current()->parent()) + if (!it.current()->tqparent()) { TQDomElement type = dom.createElement( "type" ); type.setAttribute( "ext", it.current()->text(0) ); @@ -295,7 +295,7 @@ void FCConfigWidget::saveConfiguration(TQDomDocument &dom, TQDomElement &element else dest = m_part->project()->projectDirectory() + "/templates/"; if (it.current()->text(4) == "create") - copyTemplate(TQString::null, dest, it.current()->text(0)); + copyTemplate(TQString(), dest, it.current()->text(0)); else copyTemplate(it.current()->text(4), dest, it.current()->text(0)); } @@ -322,7 +322,7 @@ void FCConfigWidget::saveConfiguration(TQDomDocument &dom, TQDomElement &element else dest = m_part->project()->projectDirectory() + "/templates/"; if (lastChild->text(4) == "create") - copyTemplate(TQString::null, dest, it.current()->text(0) + "-" + lastChild->text(0)); + copyTemplate(TQString(), dest, it.current()->text(0) + "-" + lastChild->text(0)); else copyTemplate(lastChild->text(4), dest, it.current()->text(0) + "-" + lastChild->text(0)); } @@ -434,15 +434,15 @@ void FCConfigWidget::copyToProject_button_clicked() { TQListViewItem *it_copy_parent = 0; TQString destParent; - if (it->parent()) + if (it->tqparent()) { - it_copy_parent = new TQListViewItem(fc_view, it->parent()->text(0), - it->parent()->text(1), - it->parent()->text(2), - it->parent()->text(3), - locate("data", "kdevfilecreate/file-templates/"+ it->parent()->text(0))); - destParent += it->parent()->text(0) + "-"; - TQCheckListItem *chk = dynamic_cast(it->parent()); + it_copy_parent = new TQListViewItem(fc_view, it->tqparent()->text(0), + it->tqparent()->text(1), + it->tqparent()->text(2), + it->tqparent()->text(3), + locate("data", "kdevfilecreate/file-templates/"+ it->tqparent()->text(0))); + destParent += it->tqparent()->text(0) + "-"; + TQCheckListItem *chk = dynamic_cast(it->tqparent()); if (chk) chk->setOn(false); } @@ -497,7 +497,7 @@ void FCConfigWidget::newtype_button_clicked() void FCConfigWidget::newsubtype_button_clicked() { - if (fc_view->currentItem() && (!fc_view->currentItem()->parent())) + if (fc_view->currentItem() && (!fc_view->currentItem()->tqparent())) { FCTypeEdit *te = new FCTypeEdit(this); if (te->exec() == TQDialog::Accepted ) @@ -541,10 +541,10 @@ void FCConfigWidget::moveup_button_clicked() return; TQListViewItemIterator it( i ); - TQListViewItem *parent = i->parent(); + TQListViewItem *tqparent = i->tqparent(); --it; while ( it.current() ) { - if ( it.current()->parent() == parent ) + if ( it.current()->tqparent() == tqparent ) break; --it; } @@ -564,10 +564,10 @@ void FCConfigWidget::movedown_button_clicked() return; TQListViewItemIterator it( i ); - TQListViewItem *parent = i->parent(); + TQListViewItem *tqparent = i->tqparent(); it++; while ( it.current() ) { - if ( it.current()->parent() == parent ) + if ( it.current()->tqparent() == tqparent ) break; it++; } @@ -649,7 +649,7 @@ void FCConfigWidget::edit_template_content_button_clicked( ) m_part->partController()->editDocument(content); else { - KMessageBox::information(this, i18n("Requested template does not exist yet.\nIt will be opened immediately after accepting the configuration dialog."), TQString::null, "Edit template content warning"); + KMessageBox::information(this, i18n("Requested template does not exist yet.\nIt will be opened immediately after accepting the configuration dialog."), TQString(), "Edit template content warning"); fctemplates_view->currentItem()->setPixmap(0, SmallIcon("edit")); urlsToEdit.append(content); } @@ -662,8 +662,8 @@ void FCConfigWidget::edit_type_content_button_clicked( ) return; TQListViewItem *it = fc_view->currentItem(); TQString type_name = it->text(0); - if (it->parent()) - type_name.prepend(it->parent()->text(0) + "-"); + if (it->tqparent()) + type_name.prepend(it->tqparent()->text(0) + "-"); if (!m_global) { TQString typePath = m_part->project()->projectDirectory() + "/templates/" + type_name; @@ -674,9 +674,9 @@ void FCConfigWidget::edit_type_content_button_clicked( ) else { if (it->text(4) == "create") - KMessageBox::information(this, i18n("Template for the selected file type does not exist yet.\nIt will be opened immediately after accepting the configuration dialog."), TQString::null, "Edit type template content warning"); + KMessageBox::information(this, i18n("Template for the selected file type does not exist yet.\nIt will be opened immediately after accepting the configuration dialog."), TQString(), "Edit type template content warning"); else - KMessageBox::information(this, i18n("Template for the selected file type has been changed.\nIt will be opened immediately after accepting the configuration dialog."), TQString::null, "Edit type template content warning"); + KMessageBox::information(this, i18n("Template for the selected file type has been changed.\nIt will be opened immediately after accepting the configuration dialog."), TQString(), "Edit type template content warning"); fc_view->currentItem()->setPixmap(0, SmallIcon("edit")); urlsToEdit.append(content); } @@ -697,9 +697,9 @@ void FCConfigWidget::edit_type_content_button_clicked( ) else { if (it->text(4) == "create") - KMessageBox::information(this, i18n("Template for the selected file type does not exist yet.\nIt will be opened immediately after accepting the configuration dialog."), TQString::null, "Edit global type template content warning"); + KMessageBox::information(this, i18n("Template for the selected file type does not exist yet.\nIt will be opened immediately after accepting the configuration dialog."), TQString(), "Edit global type template content warning"); else - KMessageBox::information(this, i18n("Template for the selected file type has been changed.\nIt will be opened immediately after accepting the configuration dialog."), TQString::null, "Edit global type template content warning"); + KMessageBox::information(this, i18n("Template for the selected file type has been changed.\nIt will be opened immediately after accepting the configuration dialog."), TQString(), "Edit global type template content warning"); fc_view->currentItem()->setPixmap(0, SmallIcon("edit")); urlsToEdit.append(content); } diff --git a/parts/filecreate/fcconfigwidget.h b/parts/filecreate/fcconfigwidget.h index 2e69b6d5..19087ba6 100644 --- a/parts/filecreate/fcconfigwidget.h +++ b/parts/filecreate/fcconfigwidget.h @@ -29,8 +29,9 @@ class FileType; class FCConfigWidget : public FCConfigWidgetBase { Q_OBJECT + TQ_OBJECT public: - FCConfigWidget(FileCreatePart * part, bool global, TQWidget *parent, const char *name); + FCConfigWidget(FileCreatePart * part, bool global, TQWidget *tqparent, const char *name); ~FCConfigWidget(); diff --git a/parts/filecreate/fcconfigwidgetbase.ui b/parts/filecreate/fcconfigwidgetbase.ui index 72f62260..089141a2 100644 --- a/parts/filecreate/fcconfigwidgetbase.ui +++ b/parts/filecreate/fcconfigwidgetbase.ui @@ -1,6 +1,6 @@ FCConfigWidgetBase - + FCConfigWidgetBase @@ -22,11 +22,11 @@ 0 - + fc_tabs - + tab1 @@ -37,7 +37,7 @@ unnamed - + remove_button @@ -45,7 +45,7 @@ Re&move Type - + edittype_button @@ -53,7 +53,7 @@ Edit T&ype... - + newsubtype_button @@ -61,7 +61,7 @@ New &Subtype... - + newtype_button @@ -69,7 +69,7 @@ &New Type... - + Type Extension @@ -140,14 +140,14 @@ Expanding - + 20 20 - + moveup_button @@ -155,7 +155,7 @@ Move &Up - + movedown_button @@ -173,7 +173,7 @@ Fixed - + 20 20 @@ -190,14 +190,14 @@ Fixed - + 20 20 - + edit_type_content_button @@ -207,7 +207,7 @@ - + tab2 @@ -218,7 +218,7 @@ unnamed - + Type Extension @@ -286,14 +286,14 @@ Expanding - + 330 20 - + copyToProject_button @@ -303,7 +303,7 @@ - + tab3 @@ -314,7 +314,7 @@ unnamed - + Template Name @@ -339,7 +339,7 @@ AllColumns - + edittemplate_button @@ -347,7 +347,7 @@ C&hange Content... - + newtemplate_button @@ -355,7 +355,7 @@ &New Template... - + templatesDir_label @@ -363,7 +363,7 @@ - + removetemplate_button @@ -381,14 +381,14 @@ Expanding - + 20 150 - + edit_template_content_button @@ -406,7 +406,7 @@ Fixed - + 20 20 @@ -520,7 +520,7 @@ AddGlobalDlg *global_dlg; - + removetemplate_button_clicked() copyToProject_button_clicked() newtype_button_clicked() @@ -534,7 +534,7 @@ edit_template_contents_button_clicked() edit_template_content_button_clicked() edit_type_content_button_clicked() - - - + + + diff --git a/parts/filecreate/fctemplateedit.cpp b/parts/filecreate/fctemplateedit.cpp index b019ddb9..1fcc6e02 100644 --- a/parts/filecreate/fctemplateedit.cpp +++ b/parts/filecreate/fctemplateedit.cpp @@ -11,8 +11,8 @@ #include "fctemplateedit.h" #include -FCTemplateEdit::FCTemplateEdit(TQWidget *parent, const char *name): - FCTemplateEditBase(parent, name) +FCTemplateEdit::FCTemplateEdit(TQWidget *tqparent, const char *name): + FCTemplateEditBase(tqparent, name) { connect( templatename_edit, TQT_SIGNAL(textChanged ( const TQString & )), this, TQT_SLOT( slotTemplateNameChanged( ))); diff --git a/parts/filecreate/fctemplateedit.h b/parts/filecreate/fctemplateedit.h index 8ecf7a81..a5a0c2f6 100644 --- a/parts/filecreate/fctemplateedit.h +++ b/parts/filecreate/fctemplateedit.h @@ -17,8 +17,9 @@ class FCTemplateEdit : public FCTemplateEditBase { Q_OBJECT + TQ_OBJECT public: - FCTemplateEdit(TQWidget *parent=0, const char *name=0); + FCTemplateEdit(TQWidget *tqparent=0, const char *name=0); ~FCTemplateEdit(); diff --git a/parts/filecreate/fctemplateeditbase.ui b/parts/filecreate/fctemplateeditbase.ui index 976bff33..6ea599e2 100644 --- a/parts/filecreate/fctemplateeditbase.ui +++ b/parts/filecreate/fctemplateeditbase.ui @@ -1,6 +1,6 @@ FCTemplateEditBase - + FCTemplateEditBase @@ -19,9 +19,9 @@ unnamed - + - layout5 + tqlayout5 @@ -30,7 +30,7 @@ 0 - + textLabel1 @@ -40,7 +40,7 @@ Template &name: - + AlignBottom @@ -54,15 +54,15 @@ - + - layout4 + tqlayout4 unnamed - + textLabel1_2 @@ -77,7 +77,7 @@ Set template content from &file: - + AlignBottom @@ -96,7 +96,7 @@ 0 - + 0 26 @@ -108,9 +108,9 @@ - + - layout1 + tqlayout1 @@ -126,14 +126,14 @@ Expanding - + 40 20 - + ok_button @@ -144,7 +144,7 @@ true - + cancel_button @@ -180,11 +180,11 @@ kdialog.h fctemplateeditbase.ui.h - + init() - - - + + + kurlrequester.h klineedit.h diff --git a/parts/filecreate/fctemplateeditbase.ui.h b/parts/filecreate/fctemplateeditbase.ui.h index f4fcfa05..5750f988 100644 --- a/parts/filecreate/fctemplateeditbase.ui.h +++ b/parts/filecreate/fctemplateeditbase.ui.h @@ -12,7 +12,7 @@ ** ui.h extension file, included from the uic-generated form implementation. ** ** If you wish to add, delete or rename functions or slots use -** Qt Designer which will update this file, preserving your code. Create an +** TQt Designer which will update this file, preserving your code. Create an ** init() function in place of a constructor, and a destroy() function in ** place of a destructor. *****************************************************************************/ @@ -22,5 +22,5 @@ void FCTemplateEditBase::init() { - templatename_edit->setValidator(new TQRegExpValidator(TQRegExp("^\\S*$"), this)); + templatename_edit->setValidator(new TQRegExpValidator(TQRegExp("^\\S*$"), TQT_TQOBJECT(this))); } diff --git a/parts/filecreate/fctypeedit.cpp b/parts/filecreate/fctypeedit.cpp index 5ee4eb0d..dfb29ef6 100644 --- a/parts/filecreate/fctypeedit.cpp +++ b/parts/filecreate/fctypeedit.cpp @@ -13,8 +13,8 @@ #include "fctypeedit.h" -FCTypeEdit::FCTypeEdit(TQWidget *parent, char *name) - : FCTypeEditBase(parent, name) +FCTypeEdit::FCTypeEdit(TQWidget *tqparent, char *name) + : FCTypeEditBase(tqparent, name) { connect( typeext_edit, TQT_SIGNAL( textChanged ( const TQString & )),this, TQT_SLOT( slotTypeEditTextChanged())); connect( typename_edit, TQT_SIGNAL( textChanged ( const TQString & )),this, TQT_SLOT( slotTypeEditTextChanged( ))); diff --git a/parts/filecreate/fctypeedit.h b/parts/filecreate/fctypeedit.h index f5a9bf7b..122b0b57 100644 --- a/parts/filecreate/fctypeedit.h +++ b/parts/filecreate/fctypeedit.h @@ -17,8 +17,9 @@ class FCTypeEdit : public FCTypeEditBase { Q_OBJECT + TQ_OBJECT public: - FCTypeEdit(TQWidget *parent = 0, char *name = 0); + FCTypeEdit(TQWidget *tqparent = 0, char *name = 0); ~FCTypeEdit(); diff --git a/parts/filecreate/fctypeeditbase.ui b/parts/filecreate/fctypeeditbase.ui index 8bc06f87..893a9be3 100644 --- a/parts/filecreate/fctypeeditbase.ui +++ b/parts/filecreate/fctypeeditbase.ui @@ -1,6 +1,6 @@ FCTypeEditBase - + FCTypeEditBase @@ -19,9 +19,9 @@ unnamed - + - layout5 + tqlayout5 @@ -30,7 +30,7 @@ 0 - + textLabel1 @@ -43,23 +43,23 @@ Type &extension: - + AlignBottom typename_edit - + typeext_edit - + - layout3 + tqlayout3 @@ -68,30 +68,30 @@ 0 - + textLabel3 Type &name: - + AlignBottom typedescr_edit - + typename_edit - + - layout3_2 + tqlayout3_2 @@ -100,21 +100,21 @@ 0 - + textLabel3_2 Type &description: - + AlignBottom typedescr_edit - + typedescr_edit @@ -125,7 +125,7 @@ icon_url - + 80 80 @@ -138,15 +138,15 @@ - + - layout4 + tqlayout4 unnamed - + textLabel1_2 @@ -161,7 +161,7 @@ Set template content from &file: - + AlignBottom @@ -180,7 +180,7 @@ 0 - + 0 26 @@ -192,9 +192,9 @@ - + - layout1 + tqlayout1 @@ -210,14 +210,14 @@ Expanding - + 40 20 - + ok_button @@ -228,7 +228,7 @@ true - + cancel_button @@ -268,11 +268,11 @@ kdialog.h fctypeeditbase.ui.h - + init() - - - + + + kicondialog.h kurlrequester.h diff --git a/parts/filecreate/fctypeeditbase.ui.h b/parts/filecreate/fctypeeditbase.ui.h index b9ec29b5..07576b6b 100644 --- a/parts/filecreate/fctypeeditbase.ui.h +++ b/parts/filecreate/fctypeeditbase.ui.h @@ -12,7 +12,7 @@ ** ui.h extension file, included from the uic-generated form implementation. ** ** If you wish to add, delete or rename functions or slots use -** Qt Designer which will update this file, preserving your code. Create an +** TQt Designer which will update this file, preserving your code. Create an ** init() function in place of a constructor, and a destroy() function in ** place of a destructor. *****************************************************************************/ @@ -22,5 +22,5 @@ void FCTypeEditBase::init() { - typeext_edit->setValidator(new TQRegExpValidator(TQRegExp("^\\S*$"), this)); + typeext_edit->setValidator(new TQRegExpValidator(TQRegExp("^\\S*$"), TQT_TQOBJECT(this))); } diff --git a/parts/filecreate/file-templates/ui b/parts/filecreate/file-templates/ui index 858b4678..0a453896 100644 --- a/parts/filecreate/file-templates/ui +++ b/parts/filecreate/file-templates/ui @@ -1,6 +1,6 @@ Form1 - + Form1 @@ -16,5 +16,5 @@ Form1 - + diff --git a/parts/filecreate/file-templates/ui-confdialog b/parts/filecreate/file-templates/ui-confdialog index 975ba4d4..60a0004d 100644 --- a/parts/filecreate/file-templates/ui-confdialog +++ b/parts/filecreate/file-templates/ui-confdialog @@ -1,6 +1,6 @@ MyDialog1 - + MyDialog1 @@ -28,7 +28,7 @@ 6 - + New Item @@ -46,11 +46,11 @@ - + tabWidget - + Widget2 @@ -58,7 +58,7 @@ Tab - + Widget3 @@ -67,7 +67,7 @@ - + Layout1 @@ -81,7 +81,7 @@ 6 - + buttonHelp @@ -105,14 +105,14 @@ Expanding - + 20 20 - + buttonOk @@ -129,7 +129,7 @@ true - + buttonCancel @@ -161,5 +161,5 @@ reject() - + diff --git a/parts/filecreate/file-templates/ui-dialog b/parts/filecreate/file-templates/ui-dialog index fc2aefce..4b0c8bb2 100644 --- a/parts/filecreate/file-templates/ui-dialog +++ b/parts/filecreate/file-templates/ui-dialog @@ -1,6 +1,6 @@ Form1 - + Form1 @@ -16,5 +16,5 @@ Form1 - + diff --git a/parts/filecreate/file-templates/ui-dialog-qt4 b/parts/filecreate/file-templates/ui-dialog-qt4 index d35cb285..b2096e86 100644 --- a/parts/filecreate/file-templates/ui-dialog-qt4 +++ b/parts/filecreate/file-templates/ui-dialog-qt4 @@ -3,7 +3,7 @@ Dialog - + 0 diff --git a/parts/filecreate/file-templates/ui-dialogb b/parts/filecreate/file-templates/ui-dialogb index 7ccbfb94..2929f9e3 100644 --- a/parts/filecreate/file-templates/ui-dialogb +++ b/parts/filecreate/file-templates/ui-dialogb @@ -1,6 +1,6 @@ MyDialog1 - + MyDialog1 @@ -18,7 +18,7 @@ true - + Layout1 @@ -40,7 +40,7 @@ 6 - + buttonHelp @@ -64,14 +64,14 @@ Expanding - + 20 20 - + buttonOk @@ -88,7 +88,7 @@ true - + buttonCancel @@ -119,5 +119,5 @@ reject() - + diff --git a/parts/filecreate/file-templates/ui-dialogb-qt4 b/parts/filecreate/file-templates/ui-dialogb-qt4 index 2413393e..e1b84f42 100644 --- a/parts/filecreate/file-templates/ui-dialogb-qt4 +++ b/parts/filecreate/file-templates/ui-dialogb-qt4 @@ -3,7 +3,7 @@ Dialog - + 0 @@ -15,7 +15,7 @@ Dialog - + 20 @@ -24,7 +24,7 @@ 33 - + 0 @@ -36,7 +36,7 @@ Qt::Horizontal - + 131 31 @@ -45,20 +45,20 @@ - + OK - + Cancel - + diff --git a/parts/filecreate/file-templates/ui-dialogr b/parts/filecreate/file-templates/ui-dialogr index 8cf208ec..0b7dde40 100644 --- a/parts/filecreate/file-templates/ui-dialogr +++ b/parts/filecreate/file-templates/ui-dialogr @@ -1,6 +1,6 @@ MyDialog1 - + MyDialog1 @@ -18,7 +18,7 @@ true - + Layout5 @@ -40,7 +40,7 @@ 6 - + buttonOk @@ -57,7 +57,7 @@ true - + buttonCancel @@ -71,7 +71,7 @@ true - + buttonHelp @@ -95,7 +95,7 @@ Expanding - + 20 20 @@ -119,5 +119,5 @@ reject() - + diff --git a/parts/filecreate/file-templates/ui-dialogr-qt4 b/parts/filecreate/file-templates/ui-dialogr-qt4 index 57d81913..8e2d0608 100644 --- a/parts/filecreate/file-templates/ui-dialogr-qt4 +++ b/parts/filecreate/file-templates/ui-dialogr-qt4 @@ -3,7 +3,7 @@ Dialog - + 0 @@ -15,7 +15,7 @@ Dialog - + 300 @@ -24,7 +24,7 @@ 106 - + 0 @@ -32,14 +32,14 @@ 6 - + OK - + Cancel @@ -50,7 +50,7 @@ Qt::Vertical - + 20 40 @@ -58,7 +58,7 @@ - + diff --git a/parts/filecreate/file-templates/ui-mainwin b/parts/filecreate/file-templates/ui-mainwin index 854da009..4e0a093b 100644 --- a/parts/filecreate/file-templates/ui-mainwin +++ b/parts/filecreate/file-templates/ui-mainwin @@ -1,6 +1,6 @@ Form1 - + Form1 @@ -415,7 +415,7 @@ helpAbout() - + fileNew() fileOpen() fileSave() @@ -431,6 +431,6 @@ helpIndex() helpContents() helpAbout() - - + + diff --git a/parts/filecreate/file-templates/ui-mainwin-qt4 b/parts/filecreate/file-templates/ui-mainwin-qt4 index 814096cc..a444cfa3 100644 --- a/parts/filecreate/file-templates/ui-mainwin-qt4 +++ b/parts/filecreate/file-templates/ui-mainwin-qt4 @@ -3,7 +3,7 @@ MainWindow - + 0 @@ -15,8 +15,8 @@ MainWindow - - + + 0 diff --git a/parts/filecreate/file-templates/ui-tabdialog b/parts/filecreate/file-templates/ui-tabdialog index a28ae7c7..3c45b07b 100644 --- a/parts/filecreate/file-templates/ui-tabdialog +++ b/parts/filecreate/file-templates/ui-tabdialog @@ -1,6 +1,6 @@ MyDialog1 - + MyDialog1 @@ -28,11 +28,11 @@ 6 - + tabWidget - + Widget8 @@ -40,7 +40,7 @@ Tab - + Widget9 @@ -49,7 +49,7 @@ - + Layout1 @@ -63,7 +63,7 @@ 6 - + buttonHelp @@ -87,14 +87,14 @@ Expanding - + 20 20 - + buttonOk @@ -111,7 +111,7 @@ true - + buttonCancel @@ -143,5 +143,5 @@ reject() - + diff --git a/parts/filecreate/file-templates/ui-widget b/parts/filecreate/file-templates/ui-widget index 858b4678..0a453896 100644 --- a/parts/filecreate/file-templates/ui-widget +++ b/parts/filecreate/file-templates/ui-widget @@ -1,6 +1,6 @@ Form1 - + Form1 @@ -16,5 +16,5 @@ Form1 - + diff --git a/parts/filecreate/file-templates/ui-widget-qt4 b/parts/filecreate/file-templates/ui-widget-qt4 index 2aecd3c9..d8b6e63c 100644 --- a/parts/filecreate/file-templates/ui-widget-qt4 +++ b/parts/filecreate/file-templates/ui-widget-qt4 @@ -3,7 +3,7 @@ Form - + 0 diff --git a/parts/filecreate/file-templates/ui-wizard b/parts/filecreate/file-templates/ui-wizard index 7c68689b..01338af0 100644 --- a/parts/filecreate/file-templates/ui-wizard +++ b/parts/filecreate/file-templates/ui-wizard @@ -1,6 +1,6 @@ Form1 - + Form1 @@ -15,7 +15,7 @@ Form1 - + page @@ -24,5 +24,5 @@ - + diff --git a/parts/filecreate/filecreate_filedialog.cpp b/parts/filecreate/filecreate_filedialog.cpp index ecc8df42..1baa2132 100644 --- a/parts/filecreate/filecreate_filedialog.cpp +++ b/parts/filecreate/filecreate_filedialog.cpp @@ -21,9 +21,9 @@ namespace FileCreate { FileDialog::FileDialog(const TQString& startDir, const TQString& filter, - TQWidget *parent, const char *name, + TQWidget *tqparent, const char *name, bool modal, TQWidget * extraWidget) : - KFileDialog(startDir, filter, parent, name, modal, extraWidget) { + KFileDialog(startDir, filter, tqparent, name, modal, extraWidget) { setOperationMode(Saving); diff --git a/parts/filecreate/filecreate_filedialog.h b/parts/filecreate/filecreate_filedialog.h index b1523648..26852cfc 100644 --- a/parts/filecreate/filecreate_filedialog.h +++ b/parts/filecreate/filecreate_filedialog.h @@ -21,10 +21,11 @@ namespace FileCreate { class FileDialog : public KFileDialog { Q_OBJECT + TQ_OBJECT public: FileDialog(const TQString& startDir, const TQString& filter, - TQWidget *parent, const char *name, + TQWidget *tqparent, const char *name, bool modal, TQWidget * extraWidget); virtual ~FileDialog(); diff --git a/parts/filecreate/filecreate_listitem.cpp b/parts/filecreate/filecreate_listitem.cpp index 86075af8..aa02fe23 100644 --- a/parts/filecreate/filecreate_listitem.cpp +++ b/parts/filecreate/filecreate_listitem.cpp @@ -51,7 +51,7 @@ namespace FileCreate { void ListItem::setHeight( int height ) { - KListViewItem::setHeight( QMAX(QMAX(height,m_iconHeight), m_filetypeRenderer->height() ) ); + KListViewItem::setHeight( TQMAX(TQMAX(height,m_iconHeight), m_filetypeRenderer->height() ) ); } void ListItem::prepareResize() { diff --git a/parts/filecreate/filecreate_newfile.cpp b/parts/filecreate/filecreate_newfile.cpp index b4b84de1..6b41bb0b 100644 --- a/parts/filecreate/filecreate_newfile.cpp +++ b/parts/filecreate/filecreate_newfile.cpp @@ -29,9 +29,9 @@ namespace FileCreate { - NewFileChooser::NewFileChooser(TQWidget * parent) : + NewFileChooser::NewFileChooser(TQWidget * tqparent) : KDialogBase(KDialogBase::Plain, i18n("New file dialog (title)", "New File"), KDialogBase::Ok|KDialogBase::Cancel, - KDialogBase::Ok, parent, "New file", true) + KDialogBase::Ok, tqparent, "New file", true) { TQVBoxLayout* lay = new TQVBoxLayout( plainPage(), 5, 5 ); diff --git a/parts/filecreate/filecreate_newfile.h b/parts/filecreate/filecreate_newfile.h index c1d3b730..04239e90 100644 --- a/parts/filecreate/filecreate_newfile.h +++ b/parts/filecreate/filecreate_newfile.h @@ -26,8 +26,9 @@ class KLineEdit; namespace FileCreate { class NewFileChooser : public KDialogBase { Q_OBJECT + TQ_OBJECT public: - NewFileChooser(TQWidget *parent=0); + NewFileChooser(TQWidget *tqparent=0); virtual ~NewFileChooser(); void setFileTypes(TQPtrList typelist); KURL url() const; diff --git a/parts/filecreate/filecreate_part.cpp b/parts/filecreate/filecreate_part.cpp index e07656b9..e8fbecff 100644 --- a/parts/filecreate/filecreate_part.cpp +++ b/parts/filecreate/filecreate_part.cpp @@ -61,9 +61,9 @@ K_EXPORT_COMPONENT_FACTORY( libkdevfilecreate, FileCreateFactory( data ) ) using namespace FileCreate; -FileCreatePart::FileCreatePart(TQObject *parent, const char *name, const TQStringList & ) -// : KDevCreateFile(&data, parent, name ? name : "FileCreatePart"), m_selectedWidget(-1), m_useSideTab(true), m_subPopups(0) - : KDevCreateFile(&data, parent, name ? name : "FileCreatePart"), m_subPopups(0) +FileCreatePart::FileCreatePart(TQObject *tqparent, const char *name, const TQStringList & ) +// : KDevCreateFile(&data, tqparent, name ? name : "FileCreatePart"), m_selectedWidget(-1), m_useSideTab(true), m_subPopups(0) + : KDevCreateFile(&data, tqparent, name ? name : "FileCreatePart"), m_subPopups(0) { setInstance(FileCreateFactory::instance()); setXMLFile("kdevpart_filecreate.rc"); @@ -78,7 +78,7 @@ FileCreatePart::FileCreatePart(TQObject *parent, const char *name, const TQStrin this, TQT_SLOT(insertConfigWidget(const KDialogBase*, TQWidget*, unsigned int )) ); - KToolBarPopupAction * newAction = new KToolBarPopupAction( i18n("&New"), "filenew", CTRL+Qt::Key_N, this, TQT_SLOT(slotNewFile()), actionCollection(), "file_new"); + KToolBarPopupAction * newAction = new KToolBarPopupAction( i18n("&New"), "filenew", CTRL+TQt::Key_N, this, TQT_SLOT(slotNewFile()), actionCollection(), "file_new"); newAction->setWhatsThis( i18n("New file

Creates a new file. Also adds it the project if the Add to project checkbox is turned on.") ); newAction->setToolTip( i18n("Create a new file") ); m_newPopupMenu = newAction->popupMenu(); @@ -210,8 +210,8 @@ void FileCreatePart::slotProjectClosed() { void FileCreatePart::slotFiletypeSelected(const FileType * filetype) { KDevCreateFile::CreatedFile createdFile = createNewFile(filetype->ext(), - TQString::null, - TQString::null, + TQString(), + TQString(), filetype->subtypeRef()); openCreatedFile(createdFile); @@ -274,7 +274,7 @@ FileType * FileCreatePart::getType(const TQString & ex, const TQString subtRef) TQString subtypeRef = subtRef; TQString ext = ex; - int dashPos = ext.find('-'); + int dashPos = ext.tqfind('-'); if (dashPos>-1 && subtRef.isNull()) { ext = ex.left(dashPos); subtypeRef = ex.mid(dashPos+1); @@ -301,7 +301,7 @@ FileType * FileCreatePart::getEnabledType(const TQString & ex, const TQString su TQString subtypeRef = subtRef; TQString ext = ex; - int dashPos = ext.find('-'); + int dashPos = ext.tqfind('-'); if (dashPos>-1 && subtRef.isNull()) { ext = ex.left(dashPos); subtypeRef = ex.mid(dashPos+1); @@ -383,7 +383,7 @@ KDevCreateFile::CreatedFile FileCreatePart::createNewFile(TQString ext, TQString selectedURL = dialog.url(); const FileType *selectedFileType = dialog.selectedType(); - if (dialog.addToProject() && !projectURL.isParentOf(selectedURL) && !(project()->options() & KDevProject::UsesQMakeBuildSystem) ) { + if (dialog.addToProject() && !projectURL.isParentOf(selectedURL) && !(project()->options() & KDevProject::UsesTQMakeBuildSystem) ) { result.status = KDevCreateFile::CreatedFile::STATUS_NOTWITHINPROJECT; return result; } @@ -425,7 +425,7 @@ KDevCreateFile::CreatedFile FileCreatePart::createNewFile(TQString ext, TQString // work out the path relative to the project directory // TQString relToProj = URLUtil::relativePath(projectURL, selectedURL, URLUtil::SLASH_PREFIX ); TQString relToProj; - if( project()->options() & KDevProject::UsesQMakeBuildSystem ) + if( project()->options() & KDevProject::UsesTQMakeBuildSystem ) { relToProj = URLUtil::relativePathToFile( project()->projectDirectory(), fullPath ); project()->addFile(relToProj); @@ -451,7 +451,7 @@ KDevCreateFile::CreatedFile FileCreatePart::createNewFile(TQString ext, TQString } void FileCreatePart::slotNoteFiletype(const FileType * filetype) { - kdDebug(9034) << "Noting file type: " << (filetype ? filetype->ext() : TQString::fromLatin1("Null") ) << endl; + kdDebug(9034) << "Noting file type: " << (filetype ? filetype->ext() : TQString::tqfromLatin1("Null") ) << endl; m_filedialogFiletype = filetype; } @@ -483,7 +483,7 @@ void FileCreatePart::slotInitialize( ) } } else { // if an extension + subtype have been specified, enable - // the subtype and the extension (the 'parent') + // the subtype and the extension (the 'tqparent') FileType * filetype = getType(ext); FileType * subtype = getType(ext,subtyperef); if (filetype && subtype) { @@ -501,9 +501,9 @@ void FileCreatePart::slotInitialize( ) TQDir templDir( project()->projectDirectory() + "/templates/" ); if (templDir.exists()) { templDir.setFilter( TQDir::Files ); - const QFileInfoList * list = templDir.entryInfoList(); + const TQFileInfoList * list = templDir.entryInfoList(); if( list ){ - QFileInfoListIterator it( *list ); + TQFileInfoListIterator it( *list ); TQFileInfo *fi; while ( (fi = it.current()) != 0 ) { addFileType(fi->fileName()); @@ -559,4 +559,4 @@ void FileCreatePart::slotGlobalInitialize( ) #include "filecreate_part.moc" -// kate: indent-width 2; replace-tabs on; tab-width 4; space-indent on; +// kate: indent-width 2; tqreplace-tabs on; tab-width 4; space-indent on; diff --git a/parts/filecreate/filecreate_part.h b/parts/filecreate/filecreate_part.h index 605f6fbf..c8da5b27 100644 --- a/parts/filecreate/filecreate_part.h +++ b/parts/filecreate/filecreate_part.h @@ -39,10 +39,11 @@ using namespace FileCreate; class FileCreatePart : public KDevCreateFile { Q_OBJECT + TQ_OBJECT friend class FCConfigWidget; public: - FileCreatePart(TQObject *parent, const char *name, const TQStringList &); + FileCreatePart(TQObject *tqparent, const char *name, const TQStringList &); virtual ~FileCreatePart(); /** @@ -52,26 +53,26 @@ public: /** * Call this method to create a new file, within or without the project. Supply as - * much information as you know. Leave what you don't know as TQString::null. + * much information as you know. Leave what you don't know as TQString(). * The user will be prompted as necessary for the missing information, and the * file created, and added to the project as necessary. */ - virtual KDevCreateFile::CreatedFile createNewFile(TQString ext = TQString::null, - TQString dir = TQString::null, - TQString name = TQString::null, - TQString subtype = TQString::null); + virtual KDevCreateFile::CreatedFile createNewFile(TQString ext = TQString(), + TQString dir = TQString(), + TQString name = TQString(), + TQString subtype = TQString()); /** * Finds the file type object for a given extension and optionally subtype. * You can omit the subtype and specify the extension as ext-subtype if you wish. */ - FileType * getType(const TQString & ext, const TQString subtype = TQString::null); + FileType * getType(const TQString & ext, const TQString subtype = TQString()); /** * Finds the file type object for a given extension and optionally subtype. * You can omit the subtype and specify the extension as ext-subtype if you wish. * Returns only enabled type (i.e. used in the project). */ - FileType * getEnabledType(const TQString & ext, const TQString subtype = TQString::null); + FileType * getEnabledType(const TQString & ext, const TQString subtype = TQString()); public slots: diff --git a/parts/filecreate/filecreate_typechoosersig.h b/parts/filecreate/filecreate_typechoosersig.h index 233afe70..ad98fa68 100644 --- a/parts/filecreate/filecreate_typechoosersig.h +++ b/parts/filecreate/filecreate_typechoosersig.h @@ -9,6 +9,7 @@ class FileType; class Signaller : public TQObject { Q_OBJECT + TQ_OBJECT public: Signaller() : TQObject() { } diff --git a/parts/filecreate/filecreate_widget2.cpp b/parts/filecreate/filecreate_widget2.cpp index 10816904..5c39393b 100644 --- a/parts/filecreate/filecreate_widget2.cpp +++ b/parts/filecreate/filecreate_widget2.cpp @@ -67,7 +67,7 @@ namespace FileCreate { else kdDebug(9034) << "No match!" << endl; } - // If an exact match is not found (e.g. current points to a 'parent' type) then + // If an exact match is not found (e.g. current points to a 'tqparent' type) then // look instead for an extension match if (changeToRow==-1) { for(it = typeForRow.begin(); it!= typeForRow.end() && changeToRow==-1; ++it) { @@ -164,7 +164,7 @@ namespace FileCreate { return; } - m_selected = typeForRow.contains(row) ? typeForRow[row] : NULL; + m_selected = typeForRow.tqcontains(row) ? typeForRow[row] : NULL; TQTimer::singleShot(0, this, TQT_SLOT(slotDoSelection()) ); } @@ -191,7 +191,7 @@ namespace FileCreate { if( !i ) continue; - TQSize size = i->sizeHint(); + TQSize size = i->tqsizeHint(); maxHeight = size.height()>maxHeight ? size.height() : maxHeight; } setRowHeight(row,maxHeight+2); // bit of extra room @@ -206,13 +206,13 @@ namespace FileCreate { if( !i ) continue; - TQSize size = item(r,col)->sizeHint(); + TQSize size = item(r,col)->tqsizeHint(); maxWidth = size.width()>maxWidth ? size.width() : maxWidth; } setColumnWidth(col,maxWidth+2); // bit of extra room } -#if QT_VERSION < 0x030100 +#if [[[TQT_VERSION IS DEPRECATED]]] < 0x030100 void FriendlyWidget::selectRow(int row) { if (numCols()>0 && rowrow to filetype filetype. diff --git a/parts/filecreate/filecreate_widget3.cpp b/parts/filecreate/filecreate_widget3.cpp index 5d307bff..282426c0 100644 --- a/parts/filecreate/filecreate_widget3.cpp +++ b/parts/filecreate/filecreate_widget3.cpp @@ -70,7 +70,7 @@ namespace FileCreate { lvi = lvi->nextSibling(); else { while (lvi && !lvi->nextSibling()) - lvi = lvi->parent(); + lvi = lvi->tqparent(); } } diff --git a/parts/filecreate/filecreate_widget3.h b/parts/filecreate/filecreate_widget3.h index db2a6b13..89201539 100644 --- a/parts/filecreate/filecreate_widget3.h +++ b/parts/filecreate/filecreate_widget3.h @@ -30,6 +30,7 @@ namespace FileCreate { class ListWidget : public KListView, public TypeChooser { Q_OBJECT + TQ_OBJECT public: -- cgit v1.2.1