mirror of
https://github.com/nextcloud/desktop.git
synced 2024-11-27 09:30:13 +03:00
Fix compilation on win/mac
This commit is contained in:
parent
c0f2f5bcaa
commit
11e06c33db
1 changed files with 3 additions and 4 deletions
|
@ -87,10 +87,12 @@ Application::Application(int &argc, char **argv) :
|
|||
//no need to waste time;
|
||||
if ( _helpOnly ) return;
|
||||
|
||||
QString locale = Theme::instance()->enforcedLocale();
|
||||
if (locale.isEmpty()) locale = QLocale::system().name();
|
||||
|
||||
QTranslator *qtTranslator = new QTranslator(this);
|
||||
#if defined(Q_OS_MAC)
|
||||
qtTranslator->load(QLatin1String("qt_") + locale, applicationDirPath()+QLatin1String("/../translations") ); // path defaults to app dir.
|
||||
#endif
|
||||
#elif defined(Q_OS_WIN32)
|
||||
qtTranslator->load(QLatin1String("qt_") + locale, applicationDirPath());
|
||||
#endif
|
||||
|
@ -102,9 +104,6 @@ Application::Application(int &argc, char **argv) :
|
|||
|
||||
QTranslator *mirallTranslator = new QTranslator(this);
|
||||
|
||||
QString locale = Theme::instance()->enforcedLocale();
|
||||
if (locale.isEmpty()) locale = QLocale::system().name();
|
||||
|
||||
#ifdef Q_OS_LINUX
|
||||
// FIXME - proper path!
|
||||
mirallTranslator->load(QLatin1String("mirall_") + locale, QLatin1String("/usr/share/mirall/i18n/"));
|
||||
|
|
Loading…
Reference in a new issue