Author: reinhard Date: 2010-12-03 11:29:37 -0600 (Fri, 03 Dec 2010) New Revision: 10264
Modified: trunk/gnue-forms/ trunk/gnue-forms/src/uidrivers/wx/widgets/entry.py Log: Show current record in a grid (not only for label-style entries). Property changes on: trunk/gnue-forms ___________________________________________________________________ Name: bzr:revision-info - timestamp: 2010-12-03 11:58:45.086999893 +0100 committer: Reinhard Müller <[email protected]> properties: branch-nick: forms + timestamp: 2010-12-03 12:21:40.121000051 +0100 committer: Reinhard Müller <[email protected]> properties: branch-nick: forms Name: bzr:file-ids - src/GFObjects/GFTabStop.py 3...@3a364389-8fce-0310-8f11-cc363fde16c7:trunk%2Fgnue-forms:src%2FGFObjects%2FGFTabStop.py + src/uidrivers/wx/widgets/entry.py 10...@3a364389-8fce-0310-8f11-cc363fde16c7:trunk%2Fgnue-forms:src%2Fuidrivers%2Fwx%2Fwidgets%2Fentry.py Name: bzr:revision-id:v4 - 3116 [email protected] 3117 [email protected] 3118 [email protected] 3119 [email protected] 3120 [email protected] 3121 [email protected] 3122 [email protected] 3123 [email protected] 3124 [email protected] 3125 [email protected] 3126 [email protected] 3127 [email protected] 3128 [email protected] 3129 [email protected] 3130 [email protected] 3131 [email protected] 3132 [email protected] 3133 [email protected] 3134 [email protected] 3135 [email protected] 3136 [email protected] 3137 [email protected] 3138 [email protected] 3139 [email protected] 3140 [email protected] 3141 [email protected] 3142 [email protected] 3143 [email protected] 3144 [email protected] 3145 [email protected] 3146 [email protected] 3147 [email protected] 3148 [email protected] 3149 [email protected] 3150 [email protected] 3151 [email protected] 3152 [email protected] 3153 [email protected] 3154 [email protected] 3155 [email protected] 3156 [email protected] 3157 [email protected] 3158 [email protected] 3159 [email protected] 3160 [email protected] 3161 [email protected] 3162 [email protected] 3163 [email protected] 3164 [email protected] 3165 [email protected] 3166 [email protected] 3167 [email protected] 3168 [email protected] 3169 [email protected] 3170 [email protected] + 3116 [email protected] 3117 [email protected] 3118 [email protected] 3119 [email protected] 3120 [email protected] 3121 [email protected] 3122 [email protected] 3123 [email protected] 3124 [email protected] 3125 [email protected] 3126 [email protected] 3127 [email protected] 3128 [email protected] 3129 [email protected] 3130 [email protected] 3131 [email protected] 3132 [email protected] 3133 [email protected] 3134 [email protected] 3135 [email protected] 3136 [email protected] 3137 [email protected] 3138 [email protected] 3139 [email protected] 3140 [email protected] 3141 [email protected] 3142 [email protected] 3143 [email protected] 3144 [email protected] 3145 [email protected] 3146 [email protected] 3147 [email protected] 3148 [email protected] 3149 [email protected] 3150 [email protected] 3151 [email protected] 3152 [email protected] 3153 [email protected] 3154 [email protected] 3155 [email protected] 3156 [email protected] 3157 [email protected] 3158 [email protected] 3159 [email protected] 3160 [email protected] 3161 [email protected] 3162 [email protected] 3163 [email protected] 3164 [email protected] 3165 [email protected] 3166 [email protected] 3167 [email protected] 3168 [email protected] 3169 [email protected] 3170 [email protected] 3171 [email protected] Name: bzr:text-parents - src/GFObjects/GFTabStop.py [email protected] + src/uidrivers/wx/widgets/entry.py [email protected] Modified: trunk/gnue-forms/src/uidrivers/wx/widgets/entry.py =================================================================== --- trunk/gnue-forms/src/uidrivers/wx/widgets/entry.py 2010-12-03 11:01:17 UTC (rev 10263) +++ trunk/gnue-forms/src/uidrivers/wx/widgets/entry.py 2010-12-03 17:29:37 UTC (rev 10264) @@ -684,13 +684,15 @@ def _ui_set_current_row_(self, index): - # If we are a label in a grid, change the background color. - if self.in_grid and self._gfObject.style.lower() == 'label': + # If we are in a grid, change the background color. + if self.in_grid: # Reset old current row to normal color. if self.__current_row is not None: widget = self.widgets[self.__current_row] - widget.SetForegroundColour(wx.NullColour) - widget._gnue_label_.SetForegroundColour(wx.NullColour) + if widget._gnue_label_ is not None: + widget._gnue_label_.SetForegroundColour(wx.NullColour) + else: + widget.SetForegroundColour(wx.NullColour) widget.GetParent().SetBackgroundColour( self.__current_row_color_save) widget.GetParent().Refresh() # Needed for Windows @@ -704,10 +706,12 @@ widget = self.widgets[index] self.__current_row_color_save = \ widget.GetParent().GetBackgroundColour() - widget.SetForegroundColour( - wx.SystemSettings_GetColour(wx.SYS_COLOUR_HIGHLIGHTTEXT)) - widget._gnue_label_.SetForegroundColour( - wx.SystemSettings_GetColour(wx.SYS_COLOUR_HIGHLIGHTTEXT)) + if widget._gnue_label_ is not None: + widget._gnue_label_.SetForegroundColour( + wx.SystemSettings_GetColour(wx.SYS_COLOUR_HIGHLIGHTTEXT)) + else: + widget.SetForegroundColour( + wx.SystemSettings_GetColour(wx.SYS_COLOUR_HIGHLIGHTTEXT)) widget.GetParent().SetBackgroundColour( wx.SystemSettings_GetColour(wx.SYS_COLOUR_HIGHLIGHT)) widget.GetParent().Refresh() # Needed for Windows _______________________________________________ commit-gnue mailing list [email protected] http://lists.gnu.org/mailman/listinfo/commit-gnue
