2014-01-17 18:36:58 +00:00
|
|
|
#include <stdio.h>
|
|
|
|
#include <stdlib.h>
|
|
|
|
|
|
|
|
#include "main.h"
|
|
|
|
#include "licensedialog.h"
|
|
|
|
#include "ui_licensedialog.h"
|
|
|
|
|
2014-01-27 06:24:29 +00:00
|
|
|
#include "../node/Constants.hpp"
|
|
|
|
|
2014-01-17 18:36:58 +00:00
|
|
|
LicenseDialog::LicenseDialog(QWidget *parent) :
|
|
|
|
QDialog(parent),
|
|
|
|
ui(new Ui::LicenseDialog)
|
|
|
|
{
|
|
|
|
ui->setupUi(this);
|
2014-01-27 06:24:29 +00:00
|
|
|
|
|
|
|
#ifdef __WINDOWS__
|
|
|
|
QWidgetList widgets = this->findChildren<QWidget*>();
|
|
|
|
foreach(QWidget *widget, widgets) {
|
|
|
|
QFont font(widget->font());
|
|
|
|
font.setPointSizeF(font.pointSizeF() * 0.75);
|
|
|
|
widget->setFont(font);
|
|
|
|
}
|
|
|
|
#endif
|
2014-01-17 18:36:58 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
LicenseDialog::~LicenseDialog()
|
|
|
|
{
|
|
|
|
delete ui;
|
|
|
|
}
|
|
|
|
|
|
|
|
void LicenseDialog::on_buttonBox_accepted()
|
|
|
|
{
|
|
|
|
settings->setValue("acceptedLicenseV1",true);
|
|
|
|
settings->sync();
|
|
|
|
|
|
|
|
this->setResult(QDialog::Accepted);
|
|
|
|
}
|
|
|
|
|
|
|
|
void LicenseDialog::on_buttonBox_rejected()
|
|
|
|
{
|
|
|
|
::exit(0);
|
|
|
|
}
|