[GRASS-SVN] r30891 - grass/trunk/gui/wxpython/gui_modules

svn_grass at osgeo.org svn_grass at osgeo.org
Mon Apr 7 09:54:45 EDT 2008


Author: martinl
Date: 2008-04-07 09:54:45 -0400 (Mon, 07 Apr 2008)
New Revision: 30891

Modified:
   grass/trunk/gui/wxpython/gui_modules/mapdisp.py
Log:
wxGUI (mapdisp): bugfix, set PseudoDC id also for lines/polylines (introduced in r30878)


Modified: grass/trunk/gui/wxpython/gui_modules/mapdisp.py
===================================================================
--- grass/trunk/gui/wxpython/gui_modules/mapdisp.py	2008-04-07 13:35:36 UTC (rev 30890)
+++ grass/trunk/gui/wxpython/gui_modules/mapdisp.py	2008-04-07 13:54:45 UTC (rev 30891)
@@ -245,7 +245,6 @@
         
         if img and pdctype == 'image':
             # self.imagedict[img]['coords'] = coords
-            pdc.SetId(self.imagedict[img]['id'])
             self.select[self.imagedict[img]['id']] = False # ?
 
         pdc.BeginDrawing()
@@ -262,6 +261,10 @@
         Debug.msg (5, "BufferedWindow.Draw(): id=%s, pdctype=%s, coord=%s" % \
                        (drawid, pdctype, coords))
 
+        # set PseudoDC id
+        if drawid:
+            pdc.SetId(drawid)
+        
         if pdctype == 'clear': # erase the display
             bg = wx.WHITE_BRUSH
             # bg = wx.Brush(self.GetBackgroundColour())
@@ -1812,7 +1815,6 @@
 
         return exit
 
-
     def Pixel2Cell(self, (x, y)):
         """
         Convert image coordinates to real word coordinates



More information about the grass-commit mailing list