aboutsummaryrefslogtreecommitdiffstats
path: root/src/core/function/gpg/GpgKeyOpera.h
diff options
context:
space:
mode:
authorsaturneric <[email protected]>2025-02-01 23:21:59 +0000
committersaturneric <[email protected]>2025-02-01 23:21:59 +0000
commitd06c31abe7e2540518c4d3471acd381edfababa3 (patch)
tree7efec63216119a6a3b77208328ba59419acd905f /src/core/function/gpg/GpgKeyOpera.h
parentfix: issues found on unit test mode (diff)
downloadGpgFrontend-d06c31abe7e2540518c4d3471acd381edfababa3.tar.gz
GpgFrontend-d06c31abe7e2540518c4d3471acd381edfababa3.zip
feat: upgrade KeyGenDialog to meet easy and advanced requirements
Diffstat (limited to 'src/core/function/gpg/GpgKeyOpera.h')
-rw-r--r--src/core/function/gpg/GpgKeyOpera.h21
1 files changed, 12 insertions, 9 deletions
diff --git a/src/core/function/gpg/GpgKeyOpera.h b/src/core/function/gpg/GpgKeyOpera.h
index 0084d473..d724f5f8 100644
--- a/src/core/function/gpg/GpgKeyOpera.h
+++ b/src/core/function/gpg/GpgKeyOpera.h
@@ -31,6 +31,7 @@
#include <functional>
#include "core/function/gpg/GpgContext.h"
+#include "core/function/gpg/GpgKeyGetter.h"
#include "core/typedef/GpgTypedef.h"
namespace GpgFrontend {
@@ -114,7 +115,7 @@ class GPGFRONTEND_CORE_EXPORT GpgKeyOpera
* @param result
* @return GpgFrontend::GpgError
*/
- void GenerateKey(const std::shared_ptr<GenKeyInfo>&,
+ void GenerateKey(const QSharedPointer<GenKeyInfo>&,
const GpgOperationCallback&);
/**
@@ -122,7 +123,7 @@ class GPGFRONTEND_CORE_EXPORT GpgKeyOpera
*
* @param params
*/
- auto GenerateKeySync(const std::shared_ptr<GenKeyInfo>& params)
+ auto GenerateKeySync(const QSharedPointer<GenKeyInfo>& params)
-> std::tuple<GpgError, DataObjectPtr>;
/**
@@ -133,7 +134,7 @@ class GPGFRONTEND_CORE_EXPORT GpgKeyOpera
* @return GpgFrontend::GpgError
*/
void GenerateSubkey(const GpgKey& key,
- const std::shared_ptr<GenKeyInfo>& params,
+ const QSharedPointer<GenKeyInfo>& params,
const GpgOperationCallback&);
/**
@@ -143,7 +144,7 @@ class GPGFRONTEND_CORE_EXPORT GpgKeyOpera
* @param params
*/
auto GenerateSubkeySync(const GpgKey& key,
- const std::shared_ptr<GenKeyInfo>& params)
+ const QSharedPointer<GenKeyInfo>& params)
-> std::tuple<GpgError, DataObjectPtr>;
/**
@@ -153,8 +154,8 @@ class GPGFRONTEND_CORE_EXPORT GpgKeyOpera
* @param subkey_params
* @param callback
*/
- void GenerateKeyWithSubkey(const std::shared_ptr<GenKeyInfo>& params,
- const std::shared_ptr<GenKeyInfo>& subkey_params,
+ void GenerateKeyWithSubkey(const QSharedPointer<GenKeyInfo>& p_params,
+ const QSharedPointer<GenKeyInfo>& s_params,
const GpgOperationCallback& callback);
/**
@@ -164,13 +165,15 @@ class GPGFRONTEND_CORE_EXPORT GpgKeyOpera
* @param subkey_params
* @param callback
*/
- auto GenerateKeyWithSubkeySync(
- const std::shared_ptr<GenKeyInfo>& params,
- const std::shared_ptr<GenKeyInfo>& subkey_params)
+ auto GenerateKeyWithSubkeySync(const QSharedPointer<GenKeyInfo>& p_params,
+ const QSharedPointer<GenKeyInfo>& s_params)
-> std::tuple<GpgError, DataObjectPtr>;
private:
GpgContext& ctx_ =
GpgContext::GetInstance(SingletonFunctionObject::GetChannel()); ///<
+
+ GpgKeyGetter& key_getter_ =
+ GpgKeyGetter::GetInstance(SingletonFunctionObject::GetChannel()); ///<
};
} // namespace GpgFrontend