[GRASS-SVN] r46886 - grass/trunk/gui/wxpython/gui_modules
svn_grass at osgeo.org
svn_grass at osgeo.org
Fri Jul 1 03:38:59 EDT 2011
Author: martinl
Date: 2011-07-01 00:38:59 -0700 (Fri, 01 Jul 2011)
New Revision: 46886
Modified:
grass/trunk/gui/wxpython/gui_modules/preferences.py
Log:
wxGUI: clean up savings settings
Modified: grass/trunk/gui/wxpython/gui_modules/preferences.py
===================================================================
--- grass/trunk/gui/wxpython/gui_modules/preferences.py 2011-07-01 07:26:49 UTC (rev 46885)
+++ grass/trunk/gui/wxpython/gui_modules/preferences.py 2011-07-01 07:38:59 UTC (rev 46886)
@@ -764,15 +764,13 @@
if settings is None:
settings = self.userSettings
- home = os.path.expanduser("~") # MS Windows fix ?
-
dirPath = utils.GetSettingsPath()
- if os.path.exists(dirPath) == False:
+ if not os.path.exists(dirPath):
try:
os.mkdir(dirPath)
except:
- wx.MessageBox(_('Cannot create directory for settings [home]/.grass7'),
- _('Error saving preferences'))
+ gcmd.GError(_('Unable to create settings directory'))
+ return
try:
file = open(self.filePath, "w")
More information about the grass-commit
mailing list