From 8130efd64ae996939c36088fb2cc4c4692371f4f Mon Sep 17 00:00:00 2001 From: =?utf8?q?Elan=20Ruusam=C3=A4e?= Date: Wed, 20 Oct 2010 09:48:26 +0000 Subject: [PATCH] - use qtinfo Changed files: unbundle-po.patch -> 1.4 --- unbundle-po.patch | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/unbundle-po.patch b/unbundle-po.patch index 317abfd..45e2b3c 100644 --- a/unbundle-po.patch +++ b/unbundle-po.patch @@ -52,10 +52,10 @@ Author: Elan Ruusamäe - // The regex captures the "ru" from "clementine_ru.qm" - if (!lang_re.exactMatch(filename)) +// QDir dir(":/translations/"); -+ QDir localeDir("/usr/share/locale"); ++ QDir localeDir(QLibraryInfo::location(QLibraryInfo::TranslationsPath)); + QStringList dirList = localeDir.entryList(QDir::Dirs | QDir::NoDotAndDotDot, QDir::Name); + foreach (const QString& code, dirList) { -+ if (!QFile::exists( "/usr/share/locale/" + code + "/LC_MESSAGES/clementine.qm")) { ++ if (!QFile::exists(QLibraryInfo::location(QLibraryInfo::TranslationsPath) + "/" + code + "/LC_MESSAGES/clementine.qm")) { continue; + } -- 2.44.0