diff options
author | Ingo Klöcker <[email protected]> | 2022-01-04 14:38:49 +0000 |
---|---|---|
committer | Ingo Klöcker <[email protected]> | 2022-01-04 14:44:16 +0000 |
commit | 4e80563fabfdf1d1c136d65252e5353fdd1e9092 (patch) | |
tree | f1edc3ecd890387f94e2bb5ef4b14b88f4394906 /lang/qt/src/protocol.h | |
parent | cpp: Allow export of secret keys (diff) | |
download | gpgme-4e80563fabfdf1d1c136d65252e5353fdd1e9092.tar.gz gpgme-4e80563fabfdf1d1c136d65252e5353fdd1e9092.zip |
qt: Use QGpgMEExportJob also for export of secret keys
* lang/qt/src/protocol.h (Protocol::secretKeyExportJob): Document
charset argument as ignored.
* lang/qt/src/protocol_p.h (Protocol::secretKeyExportJob): Use
QGpgMEExportJob instead of QGpgMESecretKeyExportJob.
* lang/qt/src/qgpgmeexportjob.h (class QGpgMEExportJob): Add c'tor
taking an export mode. Add member m_exportMode. Rename member m_flags to
m_additionalExportModeFlags.
(QGpgMEExportJob::~QGpgMEExportJob): Mark as override.
* lang/qt/src/qgpgmeexportjob.cpp (QGpgMEExportJob::QGpgMEExportJob):
Delegate to new c'tor. Implement new c'tor.
(QGpgMEExportJob::~QGpgMEExportJob): Use default.
(export_qba): Rename argument flags to mode.
(QGpgMEExportJob::start): Pass combination of export mode and additional
mode flags to export_qba.
(QGpgMEExportJob::setExportFlags): Adapt to renaming of member.
* lang/qt/tests/run-exportjob.cpp: New.
--
This change makes it possible to export secret OpenPGP keys.
GnuPG-bug-id: 5757
Diffstat (limited to 'lang/qt/src/protocol.h')
-rw-r--r-- | lang/qt/src/protocol.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lang/qt/src/protocol.h b/lang/qt/src/protocol.h index cffd53b2..35789414 100644 --- a/lang/qt/src/protocol.h +++ b/lang/qt/src/protocol.h @@ -126,8 +126,8 @@ public: virtual ImportJob *importJob() const = 0; virtual ImportFromKeyserverJob *importFromKeyserverJob() const = 0; virtual ExportJob *publicKeyExportJob(bool armor = false) const = 0; - // @param charset the encoding of the passphrase in the exported file - virtual ExportJob *secretKeyExportJob(bool armor = false, const QString &charset = QString()) const = 0; + // the second parameter is ignored; the passphrase in the exported file is always utf-8 encoded + virtual ExportJob *secretKeyExportJob(bool armor = false, const QString & = QString()) const = 0; virtual DownloadJob *downloadJob(bool armor = false) const = 0; virtual DeleteJob *deleteJob() const = 0; virtual SignEncryptJob *signEncryptJob(bool armor = false, bool textMode = false) const = 0; |