Selaa lähdekoodia

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 11 vuotta sitten
vanhempi
commit
df076369c8
1 muutettua tiedostoa jossa 5 lisäystä ja 2 poistoa
  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,