Commit b72fb07f authored by Karel Slaný's avatar Karel Slaný

Language codes are standard C string now.

parent 608fed1a
......@@ -26,9 +26,9 @@
QLocale Localisation::programLocale;
QCollator Localisation::stringCollator;
const QString Localisation::langCs(QStringLiteral("cs"));
const QString Localisation::langEn(QStringLiteral("en"));
const QString Localisation::langSystem(QStringLiteral("system"));
const char *Localisation::langCs = "cs";
const char *Localisation::langEn = "en";
const char *Localisation::langSystem = "system";
void Localisation::setProgramLocale(const QString &langCode)
{
......
......@@ -62,10 +62,14 @@ public:
static
QCollator stringCollator; /*!< Used for localised string collation. */
/*
* Using QString unstead of char* causes problems with initialisation
* order, where the object may be used before actually being created.
*/
static
const QString langCs; /*!< Czech language code. */
const char *langCs; /*!< Czech language code. */
static
const QString langEn; /*!< English language code. */
const char *langEn; /*!< English language code. */
static
const QString langSystem; /*!< System-set language. */
const char *langSystem; /*!< System-set language. */
};
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment