2 // C++ Interface: mainwindow
4 // Author: Oliver Groß <z.o.gross@gmx.de>, (C) 2008
6 // Copyright: See COPYING file that comes with this distribution
8 #ifndef MUSIQUE_MAINWINDOW_H
9 #define MUSIQUE_MAINWINDOW_H
11 #include <QMainWindow>
12 #include <xmmsclient/xmmsclient-qt4.h>
13 #include "ui/ui_mainwin.h"
20 class CCollectionsModel
;
22 class CMainWindow
: public QMainWindow
{
25 CMainWindow(QWidget
* parent
= 0);
29 void switchToPrevious();
34 void removeSelectedEntries();
36 void randomizePlaylist();
39 QString lastDirectoryDir
;
40 QStringList lastAppendedUrls
;
43 QSlider
* m_VolumeSlider
;
44 QLabel
* m_VolumeLabel
;
45 QLabel
* m_CurrentLabel
;
48 QString m_CurrentTitle
;
50 CPlaylistModel
* m_PlaylistModel
;
51 CCollectionsModel
* m_CollectionsModel
;
53 XmmsQt::QClient m_Client
;
54 XmmsQt::QPlayback m_Playback
;
55 XmmsQt::QMedialib m_Medialib
;
59 inline void setupActions();
60 inline void setupToolbars();
61 inline QString
toFormatedTitleInfo(quint32 id
);
63 void updatePlaytime(quint32 time
);
65 void updateStatus(xmms_playback_status_t status
);
66 void updateCurrentId(quint32 id
);
67 void checkMediaUpdate(quint32 id
);
68 void switchToEntry(QModelIndex index
);
69 //void switchToPlaylist(QModelIndex index);
70 void switchToActivePlaylist();
71 //void handleActivePlaylistOnce();
72 void handleEntrySelectionChange(const QItemSelection
& selected
);