-
Notifications
You must be signed in to change notification settings - Fork 0
/
widget.h
59 lines (49 loc) · 1.14 KB
/
widget.h
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
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
#ifndef WIDGET_H
#define WIDGET_H
#include <QFuture>
#include <QFutureWatcher>
#include <QHBoxLayout>
#include <QLabel>
#include <QLineEdit>
#include <QPushButton>
#include <QTableWidget>
#include <QVBoxLayout>
#include <QWidget>
#include "MovieRecord.h"
#include "parser.hpp"
#include "utils.hpp"
QT_BEGIN_NAMESPACE
namespace Ui { class Widget; }
QT_END_NAMESPACE
class Widget : public QWidget
{
Q_OBJECT
public:
Widget(QWidget *parent = nullptr);
~Widget();
signals:
void fullScreenChanged(bool isFullScreen);
private slots:
void SetQuery();
void onQueryFinished();
void onQueryStarted();
private:
QFutureWatcher<TimedResult<void>> futureWatcher{};
std::vector<MovieRecord> queryRecords{};
parserResult queryResult;
Ui::Widget *ui;
QVBoxLayout* global;
QHBoxLayout* H1;
QHBoxLayout *H2;
QTableWidget* tabla;
QLineEdit* consulta;
QLabel * result;
QLabel *tiempoResult;
QPushButton *boton;
parserSQL parsero;
void displayRecords(std::vector<MovieRecord> &);
void execute_action();
template<typename T>
void update_time(TimedResult<T>&);
};
#endif // WIDGET_H