Skip to content

Commit

Permalink
wxGUI/vselect: fix output fully qualified vector name (OSGeo#2483)
Browse files Browse the repository at this point in the history
For the correct way to remove a vector map layer from the Map Display
tree if map is removed from the Data Catalog tree.
  • Loading branch information
tmszi committed Jul 19, 2022
1 parent effc544 commit 006a3c7
Showing 1 changed file with 10 additions and 3 deletions.
13 changes: 10 additions & 3 deletions gui/wxpython/gui_core/vselect.py
Original file line number Diff line number Diff line change
Expand Up @@ -345,9 +345,16 @@ def OnExportMap(self, event):
if ret == 0:
tree = self._giface.GetLayerTree()
if tree:
tree.AddLayer(ltype='vector', lname=outMap,
lcmd=['d.vect', 'map=%s' % outMap],
lchecked=True)
outMap = "{map_name}@{mapset}".format(
map_name=outMap,
mapset=grass.gisenv()["MAPSET"],
)
tree.AddLayer(
ltype="vector",
lname=outMap,
lcmd=["d.vect", "map=%s" % outMap],
lchecked=True,
)

# TODO colorize new map
self.Reset()
Expand Down

0 comments on commit 006a3c7

Please sign in to comment.