浏览代码

dbmgr: put sql query part into own panel

git-svn-id: https://svn.osgeo.org/grass/grass/trunk@57044 15284696-431f-4ddb-bdfa-cd5b030d7da7
Štěpán Turek 11 年之前
父节点
当前提交
83874ef97c
共有 1 个文件被更改,包括 8 次插入3 次删除
  1. 8 3
      gui/wxpython/dbmgr/base.py

+ 8 - 3
gui/wxpython/dbmgr/base.py

@@ -1005,8 +1005,10 @@ class DbMgrBrowsePage(DbMgrNotebookBase):
             
         pageSizer = wx.BoxSizer(wx.VERTICAL)
 
+        sqlQueryPanel = wx.Panel(parent = panel, id = wx.ID_ANY)
+
         # attribute data            
-        sqlBox = wx.StaticBox(parent = panel, id = wx.ID_ANY,
+        sqlBox = wx.StaticBox(parent = sqlQueryPanel, id = wx.ID_ANY,
                               label = " %s " % _("SQL Query"))
 
         sqlSizer = wx.StaticBoxSizer(sqlBox, wx.VERTICAL)
@@ -1031,7 +1033,7 @@ class DbMgrBrowsePage(DbMgrNotebookBase):
             dbmStyle = { 'agwStyle' : FNPageStyle }
         else:
             dbmStyle = { 'style' : FNPageStyle }
-        sqlNtb = FN.FlatNotebook(parent = panel, id = wx.ID_ANY,
+        sqlNtb = FN.FlatNotebook(parent = sqlQueryPanel, id = wx.ID_ANY,
                                  **dbmStyle)
         # Simple tab
         simpleSqlPanel = wx.Panel(parent = sqlNtb, id = wx.ID_ANY)
@@ -1118,7 +1120,10 @@ class DbMgrBrowsePage(DbMgrNotebookBase):
                       proportion = 1,
                       flag = wx.ALL | wx.EXPAND,
                       border = 5)
-        pageSizer.Add(item = sqlSizer,
+
+        sqlQueryPanel.SetSizer(sqlSizer)
+        
+        pageSizer.Add(item = sqlQueryPanel,
                       proportion = 0,
                       flag = wx.BOTTOM | wx.LEFT | wx.RIGHT | wx.EXPAND,
                       border = 5)