-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathparserwindow.h
More file actions
39 lines (30 loc) · 986 Bytes
/
parserwindow.h
File metadata and controls
39 lines (30 loc) · 986 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
#ifndef PARSERWINDOW_H
#define PARSERWINDOW_H
#include <QMainWindow>
#include <QObject>
#include <QNetworkAccessManager>
#include <QNetworkRequest>
#include <QNetworkReply>
#include <QUrl>
#include <QTextCodec> //для преобразования кодировки
namespace Ui {
class ParserWindow;
}
class ParserWindow : public QMainWindow
{
Q_OBJECT
public:
explicit ParserWindow(QWidget *parent = 0);
~ParserWindow();
void startRequest(QUrl url); //стартовый запрос
private slots:
void downloadFile(); //когда щелкаем по кнопке Download
void ReplyFinished(); //cлот, выполняемый при завершении запроса
private:
Ui::ParserWindow *ui; //создается экземпляр, через который
//мы обращаемся к форме
QUrl url;
QNetworkAccessManager *manager;
QNetworkReply *reply;
};
#endif // PARSERWINDOW_H