File tree Expand file tree Collapse file tree
Source/GUI/Windows/Translator Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -57,7 +57,7 @@ endif()
5757if (Z_USE_LIB_NOTIFY)
5858 if (NOT LINUX )
5959 message (FATAL_ERROR "Could not use 'LibNotify' in operating system outside of Linux" )
60- endif
60+ endif ()
6161
6262 if (Z_STATIC_LINKING)
6363 message (FATAL_ERROR "Could not use 'LibNotify' if you want use static linking mode" )
Original file line number Diff line number Diff line change 1+ #ifndef SETTING_WINDOW_TRANSLATOR_HPP
2+ #define SETTING_WINDOW_TRANSLATOR_HPP
3+ #include " ../../../../Utils/Include/Namespace_Macro.hpp"
4+ #include " ../../../../Lib_Memory/Include/Memory.hpp"
5+ #include " ../../../../GUI/Toolkit/Include/SettingWindow_Components.hpp"
6+ #include < QSettings>
7+ #include < QDialog>
8+
9+ using ZClipboard::Lib_Memory::PtrUnique;
10+ using ZClipboard::GUI::Toolkit::SettingWindowComponentsManager;
11+
12+ GUI_WINDOW_TRANSLATOR_NAMESPACE
13+
14+ class SettingWindowTranslator {
15+ private:
16+ using Settings = QSettings;
17+ using Components = SettingWindowComponentsManager;
18+ using Window = QDialog;
19+
20+ private:
21+ PtrUnique<Settings> settings;
22+
23+ private:
24+ void VietNameseTranslator (Window *window, Components *components);
25+ void EnglishTranslator (Window *window, Components *components);
26+
27+ public:
28+ void LoadTranslator (Window *window, Components *components);
29+ };
30+
31+ END_NAMESPACE
32+
33+ #endif // SETTING_WINDOW_TRANSLATOR_HPP
Original file line number Diff line number Diff line change 1+ #include " Include/SettingWindow_Translator.hpp"
2+ #include " ../../../Language/Include/Language.hpp"
3+
4+ using ZClipboard::GUI::Windows::Translator::SettingWindowTranslator;
5+ using ZClipboard::Lib_Memory::MakePtr;
6+
7+ using Self = SettingWindowTranslator;
8+
9+ #if defined (Z_DEBUG)
10+
11+ #endif
12+
13+ void Self::VietNameseTranslator (Window *window, Components *components) {
14+ constexpr auto TITLE = SETTING_DIALOG_VI;
15+
16+
17+ window->setWindowTitle (TITLE);
18+ }
19+
20+ void Self::EnglishTranslator (Window *window, Components *components) {
21+ const auto TITLE = SETTING_DIALOG_EN;
22+
23+ window->setWindowTitle (TITLE);
24+ }
25+
26+ void Self::LoadTranslator (Window *window, Components *components) {
27+ if (!settings) {
28+ settings = MakePtr<Settings>();
29+
30+
31+ }
32+
33+ }
You can’t perform that action at this time.
0 commit comments