00001 /***************************************************************************** 00002 * interface_widgets.hpp : Playlist Widgets 00003 **************************************************************************** 00004 * Copyright (C) 2006-2009 the VideoLAN team 00005 * $Id: 2b793b76d2c5e73dbfdd7c7421cd0ea7faa92eb8 $ 00006 * 00007 * Authors: Clément Stenac <zorglub@videolan.org> 00008 * Jean-Baptiste Kempf <jb@videolan.org> 00009 * Rafaël Carré <funman@videolanorg> 00010 * 00011 * This program is free software; you can redistribute it and/or modify 00012 * it under the terms of the GNU General Public License as published by 00013 * the Free Software Foundation; either version 2 of the License, or 00014 * (at your option) any later version. 00015 * 00016 * This program is distributed in the hope that it will be useful, 00017 * but WITHOUT ANY WARRANTY; without even the implied warranty of 00018 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 00019 * GNU General Public License for more details. 00020 * 00021 * You should have received a copy of the GNU General Public License 00022 * along with this program; if not, write to the Free Software Foundation, Inc., 00023 * 51 Franklin Street, Fifth Floor, Boston MA 02110-1301, USA. 00024 *****************************************************************************/ 00025 00026 #ifndef _PLAYLISTWIDGET_H_ 00027 #define _PLAYLISTWIDGET_H_ 00028 00029 #ifdef HAVE_CONFIG_H 00030 # include "config.h" 00031 #endif 00032 00033 #include "qt4.hpp" 00034 00035 #include "dialogs_provider.hpp" /* Media Info from ArtLabel */ 00036 #include "components/interface_widgets.hpp" /* CoverArt */ 00037 //#include <vlc_playlist.h> 00038 00039 #include <QSplitter> 00040 00041 class PLSelector; 00042 class StandardPLPanel; 00043 class QPushButton; 00044 00045 class ArtLabel : public CoverArtLabel 00046 { 00047 public: 00048 ArtLabel( QWidget *parent, intf_thread_t *intf ) 00049 : CoverArtLabel( parent, intf ) {} 00050 00051 virtual void mouseDoubleClickEvent( QMouseEvent *event ) 00052 { 00053 THEDP->mediaInfoDialog(); 00054 event->accept(); 00055 } 00056 }; 00057 00058 class PlaylistWidget : public QSplitter 00059 { 00060 Q_OBJECT 00061 public: 00062 PlaylistWidget( intf_thread_t *_p_i, QWidget * ); 00063 virtual ~PlaylistWidget(); 00064 void forceHide(); 00065 void forceShow(); 00066 private: 00067 PLSelector *selector; 00068 ArtLabel *art; 00069 StandardPLPanel *rightPanel; 00070 QPushButton *addButton; 00071 QSplitter *leftSplitter; 00072 protected: 00073 intf_thread_t *p_intf; 00074 virtual void dropEvent( QDropEvent *); 00075 virtual void dragEnterEvent( QDragEnterEvent * ); 00076 virtual void closeEvent( QCloseEvent * ); 00077 00078 }; 00079 00080 #endif
1.5.6