aheinecke@404: /* Copyright (C) 2014 by Bundesamt für Sicherheit in der Informationstechnik aheinecke@404: * Software engineering by Intevation GmbH aheinecke@404: * aheinecke@404: * This file is Free Software under the GNU GPL (v>=2) aheinecke@404: * and comes with ABSOLUTELY NO WARRANTY! aheinecke@404: * See LICENSE.txt for details. aheinecke@404: */ rrenkert@199: #include "aboutdialog.h" rrenkert@427: #include rrenkert@199: #include rrenkert@199: #include rrenkert@427: #include rrenkert@199: #include rrenkert@427: #include rrenkert@199: rrenkert@199: AboutDialog::AboutDialog(QMainWindow *parent) : rrenkert@199: QDialog(parent) rrenkert@199: { rrenkert@427: setWindowTitle("About TrustBridge"); rrenkert@199: setupGUI(); rrenkert@199: } rrenkert@199: rrenkert@199: void AboutDialog::setupGUI() rrenkert@199: { rrenkert@199: QVBoxLayout *mainLayout = new QVBoxLayout(this); rrenkert@427: QHBoxLayout *headerLayout = new QHBoxLayout; rrenkert@427: QVBoxLayout *headerTextLayout = new QVBoxLayout; rrenkert@427: QVBoxLayout *centerLayout = new QVBoxLayout; rrenkert@427: QHBoxLayout *bottomLayout = new QHBoxLayout; rrenkert@199: rrenkert@427: QLabel *title = new QLabel("

" + tr("TrustBridge") + "

"); rrenkert@427: QString version = tr("Version: "); rrenkert@427: version.append(QApplication::applicationVersion()); rrenkert@427: QLabel *appVersion = new QLabel(version); rrenkert@568: appVersion->setTextInteractionFlags( rrenkert@568: Qt::TextSelectableByMouse | rrenkert@568: Qt::TextSelectableByKeyboard); rrenkert@427: rrenkert@427: headerTextLayout->addWidget(title); rrenkert@427: headerTextLayout->addWidget(appVersion); rrenkert@427: headerLayout->addLayout(headerTextLayout); rrenkert@427: headerLayout->insertStretch(2, 10); rrenkert@427: aheinecke@531: QLabel *textDesc = new QLabel(tr("TrustBridge is a root certificate" andre@807: " installer for Windows and GNU/Linux.
") + andre@807: tr("The root certificate lists are managed" andre@807: " by the German " andre@807: "Federal Office for Information Security (BSI).

") + andre@807: tr("The software was developed by the companies" andre@807: " Intevation GmbH and " andre@807: " DN-Systems GmbH,
" andre@807: " contracted by the German Federal Office for Information Security (BSI).

") + andre@807: tr("TrustBridge is Free Software licensed" andre@807: " under GNU GPL v2+.

Copyright (C) 2014 by Bundesamt für Sicherheit" andre@807: " in der Informationstechnik")); andre@807: textDesc->setTextFormat(Qt::RichText); rrenkert@568: textDesc->setTextInteractionFlags( rrenkert@568: Qt::TextSelectableByMouse | rrenkert@568: Qt::TextSelectableByKeyboard); emanuel@843: textDesc->setOpenExternalLinks(true); rrenkert@427: rrenkert@427: centerLayout->addWidget(textDesc); rrenkert@428: centerLayout->insertStretch(8, 10); rrenkert@427: rrenkert@199: QPushButton *closeButton = new QPushButton(tr("Close")); rrenkert@199: connect(closeButton, SIGNAL(clicked()), this, SLOT(close())); rrenkert@427: bottomLayout->insertStretch(0, 10); rrenkert@427: bottomLayout->addWidget(closeButton); rrenkert@199: rrenkert@427: QFrame *bottomSeparator = new QFrame(); rrenkert@427: bottomSeparator->setFrameShape(QFrame::HLine); rrenkert@427: bottomSeparator->setFrameShadow(QFrame::Sunken); rrenkert@427: mainLayout->addLayout(headerLayout); rrenkert@427: mainLayout->addLayout(centerLayout); rrenkert@427: mainLayout->addWidget(bottomSeparator); rrenkert@427: mainLayout->addLayout(bottomLayout); rrenkert@199: }