feisty meow concerns codebase
2.140
|
A base class for the active items that can be stored inside a menu. More...
#include <menu_base.h>
Public Member Functions | |
menu_item (const string_array &triggers, const astring &text, const astring &description) | |
constructs a menu item that shows the "text" and "description". More... | |
menu_item (const menu_item &to_copy) | |
virtual | ~menu_item () |
menu_item & | operator= (const menu_item &to_copy) |
DEFINE_CLASS_NAME ("menu_item") | |
const string_array & | triggers () const |
const astring & | text () const |
const astring & | description () const |
virtual void | menu_activation (char trigger) |
invoked when the user chooses the menu item in question. More... | |
Public Member Functions inherited from menu_common_base | |
virtual | ~menu_common_base () |
bool | enabled () const |
void | enable (bool enable=true) |
A base class for the active items that can be stored inside a menu.
Definition at line 47 of file menu_base.h.
menu_item::menu_item | ( | const string_array & | triggers, |
const astring & | text, | ||
const astring & | description | ||
) |
constructs a menu item that shows the "text" and "description".
the "triggers" is a list of characters that are used to activate this menu item. these correspond to hot keys that are often underlined.
Definition at line 33 of file menu_base.cpp.
menu_item::menu_item | ( | const menu_item & | to_copy | ) |
Definition at line 40 of file menu_base.cpp.
|
virtual |
Definition at line 48 of file menu_base.cpp.
References basis::WHACK().
menu_item::DEFINE_CLASS_NAME | ( | "menu_item" | ) |
const astring & menu_item::description | ( | ) | const |
Definition at line 69 of file menu_base.cpp.
|
virtual |
invoked when the user chooses the menu item in question.
the "trigger" holds the value that they actually chose.
Definition at line 63 of file menu_base.cpp.
Definition at line 54 of file menu_base.cpp.
const astring & menu_item::text | ( | ) | const |
Definition at line 67 of file menu_base.cpp.
const string_array & menu_item::triggers | ( | ) | const |
Definition at line 65 of file menu_base.cpp.