Author: reinhard Date: 2010-01-28 05:53:45 -0600 (Thu, 28 Jan 2010) New Revision: 10149
Modified: trunk/gnue-forms/src/GFObjects/GFEntry.py trunk/gnue-forms/src/GFObjects/GFField.py trunk/gnue-forms/src/GFObjects/GFObj.py trunk/gnue-forms/src/GFObjects/GFParameter.py trunk/gnue-forms/src/GFObjects/commanders.py Log: Allow for all widgets to be hidden. Modified: trunk/gnue-forms/src/GFObjects/GFEntry.py =================================================================== --- trunk/gnue-forms/src/GFObjects/GFEntry.py 2010-01-28 10:08:47 UTC (rev 10148) +++ trunk/gnue-forms/src/GFObjects/GFEntry.py 2010-01-28 11:53:45 UTC (rev 10149) @@ -59,15 +59,12 @@ self._triggerSet = self.triggerSetValue self._triggerGet = self.getValue - self._triggerProperties = { + self._triggerProperties.update({ 'rows': {'get': self.triggerGetRows}, 'value': {'set': self.triggerSetValue, 'get': self.getValue}, - 'hidden': {'set': self.triggerSetHidden, - 'get': self.triggerGetHidden}, 'navigable':{'set': self.triggerSetNavigable, - 'get': self.triggerGetNavigable}, - } + 'get': self.triggerGetNavigable}}) # ------------------------------------------------------------------------- @@ -165,18 +162,6 @@ # ------------------------------------------------------------------------- - def triggerSetHidden(self, value): - - self.hidden = bool(value) - - # ------------------------------------------------------------------------- - - def triggerGetHidden(self): - - return self.hidden - - # ------------------------------------------------------------------------- - def triggerSetNavigable(self, value): self.navigable = bool(value) Modified: trunk/gnue-forms/src/GFObjects/GFField.py =================================================================== --- trunk/gnue-forms/src/GFObjects/GFField.py 2010-01-28 10:08:47 UTC (rev 10148) +++ trunk/gnue-forms/src/GFObjects/GFField.py 2010-01-28 11:53:45 UTC (rev 10149) @@ -133,13 +133,13 @@ 'getFKDescription' : {'function': self.get_value}, 'setFKDescription' : {'function': self.set_value}} - self._triggerProperties = { + self._triggerProperties.update({ 'value': { 'get': self.get_value, 'set': self.set_value}, 'editable': { 'get': self.__get_editable, - 'set': self.__set_editable}} + 'set': self.__set_editable}}) self._triggerGet = self.__get_value self._triggerSet = self.__set_value Modified: trunk/gnue-forms/src/GFObjects/GFObj.py =================================================================== --- trunk/gnue-forms/src/GFObjects/GFObj.py 2010-01-28 10:08:47 UTC (rev 10148) +++ trunk/gnue-forms/src/GFObjects/GFObj.py 2010-01-28 11:53:45 UTC (rev 10149) @@ -77,7 +77,12 @@ # uidrivers._base.UIdriver._buildUI () function. self.uiWidget = None + self._triggerProperties = { + 'hidden': {'set': self.__set_hidden, + 'get': self.__get_hidden}, + } + # ------------------------------------------------------------------------- # Phase 1 initialization # ------------------------------------------------------------------------- @@ -205,3 +210,18 @@ return False has_label = property(__get_has_label) + + + # ------------------------------------------------------------------------- + # Trigger functions + # ------------------------------------------------------------------------- + + def __set_hidden(self, value): + + self.hidden = bool(value) + + # ------------------------------------------------------------------------- + + def __get_hidden(self): + + return self.hidden Modified: trunk/gnue-forms/src/GFObjects/GFParameter.py =================================================================== --- trunk/gnue-forms/src/GFObjects/GFParameter.py 2010-01-28 10:08:47 UTC (rev 10148) +++ trunk/gnue-forms/src/GFObjects/GFParameter.py 2010-01-28 11:53:45 UTC (rev 10149) @@ -71,10 +71,10 @@ # Trigger support self._triggerGlobal = True - self._triggerProperties = { + self._triggerProperties.update({ 'value': { 'get': self.__get_value, - 'set': self.__set_value}} + 'set': self.__set_value}}) # ------------------------------------------------------------------------- Modified: trunk/gnue-forms/src/GFObjects/commanders.py =================================================================== --- trunk/gnue-forms/src/GFObjects/commanders.py 2010-01-28 10:08:47 UTC (rev 10148) +++ trunk/gnue-forms/src/GFObjects/commanders.py 2010-01-28 11:53:45 UTC (rev 10149) @@ -92,13 +92,13 @@ self._inits.append(self._phase_2_init_) # Trigger support - _triggerProperties = { + self._triggerProperties.update({ 'state': { 'get': self.__trigger_get_state, 'set': self.__trigger_set_state}, 'enabled': { 'get': self.__trigger_get_enabled, - 'set': self.__trigger_set_enabled}} + 'set': self.__trigger_set_enabled}}) # ------------------------------------------------------------------------- _______________________________________________ commit-gnue mailing list commit-gnue@gnu.org http://lists.gnu.org/mailman/listinfo/commit-gnue