SetEnabled sets the [states.Disabled] flag to the opposite of the given value.
(enabled bool)
| 46 | |
| 47 | // SetEnabled sets the [states.Disabled] flag to the opposite of the given value. |
| 48 | func (wb *WidgetBase) SetEnabled(enabled bool) *WidgetBase { |
| 49 | return wb.SetState(!enabled, states.Disabled) |
| 50 | } |
| 51 | |
| 52 | // IsDisabled returns whether this node is flagged as [Disabled]. |
| 53 | // If so, behave and style appropriately. |
no test coverage detected