1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28
|
class Temperature : public QMainWindow
{
public:
Temperature(QWidget* parent =0, Qt::WindowFlags flags =0);
private:
QTimer* timer_debug;
double tempActuelle;
double tempDesiree;
private slots:
void ecoute();
};
Temperature::Temperature(QWidget* parent, Qt::WindowFlags flags):
QMainWindow(parent, flags)
{
setFixedSize(300,200);
timer_debug = new QTimer(this);
connect(timer_debug, SIGNAL(timeout()), this, SLOT(ecoute()));
timer_debug->start(1000);
}
void Temperature::ecoute()
{
QMessageBox::information(this, "Simulateur Temperature", "Bouh!");
} |