Thermostat pour piloter jusqu'à 4 radiateurs avec fil pilote
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

50 lines
935 B

  1. // SPDX-License-Identifier: GPL-3.0-or-later
  2. /*
  3. * Qt mutizone MQTT thermostat
  4. *
  5. * Copyright (C) 2020 Richard Genoud
  6. *
  7. */
  8. #ifndef EDITDLG_H
  9. #define EDITDLG_H
  10. #include <QVector>
  11. #include <QWidget>
  12. #include <QObject>
  13. #include <QSpinBox>
  14. #include <QDateTime>
  15. #include <QVBoxLayout>
  16. #include <QDoubleSpinBox>
  17. class EditDlg : public QWidget
  18. {
  19. Q_OBJECT
  20. public:
  21. EditDlg(int idx, QWidget *parent = Q_NULLPTR,
  22. Qt::WindowFlags f = Qt::WindowFlags());
  23. ~EditDlg();
  24. private:
  25. void set_font(QWidget *widget);
  26. QHBoxLayout *add_prog_layout(const struct Program *p, int idx);
  27. QDoubleSpinBox m_default_temperature;
  28. QVBoxLayout *m_progsLayout;
  29. QVector<struct Program> m_progs;
  30. int m_idx; // room index
  31. private slots:
  32. void save(void);
  33. void add(void);
  34. void reject(void);
  35. void delete_prog_clicked(void);
  36. signals:
  37. void close_edit_dlg(void);
  38. };
  39. #endif // EDITDLG_H
  40. /* vim: set tabstop=8 shiftwidth=8 softtabstop=0 noexpandtab: */