aboutsummaryrefslogtreecommitdiff
path: root/src/kristall.hpp
diff options
context:
space:
mode:
authorFelix (xq) Queißner <git@mq32.de>2021-03-17 10:42:50 +0100
committerFelix (xq) Queißner <git@mq32.de>2021-05-08 10:44:03 +0200
commita2f36ec4d14ddf1bcee98e52a0f3a924804d06fb (patch)
tree6536ad496886f43a3c4fc363adf297ce49add830 /src/kristall.hpp
parentc9e9fccd22009a9a7d516c108ad5b33fa87c3920 (diff)
downloadkristall-a2f36ec4d14ddf1bcee98e52a0f3a924804d06fb.tar.gz
Inserts setting for current language.
Diffstat (limited to 'src/kristall.hpp')
-rw-r--r--src/kristall.hpp18
1 files changed, 17 insertions, 1 deletions
diff --git a/src/kristall.hpp b/src/kristall.hpp
index 49219cf..eac5bdd 100644
--- a/src/kristall.hpp
+++ b/src/kristall.hpp
@@ -5,6 +5,8 @@
#include <QSettings>
#include <QClipboard>
#include <QSslCertificate>
+#include <QTranslator>
+#include <QLocale>
#include "identitycollection.hpp"
#include "ssltrust.hpp"
@@ -164,9 +166,15 @@ namespace kristall
QDir styles;
};
- struct Globals
+ struct Localization
{
+ QLocale locale;
+ QTranslator qt;
+ QTranslator kristall;
+ };
+ struct Globals
+ {
ProtocolSetup protocols;
QSettings * settings;
@@ -182,6 +190,8 @@ namespace kristall
Trust trust;
Dirs dirs;
+
+ Localization localization;
};
//! returns the instance of the globals structure
@@ -222,6 +232,12 @@ namespace kristall
//! Saves the current session including all windows, tabs and positions.
void saveSession();
+
+ //! Changes the currently used locale
+ void setLocale(QLocale const & locale);
+
+ //! Saves the currently used locale
+ void saveLocale();
}
#endif // KRISTALL_HPP