summaryrefslogtreecommitdiffstats
path: root/lib/koproperty/widget.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'lib/koproperty/widget.cpp')
-rw-r--r--lib/koproperty/widget.cpp36
1 files changed, 18 insertions, 18 deletions
diff --git a/lib/koproperty/widget.cpp b/lib/koproperty/widget.cpp
index 2584477e..1efeb5c0 100644
--- a/lib/koproperty/widget.cpp
+++ b/lib/koproperty/widget.cpp
@@ -23,8 +23,8 @@
#include "editoritem.h"
#include "editor.h"
-#include <qpainter.h>
-#include <qvariant.h>
+#include <tqpainter.h>
+#include <tqvariant.h>
#include <klistview.h>
#include <kdebug.h>
@@ -47,7 +47,7 @@ class WidgetPrivate
~WidgetPrivate() {}
Property *property;
- QWidget *editor;
+ TQWidget *editor;
bool leaveTheSpaceForRevertButton : 1;
bool hasBorders : 1;
bool readOnly : 1;
@@ -55,8 +55,8 @@ class WidgetPrivate
};
}
-Widget::Widget(Property *property, QWidget *parent, const char *name)
- : QWidget(parent, name)
+Widget::Widget(Property *property, TQWidget *tqparent, const char *name)
+ : TQWidget(tqparent, name)
{
d = new WidgetPrivate();
d->property = property;
@@ -85,16 +85,16 @@ Widget::setProperty(Property *property)
}
void
-Widget::drawViewer(QPainter *p, const QColorGroup &, const QRect &r, const QVariant &value)
+Widget::drawViewer(TQPainter *p, const TQColorGroup &, const TQRect &r, const TQVariant &value)
{
p->eraseRect(r);
- QRect rect(r);
+ TQRect rect(r);
rect.setLeft(rect.left()+KPROPEDITOR_ITEM_MARGIN);
// if (d->hasBorders)
// rect.setTop(rect.top()+1); //+1 to have the same vertical position as editor
// else
// rect.setHeight(rect.height()-1); //don't place over listviews's border
- p->drawText(rect, Qt::AlignLeft | Qt::AlignVCenter | Qt::SingleLine, value.toString());
+ p->drawText(rect, TQt::AlignLeft | TQt::AlignVCenter | TQt::SingleLine, value.toString());
}
void
@@ -105,11 +105,11 @@ Widget::undo()
}
bool
-Widget::eventFilter(QObject*, QEvent* e)
+Widget::eventFilter(TQObject*, TQEvent* e)
{
- if(e->type() == QEvent::KeyPress)
+ if(e->type() == TQEvent::KeyPress)
{
- QKeyEvent* ev = static_cast<QKeyEvent*>(e);
+ TQKeyEvent* ev = TQT_TQKEYEVENT(e);
if(ev->key() == Key_Escape)
{
emit rejectInput(this);
@@ -122,7 +122,7 @@ Widget::eventFilter(QObject*, QEvent* e)
return true;
}
else {
- Editor *list = static_cast<KoProperty::Editor*>(parentWidget()->parentWidget());
+ Editor *list = static_cast<KoProperty::Editor*>(tqparentWidget()->tqparentWidget());
if (!list)
return false; //for sanity
return list->handleKeyPress(ev);
@@ -149,10 +149,10 @@ Widget::eventFilter(QObject*, QEvent* e)
}
void
-Widget::setFocusWidget(QWidget*focusProxy)
+Widget::setFocusWidget(TQWidget*focusProxy)
{
if (focusProxy) {
- if (focusProxy->focusPolicy() != NoFocus)
+ if (focusProxy->focusPolicy() != TQ_NoFocus)
setFocusProxy(focusProxy);
focusProxy->installEventFilter(this);
}
@@ -187,19 +187,19 @@ Widget::hasBorders() const
}
void
-Widget::setEditor(QWidget* editor)
+Widget::setEditor(TQWidget* editor)
{
d->editor = editor;
if (!d->editor)
return;
- d->editor->setSizePolicy(QSizePolicy::Fixed, QSizePolicy::Fixed);
+ d->editor->tqsetSizePolicy(TQSizePolicy::Fixed, TQSizePolicy::Fixed);
d->editor->move(0,0);
}
void
-Widget::resizeEvent(QResizeEvent *e)
+Widget::resizeEvent(TQResizeEvent *e)
{
- QWidget::resizeEvent(e);
+ TQWidget::resizeEvent(e);
if (d->editor)
d->editor->resize(size());
}