From b09bffed6b43262948018dfb0f11890850ddf7c1 Mon Sep 17 00:00:00 2001 From: tpearson Date: Sat, 18 Jun 2011 20:34:22 +0000 Subject: TQt4 port kdeadmin This enables compilation under both Qt3 and Qt4 git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdeadmin@1237416 283d02a7-25f6-0310-bc7c-ecb5cbfe19da --- kpackage/kplview.cpp | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) (limited to 'kpackage/kplview.cpp') diff --git a/kpackage/kplview.cpp b/kpackage/kplview.cpp index 5b7d76c..cf9014e 100644 --- a/kpackage/kplview.cpp +++ b/kpackage/kplview.cpp @@ -43,8 +43,8 @@ #define MPOS 1 -KpTreeList::KpTreeList( TQWidget *parent ) : -KListView (parent) +KpTreeList::KpTreeList( TQWidget *tqparent ) : +KListView (tqparent) { markPkg = 0; setShowSortIndicator(true); @@ -97,7 +97,7 @@ void KpTreeList::contentsMousePressEvent ( TQMouseEvent * e ) { bool markUpdate = false; - if (e->button() == LeftButton) { + if (e->button() == Qt::LeftButton) { if (inMark(e->x())) { TQPoint vp = contentsToViewport(e->pos()); KpTreeListItem *i = ( KpTreeListItem *)itemAt( vp ); @@ -430,7 +430,7 @@ bool KpTreeList::searchChild(KpTreeListItem *it) TQString s = it->text(0); // kdDebug() << "s='" << s << "'='" << searchStr << "\n"; if ((it->childCount() == 0) && (it->info->display(treeType)) && - (searchSubstr ? s.contains(searchStr,FALSE) : s == searchStr)) { + (searchSubstr ? s.tqcontains(searchStr,FALSE) : s == searchStr)) { searchResult = it; return TRUE; } @@ -458,7 +458,7 @@ KpTreeListItem *KpTreeList::changePack(KpTreeListItem *searchResult, bool push) TQListViewItem *i; i = searchResult; - while ((i = i->parent())) { + while ((i = i->tqparent())) { i->setOpen(TRUE); } if (push) { @@ -510,7 +510,7 @@ void KpTreeList::previous() void KpTreeList::stackRemove(KpTreeListItem *pack) { - int n = stack.find(pack); + int n = stack.tqfind(pack); if (n >= 0) { if (n == 0) { kpkg->disablePrevious(); @@ -571,14 +571,14 @@ void KpTreeList::readTreeConfig() ////////////////////////////////////////////////////////////////////////////// -KpTreeListItem::KpTreeListItem( TQListViewItem *parent, packageInfo* pinfo, +KpTreeListItem::KpTreeListItem( TQListViewItem *tqparent, packageInfo* pinfo, const TQPixmap& thePixmap, TQString label1, TQString label2 , TQString label3 , TQString label4 , TQString label5 , TQString label6 , TQString label7 , TQString label8 -) : TQListViewItem(parent, label1, label2, label3, label4, label5, +) : TQListViewItem(tqparent, label1, label2, label3, label4, label5, label6, label7, label8) { info = pinfo; @@ -588,13 +588,13 @@ KpTreeListItem::KpTreeListItem( TQListViewItem *parent, packageInfo* pinfo, setPixmap(1,info->interface->markUnInst); } -KpTreeListItem::KpTreeListItem( KListView *parent, packageInfo* pinfo, +KpTreeListItem::KpTreeListItem( KListView *tqparent, packageInfo* pinfo, const TQPixmap& thePixmap, TQString label1, TQString label2 , TQString label3 , TQString label4 , TQString label5 , TQString label6 , TQString label7 , TQString label8 -) : TQListViewItem(parent, label1, label2, label3, label4, label5, +) : TQListViewItem(tqparent, label1, label2, label3, label4, label5, label6, label7, label8) { info = pinfo; @@ -650,11 +650,11 @@ int KpTreeListItem::compare( TQListViewItem *i, int col, bool ascending ) const TQString k, j; j = key( col, ascending ); - j = j.replace(' ','0'); + j = j.tqreplace(' ','0'); j = j.rightJustify(6,'0'); k = i->key( col, ascending ); - k = k.replace(' ','0'); + k = k.tqreplace(' ','0'); k = k.rightJustify(6,'0'); // kdDebug() << k <<"=" << j << "\n"; -- cgit v1.2.1