diff options
Diffstat (limited to 'kommander/editor/actioneditorimpl.cpp')
-rw-r--r-- | kommander/editor/actioneditorimpl.cpp | 31 |
1 files changed, 17 insertions, 14 deletions
diff --git a/kommander/editor/actioneditorimpl.cpp b/kommander/editor/actioneditorimpl.cpp index e5358100..0e4d2a8f 100644 --- a/kommander/editor/actioneditorimpl.cpp +++ b/kommander/editor/actioneditorimpl.cpp @@ -1,7 +1,7 @@ /********************************************************************** ** Copyright (C) 2000 Trolltech AS. All rights reserved. ** -** This file is part of Qt Designer. +** This file is part of TQt Designer. ** ** This file may be distributed and/or modified under the terms of the ** GNU General Public License version 2 as published by the Free Software @@ -37,8 +37,8 @@ #include <klocale.h> -ActionEditor::ActionEditor( TQWidget* parent, const char* name, WFlags fl ) - : ActionEditorBase( parent, name, fl ), currentAction( 0 ), formWindow( 0 ) +ActionEditor::ActionEditor( TQWidget* tqparent, const char* name, WFlags fl ) + : ActionEditorBase( tqparent, name, fl ), currentAction( 0 ), formWindow( 0 ) { listActions->addColumn( i18n("Actions" ) ); setEnabled( false ); @@ -87,10 +87,10 @@ void ActionEditor::deleteAction() formWindow->actionList().removeRef( currentAction ); delete currentAction; TQValueList<MetaDataBase::Connection> conns = - MetaDataBase::connections( formWindow, currentAction ); + MetaDataBase::connections( TQT_TQOBJECT(formWindow), currentAction ); for ( TQValueList<MetaDataBase::Connection>::Iterator it2 = conns.begin(); it2 != conns.end(); ++it2 ) - MetaDataBase::removeConnection( formWindow, (*it2).sender, (*it2).signal, + MetaDataBase::removeConnection( TQT_TQOBJECT(formWindow), (*it2).sender, (*it2).signal, (*it2).receiver, (*it2).slot ); delete it.current(); break; @@ -98,10 +98,10 @@ void ActionEditor::deleteAction() formWindow->actionList().removeRef( currentAction ); delete currentAction; TQValueList<MetaDataBase::Connection> conns = - MetaDataBase::connections( formWindow, currentAction ); + MetaDataBase::connections( TQT_TQOBJECT(formWindow), currentAction ); for ( TQValueList<MetaDataBase::Connection>::Iterator it2 = conns.begin(); it2 != conns.end(); ++it2 ) - MetaDataBase::removeConnection( formWindow, (*it2).sender, (*it2).signal, + MetaDataBase::removeConnection( TQT_TQOBJECT(formWindow), (*it2).sender, (*it2).signal, (*it2).receiver, (*it2).slot ); delete it.current(); break; @@ -110,7 +110,7 @@ void ActionEditor::deleteAction() } if ( formWindow ) - formWindow->setActiveObject( formWindow->mainContainer() ); + formWindow->setActiveObject( TQT_TQOBJECT(formWindow->mainContainer()) ); } void ActionEditor::newAction() @@ -119,7 +119,7 @@ void ActionEditor::newAction() if ( actionParent ) { if ( !actionParent->actionGroup() || !actionParent->actionGroup()->inherits( TQACTIONGROUP_OBJECT_NAME_STRING ) ) - actionParent = (ActionItem*)actionParent->parent(); + actionParent = (ActionItem*)actionParent->tqparent(); } ActionItem *i = 0; @@ -151,7 +151,7 @@ void ActionEditor::newActionGroup() if ( actionParent ) { if ( !actionParent->actionGroup() || !actionParent->actionGroup()->inherits( TQACTIONGROUP_OBJECT_NAME_STRING ) ) - actionParent = (ActionItem*)actionParent->parent(); + actionParent = (ActionItem*)actionParent->tqparent(); } ActionItem *i = 0; @@ -193,7 +193,7 @@ void ActionEditor::setFormWindow( FormWindow *fw ) setEnabled( true ); for ( TQAction *a = formWindow->actionList().first(); a; a = formWindow->actionList().next() ) { ActionItem *i = 0; - if ( a->parent() && a->parent()->inherits( TQACTION_OBJECT_NAME_STRING ) ) + if ( a->tqparent() && a->tqparent()->inherits( TQACTION_OBJECT_NAME_STRING ) ) continue; i = new ActionItem( listActions, a ); i->setText( 0, a->name() ); @@ -211,9 +211,12 @@ void ActionEditor::setFormWindow( FormWindow *fw ) void ActionEditor::insertChildActions( ActionItem *i ) { - if ( !i->actionGroup() || !i->actionGroup()->children() ) + if ( !i->actionGroup() ) return; - TQObjectListIt it( *i->actionGroup()->children() ); + TQObjectList clo = i->actionGroup()->childrenListObject(); + if (clo.isEmpty()) + return; + TQObjectListIt it( clo ); while ( it.current() ) { TQObject *o = it.current(); ++it; @@ -255,7 +258,7 @@ void ActionEditor::updateActionIcon( TQAction *a ) void ActionEditor::connectionsClicked() { - ConnectionEditor editor( formWindow->mainWindow(), currentAction, formWindow, formWindow ); + ConnectionEditor editor( formWindow->mainWindow(), TQT_TQOBJECT(currentAction), TQT_TQOBJECT(formWindow), formWindow ); editor.exec(); } #include "actioneditorimpl.moc" |