aboutsummaryrefslogtreecommitdiff
path: root/src/kristall.hpp
diff options
context:
space:
mode:
authorFelix (xq) Queißner <git@mq32.de>2021-03-17 11:54:43 +0100
committerFelix (xq) Queißner <git@mq32.de>2021-05-08 10:44:03 +0200
commit10684b6d82f1843eff3921da40802d335fb3cf5c (patch)
treea80d403f0668686de90c2cd48786e7b5e5fc2128 /src/kristall.hpp
parenta2f36ec4d14ddf1bcee98e52a0f3a924804d06fb (diff)
downloadkristall-10684b6d82f1843eff3921da40802d335fb3cf5c.tar.gz
Further improves localization (#191). Allows switching and setting the chosen localization properly.
Diffstat (limited to 'src/kristall.hpp')
-rw-r--r--src/kristall.hpp15
1 files changed, 2 insertions, 13 deletions
diff --git a/src/kristall.hpp b/src/kristall.hpp
index eac5bdd..272525b 100644
--- a/src/kristall.hpp
+++ b/src/kristall.hpp
@@ -5,8 +5,6 @@
#include <QSettings>
#include <QClipboard>
#include <QSslCertificate>
-#include <QTranslator>
-#include <QLocale>
#include "identitycollection.hpp"
#include "ssltrust.hpp"
@@ -14,6 +12,7 @@
#include "protocolsetup.hpp"
#include "documentstyle.hpp"
#include "cachehandler.hpp"
+#include "localization.hpp"
enum class Theme : int
{
@@ -166,13 +165,6 @@ namespace kristall
QDir styles;
};
- struct Localization
- {
- QLocale locale;
- QTranslator qt;
- QTranslator kristall;
- };
-
struct Globals
{
ProtocolSetup protocols;
@@ -191,7 +183,7 @@ namespace kristall
Dirs dirs;
- Localization localization;
+ std::unique_ptr<Localization> localization;
};
//! returns the instance of the globals structure
@@ -233,9 +225,6 @@ 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();
}