libyui
Public Member Functions | Protected Member Functions

YRadioButtonGroup Class Reference

Inheritance diagram for YRadioButtonGroup:
YSingleChildContainerWidget YWidget

List of all members.

Public Member Functions

virtual ~YRadioButtonGroup ()
virtual const char * widgetClass () const
YRadioButtoncurrentButton () const
YRadioButtonvalue () const
virtual void addRadioButton (YRadioButton *radioButton)
virtual void removeRadioButton (YRadioButton *radioButton)
void uncheckOtherButtons (YRadioButton *radioButton)
virtual bool setProperty (const string &propertyName, const YPropertyValue &val)
virtual YPropertyValue getProperty (const std::string &propertyName)
virtual const YPropertySetpropertySet ()

Protected Member Functions

 YRadioButtonGroup (YWidget *parent)
YRadioButtonListConstIterator radioButtonsBegin () const
YRadioButtonListConstIterator radioButtonsEnd () const
int radioButtonsCount () const

Constructor & Destructor Documentation

YRadioButtonGroup::YRadioButtonGroup ( YWidget parent) [protected]

Constructor.

YRadioButtonGroup::~YRadioButtonGroup ( ) [virtual]

Destructor.


Member Function Documentation

void YRadioButtonGroup::addRadioButton ( YRadioButton radioButton) [virtual]

Add a RadioButton to this button group. RadioButtons are required to call this in their constructor.

Derived classes are free to overload this, but they should call this base class function in the overloaded function.

YRadioButton * YRadioButtonGroup::currentButton ( ) const

Find the currently selected button.

virtual YPropertyValue YRadioButtonGroup::getProperty ( const std::string &  propertyName) [virtual]

Get a property. Reimplemented from YWidget.

This method may throw exceptions, for example

  • if there is no property with that name
const YPropertySet & YRadioButtonGroup::propertySet ( ) [virtual]

Return this class's property set. This also initializes the property set upon the first call.

Reimplemented from YWidget.

Reimplemented from YWidget.

YRadioButtonListConstIterator YRadioButtonGroup::radioButtonsBegin ( ) const [protected]

Return an iterator that points to the first RadioButton of this button group.

Note that RadioButtons in this group may be direct or indirect children of the group, so don't confuse this with YWidget::widgetsBegin().

int YRadioButtonGroup::radioButtonsCount ( ) const [protected]

Return the number of RadioButtons in this button group.

YRadioButtonListConstIterator YRadioButtonGroup::radioButtonsEnd ( ) const [protected]

Return an iterator that points behind the last RadioButton of this button group.

void YRadioButtonGroup::removeRadioButton ( YRadioButton radioButton) [virtual]

Remove a RadioButton from this button group. RadioButtons are required to call this in their destructor, but only if the button group is not also in the process of being destroyed (otherwise there may be race conditions with child widgets already destroyed):

if ( ! buttonGroup()->beingDestroyed ) buttonGroup()->removeRadioButton( this );

bool YRadioButtonGroup::setProperty ( const string &  propertyName,
const YPropertyValue val 
) [virtual]

Set a property. Reimplemented from YWidget.

This method may throw exceptions, for example

  • if there is no property with that name
  • if the expected type and the type mismatch
  • if the value is out of range

This function returns 'true' if the value was successfully set and 'false' if that value requires special handling (not in error cases: those are covered by exceptions).

Reimplemented from YWidget.

void YRadioButtonGroup::uncheckOtherButtons ( YRadioButton radioButton)

Unchecks all radio buttons except one. This method can be used by a concrete UI (the Qt UI or the NCurses UI) in the implementation of YRadioButton::setValue().

YRadioButton* YRadioButtonGroup::value ( ) const [inline]

The same as currentButton() above for convenience.

virtual const char* YRadioButtonGroup::widgetClass ( ) const [inline, virtual]

Returns a descriptive name of this widget class for logging, debugging etc.

Reimplemented from YWidget.


The documentation for this class was generated from the following files:
 All Classes Functions Variables Enumerations Friends