summaryrefslogtreecommitdiffstats
path: root/pyLoadCore.py
diff options
context:
space:
mode:
authorGravatar RaNaN <Mast3rRaNaN@hotmail.de> 2010-02-10 21:59:31 +0100
committerGravatar RaNaN <Mast3rRaNaN@hotmail.de> 2010-02-10 21:59:31 +0100
commit6c4eabfc4b686a72224ff06cb56c385bfc489790 (patch)
tree913239e4a2d994e813134b94f66a49eec9a4b201 /pyLoadCore.py
parentwebif patch #75 (thx kepheus) (diff)
downloadpyload-6c4eabfc4b686a72224ff06cb56c385bfc489790.tar.xz
Webinterface with lighttpd! locale fixing try.
Diffstat (limited to 'pyLoadCore.py')
-rwxr-xr-xpyLoadCore.py10
1 files changed, 9 insertions, 1 deletions
diff --git a/pyLoadCore.py b/pyLoadCore.py
index 483750152..5ea4b43c5 100755
--- a/pyLoadCore.py
+++ b/pyLoadCore.py
@@ -108,8 +108,16 @@ class Core(object):
self.do_kill = False
self.do_restart = False
translation = gettext.translation("pyLoad", join(self.path, "locale"), languages=[self.config['general']['language']])
- translation.install(unicode=(False if sys.stdout.encoding == "ascii" else True))
+ try:
+ translation.ugettext("äöü")
+ unicode = True
+ except:
+ unicode = False
+ #@TODO cleaner method, if possible
+
+ translation.install(unicode)
+
self.check_install("Crypto", _("pycrypto to decode container files"))
self.check_install("Image", _("Python Image Libary (PIL) for captha reading"))
self.check_install("pycurl", _("pycurl for lower memory footprint while downloading"))