diff options
author | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2011-06-22 00:30:31 +0000 |
---|---|---|
committer | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2011-06-22 00:30:31 +0000 |
commit | 69cac65817d949cda2672ec4f0aa73d5e66a0ba1 (patch) | |
tree | 073fde0496ea90eb5bf5cffe66a8da43a9f55fbc /ksirc/mditoplevel.cpp | |
parent | 3467e6464beac3a162839bf7078e22e3a74d73e7 (diff) | |
download | tdenetwork-69cac65817d949cda2672ec4f0aa73d5e66a0ba1.tar.gz tdenetwork-69cac65817d949cda2672ec4f0aa73d5e66a0ba1.zip |
TQt4 port kdenetwork
This enables compilation under both Qt3 and Qt4
git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdenetwork@1237912 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'ksirc/mditoplevel.cpp')
-rw-r--r-- | ksirc/mditoplevel.cpp | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/ksirc/mditoplevel.cpp b/ksirc/mditoplevel.cpp index 73c464c3..122a934a 100644 --- a/ksirc/mditoplevel.cpp +++ b/ksirc/mditoplevel.cpp @@ -19,7 +19,7 @@ void KSTabWidget::mousePressEvent(TQMouseEvent *e) { - if(e->button() == RightButton){ + if(e->button() == Qt::RightButton){ TQPoint p = tabBar()->mapFromParent(e->pos()); TQTab *tab = tabBar()->selectTab(p); if(tab){ @@ -29,8 +29,8 @@ void KSTabWidget::mousePressEvent(TQMouseEvent *e) } } -MDITopLevel::MDITopLevel(TQWidget *parent, const char *name) - : KMainWindow(parent, name) +MDITopLevel::MDITopLevel(TQWidget *tqparent, const char *name) + : KMainWindow(tqparent, name) { m_closing = false; @@ -76,7 +76,7 @@ MDITopLevel::~MDITopLevel() void MDITopLevel::addWidget( TQWidget *widget, bool show ) { - if ( m_tabWidgets.containsRef( widget ) ) + if ( m_tabWidgets.tqcontainsRef( widget ) ) return; kdDebug(5008) << "In add widget" << endl; @@ -121,7 +121,7 @@ void MDITopLevel::hideWidget( TQWidget *widget ) void MDITopLevel::showWidget( TQWidget *widget ) { if(m_tab->indexOf(widget) == -1){ - int space = widget->caption().find(" "); + int space = widget->caption().tqfind(" "); TQString cap = space < 1 ? widget->caption():widget->caption().left(space); m_tab->addTab( widget, cap); m_tab->showPage( widget ); @@ -180,7 +180,7 @@ bool MDITopLevel::eventFilter( TQObject *obj, TQEvent *ev ) TQWidget *widget = dynamic_cast<TQWidget *>( obj ); - if ( !widget || !m_tabWidgets.containsRef( widget ) ) + if ( !widget || !m_tabWidgets.tqcontainsRef( widget ) ) return false; if ( m_tab->currentPage() == widget ) @@ -207,14 +207,14 @@ void MDITopLevel::slotMarkPageDirty( bool addressed ) { // This is called when a line appeared in this channel. // addressed is true if it was addressed to the user - KMainWindow *window = dynamic_cast<KMainWindow *>( const_cast<TQObject *>( sender() ) ); + KMainWindow *window = dynamic_cast<KMainWindow *>( TQT_TQWIDGET(const_cast<TQT_BASE_OBJECT_NAME *>( sender() )) ); if ( !window ) return; if ( window != m_tab->currentPage() ) { - if ( m_addressed.containsRef( window ) ) + if ( m_addressed.tqcontainsRef( window ) ) addressed = true; else if ( addressed ) { m_addressed.append( window ); @@ -225,13 +225,13 @@ void MDITopLevel::slotMarkPageDirty( bool addressed ) void MDITopLevel::slotChangeChannelName( const TQString &, const TQString &channelName ) { - KMainWindow *window = dynamic_cast<KMainWindow *>( const_cast<TQObject *>( sender() ) ); + KMainWindow *window = dynamic_cast<KMainWindow *>( TQT_TQWIDGET(const_cast<TQT_BASE_OBJECT_NAME *>( sender() )) ); if ( !window ) return; TQString esc = channelName; - esc.replace("&", "&&"); + esc.tqreplace("&", "&&"); m_tab->setTabLabel( window, esc ); removeFromAddressedList( window ); } |