diff options
author | Saturneric <[email protected]> | 2023-10-25 07:40:43 +0000 |
---|---|---|
committer | Saturneric <[email protected]> | 2023-10-25 07:40:43 +0000 |
commit | a23b2fbc707406dec0dd924c089b4285bc7f0010 (patch) | |
tree | 7773e4a3e45a26a38735450f065c637e170f202d /src/core/module/ModuleManager.cpp | |
parent | feat: use module instead of integrated code at version checking task (diff) | |
download | GpgFrontend-a23b2fbc707406dec0dd924c089b4285bc7f0010.tar.gz GpgFrontend-a23b2fbc707406dec0dd924c089b4285bc7f0010.zip |
feat: use rt listen publish event function in main windows' app version upgrade notification
Diffstat (limited to 'src/core/module/ModuleManager.cpp')
-rw-r--r-- | src/core/module/ModuleManager.cpp | 13 |
1 files changed, 9 insertions, 4 deletions
diff --git a/src/core/module/ModuleManager.cpp b/src/core/module/ModuleManager.cpp index 20f9ab28..c151ebb1 100644 --- a/src/core/module/ModuleManager.cpp +++ b/src/core/module/ModuleManager.cpp @@ -100,12 +100,17 @@ class ModuleManager::Impl { GRTPtr grt_; }; -bool UpsertRTValueTyped(const std::string& namespace_, const std::string& key, - const std::any& value) { +bool UpsertRTValue(const std::string& namespace_, const std::string& key, + const std::any& value) { return ModuleManager::GetInstance()->UpsertRTValue(namespace_, key, std::any(value)); } +bool GPGFRONTEND_CORE_EXPORT ListenRTPublishEvent(QObject* o, Namespace n, + Key k, LPCallback c) { + return ModuleManager::GetInstance()->ListenRTPublish(o, n, k, c); +} + ModuleManager::ModuleManager() : p_(std::make_unique<Impl>()) {} ModuleManager::~ModuleManager() = default; @@ -140,8 +145,8 @@ std::optional<std::any> ModuleManager::RetrieveRTValue(Namespace n, Key k) { return p_->RetrieveRTValue(n, k); } -bool ModuleManager::ListenPublish(QObject* o, Namespace n, Key k, - LPCallback c) { +bool ModuleManager::ListenRTPublish(QObject* o, Namespace n, Key k, + LPCallback c) { return p_->ListenPublish(o, n, k, c); } |