diff --git a/soft/thermostat/inc/edit_dlg.h b/soft/thermostat/inc/edit_dlg.h index d20ad4c..2222fb3 100644 --- a/soft/thermostat/inc/edit_dlg.h +++ b/soft/thermostat/inc/edit_dlg.h @@ -36,6 +36,7 @@ private: private slots: void save(void); + void add(void); void reject(void); void delete_prog_clicked(void); diff --git a/soft/thermostat/src/edit_dlg.cpp b/soft/thermostat/src/edit_dlg.cpp index e02ac61..d0d99b4 100644 --- a/soft/thermostat/src/edit_dlg.cpp +++ b/soft/thermostat/src/edit_dlg.cpp @@ -65,6 +65,7 @@ EditDlg::EditDlg(int idx, QWidget *parent, Qt::WindowFlags f) : QWidget(parent, upperLayout->addWidget(&m_default_temperature); QPushButton *ok_btn = new QPushButton(tr("Ok"), this); + QPushButton *add_btn = new QPushButton(tr("Add"), this); QPushButton *cancel_btn = new QPushButton(tr("Cancel"), this); @@ -73,17 +74,21 @@ EditDlg::EditDlg(int idx, QWidget *parent, Qt::WindowFlags f) : QWidget(parent, QSizePolicy::PushButton); set_font(ok_btn); + set_font(add_btn); set_font(cancel_btn); ok_btn->setSizePolicy(*szPolicy); + add_btn->setSizePolicy(*szPolicy); cancel_btn->setSizePolicy(*szPolicy); connect(ok_btn, SIGNAL(clicked(void)), this, SLOT(save(void))); + connect(add_btn, SIGNAL(clicked(void)), this, SLOT(add(void))); connect(cancel_btn, SIGNAL(clicked(void)), this, SLOT(reject(void))); QHBoxLayout *btnLayout = new QHBoxLayout; btnLayout->addWidget(cancel_btn); + btnLayout->addWidget(add_btn); btnLayout->addWidget(ok_btn); QVBoxLayout *topLayout = new QVBoxLayout; @@ -204,6 +209,10 @@ void EditDlg::reject(void) emit close_edit_dlg(); } +void EditDlg::add(void) +{ +} + void EditDlg::delete_prog_clicked(void) { QLayoutItem *lineItem, *item;