CWinCtrlRadio

Script: RADIO

Radio buttons can be grouped radio buttons with each other. When one of the radio button is turned on, the other radio button automatically turns off.

It has the CONTENTS as CHECKBOX . So it is possible to behave as a tab button.

Callbacks arriving at :class:`CWindowBase<CWindowBase>`

class CWinCtrlRadio

Functions / Properties

Boolean check { get; set; }

This value changes the state of the radio button.

  • true:

    Turns ON and OFF the grouped radio buttons. Activate any associated content.

  • false:

    Turn OFF and hide any associated content.

Example of use

// get control
CWinCtrlRadio  rdSelect = find<CWinCtrlRadio>(RADIO_Select);

if (rdSelect.check) {
  //ON
} else {
  //OFF
}

// click callback
override protected void onClick(CWinCtrlBase cCtrl) {
    switch (cCtrl.id) {
      case RADIO_Select:
        break;
    }
}
// hold callback
override protected void onHold(CWinCtrlBase cCtrl) {
    switch (cCtrl.id) {
      case RADIO_Select:
        break;
    }
}