From kde-commits Tue Jan 17 08:48:50 2006 From: Matthias Kretz Date: Tue, 17 Jan 2006 08:48:50 +0000 To: kde-commits Subject: branches/work/kdelibs-phonon/interfaces/kmediaplayer/kfileaudiopreview Message-Id: <1137487730.761628.6130.nullmailer () svn ! kde ! org> X-MARC-Message: https://marc.info/?l=kde-commits&m=113748774332325 SVN commit 499193 by mkretz: SVN_SILENT: change kdem2m to phonon here as well M +1 -1 Makefile.am M +17 -17 kfileaudiopreview.cpp M +2 -2 kfileaudiopreview.h --- branches/work/kdelibs-phonon/interfaces/kmediaplayer/kfileaudiopreview/Makefile.am #499192:499193 @@ -5,7 +5,7 @@ kfileaudiopreview_la_SOURCES = kfileaudiopreview.cpp kfileaudiopreview_la_LDFLAGS = $(all_libraries) $(KDE_RPATH) -module -avoid-version -no-undefined -kfileaudiopreview_la_LIBADD = $(top_builddir)/kdem2m/ui/libkdem2mui.la $(LIB_KIO) +kfileaudiopreview_la_LIBADD = $(top_builddir)/phonon/ui/libphononui.la $(LIB_KIO) noinst_HEADERS = kfileaudiopreview.h --- branches/work/kdelibs-phonon/interfaces/kmediaplayer/kfileaudiopreview/kfileaudiopreview.cpp #499192:499193 @@ -33,13 +33,13 @@ #include -#include -#include -#include -#include -#include -#include -#include +#include +#include +#include +#include +#include +#include +#include class KFileAudioPreviewFactory : public KLibFactory { @@ -57,8 +57,8 @@ /////////////////////////////////////////////////////////////////// /////////////////////////////////////////////////////////////////// -using namespace Kdem2m; -using namespace Kdem2m::Ui; +using namespace Phonon; +using namespace Phonon::Ui; class KFileAudioPreview::Private { @@ -128,12 +128,12 @@ delete d; } -void KFileAudioPreview::stateChanged( Kdem2m::State newstate, Kdem2m::State oldstate ) +void KFileAudioPreview::stateChanged( Phonon::State newstate, Phonon::State oldstate ) { - if( oldstate == Kdem2m::LoadingState && newstate != Kdem2m::ErrorState ) + if( oldstate == Phonon::LoadingState && newstate != Phonon::ErrorState ) d->controls->setEnabled( true ); - disconnect( d->player, SIGNAL( stateChanged( Kdem2m::State, Kdem2m::State ) ), - this, SLOT( stateChanged( Kdem2m::State, Kdem2m::State ) ) ); + disconnect( d->player, SIGNAL( stateChanged( Phonon::State, Phonon::State ) ), + this, SLOT( stateChanged( Phonon::State, Phonon::State ) ) ); } void KFileAudioPreview::showPreview( const KURL &url ) @@ -141,7 +141,7 @@ delete d->player; d->player = new MediaObject( this ); d->player->setUrl( url ); - if( d->player->state() == Kdem2m::ErrorState ) + if( d->player->state() == Phonon::ErrorState ) { delete d->player; d->player = 0; @@ -149,11 +149,11 @@ } d->controls->setMediaProducer( d->player ); - if( d->player->state() == Kdem2m::StoppedState ) + if( d->player->state() == Phonon::StoppedState ) d->controls->setEnabled( true ); else - connect( d->player, SIGNAL( stateChanged( Kdem2m::State, Kdem2m::State ) ), - SLOT( stateChanged( Kdem2m::State, Kdem2m::State ) ) ); + connect( d->player, SIGNAL( stateChanged( Phonon::State, Phonon::State ) ), + SLOT( stateChanged( Phonon::State, Phonon::State ) ) ); if( m_autoPlay->isChecked() ) d->player->play(); --- branches/work/kdelibs-phonon/interfaces/kmediaplayer/kfileaudiopreview/kfileaudiopreview.h #499192:499193 @@ -22,7 +22,7 @@ #include #include -#include +#include class QCheckBox; class QPushButton; @@ -48,7 +48,7 @@ private slots: void toggleAuto( bool ); - void stateChanged( Kdem2m::State, Kdem2m::State ); + void stateChanged( Phonon::State, Phonon::State ); private: QCheckBox *m_autoPlay;