From d8cc8bdfa7fa624a526d5aa1626974e1444cb799 Mon Sep 17 00:00:00 2001 From: tpearson Date: Fri, 27 May 2011 19:21:21 +0000 Subject: TQt4 port k3b This enables compilation under both Qt3 and Qt4 git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/applications/k3b@1233803 283d02a7-25f6-0310-bc7c-ecb5cbfe19da --- src/projects/k3bview.cpp | 42 +++++++++++++++++++++--------------------- 1 file changed, 21 insertions(+), 21 deletions(-) (limited to 'src/projects/k3bview.cpp') diff --git a/src/projects/k3bview.cpp b/src/projects/k3bview.cpp index 0809f59..ccb2656 100644 --- a/src/projects/k3bview.cpp +++ b/src/projects/k3bview.cpp @@ -14,13 +14,13 @@ */ -// include files for Qt -#include -#include -#include -#include -#include -#include +// include files for TQt +#include +#include +#include +#include +#include +#include #include #include @@ -40,11 +40,11 @@ #include -K3bView::K3bView( K3bDoc* pDoc, QWidget *parent, const char* name ) - : QWidget( parent, name ), +K3bView::K3bView( K3bDoc* pDoc, TQWidget *tqparent, const char* name ) + : TQWidget( tqparent, name ), m_doc( pDoc ) { - QGridLayout* grid = new QGridLayout( this ); + TQGridLayout* grid = new TQGridLayout( this ); m_toolBox = new K3bToolBox( this, "toolbox" ); m_fillStatusDisplay = new K3bFillStatusDisplay( m_doc, this ); @@ -57,10 +57,10 @@ K3bView::K3bView( K3bDoc* pDoc, QWidget *parent, const char* name ) grid->setSpacing( 5 ); grid->setMargin( 2 ); - KAction* burnAction = new KAction( i18n("&Burn"), "cdburn", CTRL + Key_B, this, SLOT(slotBurn()), + KAction* burnAction = new KAction( i18n("&Burn"), "cdburn", CTRL + Key_B, TQT_TQOBJECT(this), TQT_SLOT(slotBurn()), actionCollection(), "project_burn"); burnAction->setToolTip( i18n("Open the burn dialog for the current project") ); - KAction* propAction = new KAction( i18n("&Properties"), "edit", CTRL + Key_P, this, SLOT(slotProperties()), + KAction* propAction = new KAction( i18n("&Properties"), "edit", CTRL + Key_P, TQT_TQOBJECT(this), TQT_SLOT(slotProperties()), actionCollection(), "project_properties"); propAction->setToolTip( i18n("Open the properties dialog") ); @@ -85,9 +85,9 @@ K3bView::~K3bView() } -void K3bView::setMainWidget( QWidget* w ) +void K3bView::setMainWidget( TQWidget* w ) { - static_cast(layout())->addMultiCellWidget( w, 1, 1, 0, 1 ); + static_cast(tqlayout())->addMultiCellWidget( w, 1, 1, 0, 1 ); } @@ -95,7 +95,7 @@ void K3bView::slotBurn() { if( m_doc->numOfTracks() == 0 || m_doc->size() == 0 ) { KMessageBox::information( this, i18n("Please add files to your project first."), - i18n("No Data to Burn"), QString::null, false ); + i18n("No Data to Burn"), TQString(), false ); } else { K3bProjectBurnDialog* dlg = newBurnDialog( this ); @@ -131,16 +131,16 @@ void K3bView::slotProperties() void K3bView::addPluginButtons( int projectType ) { - QPtrList pl = k3bcore->pluginManager()->plugins( "ProjectPlugin" ); - for( QPtrListIterator it( pl ); *it; ++it ) { + TQPtrList pl = k3bcore->pluginManager()->plugins( "ProjectPlugin" ); + for( TQPtrListIterator it( pl ); *it; ++it ) { K3bProjectPlugin* pp = dynamic_cast( *it ); if( pp && (pp->type() & projectType) ) { - QToolButton* button = toolBox()->addButton( pp->text(), + TQToolButton* button = toolBox()->addButton( pp->text(), pp->icon(), pp->toolTip(), pp->whatsThis(), - this, - SLOT(slotPluginButtonClicked()) ); + TQT_TQOBJECT(this), + TQT_SLOT(slotPluginButtonClicked()) ); m_plugins.insert( static_cast(button), pp ); } } @@ -149,7 +149,7 @@ void K3bView::addPluginButtons( int projectType ) void K3bView::slotPluginButtonClicked() { - QObject* o = const_cast(sender()); + TQObject* o = TQT_TQOBJECT(const_cast(sender())); if( K3bProjectPlugin* p = m_plugins[static_cast(o)] ) { if( p->hasGUI() ) { K3bProjectPluginDialog dlg( p, doc(), this ); -- cgit v1.2.3