summaryrefslogtreecommitdiff
path: root/utils/themeeditor/gui/targetdownloader.h
diff options
context:
space:
mode:
authorRobert Bieber <robby@bieberphoto.com>2010-07-25 21:59:35 +0000
committerRobert Bieber <robby@bieberphoto.com>2010-07-25 21:59:35 +0000
commitd92f8174a1f838684645267e87b3afebfc48143f (patch)
treefe705adf4815eb38f7646ea7a0cb0a0841c74b43 /utils/themeeditor/gui/targetdownloader.h
parente1e51f99949f2a2967210342fcea6e8ae8495e0b (diff)
downloadrockbox-d92f8174a1f838684645267e87b3afebfc48143f.tar.gz
rockbox-d92f8174a1f838684645267e87b3afebfc48143f.zip
Theme Editor: Added targetdb download to preferences dialog, fixed Cancel button on FontDownloader
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@27565 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'utils/themeeditor/gui/targetdownloader.h')
-rw-r--r--utils/themeeditor/gui/targetdownloader.h60
1 files changed, 60 insertions, 0 deletions
diff --git a/utils/themeeditor/gui/targetdownloader.h b/utils/themeeditor/gui/targetdownloader.h
new file mode 100644
index 0000000000..0d2c4578b6
--- /dev/null
+++ b/utils/themeeditor/gui/targetdownloader.h
@@ -0,0 +1,60 @@
1/***************************************************************************
2 * __________ __ ___.
3 * Open \______ \ ____ ____ | | _\_ |__ _______ ___
4 * Source | _// _ \_/ ___\| |/ /| __ \ / _ \ \/ /
5 * Jukebox | | ( <_> ) \___| < | \_\ ( <_> > < <
6 * Firmware |____|_ /\____/ \___ >__|_ \|___ /\____/__/\_ \
7 * \/ \/ \/ \/ \/
8 * $Id$
9 *
10 * Copyright (C) 2010 Robert Bieber
11 *
12 * This program is free software; you can redistribute it and/or
13 * modify it under the terms of the GNU General Public License
14 * as published by the Free Software Foundation; either version 2
15 * of the License, or (at your option) any later version.
16 *
17 * This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY
18 * KIND, either express or implied.
19 *
20 ****************************************************************************/
21
22#ifndef TARGETDOWNLOADER_H
23#define TARGETDOWNLOADER_H
24
25#include <QDialog>
26#include <QDir>
27#include <QNetworkAccessManager>
28#include <QNetworkReply>
29
30namespace Ui {
31 class TargetDownloader;
32}
33
34class TargetDownloader : public QDialog {
35 Q_OBJECT
36public:
37 TargetDownloader(QWidget *parent, QString dir);
38 virtual ~TargetDownloader();
39
40private slots:
41 void cancel();
42
43 void dataReceived();
44 void progress(qint64 bytes, qint64 available);
45 void finished();
46 void netError(QNetworkReply::NetworkError code);
47
48private:
49 void closeEvent(QCloseEvent *event);
50
51 Ui::TargetDownloader *ui;
52
53 QNetworkAccessManager* manager;
54 QFile fout;
55 QNetworkReply* reply;
56
57 bool cancelled;
58};
59
60#endif // TARGETDOWNLOADER_H