Browse Source

wxGUI/vdigit: cancel action when tool changed (trac https://trac.osgeo.org/grass/ticket/286)
(merge from relbr64, https://trac.osgeo.org/grass/changeset/36423)


git-svn-id: https://svn.osgeo.org/grass/grass/trunk@36425 15284696-431f-4ddb-bdfa-cd5b030d7da7

Martin Landa 16 years ago
parent
commit
260ba29793
1 changed files with 4 additions and 0 deletions
  1. 4 0
      gui/wxpython/gui_modules/toolbars.py

+ 4 - 0
gui/wxpython/gui_modules/toolbars.py

@@ -607,6 +607,10 @@ class VDigitToolbar(AbstractToolbar):
         # clear tmp canvas
         if self.action['id'] != id:
             self.parent.MapWindow.ClearLines(pdc=self.parent.MapWindow.pdcTmp)
+            if self.parent.digit and \
+                    len(self.parent.digit.driver.GetSelected()) > 0:
+                # cancel action
+                self.parent.MapWindow.OnMiddleDown(None)
         
     def OnAddPoint(self, event):
         """Add point to the vector map Laier"""