From 0b8fe770d5c969b909e597c135936e5a3dd499ac Mon Sep 17 00:00:00 2001 From: Andreas Preikschat Date: Thu, 2 Jun 2011 15:58:49 +0200 Subject: [PATCH] Do not show qm files which start with qt_ Fixes: https://launchpad.net/bugs/791814 --- openlp/core/utils/languagemanager.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/openlp/core/utils/languagemanager.py b/openlp/core/utils/languagemanager.py index 0c0a4ed56..475d0a47a 100644 --- a/openlp/core/utils/languagemanager.py +++ b/openlp/core/utils/languagemanager.py @@ -77,6 +77,8 @@ class LanguageManager(object): AppLocation.LanguageDir)) file_names = trans_dir.entryList(QtCore.QStringList(u'*.qm'), QtCore.QDir.Files, QtCore.QDir.Name) + # Remove qm files from the list which start with "qt_". + file_names = file_names.filter(QtCore.QRegExp("^(?!qt_)")) for name in file_names: file_names.replaceInStrings(name, trans_dir.filePath(name)) return file_names