CEGUI::ComboDropList Class Reference

Base class for the combo box drop down list. This is a specialisation of the Listbox class. More...

Inheritance diagram for CEGUI::ComboDropList:

Inheritance graph
[legend]
Collaboration diagram for CEGUI::ComboDropList:

Collaboration graph
[legend]

List of all members.

Public Member Functions

virtual void initialiseComponents (void)
 Initialise the Window based object ready for use.
void setArmed (bool setting)
 Set whether the drop-list is 'armed' for selection.
bool isArmed (void) const
 Return the 'armed' state of the ComboDropList.
void setAutoArmEnabled (bool setting)
 Set the mode of operation for the ComboDropList.
bool isAutoArmEnabled (void) const
 returns the mode of operation for the drop-list
 ComboDropList (const String &type, const String &name)
 Constructor for ComboDropList base class.
virtual ~ComboDropList (void)
 Destructor for ComboDropList base class.

Static Public Attributes

static const String EventNamespace
 Namespace for global events.
static const String WidgetTypeName
 Window factory name.
static const String EventListSelectionAccepted
 Event fired when the user confirms the selection by clicking the mouse.

Protected Member Functions

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.
void onListSelectionAccepted (WindowEventArgs &e)
 Handler for when list selection is confirmed.
virtual void onMouseMove (MouseEventArgs &e)
 Handler called when the mouse cursor has been moved within this window's area.
virtual void onMouseButtonDown (MouseEventArgs &e)
 Handler called when a mouse button has been depressed within this window's area.
virtual void onMouseButtonUp (MouseEventArgs &e)
 Handler called when a mouse button has been released within this window's area.
virtual void onCaptureLost (WindowEventArgs &e)
 Handler called when this window loses capture of mouse inputs.
virtual void onActivated (ActivationEventArgs &e)
 Handler called when this window has become the active window.
virtual void onListContentsChanged (WindowEventArgs &e)
 Handler called internally when the list contents are changed.
virtual void onSelectionChanged (WindowEventArgs &e)
 Handler called internally when the currently selected item or items changes.

Protected Attributes

bool d_autoArm
 true if the box auto-arms when the mouse enters it.
bool d_armed
 true when item selection has been armed.
ListboxItemd_lastClickSelected
 Item last accepted by user.


Detailed Description

Base class for the combo box drop down list. This is a specialisation of the Listbox class.

Member Function Documentation

void CEGUI::ComboDropList::initialiseComponents ( void   )  [virtual]

Initialise the Window based object ready for use.

Note:
This must be called for every window created. Normally this is handled automatically by the WindowFactory for each Window type.
Returns:
Nothing

Reimplemented from CEGUI::Listbox.

References CEGUI::Listbox::getHorzScrollbar(), CEGUI::Listbox::getVertScrollbar(), and CEGUI::Window::setRestoreCapture().

bool CEGUI::ComboDropList::isArmed ( void   )  const [inline]

Return the 'armed' state of the ComboDropList.

Returns:
  • true if the box is armed; items will be highlighted and the next left button up event will cause dismissal and possible item selection.
  • false if the box is not armed; items will not be highlighted or selected until the box is armed.

bool CEGUI::ComboDropList::isAutoArmEnabled ( void   )  const [inline]

returns the mode of operation for the drop-list

Returns:
  • true if the ComboDropList auto-arms when the mouse enters the box.
  • false if the user must click to arm the box.

void CEGUI::ComboDropList::onActivated ( ActivationEventArgs e  )  [protected, virtual]

Handler called when this window has become the active window.

Parameters:
e ActivationEventArgs class whose 'otherWindow' field is set to the window that previously was active, or NULL for none.

Reimplemented from CEGUI::Window.

void CEGUI::ComboDropList::onCaptureLost ( WindowEventArgs e  )  [protected, virtual]

Handler called when this window loses capture of mouse inputs.

Parameters:
e WindowEventArgs object whose 'window' pointer field is set to the window that triggered the event. For this event the trigger window is always 'this'.

Reimplemented from CEGUI::Window.

References CEGUI::Listbox::clearAllSelections_impl(), d_armed, d_lastClickSelected, CEGUI::EventArgs::handled, CEGUI::Window::hide(), CEGUI::ListboxItem::isSelected(), and CEGUI::Listbox::setItemSelectState().

void CEGUI::ComboDropList::onMouseButtonDown ( MouseEventArgs e  )  [protected, virtual]

Handler called when a mouse button has been depressed within this window's area.

Parameters:
e MouseEventArgs object. All fields are valid.

Reimplemented from CEGUI::Listbox.

References CEGUI::MouseEventArgs::button, CEGUI::Listbox::clearAllSelections(), d_armed, CEGUI::EventArgs::handled, CEGUI::Window::isHit(), CEGUI::LeftButton, CEGUI::MouseEventArgs::position, and CEGUI::Window::releaseInput().

void CEGUI::ComboDropList::onMouseButtonUp ( MouseEventArgs e  )  [protected, virtual]

Handler called when a mouse button has been released within this window's area.

Parameters:
e MouseEventArgs object. All fields are valid.

Reimplemented from CEGUI::Window.

References CEGUI::MouseEventArgs::button, d_armed, CEGUI::Window::getChildAtPosition(), CEGUI::Listbox::getSelectedCount(), CEGUI::EventArgs::handled, CEGUI::LeftButton, onListSelectionAccepted(), CEGUI::MouseEventArgs::position, and CEGUI::Window::releaseInput().

void CEGUI::ComboDropList::onMouseMove ( MouseEventArgs e  )  [protected, virtual]

void CEGUI::ComboDropList::setArmed ( bool  setting  )  [inline]

Set whether the drop-list is 'armed' for selection.

Note:
This setting is not exclusively under client control; the ComboDropList will auto-arm in response to certain left mouse button events. This is also dependant upon the autoArm setting of the ComboDropList.
Parameters:
setting 
  • true to arm the box; items will be highlighted and the next left button up event will cause dismissal and possible item selection.
  • false to disarm the box; items will not be highlighted or selected until the box is armed.

Returns:
Nothing.

void CEGUI::ComboDropList::setAutoArmEnabled ( bool  setting  )  [inline]

Set the mode of operation for the ComboDropList.

Parameters:
setting 
  • true if the ComboDropList auto-arms when the mouse enters the box.
  • false if the user must click to arm the box.
Returns:
Nothing.

Referenced by CEGUI::Combobox::setSingleClickEnabled().

virtual bool CEGUI::ComboDropList::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.

Parameters:
class_name The class name that is to be checked.
Returns:
true if this window was inherited from class_name. false if not.

Reimplemented from CEGUI::Listbox.

References CEGUI::Listbox::testClassName_impl().


Generated on Thu Nov 27 20:34:33 2008 for Crazy Eddies GUI System by  doxygen 1.5.7.1