nixpkgs-suyu/pkgs/applications/misc/gpxsee/fix-qttranslations-path.diff

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

19 lines
722 B
Diff
Raw Normal View History

2020-06-01 10:45:46 +02:00
diff --git i/src/GUI/app.cpp w/src/GUI/app.cpp
2020-12-22 23:29:59 +01:00
index 37e9d3f..d4a065c 100644
2020-06-01 10:45:46 +02:00
--- i/src/GUI/app.cpp
+++ w/src/GUI/app.cpp
2020-12-22 23:29:59 +01:00
@@ -35,11 +35,10 @@ App::App(int &argc, char **argv) : QApplication(argc, argv)
installTranslator(gpxsee);
2020-06-01 10:45:46 +02:00
QTranslator *qt = new QTranslator(this);
-#if defined(Q_OS_WIN32) || defined(Q_OS_MAC)
+#if defined(Q_OS_WIN32)
2020-12-22 23:29:59 +01:00
if (qt->load(QLocale::system(), "qt", "_", ProgramPaths::translationsDir()))
2020-06-01 10:45:46 +02:00
#else // Q_OS_WIN32 || Q_OS_MAC
2020-12-22 23:29:59 +01:00
- if (qt->load(QLocale::system(), "qt", "_", QLibraryInfo::location(
- QLibraryInfo::TranslationsPath)))
+ if (qt->load(QLocale::system(), "qt", "_", QLatin1String("@qttranslations@/translations")))
2020-06-01 10:45:46 +02:00
#endif // Q_OS_WIN32 || Q_OS_MAC
2020-12-22 23:29:59 +01:00
installTranslator(qt);
2020-06-01 10:45:46 +02:00