Skip to content

[feature request] option to prevent "no selection" (aka radio button set) #30

@artificiel

Description

@artificiel

it would be great to be able to enforce at least one selection: in conjunction with disableMultipleSelection(), it would behave like a radio button, where one of the options is always required. perhaps some call like disallowEmptySelectedValue().

thought it would be a simple implementation but (as far as I understand) the ofxDropdownOption process their own mouse clicks and toggle themselves, without being aware if a rule would prevent themselves to toggle off?

would the design be to propagate a new _bDisallowSelfTurningOff bool into the Options? there seems to be the idea around _bSelectOnMouseRelease but it's not clear what happens if the flag is set before children are populated?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions