From 6983b5c1dd82d159236ebd06cf17f071cc9c1ee9 Mon Sep 17 00:00:00 2001 From: saturneric Date: Fri, 12 Jan 2024 23:08:38 +0800 Subject: refactor: remove boost and use QString instead of std::filesystem::path --- src/GpgFrontendContext.cpp | 16 +++------------- 1 file changed, 3 insertions(+), 13 deletions(-) (limited to 'src/GpgFrontendContext.cpp') diff --git a/src/GpgFrontendContext.cpp b/src/GpgFrontendContext.cpp index 461bbeaa..9d264dcd 100644 --- a/src/GpgFrontendContext.cpp +++ b/src/GpgFrontendContext.cpp @@ -34,24 +34,14 @@ #include #include "core/utils/MemoryUtils.h" -#include "ui/GpgFrontendApplication.h" namespace GpgFrontend { -void GpgFrontendContext::InitApplication(bool gui_mode) { - if (!gui_mode) { - app_ = SecureCreateObject(argc, argv); - } else { - app_ = SecureCreateObject(argc, argv); - } - this->load_ui_env = gui_mode; +void GpgFrontendContext::InitApplication() { + app_ = SecureCreateObject(argc, argv); } -auto GpgFrontendContext::GetApp() -> QCoreApplication* { return app_; } - -auto GpgFrontendContext::GetGuiApp() -> QApplication* { - return qobject_cast(app_); -} +auto GpgFrontendContext::GetApp() -> QApplication* { return app_; } GpgFrontendContext::GpgFrontendContext(int argc, char** argv) : argc(argc), argv(argv) {} -- cgit v1.2.3