1 /***************************************************************************
3 * Open \______ \ ____ ____ | | _\_ |__ _______ ___
4 * Source | _// _ \_/ ___\| |/ /| __ \ / _ \ \/ /
5 * Jukebox | | ( <_> ) \___| < | \_\ ( <_> > < <
6 * Firmware |____|_ /\____/ \___ >__|_ \|___ /\____/__/\_ \
9 * Copyright (C) 2007 by Dominik Wenger
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.
17 * This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY
18 * KIND, either express or implied.
20 ****************************************************************************/
31 #include "progressloggerinterface.h"
34 class ZipInstaller
: public QObject
38 ZipInstaller(QObject
* parent
) ;
40 void install(ProgressloggerInterface
* dp
);
41 void setMountPoint(QString mountpoint
) {m_mountpoint
= mountpoint
;}
42 void setUrl(QString url
){m_urllist
= QStringList(url
);}
43 void setUrl(QStringList url
) { m_urllist
= url
; }
44 void setLogSection(QString name
) {m_loglist
= QStringList(name
);}
45 void setLogSection(QStringList name
) { m_loglist
= name
; }
46 void setLogVersion(QString v
) { m_verlist
= QStringList(v
); qDebug() << m_verlist
;}
47 void setLogVersion(QStringList v
) { m_verlist
= v
; qDebug() << m_verlist
;}
48 void setUnzip(bool i
) { m_unzip
= i
; }
49 void setTarget(QString t
) { m_target
= t
; }
50 void setCache(QDir c
) { m_cache
= c
; m_usecache
= true; };
51 void setCache(bool c
) { m_usecache
= c
; };
52 void setCache(QString c
) { m_cache
= QDir(c
); m_usecache
= true; }
55 void done(bool error
);
59 void downloadDone(bool);
60 void installStart(void);
61 void installContinue(void);
64 void installSingle(ProgressloggerInterface
*dp
);
65 QString m_url
, m_file
, m_mountpoint
, m_logsection
, m_logver
;
66 QStringList m_urllist
, m_loglist
, m_verlist
;
74 QTemporaryFile
*downloadFile
;
76 ProgressloggerInterface
* m_dp
;