aboutsummaryrefslogtreecommitdiffstats
path: root/lang/qt/src/quickjob.h
diff options
context:
space:
mode:
authorIngo Klöcker <[email protected]>2024-08-06 16:57:14 +0200
committerIngo Klöcker <[email protected]>2024-08-07 10:53:21 +0200
commit63822343dfaac8b638ef475d441c4379da3a9804 (patch)
treea72fc7cdfea56eed20c09aadc1ab31ac755edbcc /lang/qt/src/quickjob.h
parentcpp: Add support for setting owner trust and for disabling keys (diff)
downloadgpgme-63822343dfaac8b638ef475d441c4379da3a9804.tar.gz
gpgme-63822343dfaac8b638ef475d441c4379da3a9804.zip
qt: Support disabling and enabling of keys
* lang/qt/src/Makefile.am: Add new files. * lang/qt/src/job.cpp (QuickJob): Move definition of constructor and destructor and inclusion of the moc file to quickjob.cpp. * lang/qt/src/qgpgmequickjob.cpp (class QGpgMEQuickJobPrivate): New. (QGpgMEQuickJob::QGpgMEQuickJob): Instantiate private job class. (set_key_enabled): New. * lang/qt/src/quickjob.cpp: New. * lang/qt/src/quickjob.h (class QuickJob): Add member function startSetKeyEnabled. * lang/qt/src/quickjob_p.h: New. * lang/qt/tests/Makefile.am: Add new test for Qt 5 and Qt 6. * lang/qt/tests/t-disablekey.cpp: New. -- GnuPG-bug-id: 7239
Diffstat (limited to 'lang/qt/src/quickjob.h')
-rw-r--r--lang/qt/src/quickjob.h8
1 files changed, 8 insertions, 0 deletions
diff --git a/lang/qt/src/quickjob.h b/lang/qt/src/quickjob.h
index 049438d6..df8ac2b5 100644
--- a/lang/qt/src/quickjob.h
+++ b/lang/qt/src/quickjob.h
@@ -84,6 +84,14 @@ public:
/** Start --quick-add-adsk */
virtual void startAddAdsk(const GpgME::Key &key, const char *adsk) = 0;
+ /**
+ * Starts the operation to enable or disable the OpenPGP key \a key.
+ * If \a enabled is \c true then the key is enabled. Otherwise, the key is disabled.
+ *
+ * \note Requires gpg 2.4.6.
+ */
+ GpgME::Error startSetKeyEnabled(const GpgME::Key &key, bool enabled);
+
Q_SIGNALS:
void result(const GpgME::Error &error,
const QString &auditLogAsHtml = QString(), const GpgME::Error &auditLogError = GpgME::Error());