Commit 069c755078f16b5d3f8d2966191b1210fac168a6

Authored by 고영탁
1 parent 6defa93ae3
Exists in master and in 2 other branches fhd, fhd-demo

메인 설정 버튼 기능 변경

 - 이전 : 기능테스트 실행
 - 변경 : 엔지니어모드 메뉴 실행
app/gui/oven_control/engineermenuwindow.cpp
... ... @@ -3,10 +3,12 @@
3 3 #include "servicehistorymain.h"
4 4 #include "operationtimemain.h"
5 5 #include "realtimemain.h"
  6 +#include "functiontestwindow.h"
  7 +#include "ovenstatics.h"
6 8  
7   -engineermenuwindow::engineermenuwindow(QWidget *parent) :
  9 +engineermenuwindow::engineermenuwindow(QWidget *parent, UdpHandler *udp) :
8 10 QMainWindow(parent),
9   - ui(new Ui::engineermenuwindow)
  11 + ui(new Ui::engineermenuwindow), udp(udp)
10 12 {
11 13 ui->setupUi(this);
12 14  
... ... @@ -14,6 +16,7 @@ engineermenuwindow::engineermenuwindow(QWidget *parent) :
14 16 //setAttribute(Qt::WA_DeleteOnClose);
15 17  
16 18 connect(ui->backButton, SIGNAL(released()), this, SLOT(deleteLater()));
  19 +
17 20 }
18 21  
19 22 engineermenuwindow::~engineermenuwindow()
... ... @@ -41,3 +44,11 @@ void engineermenuwindow::on_realdatabutton_clicked()
41 44 w->setWindowModality(Qt::WindowModal);
42 45 w->showFullScreen();
43 46 }
  47 +
  48 +void engineermenuwindow::on_functiontestbutton_clicked()
  49 +{
  50 + FunctionTestWindow *w = new FunctionTestWindow(this, udp);
  51 + w->setWindowModality(Qt::WindowModal);
  52 + w->showFullScreen();
  53 + w->raise();
  54 +}
... ...
app/gui/oven_control/engineermenuwindow.h
... ... @@ -2,6 +2,7 @@
2 2 #define ENGINEERMENUWINDOW_H
3 3  
4 4 #include <QMainWindow>
  5 +#include "udphandler.h"
5 6  
6 7 namespace Ui {
7 8 class engineermenuwindow;
... ... @@ -12,7 +13,7 @@ class engineermenuwindow : public QMainWindow
12 13 Q_OBJECT
13 14  
14 15 public:
15   - explicit engineermenuwindow(QWidget *parent = 0);
  16 + explicit engineermenuwindow(QWidget *parent = 0 , UdpHandler *udp = 0);
16 17 ~engineermenuwindow();
17 18  
18 19 private slots:
... ... @@ -22,8 +23,11 @@ private slots:
22 23  
23 24 void on_realdatabutton_clicked();
24 25  
  26 + void on_functiontestbutton_clicked();
  27 +
25 28 private:
26 29 Ui::engineermenuwindow *ui;
  30 + UdpHandler *udp;
27 31 };
28 32  
29 33 #endif // ENGINEERMENUWINDOW_H
... ...
app/gui/oven_control/mainwindow.cpp
... ... @@ -67,11 +67,7 @@ void MainWindow::onModeButtonClicked(int mode)
67 67  
68 68 void MainWindow::on_configButton_clicked()
69 69 {
70   -// ConfigWindow *w = new ConfigWindow(this, udp);
71   -// w->setAttribute(Qt::WA_DeleteOnClose);
72   -// w->showFullScreen();
73   -
74   - FunctionTestWindow *w = new FunctionTestWindow(this, udp);
  70 + engineermenuwindow *w = new engineermenuwindow(this, udp);
75 71 w->setWindowModality(Qt::WindowModal);
76 72 w->showFullScreen();
77 73 w->raise();
... ... @@ -111,7 +107,5 @@ void MainWindow::on_washButton_clicked()
111 107  
112 108 void MainWindow::on_helpButton_clicked()
113 109 {
114   - engineermenuwindow *w = new engineermenuwindow(this);
115   - w->setWindowModality(Qt::WindowModal);
116   - w->showFullScreen();
  110 +
117 111 }
... ...