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

svn_grass at osgeo.org svn_grass at osgeo.org
Wed Mar 23 17:54:42 EDT 2011


Author: martinl
Date: 2011-03-23 14:54:42 -0700 (Wed, 23 Mar 2011)
New Revision: 45739

Modified:
   grass/trunk/gui/wxpython/gui_modules/gcmd.py
Log:
wxGUI: showTraceback


Modified: grass/trunk/gui/wxpython/gui_modules/gcmd.py
===================================================================
--- grass/trunk/gui/wxpython/gui_modules/gcmd.py	2011-03-23 16:27:21 UTC (rev 45738)
+++ grass/trunk/gui/wxpython/gui_modules/gcmd.py	2011-03-23 21:54:42 UTC (rev 45739)
@@ -59,7 +59,7 @@
 from debug import Debug as Debug
 
 class GError:
-    def __init__(self, message, parent = None, caption = None):
+    def __init__(self, message, parent = None, caption = None, showTraceback = True):
         if not caption:
             caption = _('Error')
         style = wx.OK | wx.ICON_ERROR | wx.CENTRE
@@ -71,7 +71,7 @@
         if Debug.GetLevel() > 0 and exc_traceback:
             sys.stderr.write(exception)
         
-        if exc_traceback:
+        if showTraceback and exc_traceback:
             wx.MessageBox(parent = parent,
                           message = message + '\n\n%s: %s\n\n%s' % \
                               (_('Reason'),



More information about the grass-commit mailing list