Web   ·   Wiki   ·   Activities   ·   Blog   ·   Lists   ·   Chat   ·   Meeting   ·   Bugs   ·   Git   ·   Translate   ·   Archive   ·   People   ·   Donate
summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorTomeu Vizoso <tomeu@tomeuvizoso.net>2008-02-09 11:28:12 (GMT)
committer Tomeu Vizoso <tomeu@tomeuvizoso.net>2008-02-09 11:28:12 (GMT)
commit56da6b0b39fc3b4b9fa5c19ed0738ff526bf5072 (patch)
tree02ab2d94451f003aeeaaafba65dab6daf7a30200 /src
parent811c9c78aab06f96686eddd1c81d7a23922cf9bf (diff)
Use the right gettext domain.
Diffstat (limited to 'src')
-rw-r--r--src/sugar/__init__.py14
1 files changed, 13 insertions, 1 deletions
diff --git a/src/sugar/__init__.py b/src/sugar/__init__.py
index 91451dd..9be4404 100644
--- a/src/sugar/__init__.py
+++ b/src/sugar/__init__.py
@@ -1,5 +1,5 @@
# Copyright (C) 2006-2007, Red Hat, Inc.
-# Copyright (C) 2007, One Laptop Per Child
+# Copyright (C) 2007-2008, One Laptop Per Child
#
# This library is free software; you can redistribute it and/or
# modify it under the terms of the GNU Lesser General Public
@@ -16,3 +16,15 @@
# Free Software Foundation, Inc., 59 Temple Place - Suite 330,
# Boston, MA 02111-1307, USA.
+import os
+import gettext
+
+if os.environ.has_key('SUGAR_PREFIX'):
+ prefix = os.environ['SUGAR_PREFIX']
+else:
+ prefix = '/usr'
+
+locale_path = os.path.join(prefix, 'share', 'locale')
+
+gettext.bindtextdomain('sugar', locale_path)
+