File: aboutdialog.cpp

package info (click to toggle)
nageru 2.3.2-1
  • links: PTS
  • area: main
  • in suites: forky, sid
  • size: 3,120 kB
  • sloc: cpp: 39,131; perl: 94; sh: 18; makefile: 4
file content (21 lines) | stat: -rw-r--r-- 552 bytes parent folder | download | duplicates (5)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
#include "aboutdialog.h"

#include <QDialogButtonBox>

#include "ui_aboutdialog.h"

using namespace std;

AboutDialog::AboutDialog(const string &program, const string &subheading)
	: ui(new Ui::AboutDialog)
{
	ui->setupUi(this);
	QString str = ui->header->text();
	str.replace("@NAGERU_VERSION@", NAGERU_VERSION);
	str.replace("@PROGRAM@", QString::fromStdString(program));
	str.replace("@SUBHEADING@", QString::fromStdString(subheading));
	ui->header->setText(str);

	connect(ui->button_box, &QDialogButtonBox::accepted, [this]{ this->close(); });
}