[GRASS-SVN] r29543 - grass/trunk/gui/wxpython

svn_grass at osgeo.org svn_grass at osgeo.org
Sun Dec 30 16:45:59 EST 2007


Author: cmbarton
Date: 2007-12-30 16:45:59 -0500 (Sun, 30 Dec 2007)
New Revision: 29543

Modified:
   grass/trunk/gui/wxpython/gis_set.py
Log:
Sort mapset list so that PERMANENT is at the top.

Modified: grass/trunk/gui/wxpython/gis_set.py
===================================================================
--- grass/trunk/gui/wxpython/gis_set.py	2007-12-30 11:51:27 UTC (rev 29542)
+++ grass/trunk/gui/wxpython/gis_set.py	2007-12-30 21:45:59 UTC (rev 29543)
@@ -512,10 +512,11 @@
         """Update list of mapsets"""
         self.listOfMapsets = []
 
+        self.listOfMapsets.append('PERMANENT')
         for mapset in glob.glob(os.path.join(self.gisdbase, location, "*")):
-            if os.path.isdir(mapset):
+            if os.path.isdir(mapset) and os.path.basename(mapset) != 'PERMANENT':
                 self.listOfMapsets.append(os.path.basename(mapset))
-
+ 
         self.lbmapsets.Clear()
         self.lbmapsets.InsertItems(self.listOfMapsets,0)
 



More information about the grass-commit mailing list