changeset 368:f9c98f9e9f76

Show the new dialog on save button click.
author Raimund Renkert <rrenkert@intevation.de>
date Tue, 15 Apr 2014 09:44:32 +0200
parents 9491782a8f5a
children 78eec57bc133
files ui/CMakeLists.txt ui/administratorwindow.cpp ui/administratorwindow.h
diffstat 3 files changed, 10 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/ui/CMakeLists.txt	Tue Apr 15 09:43:53 2014 +0200
+++ b/ui/CMakeLists.txt	Tue Apr 15 09:44:32 2014 +0200
@@ -33,6 +33,7 @@
     ${CMAKE_CURRENT_SOURCE_DIR}/certificatetablemodel.cpp
     ${CMAKE_CURRENT_SOURCE_DIR}/certificatetabledelegate.cpp
     ${CMAKE_CURRENT_SOURCE_DIR}/createinstallerdialog.cpp
+    ${CMAKE_CURRENT_SOURCE_DIR}/createcertlistdialog.cpp
     ${CERTIFICATELIST_SOURCES}
 )
 
--- a/ui/administratorwindow.cpp	Tue Apr 15 09:43:53 2014 +0200
+++ b/ui/administratorwindow.cpp	Tue Apr 15 09:44:32 2014 +0200
@@ -17,6 +17,7 @@
 
 #include "certificatetabledelegate.h"
 #include "createinstallerdialog.h"
+#include "createcertlistdialog.h"
 
 AdministratorWindow::AdministratorWindow() {
     createActions();
@@ -93,6 +94,7 @@
     // The buttons.
     bottomLayout->setAlignment(Qt::AlignBottom);
     saveButton = new QPushButton(tr("Save"));
+    connect(saveButton, SIGNAL(clicked()), this, SLOT(saveCertificateFile()));
     loadButton = new QPushButton(tr("Load"));
     connect(loadButton, SIGNAL(clicked()), this, SLOT(loadCertificateFile()));
     addButton = new QPushButton(tr("Add"));
@@ -131,6 +133,12 @@
     }
 }
 
+void AdministratorWindow::saveCertificateFile()
+{
+    CreateCertListDialog *dialog = new CreateCertListDialog(this);
+    dialog->show();
+}
+
 void AdministratorWindow::addCertificates()
 {
     QString certFile = QFileDialog::getOpenFileName(
--- a/ui/administratorwindow.h	Tue Apr 15 09:43:53 2014 +0200
+++ b/ui/administratorwindow.h	Tue Apr 15 09:44:32 2014 +0200
@@ -31,6 +31,7 @@
     void showHelp();
     void showAbout();
     void loadCertificateFile();
+    void saveCertificateFile();
     void addCertificates();
 
 private:

http://wald.intevation.org/projects/trustbridge/