Qmmp
Loading...
Searching...
No Matches
addurldialog_p.h
1/***************************************************************************
2 * Copyright (C) 2006-2025 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 ADDURLDIALOG_P_H
22#define ADDURLDIALOG_P_H
23
24#include <QDialog>
25#include <QPointer>
26#include <QUrl>
27
28class QNetworkAccessManager;
29class QNetworkReply;
30class PlayListModel;
32
33namespace Ui {
34class AddUrlDialog;
35}
36
40class AddUrlDialog : public QDialog
41{
42 Q_OBJECT
43public:
44 static void popup(QWidget* parent ,PlayListModel*);
45
46private slots:
47 void onFinished(bool ok, const QString &message);
48
49private:
50 explicit AddUrlDialog(QWidget *parent);
51 ~AddUrlDialog();
52 void accept() override;
53 void setModel(PlayListModel*);
54 void addToHistory(const QString &path);
55 static QPointer<AddUrlDialog> m_instance;
56 Ui::AddUrlDialog *m_ui;
57 PlayListModel *m_model;
58 PlayListDownloader *m_downloader;
59 QStringList m_history;
60};
61#endif //ADDURLDIALOG_P_H
The PlayListDownloader class downloads playlist from remote URL and extracts tracks.
Definition playlistdownloader.h:37
The PlayListModel class provides a data model for the playlist.
Definition playlistmodel.h:88