Explorar o código

wxGUI: close current workspace and create new one when creating new location

git-svn-id: https://svn.osgeo.org/grass/grass/trunk@58254 15284696-431f-4ddb-bdfa-cd5b030d7da7
Martin Landa %!s(int64=11) %!d(string=hai) anos
pai
achega
df076369c8
Modificáronse 1 ficheiros con 5 adicións e 2 borrados
  1. 5 2
      gui/wxpython/lmgr/frame.py

+ 5 - 2
gui/wxpython/lmgr/frame.py

@@ -396,7 +396,10 @@ class GMFrame(wx.Frame):
                               location = location,
                               mapset = 'PERMANENT') != 0:
                     return
-                
+
+                # close current workspace and create new one
+                self.OnWorkspaceClose()
+                self.OnWorkspaceNew()
                 GMessage(parent = self,
                          message = _("Current location is <%(loc)s>.\n"
                                      "Current mapset is <%(mapset)s>.") % \
@@ -867,7 +870,7 @@ class GMFrame(wx.Frame):
                           mapset = mapset) != 0:
                 return # error reported
             
-            # close workspace
+            # close current workspace and create new one
             self.OnWorkspaceClose()
             self.OnWorkspaceNew()
             GMessage(parent = self,