summaryrefslogtreecommitdiff
path: root/noncore/multimedia
authorsimon <simon>2002-12-02 19:46:48 (UTC)
committer simon <simon>2002-12-02 19:46:48 (UTC)
commite77f4914311d8a623c084d01a287798440abf01f (patch) (side-by-side diff)
tree673375b737c4b1435929cdc804641b08d20e62c8 /noncore/multimedia
parent1706751f05c1d4312beb1ca939a156b090c7b5f6 (diff)
downloadopie-e77f4914311d8a623c084d01a287798440abf01f.zip
opie-e77f4914311d8a623c084d01a287798440abf01f.tar.gz
opie-e77f4914311d8a623c084d01a287798440abf01f.tar.bz2
- inherit from MediaWidget
Diffstat (limited to 'noncore/multimedia') (more/less context) (ignore whitespace changes)
-rw-r--r--noncore/multimedia/opieplayer2/audiowidget.cpp5
-rw-r--r--noncore/multimedia/opieplayer2/audiowidget.h9
-rw-r--r--noncore/multimedia/opieplayer2/videowidget.cpp5
-rw-r--r--noncore/multimedia/opieplayer2/videowidget.h6
4 files changed, 12 insertions, 13 deletions
diff --git a/noncore/multimedia/opieplayer2/audiowidget.cpp b/noncore/multimedia/opieplayer2/audiowidget.cpp
index 1600320..0b7d470 100644
--- a/noncore/multimedia/opieplayer2/audiowidget.cpp
+++ b/noncore/multimedia/opieplayer2/audiowidget.cpp
@@ -90,9 +90,9 @@ static void changeTextColor( QWidget *w ) {
static const int numButtons = (sizeof(audioButtons)/sizeof(MediaButton));
-AudioWidget::AudioWidget(QWidget* parent, const char* name, WFlags f) :
+AudioWidget::AudioWidget(QWidget* parent, const char* name) :
- QWidget( parent, name, f ), songInfo( this ), slider( Qt::Horizontal, this ), time( this ) {
+ MediaWidget( parent, name ), songInfo( this ), slider( Qt::Horizontal, this ), time( this ) {
setCaption( tr("OpiePlayer") );
@@ -160,7 +160,6 @@ AudioWidget::AudioWidget(QWidget* parent, const char* name, WFlags f) :
resizeEvent( NULL );
connect( mediaPlayerState, SIGNAL( lengthChanged(long) ), this, SLOT( setLength(long) ) );
- connect( mediaPlayerState, SIGNAL( displayTypeChanged(MediaPlayerState::DisplayType) ), this, SLOT( setDisplayType(MediaPlayerState::DisplayType) ) );
connect( mediaPlayerState, SIGNAL( loopingToggled(bool) ), this, SLOT( setLooping(bool) ) );
connect( mediaPlayerState, SIGNAL( playingToggled(bool) ), this, SLOT( setPlaying(bool) ) );
connect( mediaPlayerState, SIGNAL( isSeekableToggled( bool ) ), this, SLOT( setSeekable( bool ) ) );
diff --git a/noncore/multimedia/opieplayer2/audiowidget.h b/noncore/multimedia/opieplayer2/audiowidget.h
index 91fcbc5..74c5b0e 100644
--- a/noncore/multimedia/opieplayer2/audiowidget.h
+++ b/noncore/multimedia/opieplayer2/audiowidget.h
@@ -34,7 +34,6 @@
#ifndef AUDIO_WIDGET_H
#define AUDIO_WIDGET_H
-#include <qwidget.h>
#include <qpainter.h>
#include <qdrawutil.h>
#include <qpixmap.h>
@@ -46,7 +45,7 @@
#include <opie/oticker.h>
-#include "mediaplayerstate.h"
+#include "mediawidget.h"
class QPixmap;
@@ -66,10 +65,10 @@ enum AudioButtons {
};
};
-class AudioWidget : public QWidget {
+class AudioWidget : public MediaWidget {
Q_OBJECT
public:
- AudioWidget( QWidget* parent=0, const char* name=0, WFlags f=0 );
+ AudioWidget( QWidget* parent=0, const char* name=0 );
~AudioWidget();
void setTickerText( const QString &text ) { songInfo.setText( text ); }
public slots:
@@ -81,6 +80,8 @@ public slots:
void setPosition( long );
void setLength( long );
void setSeekable( bool );
+
+public:
void setDisplayType( MediaPlayerState::DisplayType displayType );
signals:
diff --git a/noncore/multimedia/opieplayer2/videowidget.cpp b/noncore/multimedia/opieplayer2/videowidget.cpp
index 9ce2b57..8a0016e 100644
--- a/noncore/multimedia/opieplayer2/videowidget.cpp
+++ b/noncore/multimedia/opieplayer2/videowidget.cpp
@@ -83,8 +83,8 @@ const char *skinV_mask_file_names[7] = {
static const int numVButtons = (sizeof(videoButtons)/sizeof(MediaButton));
-VideoWidget::VideoWidget(QWidget* parent, const char* name, WFlags f) :
-QWidget( parent, name, f ), scaledWidth( 0 ), scaledHeight( 0 ) {
+VideoWidget::VideoWidget(QWidget* parent, const char* name) :
+MediaWidget( parent, name ), scaledWidth( 0 ), scaledHeight( 0 ) {
setCaption( tr("OpiePlayer - Video") );
@@ -139,7 +139,6 @@ QWidget( parent, name, f ), scaledWidth( 0 ), scaledHeight( 0 ) {
resizeEvent( NULL );
connect( mediaPlayerState, SIGNAL( lengthChanged(long) ), this, SLOT( setLength(long) ) );
- connect( mediaPlayerState, SIGNAL( displayTypeChanged(MediaPlayerState::DisplayType) ), this, SLOT( setDisplayType(MediaPlayerState::DisplayType) ) );
connect( mediaPlayerState, SIGNAL( playingToggled(bool) ), this, SLOT( setPlaying(bool) ) );
setLength( mediaPlayerState->length() );
diff --git a/noncore/multimedia/opieplayer2/videowidget.h b/noncore/multimedia/opieplayer2/videowidget.h
index 89af646..8e9dd7e 100644
--- a/noncore/multimedia/opieplayer2/videowidget.h
+++ b/noncore/multimedia/opieplayer2/videowidget.h
@@ -37,7 +37,7 @@
#include <qwidget.h>
#include "xinevideowidget.h"
-#include "mediaplayerstate.h"
+#include "mediawidget.h"
class QPixmap;
class QSlider;
@@ -53,10 +53,10 @@ enum VideoButtons {
VideoFullscreen
};
-class VideoWidget : public QWidget {
+class VideoWidget : public MediaWidget {
Q_OBJECT
public:
- VideoWidget( QWidget* parent=0, const char* name=0, WFlags f=0 );
+ VideoWidget( QWidget* parent=0, const char* name=0 );
~VideoWidget();