diff options
author | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2011-05-26 21:04:57 +0000 |
---|---|---|
committer | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2011-05-26 21:04:57 +0000 |
commit | bf7f88413be3831a9372d323d02fc0335b9f9188 (patch) | |
tree | 516fdef9206245b40a14f99b4e3d9ef9289196e0 /src/app/vtabwidget.cpp | |
parent | e238aa77b1fb3c2f55aef2ef2c91ce52166d2cc8 (diff) | |
download | gwenview-bf7f88413be3831a9372d323d02fc0335b9f9188.tar.gz gwenview-bf7f88413be3831a9372d323d02fc0335b9f9188.zip |
TQt4 port Gwenview
This enables compilation under both Qt3 and Qt4
git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/applications/gwenview@1233720 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'src/app/vtabwidget.cpp')
-rw-r--r-- | src/app/vtabwidget.cpp | 30 |
1 files changed, 15 insertions, 15 deletions
diff --git a/src/app/vtabwidget.cpp b/src/app/vtabwidget.cpp index a05772c..24918f8 100644 --- a/src/app/vtabwidget.cpp +++ b/src/app/vtabwidget.cpp @@ -1,5 +1,5 @@ // vim: set tabstop=4 shiftwidth=4 noexpandtab: -// kate: indent-mode csands; indent-width 4; replace-tabs-save off; replace-tabs off; replace-trailing-space-save off; space-indent off; tabs-indents on; tab-width 4; +// kate: indent-mode csands; indent-width 4; tqreplace-tabs-save off; tqreplace-tabs off; tqreplace-trailing-space-save off; space-indent off; tabs-indents on; tab-width 4; /* Gwenview - A simple image viewer for KDE Copyright 2005 Aurelien Gateau @@ -22,8 +22,8 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. #include "vtabwidget.moc" -// Qt -#include <qwidgetstack.h> +// TQt +#include <tqwidgetstack.h> // KDE #include <kmultitabbar.h> @@ -33,23 +33,23 @@ namespace Gwenview { struct VTabWidget::Private { KMultiTabBar* mTabBar; - QWidgetStack* mStack; + TQWidgetStack* mStack; bool mEmpty; }; -VTabWidget::VTabWidget(QWidget* parent) -: QWidget(parent) +VTabWidget::VTabWidget(TQWidget* tqparent) +: TQWidget(tqparent) { d=new Private; d->mEmpty=true; d->mTabBar=new KMultiTabBar(KMultiTabBar::Vertical, this); d->mTabBar->setPosition(KMultiTabBar::Left); d->mTabBar->setStyle(KMultiTabBar::KDEV3ICON); - d->mStack=new QWidgetStack(this); - QHBoxLayout* layout=new QHBoxLayout(this); - layout->add(d->mTabBar); - layout->add(d->mStack); + d->mStack=new TQWidgetStack(this); + TQHBoxLayout* tqlayout=new TQHBoxLayout(this); + tqlayout->add(d->mTabBar); + tqlayout->add(d->mStack); } @@ -58,11 +58,11 @@ VTabWidget::~VTabWidget() { } -void VTabWidget::addTab(QWidget* child, const QPixmap& pix, const QString& label) { +void VTabWidget::addTab(TQWidget* child, const TQPixmap& pix, const TQString& label) { int id=d->mStack->addWidget(child); d->mTabBar->appendTab(pix, id, label); - connect(d->mTabBar->tab(id), SIGNAL(clicked(int)), - this, SLOT(slotClicked(int)) ); + connect(d->mTabBar->tab(id), TQT_SIGNAL(clicked(int)), + this, TQT_SLOT(slotClicked(int)) ); if (d->mEmpty) { d->mTabBar->tab(id)->setOn(true); @@ -73,8 +73,8 @@ void VTabWidget::addTab(QWidget* child, const QPixmap& pix, const QString& label void VTabWidget::slotClicked(int id) { d->mStack->raiseWidget(id); - QPtrList<KMultiTabBarTab>* tabs=d->mTabBar->tabs(); - QPtrListIterator<KMultiTabBarTab> it(*tabs); + TQPtrList<KMultiTabBarTab>* tabs=d->mTabBar->tabs(); + TQPtrListIterator<KMultiTabBarTab> it(*tabs); for (; it.current(); ++it) { KMultiTabBarTab* tab=it.current(); tab->setOn(tab->id()==id); |