added version identifier to about dialog
This commit is contained in:
+28
-22
@@ -24,32 +24,38 @@
|
|||||||
#include <QLabel>
|
#include <QLabel>
|
||||||
#include <QDialogButtonBox>
|
#include <QDialogButtonBox>
|
||||||
|
|
||||||
|
#include "oliveglobal.h"
|
||||||
|
|
||||||
AboutDialog::AboutDialog(QWidget *parent) :
|
AboutDialog::AboutDialog(QWidget *parent) :
|
||||||
QDialog(parent)
|
QDialog(parent)
|
||||||
{
|
{
|
||||||
setWindowTitle("About Olive");
|
setWindowTitle("About Olive");
|
||||||
|
|
||||||
QVBoxLayout* layout = new QVBoxLayout(this);
|
QVBoxLayout* layout = new QVBoxLayout(this);
|
||||||
layout->setSpacing(20);
|
layout->setSpacing(20);
|
||||||
|
|
||||||
QLabel* label =
|
QLabel* label =
|
||||||
new QLabel("<html><head/><body>"
|
new QLabel(QString("<html><head/><body>"
|
||||||
"<p><img src=\":/icons/olive-splash.png\"/></p>"
|
"<p><img src=\":/icons/olive-splash.png\"/></p>"
|
||||||
"<p><a href=\"https://www.olivevideoeditor.org/\">"
|
"<p><a href=\"https://www.olivevideoeditor.org/\">"
|
||||||
"<span style=\" text-decoration: underline; color:#007af4;\">"
|
"<span style=\" text-decoration: underline; color:#007af4;\">"
|
||||||
"https://www.olivevideoeditor.org/"
|
"https://www.olivevideoeditor.org/"
|
||||||
"</span></a></p><p>"
|
"</span></a></p>"
|
||||||
+ tr("Olive is a non-linear video editor. This software is free and protected by the GNU GPL.")
|
"<p><b>%1</b></p>" // AppName (version identifier)
|
||||||
+ "</p><p>"
|
"<p>%2</p>" // First statement
|
||||||
+ tr("Olive Team is obliged to inform users that Olive source code is available for download from its website.")
|
"<p>%3</p>" // Second statement
|
||||||
+ "</p></body></html>", this);
|
"</body></html>").arg(olive::AppName,
|
||||||
label->setAlignment(Qt::AlignCenter);
|
tr("Olive is a non-linear video editor. This software is free and "
|
||||||
label->setWordWrap(true);
|
"protected by the GNU GPL."),
|
||||||
layout->addWidget(label);
|
tr("Olive Team is obliged to inform users that Olive source code is "
|
||||||
|
"available for download from its website.")), this);
|
||||||
|
label->setAlignment(Qt::AlignCenter);
|
||||||
|
label->setWordWrap(true);
|
||||||
|
layout->addWidget(label);
|
||||||
|
|
||||||
QDialogButtonBox* buttons = new QDialogButtonBox(QDialogButtonBox::Ok, this);
|
QDialogButtonBox* buttons = new QDialogButtonBox(QDialogButtonBox::Ok, this);
|
||||||
buttons->setCenterButtons(true);
|
buttons->setCenterButtons(true);
|
||||||
layout->addWidget(buttons);
|
layout->addWidget(buttons);
|
||||||
|
|
||||||
connect(buttons, SIGNAL(accepted()), this, SLOT(accept()));
|
connect(buttons, SIGNAL(accepted()), this, SLOT(accept()));
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -25,10 +25,10 @@
|
|||||||
|
|
||||||
class AboutDialog : public QDialog
|
class AboutDialog : public QDialog
|
||||||
{
|
{
|
||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
|
|
||||||
public:
|
public:
|
||||||
explicit AboutDialog(QWidget *parent = 0);
|
explicit AboutDialog(QWidget *parent = nullptr);
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif // ABOUTDIALOG_H
|
#endif // ABOUTDIALOG_H
|
||||||
|
|||||||
Reference in New Issue
Block a user