[GRASS-SVN] r49091 - in grass/branches/develbranch_6: gui/wxpython/gui_modules lib/python

svn_grass at osgeo.org svn_grass at osgeo.org
Fri Nov 4 07:51:01 EDT 2011


Author: martinl
Date: 2011-11-04 04:51:01 -0700 (Fri, 04 Nov 2011)
New Revision: 49091

Modified:
   grass/branches/develbranch_6/gui/wxpython/gui_modules/menuform.py
   grass/branches/develbranch_6/lib/python/task.py
Log:
wxGUI: fix r49064 (#1485)


Modified: grass/branches/develbranch_6/gui/wxpython/gui_modules/menuform.py
===================================================================
--- grass/branches/develbranch_6/gui/wxpython/gui_modules/menuform.py	2011-11-04 10:32:38 UTC (rev 49090)
+++ grass/branches/develbranch_6/gui/wxpython/gui_modules/menuform.py	2011-11-04 11:51:01 UTC (rev 49091)
@@ -1919,7 +1919,7 @@
         if not self.grass_task:
             enc = locale.getdefaultlocale()[1]
             if enc and enc.lower() == "cp932":
-                p = re.compile('encoding="' + enc + "'", re.IGNORECASE)
+                p = re.compile('encoding="' + enc + '"', re.IGNORECASE)
                 tree = etree.fromstring(p.sub('encoding="utf-8"',
                                               gtask.get_interface_description(cmd).decode(enc).encode('utf-8')))
             else:

Modified: grass/branches/develbranch_6/lib/python/task.py
===================================================================
--- grass/branches/develbranch_6/lib/python/task.py	2011-11-04 10:32:38 UTC (rev 49090)
+++ grass/branches/develbranch_6/lib/python/task.py	2011-11-04 11:51:01 UTC (rev 49091)
@@ -450,7 +450,9 @@
     """
     enc = locale.getdefaultlocale()[1]
     if enc and enc.lower() == "cp932":
-        tree = etree.fromstring(get_interface_description(name).decode(enc).encode("utf-8"))
+        p = re.compile('encoding="' + enc + '"', re.IGNORECASE)
+        tree = etree.fromstring(p.sub('encoding="utf-8"',
+                                      get_interface_description(name).decode(enc).encode("utf-8")))
     else:
         tree = etree.fromstring(get_interface_description(name))
     



More information about the grass-commit mailing list