mirror of
https://github.com/Rockbox/rockbox.git
synced 2025-12-09 05:05:20 -05:00
Extend HttpGet class to allow downloading a file to a buffer instead of a file.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@14347 a1c6a512-1295-4272-9138-f99709370657
This commit is contained in:
parent
cacd382963
commit
07e4ddb79d
2 changed files with 68 additions and 20 deletions
|
|
@ -7,7 +7,7 @@
|
|||
* \/ \/ \/ \/ \/
|
||||
*
|
||||
* Copyright (C) 2007 by Dominik Riebeling
|
||||
* $Id:$
|
||||
* $Id$
|
||||
*
|
||||
* All files in this archive are subject to the GNU General Public License.
|
||||
* See the file COPYING in the source tree root for full license agreement.
|
||||
|
|
@ -39,6 +39,7 @@ class HttpGet : public QObject
|
|||
QString errorString(void);
|
||||
void setFile(QFile*);
|
||||
int httpResponse(void);
|
||||
QByteArray readAll(void);
|
||||
|
||||
public slots:
|
||||
void abort(void);
|
||||
|
|
@ -53,11 +54,15 @@ class HttpGet : public QObject
|
|||
void httpProgress(int, int);
|
||||
void httpFinished(int, bool);
|
||||
void httpResponseHeader(const QHttpResponseHeader&);
|
||||
void httpState(int);
|
||||
void httpStarted(int);
|
||||
|
||||
private:
|
||||
QHttp http;
|
||||
QFile *outputFile;
|
||||
int response;
|
||||
int getRequest;
|
||||
QByteArray dataBuffer;
|
||||
};
|
||||
|
||||
#endif
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue