nixpkgs/pkgs/applications/misc/crow-translate/fix-qttranslations-path.patch
2023-07-22 02:29:11 +04:00

14 lines
863 B
Diff

diff --git i/src/settings/appsettings.cpp w/src/settings/appsettings.cpp
index 32cabfb..aab92ea 100644
--- i/src/settings/appsettings.cpp
+++ w/src/settings/appsettings.cpp
@@ -79,7 +79,7 @@ void AppSettings::applyLocale(const QLocale &locale)
const QLocale newLocale = locale == defaultLocale() ? QLocale::system() : locale;
QLocale::setDefault(newLocale);
s_appTranslator.load(newLocale, QStringLiteral(PROJECT_NAME), QStringLiteral("_"), QStandardPaths::locate(QStandardPaths::AppDataLocation, i18nDir, QStandardPaths::LocateDirectory));
- s_qtTranslator.load(newLocale, QStringLiteral("qt"), QStringLiteral("_"), QLibraryInfo::location(QLibraryInfo::TranslationsPath));
+ s_qtTranslator.load(newLocale, QStringLiteral("qt"), QStringLiteral("_"), QLatin1String("@qttranslations@/translations"));
}
QLocale AppSettings::defaultLocale()