[GRASS-SVN] r63435 - in grass/trunk/gui/wxpython: core mapdisp

svn_grass at osgeo.org svn_grass at osgeo.org
Mon Dec 8 04:08:23 PST 2014


Author: martinl
Date: 2014-12-08 04:08:23 -0800 (Mon, 08 Dec 2014)
New Revision: 63435

Modified:
   grass/trunk/gui/wxpython/core/render.py
   grass/trunk/gui/wxpython/mapdisp/frame.py
Log:
wxGUI: avoid creating Map() instance twice

Modified: grass/trunk/gui/wxpython/core/render.py
===================================================================
--- grass/trunk/gui/wxpython/core/render.py	2014-12-08 10:36:34 UTC (rev 63434)
+++ grass/trunk/gui/wxpython/core/render.py	2014-12-08 12:08:23 UTC (rev 63435)
@@ -389,6 +389,7 @@
 
         :param gisrc: alternative gisrc (used eg. by georectifier)
         """
+        Debug.msg (1, "Map.__init__(): %s" % gisrc)
         # region/extent settigns
         self.wind      = dict() # WIND settings (wind file)
         self.region    = dict() # region settings (g.region)

Modified: grass/trunk/gui/wxpython/mapdisp/frame.py
===================================================================
--- grass/trunk/gui/wxpython/mapdisp/frame.py	2014-12-08 10:36:34 UTC (rev 63434)
+++ grass/trunk/gui/wxpython/mapdisp/frame.py	2014-12-08 12:08:23 UTC (rev 63435)
@@ -68,7 +68,7 @@
     """
     def __init__(self, parent, giface, title = _("GRASS GIS - Map display"),
                  toolbars = ["map"], tree = None, notebook = None, lmgr = None,
-                 page = None, Map = Map(), auimgr = None, name = 'MapWindow', **kwargs):
+                 page = None, Map = None, auimgr = None, name = 'MapWindow', **kwargs):
         """Main map display window with toolbars, statusbar and
         2D map window, 3D map window and digitizer.
         
@@ -83,7 +83,7 @@
         :param kwargs: wx.Frame attributes
         """
         SingleMapFrame.__init__(self, parent = parent, title = title,
-                              Map = Map, auimgr = auimgr, name = name, **kwargs)
+                                Map = Map, auimgr = auimgr, name = name, **kwargs)
         
         self._giface = giface
         # Layer Manager object



More information about the grass-commit mailing list