Qmmp
jumptotrackdialog_p.h
1 /***************************************************************************
2  * Copyright (C) 2007-2016 by Ilya Kotov *
3  * forkotov02@ya.ru *
4  * *
5  * This program is free software; you can redistribute it and/or modify *
6  * it under the terms of the GNU General Public License as published by *
7  * the Free Software Foundation; either version 2 of the License, or *
8  * (at your option) any later version. *
9  * *
10  * This program is distributed in the hope that it will be useful, *
11  * but WITHOUT ANY WARRANTY; without even the implied warranty of *
12  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
13  * GNU General Public License for more details. *
14  * *
15  * You should have received a copy of the GNU General Public License *
16  * along with this program; if not, write to the *
17  * Free Software Foundation, Inc., *
18  * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. *
19  ***************************************************************************/
20 
21 #ifndef JUMPTOTRACKDIALOG_P_H
22 #define JUMPTOTRACKDIALOG_P_H
23 
24 #include <QDialog>
25 #include <QList>
26 #include "metadataformatter.h"
27 #include "ui_jumptotrackdialog.h"
28 
29 class QStringListModel;
30 class QSortFilterProxyModel;
31 class QEvent;
32 class PlayListManager;
33 class PlayListModel;
34 
39 class JumpToTrackDialog : public QDialog, private Ui::JumpToTrackDialog
40 {
41  Q_OBJECT
42 
43 public:
44  JumpToTrackDialog(PlayListModel *model, QWidget* parent = 0);
45  ~JumpToTrackDialog();
46  void refresh();
47 
48 private slots:
49  void on_refreshPushButton_clicked();
50  void on_queuePushButton_clicked();
51  void on_jumpToPushButton_clicked();
52  void jumpTo(const QModelIndex&);
53  void queueUnqueue(const QModelIndex&,const QModelIndex&);
54 
55 private:
56  bool eventFilter(QObject *o, QEvent *e);
57  QStringListModel* m_listModel;
58  QSortFilterProxyModel* m_proxyModel;
59  PlayListManager *m_pl_manager;
60  PlayListModel *m_model;
61  QList<int> m_indexes;
62  MetaDataFormatter m_titleFormatter;
63 };
64 
65 #endif //JUMPTOTRACKDIALOG_P_H
The PlayListModel class provides a data model for the playlist.
Definition: playlistmodel.h:103
The MetaDataFormatter formats metadata using templates.
Definition: metadataformatter.h:34
The PlayListManager class is used to handle multiple playlists.
Definition: playlistmanager.h:36