author | harlekin <harlekin> | 2002-08-05 16:43:59 (UTC) |
---|---|---|
committer | harlekin <harlekin> | 2002-08-05 16:43:59 (UTC) |
commit | af5168ac637f2f5b871cc73a69151dd3d829fec0 (patch) (side-by-side diff) | |
tree | 2cc8dad511ee01709a6c19699206b6ad20184a76 | |
parent | c4a390e38fe72eeafa0620fc1f8299f561958d21 (diff) | |
download | opie-af5168ac637f2f5b871cc73a69151dd3d829fec0.zip opie-af5168ac637f2f5b871cc73a69151dd3d829fec0.tar.gz opie-af5168ac637f2f5b871cc73a69151dd3d829fec0.tar.bz2 |
seeking is working now
-rw-r--r-- | noncore/multimedia/opieplayer2/audiowidget.cpp | 22 | ||||
-rw-r--r-- | noncore/multimedia/opieplayer2/xinecontrol.cpp | 7 | ||||
-rw-r--r-- | noncore/multimedia/opieplayer2/xinecontrol.h | 2 |
3 files changed, 16 insertions, 15 deletions
diff --git a/noncore/multimedia/opieplayer2/audiowidget.cpp b/noncore/multimedia/opieplayer2/audiowidget.cpp index 23f4329..0e9e7ea 100644 --- a/noncore/multimedia/opieplayer2/audiowidget.cpp +++ b/noncore/multimedia/opieplayer2/audiowidget.cpp @@ -78,3 +78,3 @@ MediaButton audioButtons[] = { { FALSE, FALSE, FALSE }, // forward - { FALSE, FALSE, FALSE } // back + { FALSE, FALSE, FALSE } // back }; @@ -100,3 +100,3 @@ AudioWidget::AudioWidget(QWidget* parent, const char* name, WFlags f) : setCaption( tr("OpiePlayer") ); - + Config cfg("OpiePlayer"); @@ -124,4 +124,4 @@ AudioWidget::AudioWidget(QWidget* parent, const char* name, WFlags f) : uchar *line = dest[y]; - for ( int x = 0; x < imgUp->width(); x++ ) - if ( !qRed( imgMask.pixel( x, y ) ) ) + for ( int x = 0; x < imgUp->width(); x++ ) + if ( !qRed( imgMask.pixel( x, y ) ) ) line[x] = i + 1; @@ -163,3 +163,3 @@ AudioWidget::AudioWidget(QWidget* parent, const char* name, WFlags f) : connect( mediaPlayerState, SIGNAL( playingToggled(bool) ), this, SLOT( setPlaying(bool) ) ); - + // Intialise state @@ -174,3 +174,3 @@ AudioWidget::AudioWidget(QWidget* parent, const char* name, WFlags f) : AudioWidget::~AudioWidget() { - + for ( int i = 0; i < 11; i++ ) { @@ -276,3 +276,3 @@ void AudioWidget::setView( char view ) { // does not stop stream when it reaches the end - slider.show(); + // slider.show(); connect( mediaPlayerState, SIGNAL( positionChanged(long) ),this, SLOT( setPosition(long) ) ); @@ -301,3 +301,3 @@ void AudioWidget::updateSlider( long i, long max ) { // qDebug( timeAsString( i ) + " / " + timeAsString( max ) ) ; - + if ( max == 0 ) { @@ -362,3 +362,3 @@ void AudioWidget::mouseMoveEvent( QMouseEvent *event ) { - if ( isOnButton && i == AudioVolumeUp ) + if ( isOnButton && i == AudioVolumeUp ) qDebug("on up"); @@ -369,5 +369,5 @@ void AudioWidget::mouseMoveEvent( QMouseEvent *event ) { switch (i) { - case AudioVolumeUp: + case AudioVolumeUp: qDebug("more clicked"); - emit moreClicked(); + emit moreClicked(); return; diff --git a/noncore/multimedia/opieplayer2/xinecontrol.cpp b/noncore/multimedia/opieplayer2/xinecontrol.cpp index 33889d0..d08ff04 100644 --- a/noncore/multimedia/opieplayer2/xinecontrol.cpp +++ b/noncore/multimedia/opieplayer2/xinecontrol.cpp @@ -48,3 +48,2 @@ XineControl::XineControl( QObject *parent, const char *name ) connect( this, SIGNAL( positionChanged( long ) ), mediaPlayerState, SLOT( updatePosition( long ) ) ); - connect( this, SIGNAL( positionChanged( long ) ), mediaPlayerState, SLOT( setPosition( long ) ) ); connect( mediaPlayerState, SIGNAL( playingToggled( bool ) ), this, SLOT( stop( bool ) ) ); @@ -60,2 +59,3 @@ XineControl::~XineControl() { void XineControl::play( const QString& fileName ) { + m_fileName = fileName; libXine->play( fileName ); @@ -113,3 +113,3 @@ long XineControl::position() { m_position = ( currentTime() ); - mediaPlayerState->setPosition( m_position ); + mediaPlayerState->updatePosition( m_position ); long emitPos = (long)m_position; @@ -128,3 +128,4 @@ void XineControl::setFullscreen( bool isSet ) { void XineControl::seekTo( long second ) { - // libXine-> + qDebug("seek triggered!!"); + libXine->play( m_fileName , 0, (int)second ); } diff --git a/noncore/multimedia/opieplayer2/xinecontrol.h b/noncore/multimedia/opieplayer2/xinecontrol.h index 4a61f32..c7aefd4 100644 --- a/noncore/multimedia/opieplayer2/xinecontrol.h +++ b/noncore/multimedia/opieplayer2/xinecontrol.h @@ -65,3 +65,3 @@ private: long m_position; - + QString m_fileName; signals: |