Changeset 5fce561905 in tspsg for src/main.cpp


Ignore:
Timestamp:
Jun 15, 2009, 8:51:12 PM (15 years ago)
Author:
Oleksii Serdiuk
Branches:
0.1.3.145-beta1-symbian, 0.1.4.170-beta2-bb10, appveyor, imgbot, master, readme
Children:
8966f73b3f
Parents:
5354a01311
Message:

Translation related updates...

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/main.cpp

    r5354a01311 r5fce561905  
    3232/*/ i18n
    3333// TODO: Make English as program's "native" language
    34 QLocale *qlocale = &QLocale::system();
     34QTextCodec::setCodecForTr(QTextCodec::codecForName("utf8"));
     35QString locale = QLocale::languageToString(QLocale::system().language());
    3536QTranslator translator;
    3637        // Getting current locale languge name and trying to load it
    37         if (translator.load(qlocale->languageToString(qlocale->language()),"i18n"))
     38        if (translator.load(locale,"i18n"))
    3839                app.installTranslator(&translator);
    3940        // If language loading failed and locale language is not
    4041        // application's "native" we're trying to load English
    41         else if (qlocale->languageToString(qlocale->language()).compare("Russian") && translator.load("English","i18n"))
     42        else if (locale.compare("Russian") && translator.load("English","i18n"))
    4243                app.installTranslator(&translator);
    4344//*/
Note: See TracChangeset for help on using the changeset viewer.