summaryrefslogtreecommitdiffstats
path: root/scribus/downloadmanager/scdlmgr.h
blob: b9c88fc4acf0de466cc8da465bdcf31e8d6152c5 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
#ifndef SCDLMANAGER_H
#define SCDLMANAGER_H

#include <QFile>
#include <QList>
#include <QNetworkAccessManager>
#include <QObject>
#include <QQueue>
#include <QStringList>
#include <QThread>
#include <QTime>
#include <QUrl>
#include "scdlthread.h"
#include <QDialog>

class ScDLManager: public QObject
{
	Q_OBJECT
	public:
		ScDLManager(QObject *parent = 0);
//TODO: Add download groups so different parts of Scribus can be downloading at the same time

		void addURL(const QUrl &url, bool overwrite, const QString &location="");
		void addURL(const QString &url, bool overwrite, const QString &location="");
		void addURLs(const QStringList &urlList, bool overwrite, const QString &location="");
		void startDownloads();

	public slots:
		void updateText(const QString& t);

	signals:
		void finished();
		void fileReceived(const QString& t);

	private:
		ScDLThread *thread;
};

#endif