From: Pino Toscano Date: Tue, 20 Sep 2005 21:18:26 +0000 (+0000) Subject: * port to the new QToolTip API. X-Git-Tag: v3.80.2~307 X-Git-Url: https://git.rmz.fi/?a=commitdiff_plain;h=4cc2b20893265b89b9cbc824cc3552e2ee74c336;p=libqmvoc.git * port to the new QToolTip API. * we don't need to i18n() console warnings svn path=/trunk/KDE/kdeedu/libkdeedu/; revision=462370 --- diff --git a/extdate/extdatepicker.cpp b/extdate/extdatepicker.cpp index 1cd8d27..c6d303b 100644 --- a/extdate/extdatepicker.cpp +++ b/extdate/extdatepicker.cpp @@ -24,7 +24,6 @@ #include #include #include -#include #include //Added by qt3to4: #include @@ -158,14 +157,14 @@ void ExtDatePicker::init( const ExtDate &dt ) d->todayButton = new QToolButton(this); d->todayButton->setIconSet(SmallIconSet("today")); - QToolTip::add(yearForward, i18n("Next year")); - QToolTip::add(yearBackward, i18n("Previous year")); - QToolTip::add(monthForward, i18n("Next month")); - QToolTip::add(monthBackward, i18n("Previous month")); - QToolTip::add(d->selectWeek, i18n("Select a week")); - QToolTip::add(selectMonth, i18n("Select a month")); - QToolTip::add(selectYear, i18n("Select a year")); - QToolTip::add(d->todayButton, i18n("Select the current day")); + yearForward->setToolTip(i18n("Next year")); + yearBackward->setToolTip(i18n("Previous year")); + monthForward->setToolTip(i18n("Next month")); + monthBackward->setToolTip(i18n("Previous month")); + d->selectWeek->setToolTip(i18n("Select a week")); + selectMonth->setToolTip(i18n("Select a month")); + selectYear->setToolTip(i18n("Select a year")); + d->todayButton->setToolTip(i18n("Select the current day")); // ----- setFontSize(fontsize); @@ -173,17 +172,17 @@ void ExtDatePicker::init( const ExtDate &dt ) line->installEventFilter( this ); if ( QApplication::reverseLayout() ) { - yearForward->setIconSet(BarIconSet(QString::fromLatin1("2leftarrow"))); - yearBackward->setIconSet(BarIconSet(QString::fromLatin1("2rightarrow"))); - monthForward->setIconSet(BarIconSet(QString::fromLatin1("1leftarrow"))); - monthBackward->setIconSet(BarIconSet(QString::fromLatin1("1rightarrow"))); + yearForward->setIconSet(BarIconSet(QLatin1String("2leftarrow"))); + yearBackward->setIconSet(BarIconSet(QLatin1String("2rightarrow"))); + monthForward->setIconSet(BarIconSet(QLatin1String("1leftarrow"))); + monthBackward->setIconSet(BarIconSet(QLatin1String("1rightarrow"))); } else { - yearForward->setIconSet(BarIconSet(QString::fromLatin1("2rightarrow"))); - yearBackward->setIconSet(BarIconSet(QString::fromLatin1("2leftarrow"))); - monthForward->setIconSet(BarIconSet(QString::fromLatin1("1rightarrow"))); - monthBackward->setIconSet(BarIconSet(QString::fromLatin1("1leftarrow"))); + yearForward->setIconSet(BarIconSet(QLatin1String("2rightarrow"))); + yearBackward->setIconSet(BarIconSet(QLatin1String("2leftarrow"))); + monthForward->setIconSet(BarIconSet(QLatin1String("1rightarrow"))); + monthBackward->setIconSet(BarIconSet(QLatin1String("1leftarrow"))); } connect(table, SIGNAL(dateChanged(const ExtDate&)), SLOT(dateChangedSlot(const ExtDate&))); connect(table, SIGNAL(tableClicked()), SLOT(tableClickedSlot())); @@ -520,7 +519,7 @@ ExtDatePicker::setCloseButton( bool enable ) d->closeButton->setAutoRaise(true); d->navigationLayout->addSpacing(KDialog::spacingHint()); d->navigationLayout->addWidget(d->closeButton); - QToolTip::add(d->closeButton, i18n("Close")); + d->closeButton->setToolTip(i18n("Close")); d->closeButton->setPixmap( SmallIcon("remove") ); connect( d->closeButton, SIGNAL( clicked() ), topLevelWidget(), SLOT( close() ) ); diff --git a/kdeeduplot/kplotobject.cpp b/kdeeduplot/kplotobject.cpp index a53f836..361191d 100644 --- a/kdeeduplot/kplotobject.cpp +++ b/kdeeduplot/kplotobject.cpp @@ -39,7 +39,7 @@ KPlotObject::~KPlotObject() void KPlotObject::removePoint( int index ) { if ( ( index < 1 ) || ( index > pList.count() - 1 ) ) { - kdWarning() << i18n( "Ignoring attempt to remove non-existent plot object" ) << endl; + kdWarning() << "Ignoring attempt to remove non-existent plot object" << endl; return; }