<commit_before>#include "dlg_main.h"

#include "control.h"
#include "hardware.h"

#include <QtGui>
#include <QApplication>

MainDlg::MainDlg(QWidget *parent)
    : QWidget(parent)
{
	ui.setupUi(this);

	Qt::WindowFlags flags = windowFlags();
	flags |= Qt::FramelessWindowHint;
	setWindowFlags(flags);

	char buf[256];
	sprintf(buf, "%i%%", control().wVelFanCoil);
	ui.tlVelFanCoil->setText(buf);

	connect(&screenUpdate, SIGNAL( timeout(void) ), this, SLOT ( updateScreen(void) ));
	screenUpdate.setSingleShot(false);
	screenUpdate.start(100);
}

void MainDlg::on_pbNotte_toggled(bool checked)
{
	if (checked) {
		ui.pbNotte->setPalette(QPalette(QColor(255, 64, 64)));
	} else {
		ui.pbNotte->setPalette(QApplication::palette());
	}

	QMutexLocker lock(&control().mFields);
	control().xRiscaldaNotte = checked;
}

void MainDlg::on_pbGiorno_toggled(bool checked)
{
	if (checked) {
		ui.pbGiorno->setPalette(QPalette(QColor(255, 64, 64)));<commit_msg>fix "pompa auto ON" all'accensione<commit_after>#include "dlg_main.h"

#include "control.h"
#include "hardware.h"

#include <QtGui>
#include <QApplication>

MainDlg::MainDlg(QWidget *parent)
    : QWidget(parent)
{
	ui.setupUi(this);

	Qt::WindowFlags flags = windowFlags();
	flags |= Qt::FramelessWindowHint;
	setWindowFlags(flags);

	ui.pbRiscPompaCalore->setChecked(true);

	char buf[256];
	sprintf(buf, "%i%%", control().wVelFanCoil);
	ui.tlVelFanCoil->setText(buf);

	connect(&screenUpdate, SIGNAL( timeout(void) ), this, SLOT ( updateScreen(void) ));
	screenUpdate.setSingleShot(false);
	screenUpdate.start(100);
}

void MainDlg::on_pbNotte_toggled(bool checked)
{
	if (checked) {
		ui.pbNotte->setPalette(QPalette(QColor(255, 64, 64)));
	} else {
		ui.pbNotte->setPalette(QApplication::palette());
	}

	QMutexLocker lock(&control().mFields);
	control().xRiscaldaNotte = checked;
}

void MainDlg::on_pbGiorno_toggled(bool checked)
{
	if (checked) {
		ui.pbGiorno->setPalette(QPalette(QColor(255, 64, 64)));
{'fraction_non_alphanumeric': 0.1677715451300357, 'fraction_numerical': 0.02039775624681285, 'mean_word_length': 6.604651162790698, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 16, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '5341874', 'n_tokens_mistral': 816, 'n_tokens_neox': 774, 'n_words': 116}