summaryrefslogtreecommitdiff
path: root/noncore/multimedia/opieplayer2/xinecontrol.cpp
Side-by-side diff
Diffstat (limited to 'noncore/multimedia/opieplayer2/xinecontrol.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r--noncore/multimedia/opieplayer2/xinecontrol.cpp12
1 files changed, 6 insertions, 6 deletions
diff --git a/noncore/multimedia/opieplayer2/xinecontrol.cpp b/noncore/multimedia/opieplayer2/xinecontrol.cpp
index 1c489e3..a392f4a 100644
--- a/noncore/multimedia/opieplayer2/xinecontrol.cpp
+++ b/noncore/multimedia/opieplayer2/xinecontrol.cpp
@@ -33,28 +33,29 @@
#include <qtimer.h>
#include <qmessagebox.h>
#include <qpe/qcopenvelope_qws.h>
#include <qpe/qpeapplication.h>
+
#include "xinecontrol.h"
#include "mediaplayerstate.h"
#include "xinevideowidget.h"
-XineControl::XineControl( XineVideoWidget *xineWidget,
- MediaPlayerState &_mediaPlayerState,
+XineControl::XineControl( XineVideoWidget *xineWidget,
+ MediaPlayerState &_mediaPlayerState,
QObject *parent, const char *name )
: QObject( parent, name ), mediaPlayerState( _mediaPlayerState ), xineVideoWidget( xineWidget )
{
libXine = new XINE::Lib( XINE::Lib::InitializeImmediately, xineWidget );
init();
}
-XineControl::XineControl( XINE::Lib *xine, XineVideoWidget *xineWidget,
- MediaPlayerState &_mediaPlayerState,
+XineControl::XineControl( XINE::Lib *xine, XineVideoWidget *xineWidget,
+ MediaPlayerState &_mediaPlayerState,
QObject *parent, const char *name )
: QObject( parent, name ), libXine( xine ), mediaPlayerState( _mediaPlayerState ), xineVideoWidget( xineWidget )
{
xine->ensureInitialized();
xine->setWidget( xineWidget );
@@ -85,12 +86,13 @@ XineControl::~XineControl() {
}
#endif
delete libXine;
}
void XineControl::play( const QString& fileName ) {
+
hasVideoChannel = FALSE;
hasAudioChannel = FALSE;
m_fileName = fileName;
qDebug("<<FILENAME: " + fileName + ">>>>");
@@ -100,13 +102,12 @@ void XineControl::play( const QString& fileName ) {
mediaPlayerState.setPlaying( false );
return;
}
mediaPlayerState.setPlaying( true );
MediaPlayerState::DisplayType displayType;
- // qDebug( QString( "libXine->hasVideo() return : %1 ").arg( libXine->hasVideo() ) );
if ( !libXine->hasVideo() ) {
displayType = MediaPlayerState::Audio;
qDebug("HAS AUDIO");
libXine->setShowVideo( false );
hasAudioChannel = TRUE;
} else {
@@ -194,13 +195,12 @@ long XineControl::position() {
long emitPos = (long)m_position;
emit positionChanged( emitPos );
if( mediaPlayerState.isPlaying() ) {
// needs to be stopped the media is stopped
QTimer::singleShot( 1000, this, SLOT( position() ) );
}
- // qDebug("POSITION : %d", m_position);
return m_position;
}
/**
* Set videoplayback to fullscreen
* @param isSet