浏览代码

backport from develbranch_6 r36194. Fixing dbm.py freezing on the Mac because wx.StaticBox needs to be defined before any controls that go into the wx.StaticBox

git-svn-id: https://svn.osgeo.org/grass/grass/trunk@36195 15284696-431f-4ddb-bdfa-cd5b030d7da7
Michael Barton 16 年之前
父节点
当前提交
50b4f13e18
共有 1 个文件被更改,包括 10 次插入5 次删除
  1. 10 5
      gui/wxpython/gui_modules/dbm.py

+ 10 - 5
gui/wxpython/gui_modules/dbm.py

@@ -560,6 +560,15 @@ class AttributeManager(wx.Frame):
                 continue
 
             panel = wx.Panel(parent=self.browsePage, id=wx.ID_ANY)
+            
+            #IMPORTANT NOTE: wx.StaticBox MUST be defined BEFORE any of the 
+            #   controls that are placed IN the wx.StaticBox, or it will freeze
+            #   on the Mac
+            
+            listBox = wx.StaticBox(parent=panel, id=wx.ID_ANY,
+                       label=" %s " % _("Attribute data - right-click to edit/manage records"))
+            listSizer = wx.StaticBoxSizer(listBox, wx.VERTICAL)
+            
             win = VirtualAttributeList(panel, self.log,
                                        self.mapDBInfo, layer)
             if win.IsEmpty():
@@ -575,11 +584,7 @@ class AttributeManager(wx.Frame):
 
             pageSizer = wx.BoxSizer(wx.VERTICAL)
 
-            # attribute data
-            listBox = wx.StaticBox(parent=panel, id=wx.ID_ANY,
-                                   label=" %s " % _("Attribute data - right-click to edit/manage records"))
-            listSizer = wx.StaticBoxSizer(listBox, wx.VERTICAL)
-            
+            # attribute data            
             sqlBox = wx.StaticBox(parent=panel, id=wx.ID_ANY,
                                   label=" %s " % _("SQL Query"))