diff --git a/app/gui/oven_control/basicsettingwindow.cpp b/app/gui/oven_control/basicsettingwindow.cpp deleted file mode 100644 index 02f11ed..0000000 --- a/app/gui/oven_control/basicsettingwindow.cpp +++ /dev/null @@ -1,46 +0,0 @@ -#include "basicsettingwindow.h" -#include "ui_basicsettingwindow.h" - -#include "soundplayer.h" - -BasicSettingWindow::BasicSettingWindow(QWidget *parent) : - QMainWindow(parent), - ui(new Ui::BasicSettingWindow) -{ - ui->setupUi(this); - - foreach (QPushButton *button, findChildren()) - connect(button, &QPushButton::pressed, SoundPlayer::playClick); -} - -BasicSettingWindow::~BasicSettingWindow() -{ - delete ui; -} - -void BasicSettingWindow::keyPressEvent(QKeyEvent *event) -{ - -} - -void BasicSettingWindow::keyReleaseEvent(QKeyEvent *event) -{ - -} - -void BasicSettingWindow::onEncoderLeft() -{ - focusPreviousChild(); -} - -void BasicSettingWindow::onEncoderRight() -{ - focusNextChild(); -} - -void BasicSettingWindow::onEncoderClicked(QWidget *clicked) -{ - QPushButton *b = qobject_cast(clicked); - if (b) - b->click(); -} diff --git a/app/gui/oven_control/basicsettingwindow.h b/app/gui/oven_control/basicsettingwindow.h deleted file mode 100644 index eb62454..0000000 --- a/app/gui/oven_control/basicsettingwindow.h +++ /dev/null @@ -1,32 +0,0 @@ -#ifndef BASICSETTINGWINDOW_H -#define BASICSETTINGWINDOW_H - -#include - -namespace Ui { -class BasicSettingWindow; -} - -class BasicSettingWindow : public QMainWindow -{ - Q_OBJECT - -public: - explicit BasicSettingWindow(QWidget *parent = 0); - ~BasicSettingWindow(); - -protected: - void keyPressEvent(QKeyEvent *event); - void keyReleaseEvent(QKeyEvent *event); - -private: - Ui::BasicSettingWindow *ui; - - QWidget *pushed = NULL; - - void onEncoderLeft(); - void onEncoderRight(); - void onEncoderClicked(QWidget *clicked); -}; - -#endif // BASICSETTINGWINDOW_H diff --git a/app/gui/oven_control/basicsettingwindow.ui b/app/gui/oven_control/basicsettingwindow.ui deleted file mode 100644 index 6ef2a14..0000000 --- a/app/gui/oven_control/basicsettingwindow.ui +++ /dev/null @@ -1,470 +0,0 @@ - - - BasicSettingWindow - - - - 0 - 0 - 900 - 1600 - - - - #centralwidget { background-image: url(:/images/background/config_service.png); } -#bottomBar { background-image: url(:/images/bottom_bar/background.png); } -#midWidget { background-image: url(:/images/config/service/basic_setting_bgnd.png); } - - - - - - - - - 0 - 0 - 900 - 426 - - - - - #clockContainer { background-image: url(:/images/clock/background.png); } - - - - - 272 - 36 - 356 - 355 - - - - - - - 800 - 320 - 80 - 84 - - - - - - - 780 - 230 - 101 - 90 - - - - - - - 780 - 160 - 108 - 67 - - - - - - - 20 - 310 - 300 - 100 - - - - Qt::AlignBottom|Qt::AlignLeading|Qt::AlignLeft - - - - - - - - - 55 - 426 - 900 - 84 - - - - - Malgun Gothic - 11 - - - - color: rgb(255, 255, 255); - - - 서비스단계(엔지니어모드) > 기본설정 - - - - - - 0 - 1450 - 900 - 150 - - - - - - 401 - 26 - 97 - 97 - - - - - 0 - 0 - - - - QPushButton { border-image: url(:/images/bottom_bar/back.png); } -QPushButton:pressed, QPushButton:focus { border-image: url(:/images/bottom_bar/back_ov.png); } - - - - - - - - - - 40 - 545 - 821 - 66 - - - - - 0 - - - - - false - - - - 0 - 0 - - - - - Roboto - 10 - 75 - true - false - - - - QPushButton { border-image: url(:/images/config/pannel.png);color: rgb(255, 255, 255); } -QPushButton:pressed { border-image: url(:/images/config/pannel_ov.png); } -QPushButton { text-align: left;} - - - - 기본설정 - - - - - - - true - - - - Malgun Gothic - 11 - 75 - true - - - - color: rgb(255, 255, 255); - - - EM-2 - - - Qt::AlignCenter - - - 0 - - - - - - - - - 43 - 627 - 813 - 647 - - - - QLabel{ - color : white; -} - - - - - 0 - 70 - 460 - 94 - - - - - 나눔고딕 - 10 - - - - 스팀발생기 수동 스케일 제거 후 물의 양 - - - 7 - - - - - - 0 - 166 - 460 - 94 - - - - - 나눔고딕 - 10 - - - - 소형펌프모터 모드 - - - 7 - - - - - - 0 - 263 - 460 - 94 - - - - - 나눔고딕 - 10 - - - - 소형펌프모터 인터벌시간 설정 - - - 7 - - - - - - 0 - 360 - 460 - 94 - - - - - 나눔고딕 - 10 - - - - 건열퀀칭 작동 온도 - - - 7 - - - - - - 0 - 458 - 460 - 94 - - - - - 나눔고딕 - 10 - - - - 스팀퀀칭 작동 온도 - - - 7 - - - - - - 0 - 553 - 460 - 94 - - - - - 나눔고딕 - 10 - - - - 드레인볼밸브 - - - 7 - - - - - - 0 - 0 - 460 - 69 - - - - - 나눔고딕 - 10 - - - - 설정구분 - - - 7 - - - - - - 460 - 0 - 201 - 69 - - - - - 나눔고딕 - 10 - - - - 설 정 - - - Qt::AlignCenter - - - 7 - - - - - - 660 - 0 - 151 - 69 - - - - - 나눔고딕 - 10 - - - - 상태 - - - Qt::AlignCenter - - - 7 - - - - - - - - Clock - QWidget -
clock.h
- 1 -
- - WashWarnIcon - QLabel -
washwarnicon.h
-
- - DemoIcon - QLabel -
demoicon.h
-
- - HalfEnergyIcon - QLabel -
halfenergyicon.h
-
- - DigitalClock - QLabel -
digitalclock.h
-
-
- - -
diff --git a/app/gui/oven_control/oven_control.pro b/app/gui/oven_control/oven_control.pro index 283a3dd..8de850b 100644 --- a/app/gui/oven_control/oven_control.pro +++ b/app/gui/oven_control/oven_control.pro @@ -65,7 +65,6 @@ SOURCES += main.cpp\ yesnopopupdlg.cpp \ configpanelbutton.cpp \ config.cpp \ -#basicsettingwindow.cpp \ programmingwindow.cpp \ primewindow.cpp \ cookpanelbutton.cpp \ @@ -122,7 +121,6 @@ SOURCES += main.cpp\ autocookselectionpopup.cpp \ autocookcheckwindow.cpp \ autocookcheckconfigwindow.cpp \ - #programmedcookpanelbutton.cpp \ configdemomodedlg.cpp \ demoicon.cpp \ halfenergyicon.cpp \ @@ -199,7 +197,6 @@ HEADERS += mainwindow.h \ yesnopopupdlg.h \ configpanelbutton.h \ config.h \ - #basicsettingwindow.h \ programmingwindow.h \ primewindow.h \ cookpanelbutton.h \ @@ -256,7 +253,6 @@ HEADERS += mainwindow.h \ autocookselectionpopup.h \ autocookcheckwindow.h \ autocookcheckconfigwindow.h \ - #programmedcookpanelbutton.h \ configdemomodedlg.h \ demoicon.h \ halfenergyicon.h \ @@ -310,7 +306,6 @@ FORMS += mainwindow.ui \ adjustmentwindow.ui \ yesnopopupdlg.ui \ configpanelbutton.ui \ - #basicsettingwindow.ui \ programmingwindow.ui \ primewindow.ui \ cookpanelbutton.ui \ @@ -355,7 +350,6 @@ FORMS += mainwindow.ui \ autocookselectionpopup.ui \ autocookcheckwindow.ui \ autocookcheckconfigwindow.ui \ - #programmedcookpanelbutton.ui \ configdemomodedlg.ui \ notipopupdlg.ui \ configsteamwashdlg.ui \ diff --git a/app/gui/oven_control/programmedcookpanelbutton.cpp b/app/gui/oven_control/programmedcookpanelbutton.cpp deleted file mode 100644 index aa27573..0000000 --- a/app/gui/oven_control/programmedcookpanelbutton.cpp +++ /dev/null @@ -1,175 +0,0 @@ -#include "programmedcookpanelbutton.h" -#include "ui_programmedcookpanelbutton.h" - -#include - -#include "soundplayer.h" - -ProgrammedCookPanelButton::ProgrammedCookPanelButton(CookRecord record, QWidget *parent) : - QWidget(parent), - record(record), - ui(new Ui::ProgrammedCookPanelButton), - rendered(false), - longPressEnabled(false) -{ - ui->setupUi(this); - - setText(record.name); - - foreach (QPushButton *button, findChildren()) - connect(button, &QPushButton::pressed, SoundPlayer::playClick); - - longPressedTimer.setSingleShot(true); - longPressedTimer.setInterval(3000); - connect(&longPressedTimer, SIGNAL(timeout()), SLOT(emitLongPressed())); -} - -ProgrammedCookPanelButton::~ProgrammedCookPanelButton() -{ - delete ui; -} - -void ProgrammedCookPanelButton::setText(QString text) -{ - ui->pushButton->setText(text); -} - -void ProgrammedCookPanelButton::showInfo() -{ - if (!rendered) - { - QPixmap p = CookHistory::render(record); - - label = new QLabel(this); - label->setPixmap(p); - label->setGeometry((width() - p.width()) / 2, 65, p.width(), p.height()); - } - - label->show(); - setMinimumHeight(ui->pushButton->height() + label->height()); -} - -void ProgrammedCookPanelButton::hideInfo() -{ - label->hide(); - setMinimumHeight(ui->pushButton->height()); -} - -void ProgrammedCookPanelButton::setLongPressEnabled(bool enabled) -{ - longPressEnabled = enabled; -} - -QPushButton *ProgrammedCookPanelButton::bar() -{ - return ui->pushButton; -} - -QPushButton *ProgrammedCookPanelButton::infoButton() -{ - return ui->showInfoButton; -} - -QPushButton *ProgrammedCookPanelButton::deleteButton() -{ - return ui->deleteButton; -} - -void ProgrammedCookPanelButton::setEnabled(bool enabled) -{ - ui->pushButton->setEnabled(enabled); - ui->showInfoButton->setEnabled(enabled); - ui->deleteButton->setEnabled(enabled); -} - -void ProgrammedCookPanelButton::keyPressEvent(QKeyEvent *event) -{ - switch (event->key()) - { - case 0x01000032: // Turn left - event->ignore(); - break; - case 0x01000031: // Push - pushed = focusWidget(); - if (pushed == ui->pushButton) - on_pushButton_pressed(); - break; - case 0x01000030: // Turn right - event->ignore(); - break; - } -} - -void ProgrammedCookPanelButton::keyReleaseEvent(QKeyEvent *event) -{ - switch (event->key()) - { - case 0x01000032: // Turn left - event->ignore(); - break; - case 0x01000031: // Push - if (pushed == ui->pushButton) - on_pushButton_released(); - - if (focusWidget() == pushed) - onEncoderClicked(pushed); - - pushed = NULL; - break; - case 0x01000030: // Turn right - event->ignore(); - break; - } -} - -void ProgrammedCookPanelButton::onEncoderLeft() -{ - -} - -void ProgrammedCookPanelButton::onEncoderRight() -{ - -} - -void ProgrammedCookPanelButton::onEncoderClicked(QWidget *clicked) -{ - QPushButton *b = qobject_cast(clicked); - if (b) - b->click(); -} - -void ProgrammedCookPanelButton::emitLongPressed() -{ - emitted = true; - emit longPressed(this); -} - -void ProgrammedCookPanelButton::on_pushButton_pressed() -{ - longPressedTimer.start(); - emitted = false; -} - -void ProgrammedCookPanelButton::on_pushButton_released() -{ - longPressedTimer.stop(); -} - -void ProgrammedCookPanelButton::on_pushButton_clicked() -{ - if (longPressEnabled && emitted) - return; - - emit clicked(this); -} - -void ProgrammedCookPanelButton::on_showInfoButton_clicked() -{ - emit infoClicked(this); -} - -void ProgrammedCookPanelButton::on_deleteButton_clicked() -{ - emit deleteClicked(this); -} diff --git a/app/gui/oven_control/programmedcookpanelbutton.h b/app/gui/oven_control/programmedcookpanelbutton.h deleted file mode 100644 index 4027338..0000000 --- a/app/gui/oven_control/programmedcookpanelbutton.h +++ /dev/null @@ -1,74 +0,0 @@ -#ifndef PROGRAMMEDCOOKPANELBUTTON_H -#define PROGRAMMEDCOOKPANELBUTTON_H - -#include -#include -#include -#include -#include - -#include "cookhistory.h" - -namespace Ui { -class ProgrammedCookPanelButton; -} - -class ProgrammedCookPanelButton : public QWidget -{ - Q_OBJECT - -public: - explicit ProgrammedCookPanelButton(CookRecord record, QWidget *parent = 0); - ~ProgrammedCookPanelButton(); - - void setText(QString text); - void showInfo(); - void hideInfo(); - - void setLongPressEnabled(bool enabled); - - QPushButton *bar(); - QPushButton *infoButton(); - QPushButton *deleteButton(); - - CookRecord record; - -public slots: - void setEnabled(bool enabled = true); - -protected: - void keyPressEvent(QKeyEvent *event); - void keyReleaseEvent(QKeyEvent *event); - -private: - Ui::ProgrammedCookPanelButton *ui; - - QTimer longPressedTimer; - bool rendered; - QLabel *label; - bool emitted; - bool longPressEnabled; - - QWidget *pushed = NULL; - - void onEncoderLeft(); - void onEncoderRight(); - void onEncoderClicked(QWidget *clicked); - -private slots: - void emitLongPressed(); - - void on_pushButton_pressed(); - void on_pushButton_released(); - void on_pushButton_clicked(); - void on_showInfoButton_clicked(); - void on_deleteButton_clicked(); - -signals: - void clicked(ProgrammedCookPanelButton *); - void infoClicked(ProgrammedCookPanelButton *); - void deleteClicked(ProgrammedCookPanelButton *); - void longPressed(ProgrammedCookPanelButton *); -}; - -#endif // PROGRAMMEDCOOKPANELBUTTON_H diff --git a/app/gui/oven_control/programmedcookpanelbutton.ui b/app/gui/oven_control/programmedcookpanelbutton.ui deleted file mode 100644 index fd5408f..0000000 --- a/app/gui/oven_control/programmedcookpanelbutton.ui +++ /dev/null @@ -1,118 +0,0 @@ - - - ProgrammedCookPanelButton - - - - 0 - 0 - 821 - 65 - - - - Form - - - QPushButton { -background-position: center; -background-repeat: no-repeat; -border: none; -} - - - - - 670 - 0 - 70 - 65 - - - - QPushButton { background-image: url(:/images/etc/bar_icon_01.png); } -QPushButton:pressed { background-image: url(:/images/etc/bar_icon_01_ov.png); } -QPushButton:focus { background-image: url(:/images/etc/bar_icon_01_ov.png); } - - - - - - true - - - true - - - - - - 750 - 0 - 60 - 65 - - - - QPushButton { background-image: url(:/images/etc/bar_icon_02.png); } -QPushButton:pressed { background-image: url(:/images/etc/bar_icon_02_ov.png); } -QPushButton:focus { background-image: url(:/images/etc/bar_icon_02_ov.png); } - - - - - - - - - 0 - 0 - 821 - 65 - - - - - 0 - 0 - - - - - 821 - 65 - - - - - 821 - 65 - - - - - Roboto - 11 - - - - QPushButton { -background-image: url(:/images/etc/bar_03.png); -color: white; -text-align: left; -padding: 0px 40px; -} -QPushButton:pressed { background-image: url(:/images/etc/bar_02.png); } -QPushButton:focus { background-image: url(:/images/etc/bar_02.png); } - - - - - - pushButton - showInfoButton - deleteButton - - - -