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

svn_grass at osgeo.org svn_grass at osgeo.org
Fri Mar 6 11:27:27 EST 2009


Author: martinl
Date: 2009-03-06 11:27:27 -0500 (Fri, 06 Mar 2009)
New Revision: 36211

Modified:
   grass/trunk/gui/wxpython/gui_modules/menuform.py
Log:
wxGUI: don't show 'Manual' tab if manual page is missing
	(merge from devbr6, r36210)


Modified: grass/trunk/gui/wxpython/gui_modules/menuform.py
===================================================================
--- grass/trunk/gui/wxpython/gui_modules/menuform.py	2009-03-06 16:25:37 UTC (rev 36210)
+++ grass/trunk/gui/wxpython/gui_modules/menuform.py	2009-03-06 16:27:27 UTC (rev 36211)
@@ -928,12 +928,15 @@
         else:
             self.goutput = None
             self.goutputId = -1
-            
+        
         self.manual_tab = helpPanel(parent = self.notebook, grass_command = self.task.name)
         self.manual_tabsizer = wx.BoxSizer(wx.VERTICAL)
-        self.notebook.AddPage(self.manual_tab, text=_("Manual"))
-        self.manual_tab_id = self.notebook.GetPageCount() - 1
-
+        if not os.path.isfile(self.manual_tab.fspath + self.task.name + ".html"):
+            self.manual_tab.Hide()
+        else:
+            self.notebook.AddPage(self.manual_tab, text=_("Manual"))
+            self.manual_tab_id = self.notebook.GetPageCount() - 1
+        
         self.notebook.SetSelection(0)
 
         panelsizer.Add(item=self.notebook, proportion=1, flag=wx.EXPAND )



More information about the grass-commit mailing list