From 7be55ffa061c026e35e2d6a0effe1161ddb0d41f Mon Sep 17 00:00:00 2001 From: tpearson Date: Sat, 31 Jul 2010 19:53:50 +0000 Subject: Trinity Qt initial conversion git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdepim@1157655 283d02a7-25f6-0310-bc7c-ecb5cbfe19da --- ktnef/gui/ktnefview.cpp | 42 +++++++++++++++++++++--------------------- 1 file changed, 21 insertions(+), 21 deletions(-) (limited to 'ktnef/gui/ktnefview.cpp') diff --git a/ktnef/gui/ktnefview.cpp b/ktnef/gui/ktnefview.cpp index abee5a73b..a77098350 100644 --- a/ktnef/gui/ktnefview.cpp +++ b/ktnef/gui/ktnefview.cpp @@ -19,9 +19,9 @@ #include #include "attachpropertydialog.h" -#include -#include -#include +#include +#include +#include #include #include @@ -33,7 +33,7 @@ class Attachment : public QListViewItem { public: - Attachment(QListView *parent, KTNEFAttach *attach); + Attachment(TQListView *parent, KTNEFAttach *attach); ~Attachment(); KTNEFAttach* getAttachment() const { return attach_; } @@ -42,14 +42,14 @@ private: KTNEFAttach *attach_; }; -Attachment::Attachment(QListView *parent, KTNEFAttach *attach) - : QListViewItem(parent, attach->name()), attach_(attach) +Attachment::Attachment(TQListView *parent, KTNEFAttach *attach) + : TQListViewItem(parent, attach->name()), attach_(attach) { - setText(2, QString::number( attach_->size() )); + setText(2, TQString::number( attach_->size() )); if (!attach_->fileName().isEmpty()) setText(0, attach_->fileName()); KMimeType::Ptr mimeType = KMimeType::mimeType( attach_->mimeTag() ); setText(1, mimeType->comment()); - QPixmap pix = loadRenderingPixmap( attach, parent->colorGroup().base() ); + TQPixmap pix = loadRenderingPixmap( attach, parent->colorGroup().base() ); if ( !pix.isNull() ) setPixmap( 0, pix ); else @@ -63,44 +63,44 @@ Attachment::~Attachment() //------------------------------------------------------------------------------------------------------ -KTNEFView::KTNEFView(QWidget *parent, const char *name) +KTNEFView::KTNEFView(TQWidget *parent, const char *name) : KListView(parent,name) { attachments_.setAutoDelete(false); addColumn(i18n("File Name")); addColumn(i18n("File Type")); addColumn(i18n("Size")); - setFrameStyle(QFrame::WinPanel|QFrame::Sunken); + setFrameStyle(TQFrame::WinPanel|TQFrame::Sunken); setLineWidth(1); - setSelectionMode(QListView::Extended); - setHScrollBarMode(QScrollView::AlwaysOff); - setVScrollBarMode(QScrollView::AlwaysOn); - QTimer::singleShot( 0, this, SLOT(adjustColumnWidth()) ); + setSelectionMode(TQListView::Extended); + setHScrollBarMode(TQScrollView::AlwaysOff); + setVScrollBarMode(TQScrollView::AlwaysOn); + TQTimer::singleShot( 0, this, TQT_SLOT(adjustColumnWidth()) ); } KTNEFView::~KTNEFView() { } -void KTNEFView::setAttachments(QPtrList *list) +void KTNEFView::setAttachments(TQPtrList *list) { clear(); if (list) { - QPtrListIterator it(*list); + TQPtrListIterator it(*list); for (;it.current();++it) new Attachment(this, it.current()); } } -void KTNEFView::resizeEvent(QResizeEvent *e) +void KTNEFView::resizeEvent(TQResizeEvent *e) { adjustColumnWidth(); resizeContents(visibleWidth(),visibleHeight()); - if (e) QListView::resizeEvent(e); + if (e) TQListView::resizeEvent(e); } -QPtrList* KTNEFView::getSelection() +TQPtrList* KTNEFView::getSelection() { attachments_.clear(); QListViewItem *item = firstChild(); @@ -114,8 +114,8 @@ QPtrList* KTNEFView::getSelection() void KTNEFView::startDrag() { - QListViewItemIterator it( this, QListViewItemIterator::Selected ); - QValueList list; + TQListViewItemIterator it( this, TQListViewItemIterator::Selected ); + TQValueList list; while ( it.current() ) { list << static_cast( it.current() )->getAttachment(); -- cgit v1.2.1