[GRASS-SVN] r45578 - grass/branches/develbranch_6/gui/wxpython/gui_modules

svn_grass at osgeo.org svn_grass at osgeo.org
Sat Mar 5 13:36:19 EST 2011


Author: martinl
Date: 2011-03-05 10:36:19 -0800 (Sat, 05 Mar 2011)
New Revision: 45578

Modified:
   grass/branches/develbranch_6/gui/wxpython/gui_modules/layertree.py
Log:
wxGUI: TR_ALIGN_WINDOWS requires wxPython 2.8.9.2+


Modified: grass/branches/develbranch_6/gui/wxpython/gui_modules/layertree.py
===================================================================
--- grass/branches/develbranch_6/gui/wxpython/gui_modules/layertree.py	2011-03-05 18:26:05 UTC (rev 45577)
+++ grass/branches/develbranch_6/gui/wxpython/gui_modules/layertree.py	2011-03-05 18:36:19 UTC (rev 45578)
@@ -67,7 +67,7 @@
                  id = wx.ID_ANY, style = wx.SUNKEN_BORDER,
                  ctstyle = CT.TR_HAS_BUTTONS | CT.TR_HAS_VARIABLE_ROW_HEIGHT |
                  CT.TR_HIDE_ROOT | CT.TR_ROW_LINES | CT.TR_FULL_ROW_HIGHLIGHT |
-                 CT.TR_MULTIPLE | CT.TR_ALIGN_WINDOWS, **kwargs):
+                 CT.TR_MULTIPLE, **kwargs):
         
         if 'style' in kwargs:
             ctstyle |= kwargs['style']
@@ -94,6 +94,11 @@
         self.rerender = False                # layer change requires a rerendering if auto render
         self.reorder = False                 # layer change requires a reordering
         
+        try:
+            ctstyle |= CT.TR_ALIGN_WINDOWS
+        except AttributeError:
+            pass
+        
         if globalvar.hasAgw:
             super(LayerTree, self).__init__(parent, id, agwStyle = ctstyle, **kwargs)
         else:



More information about the grass-commit mailing list