diff options
Diffstat (limited to 'noatun-plugins/alsaplayer/userinterface.cpp')
-rw-r--r-- | noatun-plugins/alsaplayer/userinterface.cpp | 110 |
1 files changed, 55 insertions, 55 deletions
diff --git a/noatun-plugins/alsaplayer/userinterface.cpp b/noatun-plugins/alsaplayer/userinterface.cpp index 1071736..f329c4f 100644 --- a/noatun-plugins/alsaplayer/userinterface.cpp +++ b/noatun-plugins/alsaplayer/userinterface.cpp @@ -28,11 +28,11 @@ #include <noatun/effects.h> #include <noatun/engine.h> -#include <qtoolbutton.h> -#include <qdragobject.h> -#include <qlayout.h> -#include <qtooltip.h> -#include <qframe.h> +#include <tqtoolbutton.h> +#include <tqdragobject.h> +#include <tqlayout.h> +#include <tqtooltip.h> +#include <tqframe.h> #include <kstatusbar.h> #include <kpopupmenu.h> @@ -60,92 +60,92 @@ AlsaPlayer::AlsaPlayer() connect ( playlistButton, - SIGNAL(clicked()), + TQT_SIGNAL(clicked()), napp->player(), - SLOT(toggleListView()) + TQT_SLOT(toggleListView()) ); connect ( previousButton, - SIGNAL(clicked()), + TQT_SIGNAL(clicked()), napp->player(), - SLOT(back()) + TQT_SLOT(back()) ); connect ( nextButton, - SIGNAL(clicked()), + TQT_SIGNAL(clicked()), napp->player(), - SLOT(forward()) + TQT_SLOT(forward()) ); connect ( stopButton, - SIGNAL(clicked()), + TQT_SIGNAL(clicked()), napp->player(), - SLOT(stop()) + TQT_SLOT(stop()) ); connect ( playButton, - SIGNAL(clicked()), + TQT_SIGNAL(clicked()), napp->player(), - SLOT(playpause()) + TQT_SLOT(playpause()) ); - connect(napp, SIGNAL(hideYourself()), SLOT(hide())); - connect(napp, SIGNAL(showYourself()), SLOT(show())); + connect(napp, TQT_SIGNAL(hideYourself()), TQT_SLOT(hide())); + connect(napp, TQT_SIGNAL(showYourself()), TQT_SLOT(show())); - connect(napp->player(), SIGNAL(playlistShown()), SLOT(slotPlayListShown())); - connect(napp->player(), SIGNAL(playlistHidden()), SLOT(slotPlayListHidden())); - connect(napp->player(), SIGNAL(playing()), SLOT(slotPlaying())); - connect(napp->player(), SIGNAL(stopped()), SLOT(slotStopped())); - connect(napp->player(), SIGNAL(paused()), SLOT(slotPaused())); + connect(napp->player(), TQT_SIGNAL(playlistShown()), TQT_SLOT(slotPlayListShown())); + connect(napp->player(), TQT_SIGNAL(playlistHidden()), TQT_SLOT(slotPlayListHidden())); + connect(napp->player(), TQT_SIGNAL(playing()), TQT_SLOT(slotPlaying())); + connect(napp->player(), TQT_SIGNAL(stopped()), TQT_SLOT(slotStopped())); + connect(napp->player(), TQT_SIGNAL(paused()), TQT_SLOT(slotPaused())); - connect(napp->player(), SIGNAL(timeout()), SLOT(slotTimeout())); - connect(napp->player(), SIGNAL(changed()), SLOT(slotTrackChanged())); + connect(napp->player(), TQT_SIGNAL(timeout()), TQT_SLOT(slotTimeout())); + connect(napp->player(), TQT_SIGNAL(changed()), TQT_SLOT(slotTrackChanged())); connect ( napp->player(), - SIGNAL(volumeChanged(int)), - SLOT(slotVolumeChanged(int)) + TQT_SIGNAL(volumeChanged(int)), + TQT_SLOT(slotVolumeChanged(int)) ); connect ( new AlsaPlayerConfigModule(this), - SIGNAL(saved()), - SLOT(slotConfigChanged()) + TQT_SIGNAL(saved()), + TQT_SLOT(slotConfigChanged()) ); connect ( volumeSlider, - SIGNAL(valueChanged(int)), + TQT_SIGNAL(valueChanged(int)), napp->player(), - SLOT(setVolume(int)) + TQT_SLOT(setVolume(int)) ); connect ( forwardButton, - SIGNAL(clicked()), - SLOT(slotForward()) + TQT_SIGNAL(clicked()), + TQT_SLOT(slotForward()) ); connect ( pauseButton, - SIGNAL(clicked()), - SLOT(slotPause()) + TQT_SIGNAL(clicked()), + TQT_SLOT(slotPause()) ); - connect(speedSlider, SIGNAL(valueChanged(int)), SLOT(slotSetSpeed(int))); + connect(speedSlider, TQT_SIGNAL(valueChanged(int)), TQT_SLOT(slotSetSpeed(int))); menuButton->setPopup(NoatunStdAction::ContextMenu::contextMenu()); @@ -165,17 +165,17 @@ AlsaPlayer::~AlsaPlayer() // Empty. } -void AlsaPlayer::closeEvent(QCloseEvent *) +void AlsaPlayer::closeEvent(TQCloseEvent *) { unload(); } -void AlsaPlayer::dragEnterEvent(QDragEnterEvent *event) +void AlsaPlayer::dragEnterEvent(TQDragEnterEvent *event) { event->accept(KURLDrag::canDecode(event)); } -void AlsaPlayer::dropEvent(QDropEvent *event) +void AlsaPlayer::dropEvent(TQDropEvent *event) { KURL::List uri; if (KURLDrag::decode(event, uri)) @@ -185,9 +185,9 @@ void AlsaPlayer::dropEvent(QDropEvent *event) } } -void AlsaPlayer::setTitleText(const QString & s) +void AlsaPlayer::setTitleText(const TQString & s) { - QString titleText + TQString titleText (s.isNull() ? napp->player()->current().title() : s); if (titleLabel->text() != titleText) @@ -196,7 +196,7 @@ void AlsaPlayer::setTitleText(const QString & s) void AlsaPlayer::slotPlaying() { - setTitleText(QString::null); + setTitleText(TQString::null); playButton->setOn(true); stopButton->setEnabled(true); @@ -212,22 +212,22 @@ void AlsaPlayer::slotStopped() void AlsaPlayer::slotPaused() { - setTitleText(QString::null); + setTitleText(TQString::null); stopButton->setEnabled(true); playButton->setOn(false); } -bool AlsaPlayer::eventFilter(QObject *o, QEvent *e) +bool AlsaPlayer::eventFilter(TQObject *o, TQEvent *e) { switch (e->type()) { - case QEvent::MouseButtonPress: - mousePressEvent(static_cast<QMouseEvent *>(e)); + case TQEvent::MouseButtonPress: + mousePressEvent(static_cast<TQMouseEvent *>(e)); break; - case QEvent::Wheel: - wheelEvent(static_cast<QWheelEvent*>(e)); + case TQEvent::Wheel: + wheelEvent(static_cast<TQWheelEvent*>(e)); return true; break; @@ -235,7 +235,7 @@ bool AlsaPlayer::eventFilter(QObject *o, QEvent *e) break; } - return QWidget::eventFilter(o, e); + return TQWidget::eventFilter(o, e); } void AlsaPlayer::slotPlayListShown() @@ -248,7 +248,7 @@ void AlsaPlayer::slotPlayListHidden() playlistButton->setOn(false); } -void AlsaPlayer::mousePressEvent(QMouseEvent * e) +void AlsaPlayer::mousePressEvent(TQMouseEvent * e) { if (e->button() == RightButton) { @@ -256,10 +256,10 @@ void AlsaPlayer::mousePressEvent(QMouseEvent * e) return; } - return QWidget::mousePressEvent(e); + return TQWidget::mousePressEvent(e); } -void AlsaPlayer::wheelEvent(QWheelEvent * e) +void AlsaPlayer::wheelEvent(TQWheelEvent * e) { int newVolume = napp->player()->volume() + (e->delta() / 120); napp->player()->setVolume(newVolume); @@ -272,7 +272,7 @@ void AlsaPlayer::slotConfigChanged() void AlsaPlayer::slotVolumeChanged(int i) { - QString text("%1%"); + TQString text("%1%"); volumeLabel->setText(text.arg(i)); volumeSlider->setValue(i); } @@ -284,9 +284,9 @@ void AlsaPlayer::slotTimeout() if (!napp->player()->current()) return; - setTitleText(QString::null); + setTitleText(TQString::null); - QString lengthText(napp->player()->lengthString()); + TQString lengthText(napp->player()->lengthString()); if (timeLabel->text() != lengthText) timeLabel->setText(lengthText); @@ -312,7 +312,7 @@ void AlsaPlayer::slotSetSpeed(int newSpeed) speed_ = newSpeed; pauseButton->setEnabled(0 != speed_); - speedLabel->setText(QString("%1%").arg(speed_)); + speedLabel->setText(TQString("%1%").arg(speed_)); Arts::PlayObject playobject(napp->player()->engine()->playObject()); Arts::PitchablePlayObject pitchable = Arts::DynamicCast(playobject); |