2007-08-15 21:54:15 +00:00
|
|
|
/***************************************************************************
|
|
|
|
* __________ __ ___.
|
|
|
|
* Open \______ \ ____ ____ | | _\_ |__ _______ ___
|
|
|
|
* Source | _// _ \_/ ___\| |/ /| __ \ / _ \ \/ /
|
|
|
|
* Jukebox | | ( <_> ) \___| < | \_\ ( <_> > < <
|
|
|
|
* Firmware |____|_ /\____/ \___ >__|_ \|___ /\____/__/\_ \
|
|
|
|
* \/ \/ \/ \/ \/
|
|
|
|
*
|
|
|
|
* Copyright (C) 2007 by Dominik Riebeling
|
|
|
|
* $Id$
|
|
|
|
*
|
2008-06-28 18:10:04 +00:00
|
|
|
* This program is free software; you can redistribute it and/or
|
|
|
|
* modify it under the terms of the GNU General Public License
|
|
|
|
* as published by the Free Software Foundation; either version 2
|
|
|
|
* of the License, or (at your option) any later version.
|
2007-08-15 21:54:15 +00:00
|
|
|
*
|
|
|
|
* This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY
|
|
|
|
* KIND, either express or implied.
|
|
|
|
*
|
|
|
|
****************************************************************************/
|
|
|
|
|
|
|
|
#ifndef INSTALLTHEMES_H
|
|
|
|
#define INSTALLTHEMES_H
|
|
|
|
|
|
|
|
#include <QtGui>
|
|
|
|
#include <QTemporaryFile>
|
|
|
|
|
|
|
|
#include "ui_installthemesfrm.h"
|
|
|
|
#include "httpget.h"
|
|
|
|
#include "installzip.h"
|
|
|
|
#include "progressloggergui.h"
|
2008-01-25 00:12:25 +00:00
|
|
|
#include "rbsettings.h"
|
2007-08-15 21:54:15 +00:00
|
|
|
|
|
|
|
class ThemesInstallWindow : public QDialog
|
|
|
|
{
|
|
|
|
Q_OBJECT
|
|
|
|
|
|
|
|
public:
|
|
|
|
ThemesInstallWindow(QWidget* parent = 0);
|
2007-09-14 22:16:22 +00:00
|
|
|
~ThemesInstallWindow();
|
2008-01-25 00:12:25 +00:00
|
|
|
void setSettings(RbSettings* sett){settings=sett;}
|
2007-08-15 21:54:15 +00:00
|
|
|
void downloadInfo(void);
|
|
|
|
void show(void);
|
2007-09-14 22:16:22 +00:00
|
|
|
|
2007-08-15 21:54:15 +00:00
|
|
|
public slots:
|
2007-09-15 21:58:31 +00:00
|
|
|
void accept(void);
|
2007-08-15 21:54:15 +00:00
|
|
|
|
|
|
|
private:
|
|
|
|
Ui::ThemeInstallFrm ui;
|
2008-01-25 00:12:25 +00:00
|
|
|
RbSettings* settings;
|
2007-08-15 21:54:15 +00:00
|
|
|
HttpGet *getter;
|
|
|
|
HttpGet igetter;
|
|
|
|
QTemporaryFile themesInfo;
|
|
|
|
int currentItem;
|
|
|
|
void resizeEvent(QResizeEvent*);
|
|
|
|
QByteArray imgData;
|
|
|
|
ProgressLoggerGui *logger;
|
|
|
|
ZipInstaller *installer;
|
|
|
|
QString file;
|
|
|
|
QString fileName;
|
2007-09-14 22:16:22 +00:00
|
|
|
|
|
|
|
QString infocachedir;
|
|
|
|
|
2007-08-15 21:54:15 +00:00
|
|
|
private slots:
|
|
|
|
void downloadDone(bool);
|
|
|
|
void downloadDone(int, bool);
|
|
|
|
void updateDetails(int);
|
|
|
|
void updateImage(bool);
|
|
|
|
void abort(void);
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
|
|
#endif
|