diff options
Diffstat (limited to 'kdeui')
34 files changed, 164 insertions, 158 deletions
diff --git a/kdeui/kaction.cpp b/kdeui/kaction.cpp index 5327845ab..2c5b5caec 100644 --- a/kdeui/kaction.cpp +++ b/kdeui/kaction.cpp @@ -256,7 +256,7 @@ void KAction::initPrivate( const TQString& text, const KShortcut& cut, { d->m_cutDefault = cut; - m_parentCollection = dynamic_cast<KActionCollection *>( parent() ); + m_parentCollection = tqt_dynamic_cast<KActionCollection *>( parent() ); kdDebug(129) << "KAction::initPrivate(): this = " << this << " name = \"" << name() << "\" cut = " << cut.toStringInternal() << " m_parentCollection = " << m_parentCollection << endl; if ( m_parentCollection ) m_parentCollection->insert( this ); @@ -816,7 +816,7 @@ void KAction::plugMainWindowAccel( TQWidget *w ) while ( !tl->isDialog() && ( n = tl->tqparentWidget() ) ) // lookup parent and store tl = n; - KMainWindow * mw = dynamic_cast<KMainWindow *>(tl); // try to see if it's a kmainwindow + KMainWindow * mw = tqt_dynamic_cast<KMainWindow *>(tl); // try to see if it's a kmainwindow if (mw) plugAccel( mw->accel() ); else @@ -1051,12 +1051,12 @@ TQWidget* KAction::container( int index ) const KToolBar* KAction::toolBar( int index ) const { - return dynamic_cast<KToolBar *>( d->m_containers[ index ].m_container ); + return tqt_dynamic_cast<KToolBar *>( d->m_containers[ index ].m_container ); } TQPopupMenu* KAction::popupMenu( int index ) const { - return dynamic_cast<TQPopupMenu *>( d->m_containers[ index ].m_container ); + return tqt_dynamic_cast<TQPopupMenu *>( d->m_containers[ index ].m_container ); } TQWidget* KAction::representative( int index ) const @@ -1120,14 +1120,14 @@ void KAction::slotPopupActivated() { if( ::tqqt_cast<TQSignal *>(sender())) { - int id = dynamic_cast<const TQSignal *>(sender())->value().toInt(); + int id = tqt_dynamic_cast<const TQSignal *>(sender())->value().toInt(); int pos = findContainer(id); if(pos != -1) { - TQPopupMenu* qpm = dynamic_cast<TQPopupMenu *>( container(pos) ); + TQPopupMenu* qpm = tqt_dynamic_cast<TQPopupMenu *>( container(pos) ); if(qpm) { - KPopupMenu* kpm = dynamic_cast<KPopupMenu *>( qpm ); + KPopupMenu* kpm = tqt_dynamic_cast<KPopupMenu *>( qpm ); TQt::ButtonState state; if ( kpm ) // KPopupMenu? Nice, it stores the state. state = kpm->state(); diff --git a/kdeui/kactionclasses.cpp b/kdeui/kactionclasses.cpp index 3185db276..2d926f971 100644 --- a/kdeui/kactionclasses.cpp +++ b/kdeui/kactionclasses.cpp @@ -1949,8 +1949,8 @@ int KToolBarPopupAction::plug( TQWidget *widget, int index ) int id_ = KAction::getToolButtonID(); if ( icon().isEmpty() && !iconSet().isNull() ) { - bar->insertButton( iconSet().pixmap(), id_, TQT_SIGNAL( buttonClicked(int, Qt::ButtonState) ), this, - TQT_SLOT( slotButtonClicked(int, Qt::ButtonState) ), + bar->insertButton( iconSet().pixmap(), id_, TQT_SIGNAL( buttonClicked(int, TQt::ButtonState) ), this, + TQT_SLOT( slotButtonClicked(int, TQt::ButtonState) ), isEnabled(), plainText(), index ); } else { @@ -1960,8 +1960,8 @@ int KToolBarPopupAction::plug( TQWidget *widget, int index ) else instance = KGlobal::instance(); - bar->insertButton( icon(), id_, TQT_SIGNAL( buttonClicked(int, Qt::ButtonState) ), this, - TQT_SLOT( slotButtonClicked(int, Qt::ButtonState) ), + bar->insertButton( icon(), id_, TQT_SIGNAL( buttonClicked(int, TQt::ButtonState) ), this, + TQT_SLOT( slotButtonClicked(int, TQt::ButtonState) ), isEnabled(), plainText(), index, instance ); } @@ -2027,7 +2027,7 @@ int KToggleToolBarAction::plug( TQWidget* w, int index ) while ( !tl->isDialog() && ( n = tl->tqparentWidget() ) ) // lookup parent and store tl = n; - KMainWindow * mw = dynamic_cast<KMainWindow *>(tl); // try to see if it's a kmainwindow + KMainWindow * mw = tqt_dynamic_cast<KMainWindow *>(tl); // try to see if it's a kmainwindow if ( mw ) m_toolBar = mw->toolBar( m_toolBarName ); @@ -2326,7 +2326,7 @@ void KPasteTextAction::menuAboutToShow() if (reply.isValid()) list = reply; } - TQString clipboardText = tqApp->clipboard()->text(TQClipboard::Clipboard); + TQString clipboardText = tqApp->tqclipboard()->text(TQClipboard::Clipboard); if (list.isEmpty()) list << clipboardText; bool found = false; @@ -2354,7 +2354,7 @@ void KPasteTextAction::menuItemActivated( int id) TQString clipboardText = reply; reply = klipper.call("setClipboardContents(TQString)", clipboardText); if (reply.isValid()) - kdDebug(129) << "Clipboard: " << TQString(tqApp->clipboard()->text(TQClipboard::Clipboard)) << endl; + kdDebug(129) << "Clipboard: " << TQString(tqApp->tqclipboard()->text(TQClipboard::Clipboard)) << endl; } TQTimer::singleShot(20, this, TQT_SLOT(slotActivated())); } diff --git a/kdeui/kactioncollection.cpp b/kdeui/kactioncollection.cpp index 47f649d6b..671bc5d94 100644 --- a/kdeui/kactioncollection.cpp +++ b/kdeui/kactioncollection.cpp @@ -110,7 +110,7 @@ KActionCollection::KActionCollection( TQObject *parent, const char *name, kdWarning(129) << "KActionCollection::KActionCollection( TQObject *parent, const char *name, KInstance *instance )" << endl; //ellis kdDebug(129) << kdBacktrace() << endl; d = new KActionCollectionPrivate; - TQWidget* w = dynamic_cast<TQWidget*>( parent ); + TQWidget* w = tqt_dynamic_cast<TQWidget*>( parent ); if( w ) setWidget( w ); //d->m_bOneKAccelOnly = (d->m_kaccelList.count() > 0); @@ -250,8 +250,8 @@ void KActionCollection::removeWidget( TQWidget* w ) } delete pKAccel; - d->m_widgetList.remove( d->m_widgetList.at( i ) ); - d->m_kaccelList.remove( d->m_kaccelList.at( i ) ); + d->m_widgetList.remove( d->m_widgetList.tqat( i ) ); + d->m_kaccelList.remove( d->m_kaccelList.tqat( i ) ); if( d->m_iWidgetCurrent == (int)i ) d->m_iWidgetCurrent = -1; @@ -402,7 +402,7 @@ KAction* KActionCollection::action( int index ) const TQAsciiDictIterator<KAction> it( d->m_actionDict ); it += index; return it.current(); -// return d->m_actions.at( index ); +// return d->m_actions.tqat( index ); } bool KActionCollection::readShortcutSettings( const TQString& sConfigGroup, KConfigBase* pConfig ) diff --git a/kdeui/kcolorbutton.cpp b/kdeui/kcolorbutton.cpp index 847b6816b..c208d96f4 100644 --- a/kdeui/kcolorbutton.cpp +++ b/kdeui/kcolorbutton.cpp @@ -159,7 +159,7 @@ void KColorButton::keyPressEvent( TQKeyEvent *e ) } else if ( KStdAccel::paste().contains( key ) ) { TQColor color; - KColorDrag::decode( TQApplication::tqclipboard()->data( QClipboard::Clipboard ), color ); + KColorDrag::decode( TQApplication::tqclipboard()->data( TQClipboard::Clipboard ), color ); setColor( color ); } else diff --git a/kdeui/kcombobox.cpp b/kdeui/kcombobox.cpp index 94df22190..25a6a4a43 100644 --- a/kdeui/kcombobox.cpp +++ b/kdeui/kcombobox.cpp @@ -261,7 +261,7 @@ void KComboBox::setLineEdit( TQLineEdit *edit ) } TQComboBox::setLineEdit( edit ); - d->klineEdit = dynamic_cast<KLineEdit*>( edit ); + d->klineEdit = tqt_dynamic_cast<KLineEdit*>( edit ); setDelegate( d->klineEdit ); // Connect the returnPressed signal for both Q[K]LineEdits' diff --git a/kdeui/kcursor.cpp b/kdeui/kcursor.cpp index 0ee90bb1e..da32249a9 100644 --- a/kdeui/kcursor.cpp +++ b/kdeui/kcursor.cpp @@ -308,7 +308,7 @@ TQWidget* KCursorPrivateAutoHideEventFilter::actualWidget() const TQWidget* w = m_widget; // Is w a scrollview ? Call setCursor on the viewport in that case. - TQScrollView * sv = dynamic_cast<TQScrollView *>( w ); + TQScrollView * sv = tqt_dynamic_cast<TQScrollView *>( w ); if ( sv ) w = sv->viewport(); diff --git a/kdeui/kdockwidget.cpp b/kdeui/kdockwidget.cpp index 3c8832391..7375a25e9 100644 --- a/kdeui/kdockwidget.cpp +++ b/kdeui/kdockwidget.cpp @@ -535,7 +535,7 @@ void KDockWidget::setPixmap(const TQPixmap& pixmap) { dtg->changeTab(this,pixmap,dtg->tabLabel(this)); TQWidget *contWid=parentDockContainer(); if (contWid) { - KDockContainer *x = dynamic_cast<KDockContainer*>(contWid); + KDockContainer *x = tqt_dynamic_cast<KDockContainer*>(contWid); if (x) { x->setPixmap(this,pixmap); } @@ -556,7 +556,7 @@ KDockWidget::~KDockWidget() } if (latestKDockContainer()) { - KDockContainer *x = dynamic_cast<KDockContainer*>(latestKDockContainer()); + KDockContainer *x = tqt_dynamic_cast<KDockContainer*>(latestKDockContainer()); if (x) { x->removeWidget(this); } @@ -719,7 +719,7 @@ void KDockWidget::setLatestKDockContainer(TQWidget* container) { if (container) { - if (dynamic_cast<KDockContainer*>(container)) + if (tqt_dynamic_cast<KDockContainer*>(container)) d->container=container; else d->container=0; @@ -729,7 +729,7 @@ void KDockWidget::setLatestKDockContainer(TQWidget* container) TQWidget* KDockWidget::latestKDockContainer() { if (!(d->container)) return 0; - if (dynamic_cast<KDockContainer*>(d->container.operator->())) return d->container; + if (tqt_dynamic_cast<KDockContainer*>(d->container.operator->())) return d->container; return 0; } @@ -782,7 +782,7 @@ void KDockWidget::updateHeader() header->hide(); } else { header->setTopLevel( false ); - if (widget && dynamic_cast<KDockContainer*>(widget)) + if (widget && tqt_dynamic_cast<KDockContainer*>(widget)) header->hide(); else header->show(); @@ -999,7 +999,7 @@ KDockWidget* KDockWidget::manualDock( KDockWidget* target, DockPosition dockPos, * dock tab group, and our parent isn't a KDockContainer, and we have no explicit * parent dock container...we can't do much yet */ if ( parent() && !parent()->inherits("KDockSplitter") && !parentDockTabGroup() && - !(dynamic_cast<KDockContainer*>(parent())) && !parentDockContainer()){ + !(tqt_dynamic_cast<KDockContainer*>(parent())) && !parentDockContainer()){ // kdDebug(282)<<"KDockWidget::manualDock(): success = false (3)"<<endl; // kdDebug(282)<<parent()->name()<<endl; success = false; @@ -1064,11 +1064,11 @@ KDockWidget* KDockWidget::manualDock( KDockWidget* target, DockPosition dockPos, if (!contWid) contWid=target->widget; if (contWid) { - KDockContainer *cont=dynamic_cast<KDockContainer*>(contWid); + KDockContainer *cont=tqt_dynamic_cast<KDockContainer*>(contWid); if (cont) { if (latestKDockContainer() && (latestKDockContainer()!=contWid)) { - KDockContainer* dc = dynamic_cast<KDockContainer*>(latestKDockContainer()); + KDockContainer* dc = tqt_dynamic_cast<KDockContainer*>(latestKDockContainer()); if (dc) { dc->removeWidget(this); } @@ -1227,7 +1227,7 @@ TQWidget *KDockWidget::parentDockContainer() const { if (!parent()) return 0L; TQWidget* candidate = tqparentWidget()->tqparentWidget(); - if (candidate && dynamic_cast<KDockContainer*>(candidate)) return candidate; + if (candidate && tqt_dynamic_cast<KDockContainer*>(candidate)) return candidate; return 0L; } @@ -1382,7 +1382,7 @@ void KDockWidget::undock() { // kdDebug(282)<<"undocked from dockcontainer"<<endl; undockedFromContainer=true; - KDockContainer* dc = dynamic_cast<KDockContainer*>(d->container.operator->()); + KDockContainer* dc = tqt_dynamic_cast<KDockContainer*>(d->container.operator->()); if (dc) { dc->undockWidget(this); setFormerBrotherDockWidget(dc->parentDockWidget()); @@ -1462,7 +1462,7 @@ void KDockWidget::setWidget( TQWidget* mw ) layout = new TQVBoxLayout( this ); layout->setResizeMode( TQLayout::Minimum ); - KDockContainer* dc = dynamic_cast<KDockContainer*>(widget); + KDockContainer* dc = tqt_dynamic_cast<KDockContainer*>(widget); if (dc) { d->isContainer=true; @@ -1538,7 +1538,7 @@ void KDockWidget::makeDockVisible() } if (parentDockContainer()) { TQWidget *contWid=parentDockContainer(); - KDockContainer *x = dynamic_cast<KDockContainer*>(contWid); + KDockContainer *x = tqt_dynamic_cast<KDockContainer*>(contWid); if (x) { x->showWidget(this); } @@ -1862,7 +1862,7 @@ KDockWidget* KDockManager::findDockWidgetAt( const TQPoint& pos ) } if ( qt_tqfind_obj_child( TQT_TQOBJECT(w), "KDockSplitter", "_dock_split_" ) ) return 0L; if ( qt_tqfind_obj_child( TQT_TQOBJECT(w), "KDockTabGroup", "_dock_tab" ) ) return 0L; - if (dynamic_cast<KDockContainer*>(w)) return 0L; + if (tqt_dynamic_cast<KDockContainer*>(w)) return 0L; if (!childDockWidgetList) return 0L; if ( childDockWidgetList->tqfind(w) != -1 ) return 0L; @@ -2221,7 +2221,7 @@ void KDockManager::writeConfig(TQDomElement &base) for (TQObjectListIt it(d->containerDocks);it.current();++it) { - KDockContainer* dc = dynamic_cast<KDockContainer*>(((KDockWidget*)it.current())->widget); + KDockContainer* dc = tqt_dynamic_cast<KDockContainer*>(((KDockWidget*)it.current())->widget); if (dc) { dc->prepareSave(nList); } @@ -2241,7 +2241,7 @@ void KDockManager::writeConfig(TQDomElement &base) TQDomElement groupEl; if (obj->d->isContainer) { - KDockContainer* x = dynamic_cast<KDockContainer*>(obj->widget); + KDockContainer* x = tqt_dynamic_cast<KDockContainer*>(obj->widget); if (x) { groupEl=doc.createElement("dockContainer"); x->save(groupEl); @@ -2379,7 +2379,7 @@ void KDockManager::readConfig(TQDomElement &base) if (!(cont->d->isContainer)) { kdDebug(282)<<"restoration of dockContainer is only supported for already existing dock containers"<<endl; } else { - KDockContainer *dc=dynamic_cast<KDockContainer*>(cont->getWidget()); + KDockContainer *dc=tqt_dynamic_cast<KDockContainer*>(cont->getWidget()); if (!dc) kdDebug(282)<<"Error while trying to handle dockcontainer configuration restoration"<<endl; else { dc->load(childEl); @@ -2555,7 +2555,7 @@ void KDockManager::writeConfig( KConfig* c, TQString group ) // kdDebug(282)<<TQString("list size: %1").arg(nList.count())<<endl; for (TQObjectListIt it(d->containerDocks);it.current();++it) { - KDockContainer* dc = dynamic_cast<KDockContainer*>(((KDockWidget*)it.current())->widget); + KDockContainer* dc = tqt_dynamic_cast<KDockContainer*>(((KDockWidget*)it.current())->widget); if (dc) { dc->prepareSave(nList); } @@ -2571,7 +2571,7 @@ void KDockManager::writeConfig( KConfig* c, TQString group ) obj->header->saveConfig( c ); } if (obj->d->isContainer) { - KDockContainer* x = dynamic_cast<KDockContainer*>(obj->widget); + KDockContainer* x = tqt_dynamic_cast<KDockContainer*>(obj->widget); if (x) { x->save(c,group); } @@ -2734,7 +2734,7 @@ void KDockManager::readConfig( KConfig* c, TQString group ) } if (obj && obj->d->isContainer) { - dynamic_cast<KDockContainer*>(obj->widget)->load(c,group); + tqt_dynamic_cast<KDockContainer*>(obj->widget)->load(c,group); removeFromAutoCreateList(obj); } if ( obj && obj->header){ @@ -2774,7 +2774,7 @@ void KDockManager::readConfig( KConfig* c, TQString group ) KDockWidget* d2 = getDockWidgetFromName( list.current() ); tabDockGroup = d2->manualDock( d1, KDockWidget::DockCenter ); if ( tabDockGroup ){ - KDockTabGroup* tab = dynamic_cast<KDockTabGroup*>(tabDockGroup->widget); + KDockTabGroup* tab = tqt_dynamic_cast<KDockTabGroup*>(tabDockGroup->widget); list.next(); while ( list.current() && tabDockGroup ){ KDockWidget* tabDock = getDockWidgetFromName( list.current() ); @@ -2791,7 +2791,7 @@ void KDockManager::readConfig( KConfig* c, TQString group ) obj = tabDockGroup; } - if (obj && obj->d->isContainer) dynamic_cast<KDockContainer*>(obj->widget)->load(c,group); + if (obj && obj->d->isContainer) tqt_dynamic_cast<KDockContainer*>(obj->widget)->load(c,group); if ( obj && obj->header){ obj->header->loadConfig( c ); } @@ -2950,7 +2950,7 @@ void KDockManager::slotMenuPopup() void KDockManager::slotMenuActivated( int id ) { - MenuDockData* data = menuData->at( id ); + MenuDockData* data = menuData->tqat( id ); data->dock->changeHideShowState(); } @@ -3121,9 +3121,9 @@ void KDockArea::resizeEvent(TQResizeEvent *rsize) // for (unsigned int i=0;i<children()->count();i++) { // TQPtrList<TQObject> list(children()); -// TQObject *obj=((TQPtrList<TQObject*>)children())->at(i); +// TQObject *obj=((TQPtrList<TQObject*>)children())->tqat(i); TQObject *obj=children()->getFirst(); - if (split = dynamic_cast<KDockSplitter*>(obj)) + if (split = tqt_dynamic_cast<KDockSplitter*>(obj)) { split->setGeometry( TQRect(TQPoint(0,0), size() )); // break; @@ -3272,7 +3272,7 @@ void KDockContainer::prepareSave(TQStringList &names) names.remove(tmp->data); // for (uint i=0;i<m_children.count();i++) // { -// names.remove(m_children.at(i)); +// names.remove(m_children.tqat(i)); // } } diff --git a/kdeui/kdockwidget_private.cpp b/kdeui/kdockwidget_private.cpp index c049d6fb1..707a72f19 100644 --- a/kdeui/kdockwidget_private.cpp +++ b/kdeui/kdockwidget_private.cpp @@ -274,7 +274,7 @@ void KDockSplitter::resizeEvent(TQResizeEvent *ev) // However, this works surprising well! if (m_orientation == Qt::Horizontal) { if (ev->oldSize().height() != ev->size().height()) { - if( (c1->getWidget()) && (dc=dynamic_cast<KDockContainer*>(c1->getWidget()))) { + if( (c1->getWidget()) && (dc=tqt_dynamic_cast<KDockContainer*>(c1->getWidget()))) { // dockwidget is on the bottom. move xpos so that the size from child1 stays xpos = (int)ceil(((double)factor) * checkValue(height() - child1->height() - 4) / height()); } else { @@ -286,7 +286,7 @@ void KDockSplitter::resizeEvent(TQResizeEvent *ev) } } else { if (ev->oldSize().width() != width()) { - if( (c1->getWidget()) && (dc=dynamic_cast<KDockContainer*>(c1->getWidget()))) { + if( (c1->getWidget()) && (dc=tqt_dynamic_cast<KDockContainer*>(c1->getWidget()))) { xpos = (int)ceil(((double)factor) * checkValue(width() - child1->width() - 4) / width()); } else { // xpos should not change @@ -332,11 +332,11 @@ void KDockSplitter::resizeEvent(TQResizeEvent *ev) kdDebug(282) << "Splitter visibility : " << divider->isVisible() << endl;; kdDebug(282) << "Splitter procentual pos: " << xpos << endl; if (c0->getWidget()) { - dc=dynamic_cast<KDockContainer*>(c0->getWidget()); + dc=tqt_dynamic_cast<KDockContainer*>(c0->getWidget()); kdDebug(282) << "Child 0 KDockContainer?: " << dc << endl; } if (c1->getWidget()) { - dc=dynamic_cast<KDockContainer*>(c1->getWidget()); + dc=tqt_dynamic_cast<KDockContainer*>(c1->getWidget()); kdDebug(282) << "Child 1 KDockContainer?: " << dc << endl; } kdDebug(282) << "Child0 : " << child0 << endl; @@ -348,7 +348,7 @@ void KDockSplitter::resizeEvent(TQResizeEvent *ev) // if( ( (m_orientation==Qt::Vertical) &&((fixedWidth0==-1) && (fixedWidth1==-1)) ) || ( (m_orientation==Qt::Horizontal) &&((fixedHeight0==-1) && (fixedHeight1==-1)) ) ) { - if ((c0->getWidget()) && (dc=dynamic_cast<KDockContainer*>(c0->getWidget())) + if ((c0->getWidget()) && (dc=tqt_dynamic_cast<KDockContainer*>(c0->getWidget())) && (dc->isOverlapMode())) { // child0 ist a KDockContainer int position; @@ -367,7 +367,7 @@ void KDockSplitter::resizeEvent(TQResizeEvent *ev) divider->setGeometry(position, 0, 4, height()); } } else { - if ((c1->getWidget()) && (dc=dynamic_cast<KDockContainer*>(c1->getWidget())) + if ((c1->getWidget()) && (dc=tqt_dynamic_cast<KDockContainer*>(c1->getWidget())) && (dc->isOverlapMode())) { // child1 ist a KDockContainer int position; @@ -403,7 +403,7 @@ void KDockSplitter::resizeEvent(TQResizeEvent *ev) int diff = 0; if (m_orientation == Qt::Horizontal) { - if ((c1->getWidget()) && (dc=dynamic_cast<KDockContainer*>(c1->getWidget()))) { + if ((c1->getWidget()) && (dc=tqt_dynamic_cast<KDockContainer*>(c1->getWidget()))) { // bottom is dockcontainer if( divider->isVisible() ) { child0->setGeometry(0, 0, width(), position); @@ -419,7 +419,7 @@ void KDockSplitter::resizeEvent(TQResizeEvent *ev) } divider->setGeometry(0, position, width(), 4); } else { - if ((c1->getWidget()) && (dc=dynamic_cast<KDockContainer*>(c1->getWidget()))) { + if ((c1->getWidget()) && (dc=tqt_dynamic_cast<KDockContainer*>(c1->getWidget()))) { // right is dockcontainer if( divider->isVisible() ) { child0->setGeometry(0, 0, position, height()); @@ -497,8 +497,8 @@ bool KDockSplitter::eventFilter(TQObject *o, TQEvent *e) switch (e->type()) { case TQEvent::MouseMove: mev= (TQMouseEvent*)e; - child0->setUpdatesEnabled(mOpaqueResize); - child1->setUpdatesEnabled(mOpaqueResize); + child0->tqsetUpdatesEnabled(mOpaqueResize); + child1->tqsetUpdatesEnabled(mOpaqueResize); if (m_orientation == Qt::Horizontal) { if ((fixedHeight0!=-1) || (fixedHeight1!=-1)) { @@ -536,8 +536,8 @@ bool KDockSplitter::eventFilter(TQObject *o, TQEvent *e) handled= true; break; case TQEvent::MouseButtonRelease: - child0->setUpdatesEnabled(true); - child1->setUpdatesEnabled(true); + child0->tqsetUpdatesEnabled(true); + child1->tqsetUpdatesEnabled(true); mev= (TQMouseEvent*)e; if (m_orientation == Qt::Horizontal){ if ((fixedHeight0!=-1) || (fixedHeight1!=-1)) diff --git a/kdeui/keditlistbox.cpp b/kdeui/keditlistbox.cpp index 2960252d4..f8aeb096f 100644 --- a/kdeui/keditlistbox.cpp +++ b/kdeui/keditlistbox.cpp @@ -411,7 +411,7 @@ void KEditListBox::virtual_hook( int, void* ) KEditListBox::CustomEditor::CustomEditor( KComboBox *combo ) { m_representationWidget = combo; - m_lineEdit = dynamic_cast<KLineEdit*>( combo->lineEdit() ); + m_lineEdit = tqt_dynamic_cast<KLineEdit*>( combo->lineEdit() ); assert( m_lineEdit ); } diff --git a/kdeui/kiconview.cpp b/kdeui/kiconview.cpp index 357d6b2c4..6c4c5ff4b 100644 --- a/kdeui/kiconview.cpp +++ b/kdeui/kiconview.cpp @@ -184,7 +184,7 @@ void KIconView::slotAutoSelect() bool select = !m_pCurrentItem->isSelected(); bool update = viewport()->isUpdatesEnabled(); - viewport()->setUpdatesEnabled( false ); + viewport()->tqsetUpdatesEnabled( false ); //Calculate the smallest rectangle that contains the current Item //and the one that got the autoselect event @@ -216,7 +216,7 @@ void KIconView::slotAutoSelect() } blockSignals( block ); - viewport()->setUpdatesEnabled( update ); + viewport()->tqsetUpdatesEnabled( update ); tqrepaintContents( redraw, false ); emit selectionChanged(); diff --git a/kdeui/kjanuswidget.cpp b/kdeui/kjanuswidget.cpp index cb7da4a4f..2cfbb473e 100644 --- a/kdeui/kjanuswidget.cpp +++ b/kdeui/kjanuswidget.cpp @@ -518,7 +518,7 @@ bool KJanusWidget::setSwallowedWidget( TQWidget *widget ) TQObjectList l = mSwallowPage->childrenListObject(); // silence please for( uint i=0; i < l.count(); i++ ) { - TQObject *o = l.at(i); + TQObject *o = l.tqat(i); if( o->isWidgetType() ) { ((TQWidget*)o)->hide(); diff --git a/kdeui/klanguagebutton.cpp b/kdeui/klanguagebutton.cpp index 469fef5a1..7da8b85e5 100644 --- a/kdeui/klanguagebutton.cpp +++ b/kdeui/klanguagebutton.cpp @@ -191,7 +191,7 @@ void KLanguageButton::slotActivated( int index ) setCurrentItem( index ); // Forward event from popup menu as if it was emitted from this widget: - TQString id = *m_ids->at( index ); + TQString id = *m_ids->tqat( index ); emit activated( id ); } @@ -199,7 +199,7 @@ void KLanguageButton::slotHighlighted( int index ) { //kdDebug() << "slotHighlighted" << index << endl; - TQString id = *m_ids->at( index ); + TQString id = *m_ids->tqat( index ); emit ( highlighted(id) ); } @@ -237,7 +237,7 @@ bool KLanguageButton::contains( const TQString & id ) const TQString KLanguageButton::current() const { - return *m_ids->at( currentItem() ); + return *m_ids->tqat( currentItem() ); } @@ -248,7 +248,7 @@ TQString KLanguageButton::id( int i ) const kdDebug() << "KLanguageButton::tag(), unknown tag " << i << endl; return TQString::null; } - return *m_ids->at( i ); + return *m_ids->tqat( i ); } diff --git a/kdeui/klineedit.cpp b/kdeui/klineedit.cpp index d3d50795c..48861d38c 100644 --- a/kdeui/klineedit.cpp +++ b/kdeui/klineedit.cpp @@ -420,9 +420,9 @@ bool KLineEdit::copySqueezedText(bool clipboard) const return false; TQString t = d->squeezedText; t = t.mid(start, end - start); - disconnect( TQApplication::clipboard(), TQT_SIGNAL(selectionChanged()), this, 0); - TQApplication::clipboard()->setText( t, clipboard ? QClipboard::Clipboard : QClipboard::Selection ); - connect( TQApplication::clipboard(), TQT_SIGNAL(selectionChanged()), this, + disconnect( TQApplication::tqclipboard(), TQT_SIGNAL(selectionChanged()), this, 0); + TQApplication::tqclipboard()->setText( t, clipboard ? TQClipboard::Clipboard : TQClipboard::Selection ); + connect( TQApplication::tqclipboard(), TQT_SIGNAL(selectionChanged()), this, TQT_SLOT(clipboardChanged()) ); return true; } @@ -453,7 +453,7 @@ void KLineEdit::keyPressEvent( TQKeyEvent *e ) } else if ( KStdAccel::pasteSelection().contains( key ) ) { - TQString text = TQApplication::clipboard()->text( QClipboard::Selection); + TQString text = TQApplication::tqclipboard()->text( TQClipboard::Selection); insert( text ); deselect(); return; @@ -840,7 +840,7 @@ void KLineEdit::mousePressEvent( TQMouseEvent* e ) void KLineEdit::mouseReleaseEvent( TQMouseEvent* e ) { TQLineEdit::mouseReleaseEvent( e ); - if (TQApplication::clipboard()->supportsSelection() ) { + if (TQApplication::tqclipboard()->supportsSelection() ) { if ( e->button() == Qt::LeftButton ) { // Fix copying of squeezed text if needed copySqueezedText( false ); diff --git a/kdeui/klistbox.cpp b/kdeui/klistbox.cpp index 13c5ab325..30d418daf 100644 --- a/kdeui/klistbox.cpp +++ b/kdeui/klistbox.cpp @@ -133,7 +133,7 @@ void KListBox::slotAutoSelect() bool select = !m_pCurrentItem->isSelected(); bool update = viewport()->isUpdatesEnabled(); - viewport()->setUpdatesEnabled( false ); + viewport()->tqsetUpdatesEnabled( false ); bool down = index( previousItem ) < index( m_pCurrentItem ); TQListBoxItem* it = down ? previousItem : m_pCurrentItem; @@ -150,7 +150,7 @@ void KListBox::slotAutoSelect() } blockSignals( block ); - viewport()->setUpdatesEnabled( update ); + viewport()->tqsetUpdatesEnabled( update ); triggerUpdate( false ); emit selectionChanged(); diff --git a/kdeui/klistview.cpp b/kdeui/klistview.cpp index 2e9253ac7..b65cab53b 100644 --- a/kdeui/klistview.cpp +++ b/kdeui/klistview.cpp @@ -621,7 +621,7 @@ void KListView::slotAutoSelect() bool select = !d->pCurrentItem->isSelected(); bool update = viewport()->isUpdatesEnabled(); - viewport()->setUpdatesEnabled( false ); + viewport()->tqsetUpdatesEnabled( false ); bool down = previousItem->itemPos() < d->pCurrentItem->itemPos(); TQListViewItemIterator lit( down ? previousItem : d->pCurrentItem ); @@ -638,7 +638,7 @@ void KListView::slotAutoSelect() } blockSignals( block ); - viewport()->setUpdatesEnabled( update ); + viewport()->tqsetUpdatesEnabled( update ); triggerUpdate(); emit selectionChanged(); @@ -661,7 +661,7 @@ void KListView::slotAutoSelect() } } else - kdDebug() << "KListView::slotAutoSelect: That´s not supposed to happen!!!!" << endl; + kdDebug() << "KListView::slotAutoSelect: That�s not supposed to happen!!!!" << endl; } void KListView::slotHeaderChanged() diff --git a/kdeui/klistviewsearchline.cpp b/kdeui/klistviewsearchline.cpp index 23fb14e18..6a73f9e38 100644 --- a/kdeui/klistviewsearchline.cpp +++ b/kdeui/klistviewsearchline.cpp @@ -302,7 +302,7 @@ void KListViewSearchLine::activateSearch() void KListViewSearchLine::itemAdded(TQListViewItem *item) const { - item->setVisible(itemMatches(item, text())); + item->tqsetVisible(itemMatches(item, text())); } void KListViewSearchLine::listViewDeleted() @@ -347,9 +347,9 @@ void KListViewSearchLine::checkItemParentsNotVisible() { TQListViewItem *item = it.current(); if(itemMatches(item, d->search)) - item->setVisible(true); + item->tqsetVisible(true); else - item->setVisible(false); + item->tqsetVisible(false); } } @@ -381,23 +381,23 @@ bool KListViewSearchLine::checkItemParentsVisible(TQListViewItem *item, TQListVi visible = true; if (highestHiddenParent) { - highestHiddenParent->setVisible(true); - // Calling setVisible on our ancestor will unhide all its descendents. Hide the ones + highestHiddenParent->tqsetVisible(true); + // Calling tqsetVisible on our ancestor will unhide all its descendents. Hide the ones // before us that should not be shown. for(TQListViewItem *hide = first; hide != item; hide = hide->nextSibling()) - hide->setVisible(false); + hide->tqsetVisible(false); highestHiddenParent = 0; - // If we matched, than none of our children matched, yet the setVisible() call on our + // If we matched, than none of our children matched, yet the tqsetVisible() call on our // ancestor unhid them, undo the damage: if(!childMatch) for(TQListViewItem *hide = item->firstChild(); hide; hide = hide->nextSibling()) - hide->setVisible(false); + hide->tqsetVisible(false); } else - item->setVisible(true); + item->tqsetVisible(true); } else - item->setVisible(false); + item->tqsetVisible(false); } return visible; } @@ -470,7 +470,7 @@ KListViewSearchLine *KListViewSearchLineWidget::searchLine() const void KListViewSearchLineWidget::positionInToolBar() { - KToolBar *toolBar = dynamic_cast<KToolBar *>(parent()); + KToolBar *toolBar = tqt_dynamic_cast<KToolBar *>(parent()); if(toolBar) { diff --git a/kdeui/kmainwindow.cpp b/kdeui/kmainwindow.cpp index 2a0bad08d..777f5e004 100644 --- a/kdeui/kmainwindow.cpp +++ b/kdeui/kmainwindow.cpp @@ -491,7 +491,7 @@ void KMainWindow::setupGUI( TQSize defaultSize, int options, const TQString & xm void KMainWindow::createGUI( const TQString &xmlfile, bool _conserveMemory ) { // disabling the updates prevents unnecessary redraws - setUpdatesEnabled( false ); + tqsetUpdatesEnabled( false ); // just in case we are rebuilding, let's remove our old client guiFactory()->removeClient( this ); @@ -564,7 +564,7 @@ void KMainWindow::createGUI( const TQString &xmlfile, bool _conserveMemory ) conserveMemory(); } - setUpdatesEnabled( true ); + tqsetUpdatesEnabled( true ); updateGeometry(); } diff --git a/kdeui/kmainwindowiface.cpp b/kdeui/kmainwindowiface.cpp index 0cee0f24b..9394d27bb 100644 --- a/kdeui/kmainwindowiface.cpp +++ b/kdeui/kmainwindowiface.cpp @@ -135,7 +135,7 @@ int KMainWindowInterface::getWinID() } void KMainWindowInterface::grabWindowToClipBoard() { - QClipboard *clipboard = TQApplication::clipboard(); + TQClipboard *clipboard = TQApplication::tqclipboard(); clipboard->setPixmap(TQPixmap::grabWidget(m_MainWindow)); } void KMainWindowInterface::hide() diff --git a/kdeui/kmenubar.cpp b/kdeui/kmenubar.cpp index ceee8e222..ed2702a9a 100644 --- a/kdeui/kmenubar.cpp +++ b/kdeui/kmenubar.cpp @@ -506,7 +506,7 @@ void KMenuBar::drawContents( TQPainter* p ) BackgroundMode bg_mode = backgroundMode(); BackgroundOrigin bg_origin = backgroundOrigin(); - setUpdatesEnabled(false); + tqsetUpdatesEnabled(false); setBackgroundMode(X11ParentRelative); setBackgroundOrigin(WindowOrigin); @@ -561,7 +561,7 @@ void KMenuBar::drawContents( TQPainter* p ) setBackgroundOrigin(bg_origin); setBackgroundMode(bg_mode); - setUpdatesEnabled(up_enabled); + tqsetUpdatesEnabled(up_enabled); } } diff --git a/kdeui/kpassdlg.cpp b/kdeui/kpassdlg.cpp index 37333ad21..5e5df81cd 100644 --- a/kdeui/kpassdlg.cpp +++ b/kdeui/kpassdlg.cpp @@ -187,9 +187,9 @@ void KPasswordEdit::erase() void KPasswordEdit::focusInEvent(TQFocusEvent *e) { const TQString txt = text(); - setUpdatesEnabled(false); + tqsetUpdatesEnabled(false); TQLineEdit::focusInEvent(e); - setUpdatesEnabled(true); + tqsetUpdatesEnabled(true); setText(txt); } diff --git a/kdeui/ksharedpixmap.cpp b/kdeui/ksharedpixmap.cpp index a062d2f8b..d0a74f223 100644 --- a/kdeui/ksharedpixmap.cpp +++ b/kdeui/ksharedpixmap.cpp @@ -206,13 +206,13 @@ bool KSharedPixmap::x11Event(XEvent *event) TQPixmap::resize( tw+origin.x(), th+origin.y() ); - XCopyArea(qt_xdisplay(), pixmap, ((KPixmap*)this)->handle(), qt_xget_temp_gc(qt_xscreen(), false), + XCopyArea(qt_xdisplay(), pixmap, (static_cast<KPixmap*>(this))->handle(), qt_xget_temp_gc(qt_xscreen(), false), xa, ya, t1w+origin.x(), t1h+origin.y(), origin.x(), origin.y() ); - XCopyArea(qt_xdisplay(), pixmap, ((KPixmap*)this)->handle(), qt_xget_temp_gc(qt_xscreen(), false), + XCopyArea(qt_xdisplay(), pixmap, (static_cast<KPixmap*>(this))->handle(), qt_xget_temp_gc(qt_xscreen(), false), 0, ya, tw-t1w, t1h, t1w, 0); - XCopyArea(qt_xdisplay(), pixmap, ((KPixmap*)this)->handle(), qt_xget_temp_gc(qt_xscreen(), false), + XCopyArea(qt_xdisplay(), pixmap, (static_cast<KPixmap*>(this))->handle(), qt_xget_temp_gc(qt_xscreen(), false), xa, 0, t1w, th-t1h, 0, t1h); - XCopyArea(qt_xdisplay(), pixmap, ((KPixmap*)this)->handle(), qt_xget_temp_gc(qt_xscreen(), false), + XCopyArea(qt_xdisplay(), pixmap, (static_cast<KPixmap*>(this))->handle(), qt_xget_temp_gc(qt_xscreen(), false), 0, 0, tw-t1w, th-t1h, t1w, t1h); XFree(pixmap_id); diff --git a/kdeui/ksharedpixmap.h b/kdeui/ksharedpixmap.h index 4474cc3f5..d1e3f9026 100644 --- a/kdeui/ksharedpixmap.h +++ b/kdeui/ksharedpixmap.h @@ -58,6 +58,7 @@ class KDEUI_EXPORT KSharedPixmap: public KPixmap { Q_OBJECT + TQ_OBJECT public: diff --git a/kdeui/kspell.cpp b/kdeui/kspell.cpp index 0df7b0842..7285e9c2a 100644 --- a/kdeui/kspell.cpp +++ b/kdeui/kspell.cpp @@ -995,7 +995,7 @@ bool KSpell::check( const TQString &_buffer, bool _usedialog ) // origbuffer since I got errors otherwise if ( !origbuffer.endsWith("\n\n" ) ) { - if (origbuffer.at(origbuffer.length()-1)!='\n') + if (origbuffer.tqat(origbuffer.length()-1)!='\n') { origbuffer+='\n'; origbuffer+='\n'; //shouldn't these be removed at some point? diff --git a/kdeui/ktabbar.cpp b/kdeui/ktabbar.cpp index f5682ae3f..18c5a03d6 100644 --- a/kdeui/ktabbar.cpp +++ b/kdeui/ktabbar.cpp @@ -48,7 +48,7 @@ KTabBar::KTabBar( TQWidget *parent, const char *name ) mActivateDragSwitchTabTimer = new TQTimer( this ); connect( mActivateDragSwitchTabTimer, TQT_SIGNAL( timeout() ), TQT_SLOT( activateDragSwitchTab() ) ); - connect(this, TQT_SIGNAL(layoutChanged()), TQT_SLOT(onLayoutChange())); + connect(this, TQT_SIGNAL(tqlayoutChanged()), TQT_SLOT(onLayoutChange())); } KTabBar::~KTabBar() @@ -67,7 +67,7 @@ void KTabBar::setTabEnabled( int id, bool enabled ) if ( !enabled && id == currentTab() && count()>1 ) { TQPtrList<TQTab> *tablist = tabList(); if ( mTabCloseActivatePrevious ) - t = tablist->at( count()-2 ); + t = tablist->tqat( count()-2 ); else { int index = indexOf( id ); index += ( index+1 == count() ) ? -1 : 1; diff --git a/kdeui/ktabwidget.cpp b/kdeui/ktabwidget.cpp index bc28b5d4d..3825d5aa5 100644 --- a/kdeui/ktabwidget.cpp +++ b/kdeui/ktabwidget.cpp @@ -95,7 +95,7 @@ void KTabWidget::insertTab( TQWidget *child, TQTab *tab, int index ) resizeTabs( d->m_tabNames.count()-1 ); } else { - d->m_tabNames.insert( d->m_tabNames.at( index ), tab->text() ); + d->m_tabNames.insert( d->m_tabNames.tqat( index ), tab->text() ); resizeTabs( index ); } } @@ -422,7 +422,7 @@ void KTabWidget::moveTab( int from, int to ) if ( to < 0 || to >= count() ) d->m_tabNames.append( TQString::null ); else - d->m_tabNames.insert( d->m_tabNames.at( to ), TQString::null ); + d->m_tabNames.insert( d->m_tabNames.tqat( to ), TQString::null ); } w = page( to ); @@ -441,7 +441,7 @@ void KTabWidget::removePage( TQWidget * w ) { if ( d->m_automaticResizeTabs ) { int index = indexOf( w ); if ( index != -1 ) - d->m_tabNames.remove( d->m_tabNames.at( index ) ); + d->m_tabNames.remove( d->m_tabNames.tqat( index ) ); } TQTabWidget::removePage( w ); if ( d->m_automaticResizeTabs ) diff --git a/kdeui/ktextedit.cpp b/kdeui/ktextedit.cpp index fda46df76..73bbf3c5f 100644 --- a/kdeui/ktextedit.cpp +++ b/kdeui/ktextedit.cpp @@ -172,7 +172,7 @@ void KTextEdit::keyPressEvent( TQKeyEvent *e ) } else if ( KStdAccel::pasteSelection().contains( key ) ) { - TQString text = TQApplication::clipboard()->text( QClipboard::Selection); + TQString text = TQApplication::tqclipboard()->text( TQClipboard::Selection); if ( !text.isEmpty() ) insert( text ); e->accept(); diff --git a/kdeui/ktoolbar.cpp b/kdeui/ktoolbar.cpp index d6ae372d6..456acc438 100644 --- a/kdeui/ktoolbar.cpp +++ b/kdeui/ktoolbar.cpp @@ -194,7 +194,7 @@ TQSizePolicy KToolBarSeparator::sizePolicy() const KToolBar::KToolBar( TQWidget *parent, const char *name, bool honorStyle, bool readConfig ) : TQToolBar( TQString::tqfromLatin1( name ), - dynamic_cast<TQMainWindow*>(parent), + tqt_dynamic_cast<TQMainWindow*>(parent), parent, false, name ? name : "mainToolBar") { @@ -430,7 +430,7 @@ KAnimWidget *KToolBar::animatedWidget( int id ) Id2WidgetMap::Iterator it = id2widget.tqfind( id ); if ( it == id2widget.end() ) return 0; - KAnimWidget *aw = dynamic_cast<KAnimWidget *>(*it); + KAnimWidget *aw = tqt_dynamic_cast<KAnimWidget *>(*it); if ( aw ) return aw; TQObjectList *l = queryList( "KAnimWidget" ); @@ -440,7 +440,7 @@ KAnimWidget *KToolBar::animatedWidget( int id ) } for ( TQObject *o = l->first(); o; o = l->next() ) { - KAnimWidget *aw = dynamic_cast<KAnimWidget *>(o); + KAnimWidget *aw = tqt_dynamic_cast<KAnimWidget *>(o); if ( aw ) { delete l; @@ -613,7 +613,7 @@ KComboBox * KToolBar::getCombo(int id) Id2WidgetMap::Iterator it = id2widget.tqfind( id ); if ( it == id2widget.end() ) return 0; - return dynamic_cast<KComboBox *>( *it ); + return tqt_dynamic_cast<KComboBox *>( *it ); } @@ -622,7 +622,7 @@ KLineEdit * KToolBar::getLined (int id) Id2WidgetMap::Iterator it = id2widget.tqfind( id ); if ( it == id2widget.end() ) return 0; - return dynamic_cast<KLineEdit *>( *it ); + return tqt_dynamic_cast<KLineEdit *>( *it ); } @@ -631,7 +631,7 @@ KToolBarButton * KToolBar::getButton (int id) Id2WidgetMap::Iterator it = id2widget.tqfind( id ); if ( it == id2widget.end() ) return 0; - return dynamic_cast<KToolBarButton *>( *it ); + return tqt_dynamic_cast<KToolBarButton *>( *it ); } @@ -734,7 +734,7 @@ int KToolBar::itemIndex (int id) int KToolBar::idAt (int index) { - TQWidget *w = widgets.at(index); + TQWidget *w = widgets.tqat(index); return widget2id[w]; } @@ -856,10 +856,11 @@ void KToolBar::setIconText(IconText icontext, bool update) // ugly hack to force a TQMainWindow::triggerLayout( true ) TQMainWindow *mw = mainWindow(); if ( mw ) { - mw->setUpdatesEnabled( false ); - mw->setToolBarsMovable( !mw->toolBarsMovable() ); - mw->setToolBarsMovable( !mw->toolBarsMovable() ); - mw->setUpdatesEnabled( true ); + mw->tqsetUpdatesEnabled( false ); +// mw->setToolBarsMovable( !mw->toolBarsMovable() ); // Old way +// mw->setToolBarsMovable( !mw->toolBarsMovable() ); + mw->setCentralWidget(mw->centralWidget()); // This is a faster hack + mw->tqsetUpdatesEnabled( true ); } } @@ -893,14 +894,14 @@ void KToolBar::setIconSize(int size, bool update) // ugly hack to force a TQMainWindow::triggerLayout( true ) if ( mainWindow() ) { TQMainWindow *mw = mainWindow(); - mw->setUpdatesEnabled( false ); - mw->setToolBarsMovable( !mw->toolBarsMovable() ); - mw->setToolBarsMovable( !mw->toolBarsMovable() ); - mw->setUpdatesEnabled( true ); + mw->tqsetUpdatesEnabled( false ); +// mw->setToolBarsMovable( !mw->toolBarsMovable() ); // Old way +// mw->setToolBarsMovable( !mw->toolBarsMovable() ); + mw->setCentralWidget(mw->centralWidget()); // This is a faster hack + mw->tqsetUpdatesEnabled( true ); } } - int KToolBar::iconSize() const { if ( !d->m_iconSize ) // default value? @@ -946,7 +947,7 @@ void KToolBar::setFlat (bool flag) else mainWindow()->moveDockWindow( this, DockTop ); // And remember to save the new look later - KMainWindow *kmw = dynamic_cast<KMainWindow *>(mainWindow()); + KMainWindow *kmw = tqt_dynamic_cast<KMainWindow *>(mainWindow()); if ( kmw ) kmw->setSettingsDirty(); } @@ -1092,7 +1093,7 @@ void KToolBar::saveSettings(KConfig *config, const TQString &_configGroup) // reappear at the same position the next time. // The whole set of indexes has to be saved. //kdDebug(220) << name() << " writing index " << index << endl; - KMainWindow *kmw = dynamic_cast<KMainWindow *>(mainWindow()); + KMainWindow *kmw = tqt_dynamic_cast<KMainWindow *>(mainWindow()); // don't save if there's only one toolbar // Don't use kmw->toolBarIterator() because you might @@ -1203,7 +1204,7 @@ void KToolBar::mousePressEvent ( TQMouseEvent *m ) else return; // assume this was an action handled elsewhere, no need for setSettingsDirty() } - KMainWindow *kmw = dynamic_cast<KMainWindow *>(mw); + KMainWindow *kmw = tqt_dynamic_cast<KMainWindow *>(mw); if ( kmw ) kmw->setSettingsDirty(); } @@ -1237,17 +1238,17 @@ void KToolBar::rebuildLayout() for ( TQWidget *w = widgets.first(); w; w = widgets.next() ) { if ( w == rightAligned ) continue; - KToolBarSeparator *ktbs = dynamic_cast<KToolBarSeparator *>(w); + KToolBarSeparator *ktbs = tqt_dynamic_cast<KToolBarSeparator *>(w); if ( ktbs && !ktbs->showLine() ) { l->addSpacing( orientation() == Qt::Vertical ? w->tqsizeHint().height() : w->tqsizeHint().width() ); w->hide(); continue; } - if ( dynamic_cast<TQPopupMenu *>(w) ) // w is a QPopupMenu? + if ( tqt_dynamic_cast<TQPopupMenu *>(w) ) // w is a QPopupMenu? continue; l->addWidget( w ); w->show(); - if ((orientation() == Qt::Horizontal) && dynamic_cast<TQLineEdit *>(w)) // w is TQLineEdit ? + if ((orientation() == Qt::Horizontal) && tqt_dynamic_cast<TQLineEdit *>(w)) // w is TQLineEdit ? l->addSpacing(2); // A little bit extra spacing behind it. } if ( rightAligned ) { @@ -1269,14 +1270,14 @@ void KToolBar::rebuildLayout() void KToolBar::childEvent( TQChildEvent *e ) { if ( e->child()->isWidgetType() ) { - TQWidget * w = dynamic_cast<TQWidget *>(e->child()); + TQWidget * w = tqt_dynamic_cast<TQWidget *>(e->child()); if (!w || !(::qstrcmp( "qt_dockwidget_internal", w->name()))) { TQToolBar::childEvent( e ); return; } if ( e->type() == TQEvent::ChildInserted ) { - if ( !dynamic_cast<TQPopupMenu *>(w)) { // e->child() is not a QPopupMenu + if ( !tqt_dynamic_cast<TQPopupMenu *>(w)) { // e->child() is not a QPopupMenu // prevent items that have been explicitly inserted by insert*() from // being inserted again if ( !widget2id.tqcontains( w ) ) @@ -1293,8 +1294,8 @@ void KToolBar::childEvent( TQChildEvent *e ) layoutTimer->start( 50, true ); TQBoxLayout *l = boxLayout(); - // clear the old layout so that we don't get unnecassery layout - // changes till we have rebuild the thing + // clear the old layout so that we don't get unnecessary layout + // changes until we have rebuilt the thing TQLayoutIterator it = l->iterator(); while ( it.current() ) it.deleteCurrent(); @@ -1366,7 +1367,7 @@ TQSize KToolBar::tqsizeHint() const minSize = minSize.expandedTo(TQSize(0, sh.height())); minSize += TQSize(sh.width()+1, 0); - if (dynamic_cast<TQLineEdit *>(w)) // w is a TQLineEdit ? + if (tqt_dynamic_cast<TQLineEdit *>(w)) // w is a TQLineEdit ? minSize += TQSize(2, 0); // A little bit extra spacing behind it. } @@ -1428,7 +1429,7 @@ void KToolBar::show() void KToolBar::resizeEvent( TQResizeEvent *e ) { bool b = isUpdatesEnabled(); - setUpdatesEnabled( false ); + tqsetUpdatesEnabled( false ); TQToolBar::resizeEvent( e ); if (b) { @@ -1443,6 +1444,10 @@ void KToolBar::resizeEvent( TQResizeEvent *e ) slotRepaint(); } } +// else { +// printf("[WARNING] In KToolBar::resizeEvent, but this code block should not be executing. Preventing toolbar lockup. [Code 0045]\n\r"); +// tqsetUpdatesEnabled( true ); +// } } void KToolBar::slotIconChanged(int group) @@ -1473,7 +1478,7 @@ void KToolBar::slotAppearanceChanged() applyAppearanceSettings(KGlobal::config(), TQString::null, true /* lose local settings */ ); // And remember to save the new look later - KMainWindow *kmw = dynamic_cast<KMainWindow *>(mainWindow()); + KMainWindow *kmw = tqt_dynamic_cast<KMainWindow *>(mainWindow()); if ( kmw ) kmw->setSettingsDirty(); } @@ -1727,14 +1732,14 @@ bool KToolBar::event( TQEvent *e ) void KToolBar::slotRepaint() { - setUpdatesEnabled( false ); + tqsetUpdatesEnabled( false ); // Send a resizeEvent to update the "toolbar extension arrow" // (The button you get when your toolbar-items don't fit in // the available space) TQResizeEvent ev(size(), size()); resizeEvent(&ev); TQApplication::sendPostedEvents( this, TQEvent::LayoutHint ); - setUpdatesEnabled( true ); + tqsetUpdatesEnabled( true ); tqrepaint( true ); } @@ -1745,7 +1750,7 @@ void KToolBar::toolBarPosChanged( TQToolBar *tb ) if ( d->oldPos == DockMinimized ) rebuildLayout(); d->oldPos = (TQMainWindow::ToolBarDock)barPos(); - KMainWindow *kmw = dynamic_cast<KMainWindow *>(mainWindow()); + KMainWindow *kmw = tqt_dynamic_cast<KMainWindow *>(mainWindow()); if ( kmw ) kmw->setSettingsDirty(); } @@ -2133,7 +2138,7 @@ void KToolBar::slotContextAboutToShow() // and ToolBarHandler::setupActions() deletes it, so better not keep it around. // So we currently plug/unplug the last two actions of the menu. // Another way would be to keep around the actions and plug them all into a (new each time) popupmenu. - KMainWindow *kmw = dynamic_cast<KMainWindow *>(mainWindow()); + KMainWindow *kmw = tqt_dynamic_cast<KMainWindow *>(mainWindow()); if ( kmw ) { kmw->setupToolbarMenuActions(); // Only allow hiding a toolbar if the action is also plugged somewhere else (e.g. menubar) @@ -2213,7 +2218,7 @@ void KToolBar::slotContextAboutToHide() { // We have to unplug whatever slotContextAboutToShow plugged into the menu. // Unplug the toolbar menu action - KMainWindow *kmw = dynamic_cast<KMainWindow *>(mainWindow()); + KMainWindow *kmw = tqt_dynamic_cast<KMainWindow *>(mainWindow()); if ( kmw && kmw->toolBarMenuAction() ) if ( kmw->toolBarMenuAction()->containerCount() > 1 ) kmw->toolBarMenuAction()->unplug(context); diff --git a/kdeui/ktoolbarbutton.cpp b/kdeui/ktoolbarbutton.cpp index 42f0d9b90..e5dd0c736 100644 --- a/kdeui/ktoolbarbutton.cpp +++ b/kdeui/ktoolbarbutton.cpp @@ -118,7 +118,7 @@ KToolBarButton::KToolBarButton( const TQString& _icon, int _id, TQToolButton::setTextLabel(_txt); d->m_instance = _instance; - d->m_parent = dynamic_cast<KToolBar*>(_parent); + d->m_parent = tqt_dynamic_cast<KToolBar*>(_parent); if (d->m_parent) { connect(d->m_parent, TQT_SIGNAL( modechange() ), this, TQT_SLOT( modeChange() )); @@ -151,7 +151,7 @@ KToolBarButton::KToolBarButton( const TQPixmap& pixmap, int _id, d->m_id = _id; TQToolButton::setTextLabel(txt); - d->m_parent = dynamic_cast<KToolBar*>(_parent); + d->m_parent = tqt_dynamic_cast<KToolBar*>(_parent); if (d->m_parent) { connect(d->m_parent, TQT_SIGNAL( modechange() ), this, TQT_SLOT( modeChange() )); @@ -405,7 +405,7 @@ void KToolBarButton::enterEvent(TQEvent *) bool KToolBarButton::eventFilter(TQObject *o, TQEvent *ev) { - if ((KToolBarButton *)o == this) + if (TQT_BASE_OBJECT(o) == TQT_BASE_OBJECT(this)) { // Popup the menu when the left mousebutton is pressed and the mouse diff --git a/kdeui/ktoolbarhandler.cpp b/kdeui/ktoolbarhandler.cpp index f1bce69c6..45c1962db 100644 --- a/kdeui/ktoolbarhandler.cpp +++ b/kdeui/ktoolbarhandler.cpp @@ -51,7 +51,7 @@ namespace TQPtrListIterator<TQDockWindow> dockWindowIt( dockWindows ); for ( ; dockWindowIt.current(); ++dockWindowIt ) { - KToolBar *toolBar = dynamic_cast<KToolBar *>( dockWindowIt.current() ); + KToolBar *toolBar = tqt_dynamic_cast<KToolBar *>( dockWindowIt.current() ); if ( !toolBar ) continue; @@ -232,7 +232,7 @@ void ToolBarHandler::connectToActionContainer( KAction *action ) void ToolBarHandler::connectToActionContainer( TQWidget *container ) { - TQPopupMenu *popupMenu = dynamic_cast<TQPopupMenu *>( container ); + TQPopupMenu *popupMenu = tqt_dynamic_cast<TQPopupMenu *>( container ); if ( !popupMenu ) return; diff --git a/kdeui/kwordwrap.cpp b/kdeui/kwordwrap.cpp index 0bdcf52dd..b7eeaff7c 100644 --- a/kdeui/kwordwrap.cpp +++ b/kdeui/kwordwrap.cpp @@ -201,7 +201,7 @@ void KWordWrap::drawFadeoutText(TQPainter *p, int x, int y, int maxW, int n = TQMIN( tl, 3); for (int i = 0; i < n; i++) { p->setPen( mixColors( 0.70 - i * 0.25, textColor, bgColor ) ); - TQString s( t.at( tl - n + i ) ); + TQString s( t.tqat( tl - n + i ) ); p->drawText( x, y, s ); x += fm.width( s ); } diff --git a/kdeui/kxmlguifactory.cpp b/kdeui/kxmlguifactory.cpp index 5778e74d0..169511c49 100644 --- a/kdeui/kxmlguifactory.cpp +++ b/kdeui/kxmlguifactory.cpp @@ -552,7 +552,7 @@ void KXMLGUIFactory::configureAction( KAction *action, const TQDomAttr &attribut int KXMLGUIFactory::configureShortcuts(bool bAllowLetterShortcuts , bool bSaveSettings ) { - KKeyDialog dlg( bAllowLetterShortcuts, dynamic_cast<TQWidget*>(parent()) ); + KKeyDialog dlg( bAllowLetterShortcuts, tqt_dynamic_cast<TQWidget*>(parent()) ); TQPtrListIterator<KXMLGUIClient> it( d->m_clients ); KXMLGUIClient *client; while( (client=it.current()) !=0 ) diff --git a/kdeui/kxmlguifactory_p.cpp b/kdeui/kxmlguifactory_p.cpp index f7955f471..a5ce2b4ef 100644 --- a/kdeui/kxmlguifactory_p.cpp +++ b/kdeui/kxmlguifactory_p.cpp @@ -85,7 +85,7 @@ MergingIndexList::Iterator ContainerNode::findIndex( const TQString &name ) /* * Check if the given container widget is a child of this node and return the node structure - * if fonud. + * if found. */ ContainerNode *ContainerNode::findContainerNode( TQWidget *container ) { @@ -238,7 +238,7 @@ void ContainerNode::plugActionList( BuildState &state, const MergingIndexList::I return; ContainerClient *client = findChildContainerClient( state.guiClient, - TQString::null, + TQString(), mergingIndices.end() ); client->actionLists.insert( k, state.actionList ); @@ -280,7 +280,7 @@ void ContainerNode::unplugActionList( BuildState &state, const MergingIndexList: return; ContainerClient *client = findChildContainerClient( state.guiClient, - TQString::null, + TQString(), mergingIndices.end() ); ActionListMap::Iterator lIt( client->actionLists.tqfind( k ) ); @@ -539,7 +539,7 @@ BuildHelper::BuildHelper( BuildState &state, ContainerNode *node ) } m_state.currentDefaultMergingIt = parentNode->findIndex( defaultMergingName ); - parentNode->calcMergingIndex( TQString::null, m_state.currentClientMergingIt, + parentNode->calcMergingIndex( TQString(), m_state.currentClientMergingIt, m_state, /*ignoreDefaultMergingIndex*/ false ); } @@ -727,7 +727,7 @@ void BuildHelper::processMergeElement( const TQString &tag, const TQString &name // re-calculate the running default and client merging indices. m_state.currentDefaultMergingIt = parentNode->findIndex( defaultMergingName ); - parentNode->calcMergingIndex( TQString::null, m_state.currentClientMergingIt, + parentNode->calcMergingIndex( TQString(), m_state.currentClientMergingIt, m_state, ignoreDefaultMergingIndex ); } @@ -784,7 +784,7 @@ void BuildHelper::processContainerElement( const TQDomElement &e, const TQString // and re-calculate running values, for better performance m_state.currentDefaultMergingIt = parentNode->findIndex( defaultMergingName ); - parentNode->calcMergingIndex( TQString::null, m_state.currentClientMergingIt, + parentNode->calcMergingIndex( TQString(), m_state.currentClientMergingIt, m_state, ignoreDefaultMergingIndex ); } @@ -823,8 +823,8 @@ TQWidget *BuildHelper::createContainer( TQWidget *parent, int index, void BuildState::reset() { - clientName = TQString::null; - actionListName = TQString::null; + clientName = TQString(); + actionListName = TQString(); actionList.clear(); guiClient = 0; clientBuilder = 0; diff --git a/kdeui/qxembed.cpp b/kdeui/qxembed.cpp index fa21446ed..fbf377fac 100644 --- a/kdeui/qxembed.cpp +++ b/kdeui/qxembed.cpp @@ -501,7 +501,7 @@ static int qxembed_x11_event_filter( XEvent* e) // L0683: Set focus on saved focus widget if ( focusCurrent ) { focusCurrent->setFocus(); - if( QXEmbed* emb = dynamic_cast< QXEmbed* >( focusCurrent )) + if( QXEmbed* emb = tqt_dynamic_cast< QXEmbed* >( focusCurrent )) emb->updateEmbeddedFocus( true ); } else if ( !w->tqtopLevelWidget()->tqfocusWidget() ) @@ -545,7 +545,7 @@ static int qxembed_x11_event_filter( XEvent* e) // We first record what the focus widget was // and clear the Qt focus. if ( w->tqtopLevelWidget()->tqfocusWidget() ) { - if( QXEmbed* emb = dynamic_cast< QXEmbed* >( w->tqtopLevelWidget()->tqfocusWidget())) + if( QXEmbed* emb = tqt_dynamic_cast< QXEmbed* >( w->tqtopLevelWidget()->tqfocusWidget())) emb->updateEmbeddedFocus( false ); focusMap->insert( w->tqtopLevelWidget(), new TQGuardedPtr<TQWidget>(w->tqtopLevelWidget()->tqfocusWidget() ) ); diff --git a/kdeui/tests/kdockwidgetdemo.cpp b/kdeui/tests/kdockwidgetdemo.cpp index 2f2c59d94..9b65db594 100644 --- a/kdeui/tests/kdockwidgetdemo.cpp +++ b/kdeui/tests/kdockwidgetdemo.cpp @@ -643,7 +643,7 @@ void Directory::setOpen( bool o ) return; } - listView()->setUpdatesEnabled( false ); + listView()->tqsetUpdatesEnabled( false ); const QFileInfoList * files = thisDir.entryInfoList(); if ( files ){ QFileInfoListIterator it( *files ); @@ -654,7 +654,7 @@ void Directory::setOpen( bool o ) (void)new Directory( this, f->fileName() ); } } - listView()->setUpdatesEnabled( true ); + listView()->tqsetUpdatesEnabled( true ); } TQListViewItem::setOpen( o ); } |