From 462117a0f60287d5309932937c24da3ab1292476 Mon Sep 17 00:00:00 2001 From: harlekin Date: Wed, 21 Aug 2002 20:42:09 +0000 Subject: started taking playlistwidget apart, also made gui a bit more beautiful --- (limited to 'noncore/multimedia/opieplayer2/playlistwidget.h') diff --git a/noncore/multimedia/opieplayer2/playlistwidget.h b/noncore/multimedia/opieplayer2/playlistwidget.h index 8710a99..2742252 100644 --- a/noncore/multimedia/opieplayer2/playlistwidget.h +++ b/noncore/multimedia/opieplayer2/playlistwidget.h @@ -1,3 +1,35 @@ +/* +                This file is part of the Opie Project + +              Copyright (c) 2002 Max Reiss + Copyright (c) 2002 L. Potter + Copyright (c) 2002 Holger Freyther + =. + .=l. +           .>+-= + _;:,     .>    :=|. This program is free software; you can +.> <`_,   >  .   <= redistribute it and/or modify it under +:`=1 )Y*s>-.--   : the terms of the GNU General Public +.="- .-=="i,     .._ License as published by the Free Software + - .   .-<_>     .<> Foundation; either version 2 of the License, +     ._= =}       : or (at your option) any later version. +    .%`+i>       _;_. +    .i_,=:_.      -`: PARTICULAR PURPOSE. See the GNU +..}^=.=       =       ; Library General Public License for more +++=   -.     .`     .: details. + :     =  ...= . :.=- + -.   .:....=;==+<; You should have received a copy of the GNU +  -_. . .   )=.  = Library General Public License along with +    --        :-=` this library; see the file COPYING.LIB. + If not, write to the Free Software Foundation, + Inc., 59 Temple Place - Suite 330, + Boston, MA 02111-1307, USA. + +*/ #ifndef PLAY_LIST_WIDGET_H #define PLAY_LIST_WIDGET_H @@ -9,10 +41,10 @@ #include #include -/* #include */ +#include "playlistwidgetgui.h" -class PlayListWidgetPrivate; +//class PlayListWidgetPrivate; class Config; class QListViewItem; class QListView; @@ -20,54 +52,41 @@ class QPoint; class QAction; class QLabel; -class PlayListWidget : public QMainWindow { +class PlayListWidget : public PlayListWidgetGui { Q_OBJECT public: PlayListWidget( QWidget* parent=0, const char* name=0, WFlags fl=0 ); ~PlayListWidget(); - QTabWidget * tabWidget; -// MenuItem *fullScreenButton, *scaleButton; -// QAction *fullScreenButton, *scaleButton; DocLnkSet files; DocLnkSet vFiles; - QListView *audioView, *videoView, *playlistView; - QLabel *libString; - QPopupMenu *pmView ; bool fromSetDocument; bool insanityBool; QString setDocFileRef; // retrieve the current playlist entry (media file link) const DocLnk *current(); void useSelectedDocument(); -/* QTimer * menuTimer; */ - FileSelector* playLists; - QPushButton *tbDeletePlaylist; int selected; + public slots: bool first(); bool last(); bool next(); bool prev(); void writeConfig( Config& cfg ) const; -/* void setFullScreen(); */ -/* void setScaled(); */ + protected: -/* void contentsMousePressEvent( QMouseEvent * e ); */ -/* void contentsMouseReleaseEvent( QMouseEvent * e ); */ -void keyReleaseEvent( QKeyEvent *e); -void keyPressEvent( QKeyEvent *e); + void keyReleaseEvent( QKeyEvent *e); + private: int defaultSkinIndex; - QPopupMenu *skinsMenu; bool audioScan, videoScan; void readm3u(const QString &); void readPls(const QString &); - void initializeStates(); void readConfig( Config& cfg ); - PlayListWidgetPrivate *d; // Private implementation data void populateAudioView(); void populateVideoView(); + private slots: void populateSkinsMenu(); void skinsMenuActivated(int); @@ -79,9 +98,7 @@ private slots: void setDocument( const QString& fileref ); void addToSelection( const DocLnk& ); // Add a media file to the playlist void addToSelection( QListViewItem* ); // Add a media file to the playlist - void setActiveWindow(); // need to handle this to show the right view void setPlaylist( bool ); // Show/Hide the playlist - void setView( char ); void clearList(); void addAllToList(); void addAllMusicToList(); @@ -89,7 +106,6 @@ private slots: void saveList(); // Save the playlist void loadList( const DocLnk &); // Load a playlist void playIt( QListViewItem *); - void btnPlay(bool); void deletePlaylist(); void addSelected(); @@ -98,14 +114,7 @@ private slots: void viewPressed( int, QListViewItem *, const QPoint&, int); void playlistViewPressed( int, QListViewItem *, const QPoint&, int); void playSelected(); - -protected slots: -/* void cancelMenuTimer(); */ -/* void showFileMenu(); */ - - }; - #endif // PLAY_LIST_WIDGET_H -- cgit v0.9.0.2