Home GnuPG
Diffusion GPGME 4e80563fabfd

qt: Use QGpgMEExportJob also for export of secret keys

Description

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: T5757

Details

Provenance
ikloeckerAuthored on Jan 4 2022, 3:38 PM
Parents
rM3da06d1096ee: cpp: Allow export of secret keys
Branches
Unknown
Tags
Unknown
Tasks
Unknown Object (Maniphest Task)