diff options
author | Slávek Banko <[email protected]> | 2013-07-31 17:02:11 +0200 |
---|---|---|
committer | Slávek Banko <[email protected]> | 2013-07-31 17:02:11 +0200 |
commit | 5f9410ae910e73f8966318d1e1b9be03a5651118 (patch) | |
tree | d46a2a2135dbed62dc978bed61ede6376263463b /krecipes/src/widgets/kwidgetlistbox.cpp | |
parent | 40d6261f7d30d372f6a0c9ffdd9fe1cd5b1d1002 (diff) | |
download | krecipes-5f9410ae910e73f8966318d1e1b9be03a5651118.tar.gz krecipes-5f9410ae910e73f8966318d1e1b9be03a5651118.zip |
Initial TQt conversion
Diffstat (limited to 'krecipes/src/widgets/kwidgetlistbox.cpp')
-rw-r--r-- | krecipes/src/widgets/kwidgetlistbox.cpp | 32 |
1 files changed, 16 insertions, 16 deletions
diff --git a/krecipes/src/widgets/kwidgetlistbox.cpp b/krecipes/src/widgets/kwidgetlistbox.cpp index 6a6be93..4cdf4ab 100644 --- a/krecipes/src/widgets/kwidgetlistbox.cpp +++ b/krecipes/src/widgets/kwidgetlistbox.cpp @@ -24,8 +24,8 @@ #include <kdebug.h> #include <kglobalsettings.h> -KWidgetListbox::KWidgetListbox(QWidget *parent, const char *name) - : QTable(parent, name) +KWidgetListbox::KWidgetListbox(TQWidget *parent, const char *name) + : TQTable(parent, name) { setNumRows(0); setNumCols(1); @@ -34,12 +34,12 @@ KWidgetListbox::KWidgetListbox(QWidget *parent, const char *name) setTopMargin(0); horizontalHeader()->hide(); verticalHeader()->hide(); - setSelectionMode(QTable::NoSelection); - setFocusStyle(QTable::FollowStyle); + setSelectionMode(TQTable::NoSelection); + setFocusStyle(TQTable::FollowStyle); connect(this, SIGNAL(currentChanged(int, int)), this, SLOT(selectionChanged(int, int))); - setHScrollBarMode(QScrollView::AlwaysOff); - setVScrollBarMode(QScrollView::Auto); + setHScrollBarMode(TQScrollView::AlwaysOff); + setVScrollBarMode(TQScrollView::Auto); } KWidgetListbox::~KWidgetListbox() @@ -54,7 +54,7 @@ void KWidgetListbox::clear() setNumRows(0); } -int KWidgetListbox::insertItem(QWidget* item, int index) +int KWidgetListbox::insertItem(TQWidget* item, int index) { int row = index; @@ -78,7 +78,7 @@ int KWidgetListbox::insertItem(QWidget* item, int index) return row; } -void KWidgetListbox::setSelected(QWidget* item) +void KWidgetListbox::setSelected(TQWidget* item) { setSelected(index(item)); } @@ -90,7 +90,7 @@ void KWidgetListbox::selectionChanged(int row, int col) emit selected(row); } -void KWidgetListbox::removeItem(QWidget* item) +void KWidgetListbox::removeItem(TQWidget* item) { removeItem(index(item)); } @@ -111,17 +111,17 @@ int KWidgetListbox::selected() const return currentRow(); } -QWidget* KWidgetListbox::selectedItem() const +TQWidget* KWidgetListbox::selectedItem() const { return item(selected()); } -QWidget* KWidgetListbox::item(int index) const +TQWidget* KWidgetListbox::item(int index) const { return cellWidget(index, 0); } -int KWidgetListbox::index(QWidget* itm) const +int KWidgetListbox::index(TQWidget* itm) const { for(int i = 0; i < numRows(); ++i) if(item(i) == itm) @@ -157,7 +157,7 @@ void KWidgetListbox::updateColors() void KWidgetListbox::setItemColors(int index, bool even) { - QWidget* itm = item(index); + TQWidget* itm = item(index); if ( !itm){ kdDebug()<<"no widget at index "<<index<<endl; return; } /* if(index == selected()) @@ -195,14 +195,14 @@ void KWidgetListbox::showItems(show_callback func, void* data) updateColors(); } -void KWidgetListbox::showEvent(QShowEvent*) +void KWidgetListbox::showEvent(TQShowEvent*) { //kdDebug() << k_funcinfo << endl; repaintContents(false); } -void KWidgetListbox::paintCell(QPainter*, int, int, const QRect&, - bool, const QColorGroup&) +void KWidgetListbox::paintCell(TQPainter*, int, int, const TQRect&, + bool, const TQColorGroup&) { //kdDebug() << k_funcinfo << endl; } |