diff options
| author | Felix (xq) Queißner <git@mq32.de> | 2020-06-22 21:10:04 +0200 |
|---|---|---|
| committer | Felix (xq) Queißner <git@mq32.de> | 2020-06-22 21:10:04 +0200 |
| commit | 75ec461eeaa851cb5c53f4cfffc434e3e529ed1d (patch) | |
| tree | 3944737340718ca3675381aa06636045d397e780 /src/dialogs/certificateiodialog.hpp | |
| parent | 8dbfb0890560fd1cd698d06fa05ac868c4db8576 (diff) | |
| download | kristall-75ec461eeaa851cb5c53f4cfffc434e3e529ed1d.tar.gz | |
Restructures the project source and cleans up a bit
Diffstat (limited to 'src/dialogs/certificateiodialog.hpp')
| -rw-r--r-- | src/dialogs/certificateiodialog.hpp | 50 |
1 files changed, 50 insertions, 0 deletions
diff --git a/src/dialogs/certificateiodialog.hpp b/src/dialogs/certificateiodialog.hpp new file mode 100644 index 0000000..590b282 --- /dev/null +++ b/src/dialogs/certificateiodialog.hpp @@ -0,0 +1,50 @@ +#ifndef CERTIFICATEIODIALOG_HPP +#define CERTIFICATEIODIALOG_HPP + +#include <QDialog> +#include <QSsl> + +namespace Ui { +class CertificateIoDialog; +} + +class CertificateIoDialog : public QDialog +{ + Q_OBJECT +public: + enum IoMode { + Import, + Export + }; +public: + explicit CertificateIoDialog(QWidget *parent = nullptr); + ~CertificateIoDialog(); + + IoMode mode() const { return this->current_mode; } + void setIoMode(IoMode mode); + + QSsl::KeyAlgorithm keyAlgorithm() const; + void setKeyAlgorithm(QSsl::KeyAlgorithm alg); + + QString keyFileName() const; + QString certificateFileName() const; + +private slots: + void on_select_certificate_file_button_clicked(); + + void on_select_key_file_button_clicked(); + + void on_certificate_file_name_textChanged(const QString &arg1); + + void on_key_file_name_textChanged(const QString &arg1); + +private: + void updateUI(); + +private: + Ui::CertificateIoDialog *ui; + + IoMode current_mode; +}; + +#endif // CERTIFICATEIODIALOG_HPP |
