[GRASS-SVN] r46666 - in grass/branches/develbranch_6/gui/wxpython: . gui_modules

svn_grass at osgeo.org svn_grass at osgeo.org
Sun Jun 12 04:19:25 EDT 2011


Author: martinl
Date: 2011-06-12 01:19:25 -0700 (Sun, 12 Jun 2011)
New Revision: 46666

Modified:
   grass/branches/develbranch_6/gui/wxpython/gui_modules/preferences.py
   grass/branches/develbranch_6/gui/wxpython/wxgui.py
Log:
wxGUI: changing menu style requires GUI restart (patch by Vaclav Petras)
       (merge r46665 from trunk)


Modified: grass/branches/develbranch_6/gui/wxpython/gui_modules/preferences.py
===================================================================
--- grass/branches/develbranch_6/gui/wxpython/gui_modules/preferences.py	2011-06-12 08:15:48 UTC (rev 46665)
+++ grass/branches/develbranch_6/gui/wxpython/gui_modules/preferences.py	2011-06-12 08:19:25 UTC (rev 46666)
@@ -1263,7 +1263,7 @@
         gridSizer.AddGrowableCol(0)
 
         #
-        # menu style
+        # element list
         #
         row = 0
         gridSizer.Add(item = wx.StaticText(parent = panel, id = wx.ID_ANY,
@@ -1284,9 +1284,12 @@
                       wx.ALIGN_CENTER_VERTICAL,
                       pos = (row, 1))
         
+        #
+        # menu style
+        #
         row += 1
         gridSizer.Add(item = wx.StaticText(parent = panel, id = wx.ID_ANY,
-                                         label = _("Menu style:")),
+                                           label = _("Menu style (requires GUI restart):")),
                       flag = wx.ALIGN_LEFT |
                       wx.ALIGN_CENTER_VERTICAL,
                       pos = (row, 0))
@@ -1334,10 +1337,10 @@
         #
         row += 1
         gridSizer.Add(item = wx.StaticText(parent = panel, id = wx.ID_ANY,
-                                         label = _("Icon theme:")),
-                       flag = wx.ALIGN_LEFT |
-                       wx.ALIGN_CENTER_VERTICAL,
-                       pos = (row, 0))
+                                           label = _("Icon theme (requires GUI restart):")),
+                      flag = wx.ALIGN_LEFT |
+                      wx.ALIGN_CENTER_VERTICAL,
+                      pos = (row, 0))
         iconTheme = wx.Choice(parent = panel, id = wx.ID_ANY, size = (100, -1),
                               choices = self.settings.Get(group = 'appearance', key = 'iconTheme',
                                                         subkey = 'choices', internal = True),
@@ -1350,14 +1353,6 @@
                       wx.ALIGN_CENTER_VERTICAL,
                       pos = (row, 1))
         
-        row += 1
-        gridSizer.Add(item = wx.StaticText(parent = panel, id = wx.ID_ANY,
-                                         label = _("Note: For changing the icon theme, "
-                                                 "you must save the settings and restart this GUI.")),
-                      flag = wx.ALIGN_CENTER_VERTICAL,
-                      pos = (row, 0), span = (1, 2))
-                              
-
         sizer.Add(item = gridSizer, proportion = 1, flag = wx.ALL | wx.EXPAND, border = 5)
         border.Add(item = sizer, proportion = 0, flag = wx.LEFT | wx.RIGHT | wx.BOTTOM | wx.EXPAND, border = 3)
         
@@ -1367,9 +1362,7 @@
         outfontButton.Bind(wx.EVT_BUTTON, self.OnSetOutputFont)
         
         return panel
-
-
-
+    
     def _createDisplayPage(self, notebook):
         """!Create notebook page for display settings"""
    

Modified: grass/branches/develbranch_6/gui/wxpython/wxgui.py
===================================================================
--- grass/branches/develbranch_6/gui/wxpython/wxgui.py	2011-06-12 08:15:48 UTC (rev 46665)
+++ grass/branches/develbranch_6/gui/wxpython/wxgui.py	2011-06-12 08:19:25 UTC (rev 46666)
@@ -298,9 +298,9 @@
         
     def OnSettingsChanged(self, event):
         """!Here can be functions which have to be called after EVT_SETTINGS_CHANGED. 
-        Now recreates menu and set copying of selected text to clipboard (in goutput).
+        Now only set copying of selected text to clipboard (in goutput).
         """
-        self._createMenuBar()
+        ### self._createMenuBar() # bug when menu is re-created on the fly
         self._setCopyingOfSelectedText()
         
     def OnGCPManager(self, event):



More information about the grass-commit mailing list