Public Member Functions | |
bool | isSelected (void) const |
return true if the check-box is selected (has the checkmark) | |
void | setSelected (bool select) |
set whether the check-box is selected or not | |
Checkbox (const String &type, const String &name) | |
Constructor for Checkbox class. | |
virtual | ~Checkbox (void) |
Destructor for Checkbox class. | |
Static Public Attributes | |
static const String | EventNamespace |
Namespace for global events. | |
static const String | WidgetTypeName |
Window factory name. | |
static const String | EventCheckStateChanged |
The check-state of the widget has changed. | |
Protected Member Functions | |
virtual void | onSelectStateChange (WindowEventArgs &e) |
event triggered internally when state of check-box changes | |
virtual void | onMouseButtonUp (MouseEventArgs &e) |
Handler called when a mouse button has been released within this window's area. | |
virtual bool | testClassName_impl (const String &class_name) const |
Return whether this window was inherited from the given class name at some point in the inheritance hierarchy. | |
Protected Attributes | |
bool | d_selected |
true if check-box is selected (has checkmark) |
bool CEGUI::Checkbox::isSelected | ( | void | ) | const [inline] |
return true if the check-box is selected (has the checkmark)
void CEGUI::Checkbox::onMouseButtonUp | ( | MouseEventArgs & | e | ) | [protected, virtual] |
Handler called when a mouse button has been released within this window's area.
e | MouseEventArgs object. All fields are valid. |
Reimplemented from CEGUI::ButtonBase.
References CEGUI::MouseEventArgs::button, d_selected, CEGUI::System::getGUISheet(), CEGUI::System::getSingleton(), CEGUI::Window::getTargetChildAtPosition(), CEGUI::EventArgs::handled, CEGUI::ButtonBase::isPushed(), CEGUI::LeftButton, CEGUI::MouseEventArgs::position, and setSelected().
void CEGUI::Checkbox::setSelected | ( | bool | select | ) |
set whether the check-box is selected or not
select | true to select the widget and give it the check-mark. false to de-select the widget and remove the check-mark. |
References d_selected, onSelectStateChange(), and CEGUI::Window::requestRedraw().
Referenced by onMouseButtonUp().
virtual bool CEGUI::Checkbox::testClassName_impl | ( | const String & | class_name | ) | const [inline, protected, virtual] |
Return whether this window was inherited from the given class name at some point in the inheritance hierarchy.
class_name | The class name that is to be checked. |
Reimplemented from CEGUI::ButtonBase.
References CEGUI::ButtonBase::testClassName_impl().