From 2d8372c3cbc9ce26fb988b6e05f6fd7aac797467 Mon Sep 17 00:00:00 2001 From: mlaurent Date: Thu, 27 Oct 2005 14:57:41 +0000 Subject: [PATCH] Other fix git-svn-id: svn://anonsvn.kde.org/home/kde/trunk/KDE/kdeartwork@474886 283d02a7-25f6-0310-bc7c-ecb5cbfe19da --- kwin-styles/kstep/nextclient.cpp | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/kwin-styles/kstep/nextclient.cpp b/kwin-styles/kstep/nextclient.cpp index 82b77f3c..761d988d 100644 --- a/kwin-styles/kstep/nextclient.cpp +++ b/kwin-styles/kstep/nextclient.cpp @@ -337,14 +337,14 @@ NextButton::NextButton(NextClient *parent, const char *name, { realizeButtons = realizeBtns; - setBackgroundMode( NoBackground ); + setBackgroundMode( Qt::NoBackground ); resize(titleHeight, titleHeight); setFixedSize(titleHeight, titleHeight); if(bitmap) setBitmap(bitmap, bw, bh); - QToolTip::add(this, tip); + this->setToolTip( tip); } void NextButton::reset() @@ -487,7 +487,7 @@ void NextClient::addButtons(QBoxLayout* titleLayout, const QString& spec) if (isMaximizable()) { button[MAXIMIZE_IDX] = new NextButton(this, "maximize", maximize_bits, 10, 10, - i18n("Maximize"), LeftButton|MidButton|RightButton); + i18n("Maximize"), Qt::LeftButton|Qt::MidButton|Qt::RightButton); titleLayout->addWidget( button[MAXIMIZE_IDX] ); connect( button[MAXIMIZE_IDX], SIGNAL(clicked()), this, SLOT(maximizeButtonClicked()) ); @@ -517,7 +517,7 @@ void NextClient::addButtons(QBoxLayout* titleLayout, const QString& spec) case 'M': button[MENU_IDX] = - new NextButton(this, "menu", NULL, 10, 10, i18n("Menu"), LeftButton|RightButton); + new NextButton(this, "menu", NULL, 10, 10, i18n("Menu"), Qt::LeftButton|Qt::RightButton); titleLayout->addWidget( button[MENU_IDX] ); // NOTE DIFFERENCE: capture pressed(), not clicked() connect( button[MENU_IDX], SIGNAL(pressed()), @@ -718,7 +718,7 @@ void NextClient::paintEvent( QPaintEvent* ) p.setPen(options()->color(KDecoration::ColorFont, isActive())); p.setFont(options()->font(isActive())); - p.drawText( t, AlignCenter | AlignVCenter, caption() ); + p.drawText( t, Qt::AlignCenter | Qt::AlignVCenter, caption() ); // Draw resize handle if (mustDrawHandle()) { @@ -750,7 +750,7 @@ void NextClient::paintEvent( QPaintEvent* ) void NextClient::mouseDoubleClickEvent( QMouseEvent * e ) { - if (e->button() == LeftButton && titlebar->geometry().contains( e->pos() ) ) + if (e->button() == Qt::LeftButton && titlebar->geometry().contains( e->pos() ) ) titlebarDblClickOperation(); } @@ -765,7 +765,7 @@ void NextClient::desktopChange() if (NextButton * b = button[STICKY_IDX]) { b->setBitmap( on ? unsticky_bits : sticky_bits, 10, 10); QToolTip::remove(b); - QToolTip::add(b, on ? i18n("Not on all desktops") : i18n("On all desktops")); + b->setToolTip( on ? i18n("Not on all desktops") : i18n("On all desktops")); } } @@ -775,7 +775,7 @@ void NextClient::maximizeChange() bool m = maximizeMode() == MaximizeFull; //button[MAXIMIZE_IDX]->setBitmap(m ? minmax_bits : maximize_bits); QToolTip::remove(button[MAXIMIZE_IDX]); - QToolTip::add(button[MAXIMIZE_IDX], + button[MAXIMIZE_IDX]->setToolTip( m ? i18n("Restore") : i18n("Maximize")); } //spacer->changeSize(10, mustDrawHandle() ? handleSize : 1, @@ -831,7 +831,7 @@ void NextClient::shadeChange() if (NextButton *b = button[SHADE_IDX]) { b->setBitmap(isSetShade() ? unshade_bits : shade_bits, 10, 10); QToolTip::remove(b); - QToolTip::add(b, isSetShade() ? i18n("Unshade") : i18n("Shade")); + b->setToolTip( isSetShade() ? i18n("Unshade") : i18n("Shade")); } } @@ -840,7 +840,7 @@ void NextClient::keepAboveChange(bool above) if (NextButton *b = button[ABOVE_IDX]) { b->setBitmap(above ? from_above_bits : keep_above_bits, 10, 10); QToolTip::remove(b); - QToolTip::add(b, above ? + b->setToolTip( above ? i18n("Do not keep above others") : i18n("Keep above others")); b->repaint(false); } @@ -851,7 +851,7 @@ void NextClient::keepBelowChange(bool below) if (NextButton *b = button[BELOW_IDX]) { b->setBitmap(below ? from_below_bits : keep_below_bits, 10, 10); QToolTip::remove(b); - QToolTip::add(b, below ? + b->setToolTip( below ? i18n("Do not keep below others") : i18n("Keep below others")); b->repaint(false); } -- 2.11.4.GIT