summaryrefslogtreecommitdiffstats
path: root/qt-ui/subsurfacewebservices.h
diff options
context:
space:
mode:
authorGravatar Thiago Macieira <thiago@macieira.org>2013-11-14 17:47:35 -0800
committerGravatar Thiago Macieira <thiago@macieira.org>2013-12-03 13:53:00 -0800
commit919c7045b76f61a67cd00189127cd7d3488065b0 (patch)
treea8262e5a5cdd89ebce548b6a66a27cd735b98bf2 /qt-ui/subsurfacewebservices.h
parentab1b314a84347b648fa0df6a9719f67a9fb54d54 (diff)
downloadsubsurface-919c7045b76f61a67cd00189127cd7d3488065b0.tar.gz
Add support for timing the download out
The time out is 30 seconds from the start of the request or from the last time we got any data from the server. Signed-off-by: Thiago Macieira <thiago@macieira.org>
Diffstat (limited to 'qt-ui/subsurfacewebservices.h')
-rw-r--r--qt-ui/subsurfacewebservices.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/qt-ui/subsurfacewebservices.h b/qt-ui/subsurfacewebservices.h
index 05735f859..89c41e4dd 100644
--- a/qt-ui/subsurfacewebservices.h
+++ b/qt-ui/subsurfacewebservices.h
@@ -3,6 +3,7 @@
#include <QDialog>
#include <QNetworkReply>
+#include <QTimer>
#include <libxml/tree.h>
#include "ui_webservices.h"
@@ -23,6 +24,7 @@ private slots:
virtual void startDownload() = 0;
virtual void startUpload() = 0;
virtual void buttonClicked(QAbstractButton* button) = 0;
+ virtual void downloadTimedOut();
protected slots:
void updateProgress(qint64 current, qint64 total);
@@ -33,6 +35,7 @@ protected:
Ui::WebServices ui;
QNetworkReply *reply;
+ QTimer timeout;
QByteArray downloadedData;
};