#include <uchoice.hpp>
Inheritance diagram for ubit::URadioSelect:

Public Member Functions | |
| URadioSelect (UInteger &index) | |
| constructor. | |
| virtual void | setCanUnselectMode (bool) |
| virtual bool | isCanUnselectMode () const |
| clicking on a selected item will unselect it if true (default is false). | |
| virtual void | clearSelection () |
| deselects the selected object (if any). | |
| virtual UGroup * | getSelectedItem () const |
| returns the selected object; returns null if there is no selected object. | |
| virtual void | setSelectedItem (UGroup &) |
| selects this object. | |
| UInteger & | index () const |
| virtual int | getSelectedIndex () const |
| returns the index of the selected object; returns -1 if there is no selected object. | |
| virtual void | setSelectedIndex (int n) |
| virtual void | setSelectedIndex (const UInteger &n) |
| selects the Nth object; selects the last selectable object if n = -1. | |
| virtual void | update () |
| updates parents graphics. | |
Friends | |
| URadioSelect & | uradioSelect () |
| creator shortcut that return *new URadioSelect; | |
This selector must be a child of the items it selects. These items are automatically made selectable (for instance an UButton will becone selectable if an USelect is added to it as a child).
Exemple:
URadioSelect& sel = uradioSelect();
ubox( ubutton(sel + "One" + UMode::selected)
+ ucheckbox(sel + "Two")
+ utextbox(sel + "Three")
)
| ubit::URadioSelect::URadioSelect | ( | UInteger & | index | ) |
constructor.
Notes:
1.4.7