From f7670c198945adc3b95ad69a959fe5f8ae55b493 Mon Sep 17 00:00:00 2001 From: tpearson Date: Thu, 24 Feb 2011 20:07:57 +0000 Subject: Runtime object naming repaired in kdewebdev NOTE: runtime object naming still needs to be checked for stray "Q*" strings git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdewebdev@1222551 283d02a7-25f6-0310-bc7c-ecb5cbfe19da --- kommander/editor/actiondnd.cpp | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) (limited to 'kommander/editor/actiondnd.cpp') diff --git a/kommander/editor/actiondnd.cpp b/kommander/editor/actiondnd.cpp index 17d8af3f..67491ef4 100644 --- a/kommander/editor/actiondnd.cpp +++ b/kommander/editor/actiondnd.cpp @@ -47,7 +47,7 @@ bool QDesignerAction::addTo( TQWidget *w ) if ( !widgetToInsert ) return TQAction::addTo( w ); - if ( w->inherits( "TQPopupMenu" ) ) + if ( w->inherits( TQPOPUPMENU_OBJECT_NAME_STRING ) ) return false; widgetToInsert->reparent( w, TQPoint( 0, 0 ), false ); @@ -125,11 +125,11 @@ QSeparatorAction::QSeparatorAction( TQObject *parent ) bool QSeparatorAction::addTo( TQWidget *w ) { - if ( w->inherits( "TQToolBar" ) ) { + if ( w->inherits( TQTOOLBAR_OBJECT_NAME_STRING ) ) { TQToolBar *tb = (TQToolBar*)w; wid = new QDesignerToolBarSeparator( tb->orientation(), tb ); return true; - } else if ( w->inherits( "TQPopupMenu" ) ) { + } else if ( w->inherits( TQPOPUPMENU_OBJECT_NAME_STRING ) ) { idx = ( (TQPopupMenu*)w )->count(); ( (TQPopupMenu*)w )->insertSeparator( idx ); return true; @@ -139,10 +139,10 @@ bool QSeparatorAction::addTo( TQWidget *w ) bool QSeparatorAction::removeFrom( TQWidget *w ) { - if ( w->inherits( "TQToolBar" ) ) { + if ( w->inherits( TQTOOLBAR_OBJECT_NAME_STRING ) ) { delete wid; return true; - } else if ( w->inherits( "TQPopupMenu" ) ) { + } else if ( w->inherits( TQPOPUPMENU_OBJECT_NAME_STRING ) ) { ( (TQPopupMenu*)w )->removeItemAt( idx ); return true; } @@ -202,7 +202,7 @@ void QDesignerToolBar::addAction( TQAction *a ) { actionList.append( a ); connect( a, TQT_SIGNAL( destroyed() ), this, TQT_SLOT( actionRemoved() ) ); - if ( a->inherits( "TQActionGroup" ) ) { + if ( a->inherits( TQACTIONGROUP_OBJECT_NAME_STRING ) ) { ( (QDesignerActionGroup*)a )->widget()->installEventFilter( this ); actionMap.insert( ( (QDesignerActionGroup*)a )->widget(), a ); } else if ( a->inherits( "QSeparatorAction" ) ) { @@ -450,7 +450,7 @@ void QDesignerToolBar::buttonMouseMoveEvent( TQMouseEvent *e, TQObject *o ) TQApplication::sendPostedEvents(); adjustSize(); - TQString type = a->inherits( "TQActionGroup" ) ? TQString( "application/x-designer-actiongroup" ) : + TQString type = a->inherits( TQACTIONGROUP_OBJECT_NAME_STRING ) ? TQString( "application/x-designer-actiongroup" ) : a->inherits( "QSeparatorAction" ) ? TQString( "application/x-designer-separator" ) : TQString( "application/x-designer-actions" ); TQStoredDrag *drag = new TQStoredDrag( type, this ); TQString s = TQString::number( (long)a ); // #### huha, that is evil @@ -560,7 +560,7 @@ void QDesignerToolBar::reInsert() clear(); for ( a = actionList.first(); a; a = actionList.next() ) { a->addTo( this ); - if ( a->inherits( "TQActionGroup" ) ) { + if ( a->inherits( TQACTIONGROUP_OBJECT_NAME_STRING ) ) { actionMap.insert( ( (QDesignerActionGroup*)a )->widget(), a ); if ( ( (QDesignerActionGroup*)a )->widget() ) ( (QDesignerActionGroup*)a )->widget()->installEventFilter( this ); @@ -689,7 +689,7 @@ void QDesignerToolBar::installEventFilters( TQWidget *w ) { if ( !w ) return; - TQObjectList *l = w->queryList( "TQWidget" ); + TQObjectList *l = w->queryList( TQWIDGET_OBJECT_NAME_STRING ); for ( TQObject *o = l->first(); o; o = l->next() ) o->installEventFilter( this ); delete l; @@ -1072,7 +1072,7 @@ void QDesignerPopupMenu::mouseMoveEvent( TQMouseEvent *e ) formWindow->commandHistory()->addCommand( cmd ); cmd->execute(); - TQString type = a->inherits( "TQActionGroup" ) ? TQString( "application/x-designer-actiongroup" ) : + TQString type = a->inherits( TQACTIONGROUP_OBJECT_NAME_STRING ) ? TQString( "application/x-designer-actiongroup" ) : a->inherits( "QSeparatorAction" ) ? TQString( "application/x-designer-separator" ) : TQString( "application/x-designer-actions" ); TQStoredDrag *drag = new TQStoredDrag( type, this ); TQString s = TQString::number( (long)a ); // #### huha, that is evil -- cgit v1.2.1