[GRASS-SVN] r62330 - in grass/branches/releasebranch_7_0: . gui/wxpython/dbmgr

svn_grass at osgeo.org svn_grass at osgeo.org
Tue Oct 21 13:15:51 PDT 2014


Author: martinl
Date: 2014-10-21 13:15:51 -0700 (Tue, 21 Oct 2014)
New Revision: 62330

Modified:
   grass/branches/releasebranch_7_0/
   grass/branches/releasebranch_7_0/gui/wxpython/dbmgr/sqlbuilder.py
Log:
wxGUI/sqlbuilder: GoTo - process ENTER
                  check if vector map exists
                  (merge r62328-9 from trunk)



Property changes on: grass/branches/releasebranch_7_0
___________________________________________________________________
Modified: svn:mergeinfo
   - /grass/trunk:61280,62141,62144,62269,62271,62276,62288,62300,62305,62310,62325
   + /grass/trunk:61280,62141,62144,62269,62271,62276,62288,62300,62305,62310,62325,62328-62329

Modified: grass/branches/releasebranch_7_0/gui/wxpython/dbmgr/sqlbuilder.py
===================================================================
--- grass/branches/releasebranch_7_0/gui/wxpython/dbmgr/sqlbuilder.py	2014-10-21 20:07:42 UTC (rev 62329)
+++ grass/branches/releasebranch_7_0/gui/wxpython/dbmgr/sqlbuilder.py	2014-10-21 20:15:51 UTC (rev 62330)
@@ -55,6 +55,8 @@
         self.vectmap = vectmap # fullname
         if not "@" in self.vectmap:
             self.vectmap = grass.find_file(self.vectmap, element = 'vector')['fullname']
+            if not self.vectmap:
+                grass.fatal(_("Vector map <%s> not found") % vectmap)
         self.mapname, self.mapset = self.vectmap.split("@", 1)
         
         # db info
@@ -216,7 +218,7 @@
 
         # go to
         gotosizer = wx.BoxSizer(wx.HORIZONTAL)
-        self.goto = wx.TextCtrl(parent = self.valuespanel, id = wx.ID_ANY)
+        self.goto = wx.TextCtrl(parent = self.valuespanel, id = wx.ID_ANY, style = wx.TE_PROCESS_ENTER)
         gotosizer.Add(item = wx.StaticText(parent = self.valuespanel, id = wx.ID_ANY,
                                               label = _("Go to:")), proportion = 0,
                       flag = wx.ALIGN_CENTER_VERTICAL | wx.RIGHT, border = 5)
@@ -270,13 +272,14 @@
         self.list_columns.Bind(wx.EVT_LISTBOX,   self.OnAddColumn)
         self.list_values.Bind(wx.EVT_LISTBOX,    self.OnAddValue)
         self.goto.Bind(wx.EVT_TEXT,              self.OnGoTo)
+        self.goto.Bind(wx.EVT_TEXT_ENTER,        self.OnAddValue)
 
         self.panel.SetAutoLayout(True)
         self.panel.SetSizer(self.pagesizer)
         self.pagesizer.Fit(self.panel)
         
         self.Layout()
-        self.SetMinSize((400, 550))
+        self.SetMinSize((400, 600))
         self.SetClientSize(self.panel.GetSize())
         self.CenterOnParent()
    



More information about the grass-commit mailing list