- Main Page
- Namespaces
- Classes
- Files
- Directories
- Related Pages

- Alphabetical List
- Class List
- Class Hierarchy
- Class Members

# Exponent::GUI::Controls::CSelectableMenuItem Class Reference

Inheritance diagram for Exponent::GUI::Controls::CSelectableMenuItem:

List of all members.

## Detailed Description

A representation of a menu item that can be checked or unchecked.

Date:
  12/04/2005

Author:
  Paul Chana

Version:
  1.0.0 Initial version

Note:
  All contents of this source code are copyright 2005 Exp Digital Uk.
  This source file is covered by the licence conditions of the Infinity API. You should have recieved a copy
  with the source code. If you didnt, please refer to http://www.expdigital.co.uk All content is the Intellectual property of Exp Digital Uk.
  Certain sections of this code may come from other sources. They are credited where applicable.
  If you have comments, suggestions or bug reports please visit http://support.expdigital.co.uk

Id
  CSelectableMenuItem.hpp,v 1.7 2007/02/08 21:07:54 paul Exp

Definition at line 34 of file CSelectableMenuItem.hpp.

## Public Member Functions

- CSelectableMenuItem (const CString &text, const long id, const bool selected=false)
- virtual IImage * getUnCheckedImage () const
- virtual bool isSelected () const
- virtual void setSelected (const bool selected=true)
- virtual void setUnCheckedImage (IImage *unChecked)
- virtual ~CSelectableMenuItem ()

## Protected Attributes

- bool m_isSelected
- IImage * m_unCheckedImage

## Constructor & Destructor Documentation

Exponent::GUI::Controls::CSelectableMenuItem::CSelectableMenuItem | ( | const CString & | text,
|  | const long | id,
|  | const bool | selected = `false` |
| ) |  |  |

Construction

Parameters:

  | text | The string to display
  | id | The unique ID of this menu item
  | selected | True if item is selected, false otherwise

virtual Exponent::GUI::Controls::CSelectableMenuItem::~CSelectableMenuItem | ( |  | ) | `[virtual]`

Destruction

## Member Function Documentation

virtual IImage* Exponent::GUI::Controls::CSelectableMenuItem::getUnCheckedImage | ( |  | ) | const`[inline, virtual]`

Get the unchecked image

Return values:

  | IImage* | The unchecked image, may be NULL

Definition at line 86 of file CSelectableMenuItem.hpp.

References m_unCheckedImage.

virtual bool Exponent::GUI::Controls::CSelectableMenuItem::isSelected | ( |  | ) | const`[inline, virtual]`

Is the item selected

Return values:

  | bool | True if the item is selected, false otherwise

Definition at line 71 of file CSelectableMenuItem.hpp.

References m_isSelected.

virtual void Exponent::GUI::Controls::CSelectableMenuItem::setSelected | ( | const bool | selected = `true` | ) | `[inline, virtual]`

Set the item selected

Parameters:

  | selected | True if the item is selected, false otherwise

Definition at line 65 of file CSelectableMenuItem.hpp.

References m_isSelected.

virtual void Exponent::GUI::Controls::CSelectableMenuItem::setUnCheckedImage | ( | IImage * | unChecked | ) | `[inline, virtual]`

Set the unchecked image (other images are : normal(checked) rollover(rollover)

Parameters:

  | unChecked | The unchecked image

Definition at line 77 of file CSelectableMenuItem.hpp.

References EXCHANGE_COUNTED_OBJECTS, and m_unCheckedImage.

## Member Data Documentation

bool Exponent::GUI::Controls::CSelectableMenuItem::m_isSelected`[protected]`

is the item currently selected

Definition at line 94 of file CSelectableMenuItem.hpp.

Referenced by isSelected(), and setSelected().

IImage* Exponent::GUI::Controls::CSelectableMenuItem::m_unCheckedImage`[protected]`

the image to use to uncheck this

Definition at line 95 of file CSelectableMenuItem.hpp.

Referenced by getUnCheckedImage(), and setUnCheckedImage().