-rw-r--r-- | noncore/multimedia/opieplayer2/opieplayer2.pro | 4 | ||||
-rw-r--r-- | noncore/multimedia/opieplayer2/playlistfileview.cpp | 14 | ||||
-rw-r--r-- | noncore/multimedia/opieplayer2/playlistfileview.h | 16 | ||||
-rw-r--r-- | noncore/multimedia/opieplayer2/playlistview.cpp | 14 | ||||
-rw-r--r-- | noncore/multimedia/opieplayer2/playlistview.h | 16 | ||||
-rw-r--r-- | noncore/multimedia/opieplayer2/playlistwidgetgui.cpp | 5 |
6 files changed, 65 insertions, 4 deletions
diff --git a/noncore/multimedia/opieplayer2/opieplayer2.pro b/noncore/multimedia/opieplayer2/opieplayer2.pro index dbc21b1..8d549b6 100644 --- a/noncore/multimedia/opieplayer2/opieplayer2.pro +++ b/noncore/multimedia/opieplayer2/opieplayer2.pro @@ -1,25 +1,25 @@ TEMPLATE = app #CONFIG = qt warn_on release CONFIG = qt warn_on debug DESTDIR = $(OPIEDIR)/bin HEADERS = playlistselection.h mediaplayerstate.h xinecontrol.h \ videowidget.h audiowidget.h playlistwidget.h om3u.h mediaplayer.h inputDialog.h \ frame.h lib.h xinevideowidget.h volumecontrol.h playlistwidgetgui.h\ - alphablend.h yuv2rgb.h threadutil.h mediawidget.h + alphablend.h yuv2rgb.h threadutil.h mediawidget.h playlistview.h playlistfileview.h SOURCES = main.cpp \ playlistselection.cpp mediaplayerstate.cpp xinecontrol.cpp \ videowidget.cpp audiowidget.cpp playlistwidget.cpp om3u.cpp mediaplayer.cpp inputDialog.cpp \ frame.cpp lib.cpp nullvideo.c xinevideowidget.cpp volumecontrol.cpp \ playlistwidgetgui.cpp\ alphablend.c yuv2rgb.c yuv2rgb_arm.c yuv2rgb_arm4l.S \ - threadutil.cpp mediawidget.cpp + threadutil.cpp mediawidget.cpp playlistview.cpp playlistfileview.cpp TARGET = opieplayer2 INCLUDEPATH += $(OPIEDIR)/include DEPENDPATH += $(OPIEDIR)/include LIBS += -lqpe -lpthread -lopie -lxine MOC_DIR = qpeobj OBJECTS_DIR = qpeobj #INCLUDEPATH += $(OPIEDIR)/include #DEPENDPATH += $(OPIEDIR)/include diff --git a/noncore/multimedia/opieplayer2/playlistfileview.cpp b/noncore/multimedia/opieplayer2/playlistfileview.cpp new file mode 100644 index 0000000..bdd38e0 --- a/dev/null +++ b/noncore/multimedia/opieplayer2/playlistfileview.cpp @@ -0,0 +1,14 @@ + +#include "playlistfileview.h" + +PlayListFileView::PlayListFileView( QWidget *parent, const char *name ) + : PlayListView( parent, name ) +{ +} + +PlayListFileView::~PlayListFileView() +{ +} + +/* vim: et sw=4 ts=4 + */ diff --git a/noncore/multimedia/opieplayer2/playlistfileview.h b/noncore/multimedia/opieplayer2/playlistfileview.h new file mode 100644 index 0000000..eef4bd1 --- a/dev/null +++ b/noncore/multimedia/opieplayer2/playlistfileview.h @@ -0,0 +1,16 @@ +#ifndef PLAYLISTFILEVIEW_H +#define PLAYLISTFILEVIEW_H + +#include "playlistview.h" + +class PlayListFileView : public PlayListView +{ + Q_OBJECT +public: + PlayListFileView( QWidget *parent, const char *name = 0 ); + virtual ~PlayListFileView(); +}; + +#endif // PLAYLISTFILEVIEW_H +/* vim: et sw=4 ts=4 + */ diff --git a/noncore/multimedia/opieplayer2/playlistview.cpp b/noncore/multimedia/opieplayer2/playlistview.cpp new file mode 100644 index 0000000..ebe1492 --- a/dev/null +++ b/noncore/multimedia/opieplayer2/playlistview.cpp @@ -0,0 +1,14 @@ + +#include "playlistview.h" + +PlayListView::PlayListView( QWidget *parent, const char *name ) + : QListView( parent, name ) +{ +} + +PlayListView::~PlayListView() +{ +} + +/* vim: et sw=4 ts=4 + */ diff --git a/noncore/multimedia/opieplayer2/playlistview.h b/noncore/multimedia/opieplayer2/playlistview.h new file mode 100644 index 0000000..f1abb07 --- a/dev/null +++ b/noncore/multimedia/opieplayer2/playlistview.h @@ -0,0 +1,16 @@ +#ifndef PLAYLISTVIEW_H +#define PLAYLISTVIEW_H + +#include <qlistview.h> + +class PlayListView : public QListView +{ + Q_OBJECT +public: + PlayListView( QWidget *parent, const char *name ); + virtual ~PlayListView(); +}; + +#endif // PLAYLISTVIEW_H +/* vim: et sw=4 ts=4 + */ diff --git a/noncore/multimedia/opieplayer2/playlistwidgetgui.cpp b/noncore/multimedia/opieplayer2/playlistwidgetgui.cpp index f47ddcc..de7b6d5 100644 --- a/noncore/multimedia/opieplayer2/playlistwidgetgui.cpp +++ b/noncore/multimedia/opieplayer2/playlistwidgetgui.cpp @@ -30,48 +30,49 @@ Boston, MA 02111-1307, USA. */ #include <qpe/qpemenubar.h> #include <qpe/qpetoolbar.h> #include <qpe/fileselector.h> #include <qpe/qpeapplication.h> #include <qpe/storage.h> #include <qpe/mimetype.h> #include <qpe/config.h> #include <qpe/global.h> #include <qpe/resource.h> #include <qpopupmenu.h> #include <qaction.h> #include <qcursor.h> #include <qdir.h> #include <qlayout.h> #include "playlistselection.h" #include "playlistwidget.h" #include "mediaplayerstate.h" #include "inputDialog.h" +#include "playlistfileview.h" //only needed for the random play #include <stdlib.h> #include "audiowidget.h" #include "videowidget.h" #include "mediaplayerstate.h" PlayListWidgetGui::PlayListWidgetGui( MediaPlayerState &_mediaPlayerState, QWidget* parent, const char* name ) : QMainWindow( parent, name ), mediaPlayerState( _mediaPlayerState ) { d = new PlayListWidgetPrivate; d->setDocumentUsed = FALSE; setBackgroundMode( PaletteButton ); setToolBarsMovable( FALSE ); // Create Toolbar QPEToolBar *toolbar = new QPEToolBar( this ); toolbar->setHorizontalStretchable( TRUE ); // Create Menubar QPEMenuBar *menu = new QPEMenuBar( toolbar ); menu->setMargin( 0 ); @@ -128,71 +129,71 @@ PlayListWidgetGui::PlayListWidgetGui( MediaPlayerState &_mediaPlayerState, QWidg QGridLayout *Playout = new QGridLayout( pTab ); Playout->setSpacing( 2); Playout->setMargin( 2); // Add the playlist area QVBox *vbox3 = new QVBox( pTab ); d->playListFrame = vbox3; QHBox *hbox2 = new QHBox( vbox3 ); d->selectedFiles = new PlayListSelection( hbox2 ); vbox1 = new QVBox( hbox2 ); QPEApplication::setStylusOperation( d->selectedFiles->viewport(), QPEApplication::RightOnHold ); QVBox *stretch1 = new QVBox( vbox1 ); // add stretch Playout->addMultiCellWidget( vbox3, 0, 0, 0, 1 ); QWidget *aTab; aTab = new QWidget( tabWidget, "aTab" ); QGridLayout *Alayout = new QGridLayout( aTab ); Alayout->setSpacing( 2 ); Alayout->setMargin( 2 ); - audioView = new QListView( aTab, "Audioview" ); + audioView = new PlayListFileView( aTab, "Audioview" ); audioView->addColumn( tr( "Title" ), 140 ); audioView->addColumn( tr( "Size" ), -1 ); audioView->addColumn( tr( "Media" ), 0 ); audioView->addColumn( tr( "Path" ), -1 ); audioView->setColumnAlignment( 1, Qt::AlignRight ); audioView->setColumnAlignment( 2, Qt::AlignRight ); audioView->setAllColumnsShowFocus( TRUE ); audioView->setSorting( 3, TRUE ); audioView->setMultiSelection( TRUE ); audioView->setSelectionMode( QListView::Extended ); Alayout->addMultiCellWidget( audioView, 0, 0, 0, 1 ); tabWidget->insertTab( aTab, tr( "Audio" ) ); QPEApplication::setStylusOperation( audioView->viewport(), QPEApplication::RightOnHold ); QWidget *vTab; vTab = new QWidget( tabWidget, "vTab" ); QGridLayout *Vlayout = new QGridLayout( vTab ); Vlayout->setSpacing( 2 ); Vlayout->setMargin( 2 ); - videoView = new QListView( vTab, "Videoview" ); + videoView = new PlayListFileView( vTab, "Videoview" ); videoView->addColumn( tr( "Title" ), 140); videoView->addColumn( tr( "Size" ), -1 ); videoView->addColumn(tr( "Media" ), 0 ); videoView->addColumn(tr( "Path" ), -1 ); videoView->setColumnAlignment( 1, Qt::AlignRight ); videoView->setColumnAlignment( 2, Qt::AlignRight ); videoView->setAllColumnsShowFocus( TRUE ); videoView->setSorting( 3, TRUE ); videoView->setMultiSelection( TRUE ); videoView->setSelectionMode( QListView::Extended ); Vlayout->addMultiCellWidget( videoView, 0, 0, 0, 1 ); QPEApplication::setStylusOperation( videoView->viewport(), QPEApplication::RightOnHold ); tabWidget->insertTab( vTab, tr( "Video" ) ); //playlists list QWidget *LTab; LTab = new QWidget( tabWidget, "LTab" ); QGridLayout *Llayout = new QGridLayout( LTab ); Llayout->setSpacing( 2 ); Llayout->setMargin( 2 ); playLists = new FileSelector( "playlist/plain;audio/x-mpegurl", LTab, "fileselector" , FALSE, FALSE ); |