Skip to main content

sync_radio_selected

Function sync_radio_selected 

Source
pub fn sync_radio_selected(
    commands: Commands<'_, '_>,
    store: ResMut<'_, PropertyStore>,
    radios: Query<'_, '_, (Entity, &RadioButton, Option<&Selected>, Option<&DocumentOrder>, Has<Disabled>)>,
)
Expand description

Mirror each group’s signal onto the Selected marker, and enforce exactly-one-selected: a group whose signal is unset (or empty) gets its first enabled member (markup order) selected and the signal seeded.