diff options
Diffstat (limited to 'kdgantt/KDGanttViewSubwidgets.cpp')
-rw-r--r-- | kdgantt/KDGanttViewSubwidgets.cpp | 56 |
1 files changed, 28 insertions, 28 deletions
diff --git a/kdgantt/KDGanttViewSubwidgets.cpp b/kdgantt/KDGanttViewSubwidgets.cpp index 8dcd5c75..8acf172b 100644 --- a/kdgantt/KDGanttViewSubwidgets.cpp +++ b/kdgantt/KDGanttViewSubwidgets.cpp @@ -58,8 +58,8 @@ #include <kcalendarsystem.h> #include <kdebug.h> -KDTimeTableWidget:: KDTimeTableWidget( TQWidget* tqparent,KDGanttView* myGantt) - : TQCanvas (TQT_TQOBJECT(tqparent)) +KDTimeTableWidget:: KDTimeTableWidget( TQWidget* parent,KDGanttView* myGantt) + : TQCanvas (TQT_TQOBJECT(parent)) { myGanttView = myGantt; taskLinksVisible = true; @@ -695,8 +695,8 @@ int KDTimeTableWidget::getCoordX( TQDateTime dt ) { /* *************************************************************** KDTimeHeaderWidget:: KDTimeHeaderWidget ***************************************************************** */ -KDTimeHeaderWidget:: KDTimeHeaderWidget( TQWidget* tqparent,KDGanttView* gant ) - : TQWidget (tqparent) +KDTimeHeaderWidget:: KDTimeHeaderWidget( TQWidget* parent,KDGanttView* gant ) + : TQWidget (parent) { myToolTip = new KDTimeHeaderToolTip(this,this); mySizeHint = 0; @@ -2549,10 +2549,10 @@ void KDTimeHeaderWidget::mouseMoveEvent ( TQMouseEvent * e ) /* *************************************************************** KDLegendWidget:: KDLegendWidget ***************************************************************** */ -KDLegendWidget:: KDLegendWidget( TQWidget* tqparent, +KDLegendWidget:: KDLegendWidget( TQWidget* parent, KDGanttMinimizeSplitter* legendParent ) : KDGanttSemiSizingControl ( KDGanttSemiSizingControl::Before,Qt::Vertical, - tqparent) + parent) { myLegendParent = legendParent; dock = 0; @@ -2700,7 +2700,7 @@ bool KDLegendWidget::isShown ( ) } -KDListView::KDListView(TQWidget* tqparent, KDGanttView* gantView):TQListView (tqparent) +KDListView::KDListView(TQWidget* parent, KDGanttView* gantView):TQListView (parent) { myGanttView = gantView; setAcceptDrops(true); @@ -3003,13 +3003,13 @@ void KDListView::dragMoveEvent ( TQDragMoveEvent * e) } if ( e->source() == myGanttView && gItem ){ // internal drag - do not allow to drag the item to a subitem of itself - KDGanttViewItem* pItem = gItem->tqparent(); + KDGanttViewItem* pItem = gItem->parent(); while ( pItem ) { if ( pItem == myGanttView->myCanvasView->lastClickedItem ) { e->accept( false ); return; } - pItem = pItem->tqparent(); + pItem = pItem->parent(); } if ( gItem == myGanttView->myCanvasView->lastClickedItem ) { e->accept( false ); @@ -3164,8 +3164,8 @@ KDCanvasRectangle::KDCanvasRectangle( KDTimeTableWidget* canvas, -KDGanttCanvasView::KDGanttCanvasView( KDGanttView* sender,TQCanvas* canvas, TQWidget* tqparent, const - char* name ) : TQCanvasView ( canvas, tqparent, name ), scrollBarTimer( 0, "scrollBarTimer" ) +KDGanttCanvasView::KDGanttCanvasView( KDGanttView* sender,TQCanvas* canvas, TQWidget* parent, const + char* name ) : TQCanvasView ( canvas, parent, name ), scrollBarTimer( 0, "scrollBarTimer" ) { setHScrollBarMode (TQScrollView::AlwaysOn ); setVScrollBarMode( TQScrollView::AlwaysOn ); @@ -3320,20 +3320,20 @@ void KDGanttCanvasView::insertItemAsRoot( KDGanttViewItem* item ) if ( item == cuttedItem ) cuttedItem = 0; } -void KDGanttCanvasView::insertItemAsChild( KDGanttViewItem* tqparent, KDGanttViewItem* item ) +void KDGanttCanvasView::insertItemAsChild( KDGanttViewItem* parent, KDGanttViewItem* item ) { - tqparent->insertItem( cuttedItem ); + parent->insertItem( cuttedItem ); if ( item == cuttedItem ) cuttedItem = 0; } -void KDGanttCanvasView::insertItemAfter( KDGanttViewItem* tqparent , KDGanttViewItem* item ) +void KDGanttCanvasView::insertItemAfter( KDGanttViewItem* parent , KDGanttViewItem* item ) { - if ( tqparent->tqparent() ) { - tqparent->tqparent()->insertItem( item ); + if ( parent->parent() ) { + parent->parent()->insertItem( item ); } else mySignalSender->myListView->insertItem( item ); - item->moveItem( tqparent ); + item->moveItem( parent ); if ( item == cuttedItem ) cuttedItem = 0; } @@ -3341,9 +3341,9 @@ void KDGanttCanvasView::insertItemAfter( KDGanttViewItem* tqparent , KDGanttVie void KDGanttCanvasView::cutItem() { lastClickedItem->hideSubtree(); - //qDebug("last clicked %d tqparent %d ", lastClickedItem , lastClickedItem->tqparent()); - if ( lastClickedItem->tqparent() ) - lastClickedItem->tqparent()->takeItem(lastClickedItem); + //qDebug("last clicked %d parent %d ", lastClickedItem , lastClickedItem->parent()); + if ( lastClickedItem->parent() ) + lastClickedItem->parent()->takeItem(lastClickedItem); else mySignalSender->myListView->takeItem( lastClickedItem ); mySignalSender->myTimeTable->updateMyContent(); @@ -3379,8 +3379,8 @@ void KDGanttCanvasView::pasteItem( int type ) lastClickedItem->insertItem( cuttedItem ); break; case 2://after - if ( lastClickedItem->tqparent() ) { - lastClickedItem->tqparent()->insertItem( cuttedItem ); + if ( lastClickedItem->parent() ) { + lastClickedItem->parent()->insertItem( cuttedItem ); } else mySignalSender->myListView->insertItem( cuttedItem ); @@ -3427,20 +3427,20 @@ void KDGanttCanvasView::newChildItem( int type ) temp = new KDGanttViewTaskItem( lastClickedItem, i18n( "New Task" ) ); break; case 5: - if ( lastClickedItem->tqparent() ) - temp = new KDGanttViewEventItem( lastClickedItem->tqparent(), lastClickedItem, i18n( "New Event" ) ); + if ( lastClickedItem->parent() ) + temp = new KDGanttViewEventItem( lastClickedItem->parent(), lastClickedItem, i18n( "New Event" ) ); else temp = new KDGanttViewEventItem( mySignalSender, lastClickedItem, i18n( "New Event" ) ); break; case 4: - if ( lastClickedItem->tqparent() ) - temp = new KDGanttViewSummaryItem( lastClickedItem->tqparent(), lastClickedItem, i18n( "New Summary" ) ); + if ( lastClickedItem->parent() ) + temp = new KDGanttViewSummaryItem( lastClickedItem->parent(), lastClickedItem, i18n( "New Summary" ) ); else temp = new KDGanttViewSummaryItem( mySignalSender, lastClickedItem, i18n( "New Summary" ) ); break; case 6: - if ( lastClickedItem->tqparent() ) - temp = new KDGanttViewTaskItem( lastClickedItem->tqparent(), lastClickedItem, i18n( "New Task" ) ); + if ( lastClickedItem->parent() ) + temp = new KDGanttViewTaskItem( lastClickedItem->parent(), lastClickedItem, i18n( "New Task" ) ); else temp = new KDGanttViewTaskItem( mySignalSender, lastClickedItem, i18n( "New Task" ) ); break; |