-
Notifications
You must be signed in to change notification settings - Fork 0
/
tab_template.h
110 lines (85 loc) · 2.53 KB
/
tab_template.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
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
#ifndef TAB_TEMPLATE_H
#define TAB_TEMPLATE_H
#include "datamanagement.h"
#include <QApplication>
#include <QClipboard>
#include <QMimeData>
#include <QTimer>
#include <QMainWindow>
#include <QLabel>
#include <QLineEdit>
#include <QPushButton>
#include <QBoxLayout>
#include <QPixmap>
#include <QImage>
#include <QShortcut>
#include <QKeySequence>
#include <QToolTip>
class Tab_template : public QMainWindow, protected DataManagement
{
Q_OBJECT
public:
explicit Tab_template(QWidget *parent=nullptr);
~Tab_template() override;
void read_data_tab(QSqlDatabase&, int);
void write_data_tab(QSqlDatabase&, int);
//void delete_data_tab(QSqlDatabase&, int);
bool get_flag_change_tab();
void save_tab_change(QSqlDatabase&, int);
QString get_name_resource1();
QString get_name_resource2();
void select_resource1();
void select_resource2();
private:
QWidget* widget;
bool dataChanged;
void difficult_of_passw(QLineEdit*);
bool repeating_sequence(QString);
void setVisiblePas();
QString password_generator(int);
const int length_pas=10;
int id_template_widget;
QWidget* templateWidget[6];
int fixedHeightTemplateWidget;
int fixedWidthNameResource;
int fixSizeLabel;
int fixSizeButton;
int id_horizontal_layout;
QHBoxLayout* horizontalWidget[6];
QLabel* name_label1;
QLineEdit* name_resourse1;
QPushButton* btnCopyLogin1;
QLabel* login_label1;
QLineEdit* login_line1;
QPushButton* btnCopyPassw1;
QLabel* passw_label1;
QLineEdit* passw_line1;
QPushButton* gen_pas_button1;
QPushButton* visiblePassw1;
QLabel* name_label2;
QLineEdit* name_resourse2;
QPushButton* btnCopyLogin2;
QLabel* login_label2;
QLineEdit* login_line2;
QPushButton* btnCopyPassw2;
QLabel* passw_label2;
QLineEdit* passw_line2;
QPushButton* gen_pas_button2;
QPushButton* visiblePassw2;
QPushButton* save_change_page;
QVBoxLayout* verticalWidget;
QMimeData mime;
QTimer timer_clipboard;
private slots:
void save_data_tab();
void slot_check_size_line();
void changeVisiblePas1();
void changeVisiblePas2();
void generate_passw1();
void generate_passw2();
void timeout_clipboard();
void abstractCopyData();
signals:
void signal_save_tab();
};
#endif // TAB_TEMPLATE_H