From d7ff86705e7e9094c1506a3fd6c67001b89d089c Mon Sep 17 00:00:00 2001 From: mailchuck Date: Tue, 22 Dec 2015 23:28:40 +0100 Subject: [PATCH] Fix frozen localisation Addresses Bitmessage#737 --- src/bitmessageqt/__init__.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/bitmessageqt/__init__.py b/src/bitmessageqt/__init__.py index a193b1c6..698604ad 100644 --- a/src/bitmessageqt/__init__.py +++ b/src/bitmessageqt/__init__.py @@ -88,7 +88,10 @@ def change_translation(locale): QtGui.QApplication.installTranslator(qmytranslator) qsystranslator = QtCore.QTranslator() - translationpath = os.path.join (str(QtCore.QLibraryInfo.location(QtCore.QLibraryInfo.TranslationsPath)), 'qt_' + locale) + if shared.frozen: + translationpath = os.path.join (shared.codePath(), 'translations', 'qt_' + locale) + else: + translationpath = os.path.join (str(QtCore.QLibraryInfo.location(QtCore.QLibraryInfo.TranslationsPath)), 'qt_' + locale) qsystranslator.load(translationpath) QtGui.QApplication.installTranslator(qsystranslator)