Forráskód Böngészése

wxGUI/modeler: color for running actions

git-svn-id: https://svn.osgeo.org/grass/grass/trunk@41907 15284696-431f-4ddb-bdfa-cd5b030d7da7
Martin Landa 15 éve
szülő
commit
7ee80c577c

+ 18 - 1
gui/wxpython/gui_modules/gmodeler.py

@@ -1875,7 +1875,7 @@ class PreferencesDialog(PreferencesBaseDialog):
                       wx.ALIGN_CENTER_VERTICAL,
                       pos = (row, 1))
 
-        row = 1
+        row += 1
         gridSizer.Add(item = wx.StaticText(parent = panel, id = wx.ID_ANY,
                                          label = _("Invalid:")),
                       flag = wx.ALIGN_LEFT |
@@ -1892,6 +1892,23 @@ class PreferencesDialog(PreferencesBaseDialog):
                       wx.ALIGN_CENTER_VERTICAL,
                       pos = (row, 1))
 
+        row += 1
+        gridSizer.Add(item = wx.StaticText(parent = panel, id = wx.ID_ANY,
+                                         label = _("Running:")),
+                      flag = wx.ALIGN_LEFT |
+                      wx.ALIGN_CENTER_VERTICAL,
+                      pos = (row, 0))
+        rColor = csel.ColourSelect(parent = panel, id = wx.ID_ANY,
+                                   colour = self.settings.Get(group='modeler', key='action', subkey=('color', 'running')),
+                                   size = globalvar.DIALOG_COLOR_SIZE)
+        rColor.SetName('GetColour')
+        self.winId['modeler:action:color:running'] = rColor.GetId()
+        
+        gridSizer.Add(item = rColor,
+                      flag = wx.ALIGN_RIGHT |
+                      wx.ALIGN_CENTER_VERTICAL,
+                      pos = (row, 1))
+
         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)
         

+ 2 - 1
gui/wxpython/gui_modules/preferences.py

@@ -514,8 +514,9 @@ class Settings:
             'modeler' : {
                 'action' : {
                     'color' : {
-                        'valid' : (211, 211, 211, 255), # light grey
+                        'valid' :   (211, 211, 211, 255), # light grey
                         'invalid' : (255, 255, 255, 255), # white
+                        'running' : (255, 0, 0),          # running
                         },
                     'size' : {
                         'width' : 100,