-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathAboutDialog.cpp
More file actions
37 lines (32 loc) · 888 Bytes
/
AboutDialog.cpp
File metadata and controls
37 lines (32 loc) · 888 Bytes
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
29
30
31
32
33
34
35
36
37
#include "AboutDialog.h"
#include "ui_AboutDialog.h"
#include "Settings.h"
#include "HelperFunc.h"
#include <QTabBar>
#if defined(_MSC_VER) && (_MSC_VER >= 1600)
# pragma execution_character_set("utf-8")
#endif
AboutDialog::AboutDialog(QWidget *parent) :
QDialog(parent),
ui(new Ui::AboutDialog)
{
ui->setupUi(this);
setWindowFlags(windowFlags()&~Qt::WindowContextHelpButtonHint);
setWindowTitle(tr("关于"));
ui->labelVersion->setText(tr("版本:%1").arg(EASYGO_VERSION));
#ifndef ENABLE_SPONSOR
const int sponsorIndex = ui->tabWidget->indexOf(ui->tabSponsor);
if (sponsorIndex >= 0)
{
ui->tabWidget->removeTab(sponsorIndex);
delete ui->tabSponsor;
}
ui->tabWidget->tabBar()->hide();
ui->tabWidget->setGeometry(0, 0, 420, 270);
setFixedSize(420, 270);
#endif
}
AboutDialog::~AboutDialog()
{
delete ui;
}