commit bcb18bbde48768646571d7391be09194423feb61
parent 01ad103c37ce53e4dc4126dcae6a9cd3f6a8d060
Author: ThomasV <thomasv@gitorious>
Date: Mon, 8 Sep 2014 11:02:55 +0200
call set_language before QApplication. fixes #400
Diffstat:
2 files changed, 9 insertions(+), 7 deletions(-)
diff --git a/gui/qt/__init__.py b/gui/qt/__init__.py
@@ -16,10 +16,11 @@
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
-import sys, time, datetime, re, threading
-from electrum.i18n import _, set_language
-from electrum.util import print_error, print_msg
-from electrum.plugins import run_hook
+import sys
+import time
+import datetime
+import re
+import threading
import os.path, json, ast, traceback
import shutil
import signal
@@ -33,8 +34,10 @@ from PyQt4.QtGui import *
from PyQt4.QtCore import *
import PyQt4.QtCore as QtCore
+from electrum.i18n import _, set_language
+from electrum.util import print_error, print_msg
+from electrum.plugins import run_hook
from electrum import WalletStorage, Wallet
-from electrum.i18n import _
from electrum.bitcoin import MIN_RELAY_TX_FEE
try:
@@ -62,6 +65,7 @@ class OpenFileEventFilter(QObject):
class ElectrumGui:
def __init__(self, config, network, app=None):
+ set_language(config.get('language'))
self.network = network
self.config = config
self.windows = []
diff --git a/gui/qt/main_window.py b/gui/qt/main_window.py
@@ -134,8 +134,6 @@ class ElectrumWindow(QMainWindow):
self.num_zeros = int(config.get('num_zeros',0))
self.invoices = {}
- set_language(config.get('language'))
-
self.completions = QStringListModel()
self.tabs = tabs = QTabWidget(self)