From 1db778e4481eeab3e65d157240fbe963a8113f49 Mon Sep 17 00:00:00 2001 From: nils Date: Mon, 23 Apr 2012 22:37:11 +0000 Subject: tabbed about dialog with translator file seperated, but of the encoding of the TRANSLATOR file still has to be taken care of git-svn-id: http://cpunk.de/svn/src/gpg4usb/trunk@902 34ebc366-c3a9-4b3c-9f84-69acf7962910 --- mainwindow.cpp | 39 +-------------------------------------- 1 file changed, 1 insertion(+), 38 deletions(-) (limited to 'mainwindow.cpp') diff --git a/mainwindow.cpp b/mainwindow.cpp index 9f78a08..41db36f 100644 --- a/mainwindow.cpp +++ b/mainwindow.cpp @@ -626,44 +626,7 @@ void MainWindow::closeEvent(QCloseEvent *event) void MainWindow::about() { - QPixmap *pixmap = new QPixmap(":gpg4usb-logo.png"); - QString *title = new QString(tr("About ") + qApp->applicationName()); - QString *text = new QString("

" + qApp->applicationName() + " " - + qApp->applicationVersion() + "

" - + tr("
This application allows simple encryption
" - "and decryption of text messages or files.
" - "It's licensed under the GPL v3

" - "Developer:
" - "Bene, Heimer, Juergen, Nils, Ubbo

" - "Translation:
" - "%1

" - "If you have any questions or suggestions have a look
" - "at our " - "contact page or send a mail to our
mailing list at" - " gpg4usb@gzehn.de.").arg("Viriato/Phol (es),
Serse (it), Russell (my),
Alessandro (pt_br), Kirill (ru), Tom (vi)") - + tr("

Built with Qt ") + qVersion() - + tr(" and GPGME ") + GpgME::GpgContext::getGpgmeVersion() +"
"); - - QDialog *dialog = new QDialog(this); - dialog->setWindowTitle(*title); - QPushButton *closeButton = new QPushButton(tr("&Close")); - connect(closeButton, SIGNAL(clicked()), dialog, SLOT(close())); - - QGridLayout *layout = new QGridLayout(dialog); - QLabel *pixmapLabel = new QLabel(); - pixmapLabel->setPixmap(*pixmap); - layout->addWidget(pixmapLabel, 0, 0, 1, -1, Qt::AlignCenter); - QLabel *aboutLabel = new QLabel(); - aboutLabel->setText(*text); - aboutLabel->setOpenExternalLinks(true); - layout->addWidget(aboutLabel, 1, 0, 1, -1); - layout->addItem(new QSpacerItem(20, 10, QSizePolicy::Minimum, - QSizePolicy::Fixed), 2, 1, 1, 1); - layout->addItem(new QSpacerItem(20, 20, QSizePolicy::Expanding), 3, 0, 1, 1); - layout->addWidget(closeButton, 3, 1, 1, 1); - layout->addItem(new QSpacerItem(20, 20, QSizePolicy::Expanding), 3, 2, 1, 1); - - dialog->exec(); + new AboutDialog(this); } void MainWindow::openTranslate() -- cgit v1.2.3