Mercurial > trustbridge
comparison ui/statusdialog.cpp @ 211:be628d261617
Added new status dialog.
author | Raimund Renkert <rrenkert@intevation.de> |
---|---|
date | Thu, 27 Mar 2014 09:06:35 +0100 |
parents | |
children | 17e1c8f37d72 |
comparison
equal
deleted
inserted
replaced
210:9c51c472e596 | 211:be628d261617 |
---|---|
1 #include "statusdialog.h" | |
2 #include <QDebug> | |
3 #include <QVBoxLayout> | |
4 #include <QTextEdit> | |
5 #include <QPushButton> | |
6 | |
7 StatusDialog::StatusDialog(QMainWindow *parent) : | |
8 QDialog(parent) | |
9 { | |
10 setupGUI(); | |
11 } | |
12 | |
13 void StatusDialog::setupGUI() | |
14 { | |
15 QVBoxLayout *mainLayout = new QVBoxLayout(this); | |
16 QTextEdit *helpText = new QTextEdit; | |
17 helpText->setReadOnly(true); | |
18 QString dummyText = tr("The following certificates are successfully installed:\r"); | |
19 dummyText.append(tr("* Email CA 2013\r")); | |
20 dummyText.append(tr("* Server CA 2010\r")); | |
21 dummyText.append(tr("\rThe following certificates are successfully removed:\r")); | |
22 dummyText.append(tr("* Email CA 2010\r")); | |
23 dummyText.append(tr("\rErrors while processing certificates:\r")); | |
24 dummyText.append(tr("* PCA-1-Verwaltung-08\r")); | |
25 helpText->setPlainText(dummyText); | |
26 | |
27 QHBoxLayout *buttonLayout = new QHBoxLayout; | |
28 QPushButton *closeButton = new QPushButton(tr("Close")); | |
29 connect(closeButton, SIGNAL(clicked()), this, SLOT(close())); | |
30 buttonLayout->insertStretch(0, 10); | |
31 buttonLayout->addWidget(closeButton); | |
32 | |
33 mainLayout->addWidget(helpText); | |
34 mainLayout->addLayout(buttonLayout); | |
35 } |