diff options
Diffstat (limited to 'kdevdesigner/designer/actioneditorimpl.cpp')
-rw-r--r-- | kdevdesigner/designer/actioneditorimpl.cpp | 66 |
1 files changed, 33 insertions, 33 deletions
diff --git a/kdevdesigner/designer/actioneditorimpl.cpp b/kdevdesigner/designer/actioneditorimpl.cpp index 294507a9..f97e8a47 100644 --- a/kdevdesigner/designer/actioneditorimpl.cpp +++ b/kdevdesigner/designer/actioneditorimpl.cpp @@ -54,17 +54,17 @@ ActionEditor::ActionEditor( TQWidget* parent, const char* name, WFlags fl ) buttonConnect->setEnabled( FALSE ); TQPopupMenu *popup = new TQPopupMenu( this ); - popup->insertItem( i18n( "New &Action" ), this, TQT_SLOT( newAction() ) ); - popup->insertItem( i18n( "New Action &Group" ), this, TQT_SLOT( newActionGroup() ) ); - popup->insertItem( i18n( "New &Dropdown Action Group" ), this, TQT_SLOT( newDropDownActionGroup() ) ); + popup->insertItem( i18n( "New &Action" ), this, TQ_SLOT( newAction() ) ); + popup->insertItem( i18n( "New Action &Group" ), this, TQ_SLOT( newActionGroup() ) ); + popup->insertItem( i18n( "New &Dropdown Action Group" ), this, TQ_SLOT( newDropDownActionGroup() ) ); buttonNewAction->setPopup( popup ); buttonNewAction->setPopupDelay( 0 ); - connect( listActions, TQT_SIGNAL( insertAction() ), this, TQT_SLOT( newAction() ) ); - connect( listActions, TQT_SIGNAL( insertActionGroup() ), this, TQT_SLOT( newActionGroup() ) ); - connect( listActions, TQT_SIGNAL( insertDropDownActionGroup() ), this, TQT_SLOT( newDropDownActionGroup() ) ); - connect( listActions, TQT_SIGNAL( deleteAction() ), this, TQT_SLOT( deleteAction() ) ); - connect( listActions, TQT_SIGNAL( connectAction() ), this, TQT_SLOT( connectionsClicked() ) ); + connect( listActions, TQ_SIGNAL( insertAction() ), this, TQ_SLOT( newAction() ) ); + connect( listActions, TQ_SIGNAL( insertActionGroup() ), this, TQ_SLOT( newActionGroup() ) ); + connect( listActions, TQ_SIGNAL( insertDropDownActionGroup() ), this, TQ_SLOT( newDropDownActionGroup() ) ); + connect( listActions, TQ_SIGNAL( deleteAction() ), this, TQ_SLOT( deleteAction() ) ); + connect( listActions, TQ_SIGNAL( connectAction() ), this, TQ_SLOT( connectionsClicked() ) ); } void ActionEditor::closeEvent( TQCloseEvent *e ) @@ -103,8 +103,8 @@ TQAction *ActionEditor::newActionEx() { ActionItem *i = new ActionItem( listActions, (bool)FALSE ); TQAction *a = i->action(); - TQObject::connect( a, TQT_SIGNAL( destroyed( TQObject * ) ), - this, TQT_SLOT( removeConnections( TQObject* ) ) ); + TQObject::connect( a, TQ_SIGNAL( destroyed( TQObject * ) ), + this, TQ_SLOT( removeConnections( TQObject* ) ) ); MetaDataBase::addEntry( i->action() ); TQString n = "Action"; formWindow->unify( i->action(), n, TRUE ); @@ -139,7 +139,7 @@ void ActionEditor::deleteAction() ++it; } if ( formWindow ) { - formWindow->setActiveObject( TQT_TQOBJECT(formWindow->mainContainer()) ); + formWindow->setActiveObject( formWindow->mainContainer() ); if ( formWindow->formFile() ) formWindow->formFile()->setModified( TRUE ); } @@ -149,7 +149,7 @@ void ActionEditor::newAction() { ActionItem *actionParent = (ActionItem*)listActions->selectedItem(); if ( actionParent ) { - if ( !::tqqt_cast<TQActionGroup*>(actionParent->actionGroup()) ) + if ( !::tqt_cast<TQActionGroup*>(actionParent->actionGroup()) ) actionParent = (ActionItem*)actionParent->parent(); } @@ -159,8 +159,8 @@ void ActionEditor::newAction() else i = new ActionItem( listActions, (bool)FALSE ); TQAction *a = i->action(); - TQObject::connect( a, TQT_SIGNAL( destroyed( TQObject * ) ), - this, TQT_SLOT( removeConnections( TQObject* ) ) ); + TQObject::connect( a, TQ_SIGNAL( destroyed( TQObject * ) ), + this, TQ_SLOT( removeConnections( TQObject* ) ) ); MetaDataBase::addEntry( i->action() ); TQString n = "Action"; formWindow->unify( i->action(), n, TRUE ); @@ -185,7 +185,7 @@ void ActionEditor::newActionGroup() { ActionItem *actionParent = (ActionItem*)listActions->selectedItem(); if ( actionParent ) { - if ( !::tqqt_cast<TQActionGroup*>(actionParent->actionGroup()) ) + if ( !::tqt_cast<TQActionGroup*>(actionParent->actionGroup()) ) actionParent = (ActionItem*)actionParent->parent(); } @@ -195,8 +195,8 @@ void ActionEditor::newActionGroup() else i = new ActionItem( listActions, TRUE ); TQAction *ag = i->actionGroup(); - TQObject::connect( ag, TQT_SIGNAL( destroyed( TQObject * ) ), - this, TQT_SLOT( removeConnections( TQObject* ) ) ); + TQObject::connect( ag, TQ_SIGNAL( destroyed( TQObject * ) ), + this, TQ_SLOT( removeConnections( TQObject* ) ) ); MetaDataBase::addEntry( i->actionGroup() ); MetaDataBase::setPropertyChanged( i->actionGroup(), "usesDropDown", TRUE ); TQString n = "ActionGroup"; @@ -225,23 +225,23 @@ void ActionEditor::setFormWindow( FormWindow *fw ) listActions->clear(); formWindow = fw; if ( !formWindow || - !::tqqt_cast<TQMainWindow*>(formWindow->mainContainer()) ) { + !::tqt_cast<TQMainWindow*>(formWindow->mainContainer()) ) { setEnabled( FALSE ); } else { setEnabled( TRUE ); for ( TQAction *a = formWindow->actionList().first(); a; a = formWindow->actionList().next() ) { ActionItem *i = 0; - if ( ::tqqt_cast<TQAction*>(a->parent()) ) + if ( ::tqt_cast<TQAction*>(a->parent()) ) continue; i = new ActionItem( listActions, a ); i->setText( 0, a->name() ); i->setPixmap( 0, a->iconSet().pixmap() ); // make sure we don't duplicate the connection - TQObject::disconnect( a, TQT_SIGNAL( destroyed( TQObject * ) ), - this, TQT_SLOT( removeConnections( TQObject * ) ) ); - TQObject::connect( a, TQT_SIGNAL( destroyed( TQObject * ) ), - this, TQT_SLOT( removeConnections( TQObject* ) ) ); - if ( ::tqqt_cast<TQActionGroup*>(a) ) { + TQObject::disconnect( a, TQ_SIGNAL( destroyed( TQObject * ) ), + this, TQ_SLOT( removeConnections( TQObject * ) ) ); + TQObject::connect( a, TQ_SIGNAL( destroyed( TQObject * ) ), + this, TQ_SLOT( removeConnections( TQObject* ) ) ); + if ( ::tqt_cast<TQActionGroup*>(a) ) { insertChildActions( i ); } } @@ -261,7 +261,7 @@ void ActionEditor::insertChildActions( ActionItem *i ) while ( it.current() ) { TQObject *o = it.current(); ++it; - if ( !::tqqt_cast<TQAction*>(o) ) + if ( !::tqt_cast<TQAction*>(o) ) continue; TQAction *a = (TQAction*)o; ActionItem *i2 = new ActionItem( (TQListViewItem*)i, a ); @@ -269,11 +269,11 @@ void ActionEditor::insertChildActions( ActionItem *i ) i2->setText( 0, a->name() ); i2->setPixmap( 0, a->iconSet().pixmap() ); // make sure we don't duplicate the connection - TQObject::disconnect( o, TQT_SIGNAL( destroyed( TQObject * ) ), - this, TQT_SLOT( removeConnections( TQObject * ) ) ); - TQObject::connect( o, TQT_SIGNAL( destroyed( TQObject * ) ), - this, TQT_SLOT( removeConnections( TQObject * ) ) ); - if ( ::tqqt_cast<TQActionGroup*>(a) ) + TQObject::disconnect( o, TQ_SIGNAL( destroyed( TQObject * ) ), + this, TQ_SLOT( removeConnections( TQObject * ) ) ); + TQObject::connect( o, TQ_SIGNAL( destroyed( TQObject * ) ), + this, TQ_SLOT( removeConnections( TQObject * ) ) ); + if ( ::tqt_cast<TQActionGroup*>(a) ) insertChildActions( i2 ); } } @@ -305,7 +305,7 @@ void ActionEditor::updateActionIcon( TQAction *a ) void ActionEditor::connectionsClicked() { ConnectionDialog dlg( formWindow->mainWindow() ); - dlg.setDefault( TQT_TQOBJECT(currentAction), TQT_TQOBJECT(formWindow) ); + dlg.setDefault( currentAction, formWindow ); dlg.addConnection(); dlg.exec(); } @@ -313,9 +313,9 @@ void ActionEditor::connectionsClicked() void ActionEditor::removeConnections( TQObject *o ) { TQValueList<MetaDataBase::Connection> conns = - MetaDataBase::connections( TQT_TQOBJECT(formWindow), o ); + MetaDataBase::connections( formWindow, o ); for ( TQValueList<MetaDataBase::Connection>::Iterator it2 = conns.begin(); it2 != conns.end(); ++it2 ) - MetaDataBase::removeConnection( TQT_TQOBJECT(formWindow), (*it2).sender, (*it2).signal, + MetaDataBase::removeConnection( formWindow, (*it2).sender, (*it2).signal, (*it2).receiver, (*it2).slot ); } |