Init
This commit is contained in:
38
tempzar.cpp
Normal file
38
tempzar.cpp
Normal file
@@ -0,0 +1,38 @@
|
||||
#include "tempzar.h"
|
||||
#include "ui_tempzar.h"
|
||||
|
||||
tempZar::tempZar(QWidget *parent) :
|
||||
QDialog(parent),
|
||||
ui(new Ui::tempZar)
|
||||
{
|
||||
ui->setupUi(this);
|
||||
this->setAttribute(Qt::WA_DeleteOnClose);
|
||||
((Widget*)parent)->changeOpenWidget(this);
|
||||
ZAtempZar = 0;
|
||||
ZAtempZar = (((Widget*)parent)->ZAtempZar);
|
||||
ui->lineEdit->setText(QString::number(ZAtempZar));
|
||||
}
|
||||
|
||||
tempZar::~tempZar()
|
||||
{
|
||||
delete ui;
|
||||
}
|
||||
|
||||
void tempZar::on_pushButton_clicked()
|
||||
{
|
||||
ZAtempZar = ui->lineEdit->text().toInt();
|
||||
((Widget*)parent())->ZAtempZar = ZAtempZar;
|
||||
((Widget*)parent())->writeFile();
|
||||
close();
|
||||
}
|
||||
|
||||
void tempZar::on_pushButton_2_clicked()
|
||||
{
|
||||
close();
|
||||
}
|
||||
|
||||
void tempZar::closeEvent(QCloseEvent *e)
|
||||
{
|
||||
((Widget*)parent())->clearOpenWidget();
|
||||
e->accept();
|
||||
}
|
||||
Reference in New Issue
Block a user