summaryrefslogtreecommitdiffstats
path: root/twin/lib/kcommondecoration.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'twin/lib/kcommondecoration.cpp')
-rw-r--r--twin/lib/kcommondecoration.cpp56
1 files changed, 28 insertions, 28 deletions
diff --git a/twin/lib/kcommondecoration.cpp b/twin/lib/kcommondecoration.cpp
index 54ee415e2..d8a22458b 100644
--- a/twin/lib/kcommondecoration.cpp
+++ b/twin/lib/kcommondecoration.cpp
@@ -122,8 +122,8 @@ void KCommonDecoration::init()
resetLayout();
- connect(this, TQT_SIGNAL(keepAboveChanged(bool) ), TQT_SLOT(keepAboveChange(bool) ) );
- connect(this, TQT_SIGNAL(keepBelowChanged(bool) ), TQT_SLOT(keepBelowChange(bool) ) );
+ connect(this, TQ_SIGNAL(keepAboveChanged(bool) ), TQ_SLOT(keepAboveChange(bool) ) );
+ connect(this, TQ_SIGNAL(keepBelowChanged(bool) ), TQ_SLOT(keepBelowChange(bool) ) );
updateCaption();
}
@@ -203,7 +203,7 @@ void KCommonDecoration::updateLayout() const
if (*it) {
if (!(*it)->isHidden() ) {
moveWidget(x,y, *it);
- x += layoutMetric(LM_ButtonWidth, true, ::tqqt_cast<KCommonDecorationButton*>(*it) );
+ x += layoutMetric(LM_ButtonWidth, true, ::tqt_cast<KCommonDecorationButton*>(*it) );
elementLayouted = true;
}
} else {
@@ -226,7 +226,7 @@ void KCommonDecoration::updateLayout() const
if (*it) {
if (!(*it)->isHidden() ) {
moveWidget(x,y, *it);
- x += layoutMetric(LM_ButtonWidth, true, ::tqqt_cast<KCommonDecorationButton*>(*it) );;
+ x += layoutMetric(LM_ButtonWidth, true, ::tqt_cast<KCommonDecorationButton*>(*it) );;
elementLayouted = true;
}
} else {
@@ -349,9 +349,9 @@ void KCommonDecoration::addButtons(ButtonContainer &btnContainer, const TQString
btn = createButton(MenuButton);
if (!btn) break;
btn->setTipText(i18n("Menu") );
- btn->setRealizeButtons(Qt::LeftButton|Qt::RightButton);
- connect(btn, TQT_SIGNAL(pressed()), TQT_SLOT(menuButtonPressed()));
- connect(btn, TQT_SIGNAL(released()), this, TQT_SLOT(menuButtonReleased()));
+ btn->setRealizeButtons(TQt::LeftButton|TQt::RightButton);
+ connect(btn, TQ_SIGNAL(pressed()), TQ_SLOT(menuButtonPressed()));
+ connect(btn, TQ_SIGNAL(released()), this, TQ_SLOT(menuButtonReleased()));
m_button[MenuButton] = btn;
}
@@ -366,7 +366,7 @@ void KCommonDecoration::addButtons(ButtonContainer &btnContainer, const TQString
btn->setTipText(oad?i18n("Not on all desktops"):i18n("On all desktops") );
btn->setToggleButton(true);
btn->setOn( oad );
- connect(btn, TQT_SIGNAL(clicked()), TQT_SLOT(toggleOnAllDesktops()));
+ connect(btn, TQ_SIGNAL(clicked()), TQ_SLOT(toggleOnAllDesktops()));
m_button[OnAllDesktopsButton] = btn;
}
@@ -377,7 +377,7 @@ void KCommonDecoration::addButtons(ButtonContainer &btnContainer, const TQString
btn = createButton(HelpButton);
if (!btn) break;
btn->setTipText(i18n("Help") );
- connect(btn, TQT_SIGNAL(clicked()), TQT_SLOT(showContextHelp()));
+ connect(btn, TQ_SIGNAL(clicked()), TQ_SLOT(showContextHelp()));
m_button[HelpButton] = btn;
}
@@ -387,7 +387,7 @@ void KCommonDecoration::addButtons(ButtonContainer &btnContainer, const TQString
btn = createButton(MinButton);
if (!btn) break;
btn->setTipText(i18n("Minimize") );
- connect(btn, TQT_SIGNAL(clicked()), TQT_SLOT(minimize()));
+ connect(btn, TQ_SIGNAL(clicked()), TQ_SLOT(minimize()));
m_button[MinButton] = btn;
}
@@ -396,12 +396,12 @@ void KCommonDecoration::addButtons(ButtonContainer &btnContainer, const TQString
if ((!m_button[MaxButton]) && isMaximizable()){
btn = createButton(MaxButton);
if (!btn) break;
- btn->setRealizeButtons(Qt::LeftButton|Qt::MidButton|Qt::RightButton);
+ btn->setRealizeButtons(TQt::LeftButton|TQt::MidButton|TQt::RightButton);
const bool max = maximizeMode()==MaximizeFull;
btn->setTipText(max?i18n("Restore"):i18n("Maximize") );
btn->setToggleButton(true);
btn->setOn( max );
- connect(btn, TQT_SIGNAL(clicked()), TQT_SLOT(slotMaximize()));
+ connect(btn, TQ_SIGNAL(clicked()), TQ_SLOT(slotMaximize()));
m_button[MaxButton] = btn;
}
@@ -411,7 +411,7 @@ void KCommonDecoration::addButtons(ButtonContainer &btnContainer, const TQString
btn = createButton(CloseButton);
if (!btn) break;
btn->setTipText(i18n("Close") );
- connect(btn, TQT_SIGNAL(clicked()), TQT_SLOT(closeWindow()));
+ connect(btn, TQ_SIGNAL(clicked()), TQ_SLOT(closeWindow()));
m_button[CloseButton] = btn;
}
@@ -424,7 +424,7 @@ void KCommonDecoration::addButtons(ButtonContainer &btnContainer, const TQString
btn->setTipText(above?i18n("Do not keep above others"):i18n("Keep above others") );
btn->setToggleButton(true);
btn->setOn( above );
- connect(btn, TQT_SIGNAL(clicked()), TQT_SLOT(slotKeepAbove()));
+ connect(btn, TQ_SIGNAL(clicked()), TQ_SLOT(slotKeepAbove()));
m_button[AboveButton] = btn;
}
@@ -437,7 +437,7 @@ void KCommonDecoration::addButtons(ButtonContainer &btnContainer, const TQString
btn->setTipText(below?i18n("Do not keep below others"):i18n("Keep below others") );
btn->setToggleButton(true);
btn->setOn( below );
- connect(btn, TQT_SIGNAL(clicked()), TQT_SLOT(slotKeepBelow()));
+ connect(btn, TQ_SIGNAL(clicked()), TQ_SLOT(slotKeepBelow()));
m_button[BelowButton] = btn;
}
@@ -450,7 +450,7 @@ void KCommonDecoration::addButtons(ButtonContainer &btnContainer, const TQString
btn->setTipText(shaded?i18n("Unshade"):i18n("Shade") );
btn->setToggleButton(true);
btn->setOn( shaded );
- connect(btn, TQT_SIGNAL(clicked()), TQT_SLOT(slotShade()));
+ connect(btn, TQ_SIGNAL(clicked()), TQ_SLOT(slotShade()));
m_button[ShadeButton] = btn;
}
@@ -710,7 +710,7 @@ void KCommonDecoration::resizeWidget(int w, int h, TQWidget *widget) const
void KCommonDecoration::mouseDoubleClickEvent(TQMouseEvent *e)
{
- if( e->button() != Qt::LeftButton )
+ if( e->button() != TQt::LeftButton )
return;
int tb = layoutMetric(LM_TitleEdgeTop)+layoutMetric(LM_TitleHeight)+layoutMetric(LM_TitleEdgeBottom);
@@ -844,24 +844,24 @@ void KCommonDecoration::updateWindowShape()
bool KCommonDecoration::eventFilter( TQObject* o, TQEvent* e )
{
- if( TQT_BASE_OBJECT(o) != TQT_BASE_OBJECT(widget()))
+ if( o != widget())
return false;
switch( e->type())
{
case TQEvent::Resize:
- resizeEvent(TQT_TQRESIZEEVENT(e) );
+ resizeEvent(static_cast<TQResizeEvent*>(e) );
return true;
case TQEvent::Paint:
- paintEvent(TQT_TQPAINTEVENT( e ));
+ paintEvent(static_cast<TQPaintEvent*>( e ));
return true;
case TQEvent::MouseButtonDblClick:
- mouseDoubleClickEvent(TQT_TQMOUSEEVENT( e ));
+ mouseDoubleClickEvent(static_cast<TQMouseEvent*>( e ));
return true;
case TQEvent::MouseButtonPress:
- processMousePressEvent(TQT_TQMOUSEEVENT( e ));
+ processMousePressEvent(static_cast<TQMouseEvent*>( e ));
return true;
case TQEvent::Wheel:
- wheelEvent(TQT_TQWHEELEVENT( e ));
+ wheelEvent(static_cast<TQWheelEvent*>( e ));
return true;
default:
return false;
@@ -881,7 +881,7 @@ bool KCommonDecoration::isToolWindow() const
TQRect KCommonDecoration::titleRect() const
{
int r_x, r_y, r_x2, r_y2;
- TQT_TQRECT_OBJECT(widget()->rect()).coords(&r_x, &r_y, &r_x2, &r_y2);
+ widget()->rect().coords(&r_x, &r_y, &r_x2, &r_y2);
const int titleEdgeLeft = layoutMetric(LM_TitleEdgeLeft);
const int titleEdgeTop = layoutMetric(LM_TitleEdgeTop);
const int titleEdgeRight = layoutMetric(LM_TitleEdgeRight);
@@ -900,8 +900,8 @@ KCommonDecorationButton::KCommonDecorationButton(ButtonType type, KCommonDecorat
: TQButton(parent->widget(), name),
m_decoration(parent),
m_type(type),
- m_realizeButtons(Qt::LeftButton),
- m_lastMouse(Qt::NoButton),
+ m_realizeButtons(TQt::LeftButton),
+ m_lastMouse(TQt::NoButton),
m_isLeft(true)
{
setCursor(ArrowCursor);
@@ -975,7 +975,7 @@ void KCommonDecorationButton::mousePressEvent(TQMouseEvent* e)
m_lastMouse = e->button();
// pass on event after changing button to LeftButton
TQMouseEvent me(e->type(), e->pos(), e->globalPos(),
- (e->button()&m_realizeButtons)?Qt::LeftButton:Qt::NoButton, e->state());
+ (e->button()&m_realizeButtons)?TQt::LeftButton:TQt::NoButton, e->state());
TQButton::mousePressEvent(&me);
}
@@ -985,7 +985,7 @@ void KCommonDecorationButton::mouseReleaseEvent(TQMouseEvent* e)
m_lastMouse = e->button();
// pass on event after changing button to LeftButton
TQMouseEvent me(e->type(), e->pos(), e->globalPos(),
- (e->button()&m_realizeButtons)?Qt::LeftButton:Qt::NoButton, e->state());
+ (e->button()&m_realizeButtons)?TQt::LeftButton:TQt::NoButton, e->state());
TQButton::mouseReleaseEvent(&me);
}