#include <guimenu.h>
Inheritance diagram for GuiMenuItem:


Public Types | |
| enum | TYPE { tCheckable, tClickable, tSubmenu } |
Public Member Functions | |
| DECLSPEC | GuiMenuItem (const SDL_Rect &r, GuiMenuBar *parent, const char *name, bool checkable=false, const char *txt=0, SdlSurfaceContainer *b=0, SdlAudio *u=0, SdlAudio *d=0) |
| DECLSPEC | GuiMenuItem (const SDL_Rect &r, GuiMenuBar *parent, const char *name, GuiMenuBar *submenu, const char *txt=NULL, SdlSurfaceContainer *b=0, SdlAudio *u=0, SdlAudio *d=0) |
| virtual const char * | getClassName () |
| int | getItemID () |
| |
| void | setItemID (int id) |
| DECLSPEC void | setSelectable (bool cansel) |
| GuiMenuBar * | getBar () |
| void | setButtonImages (SdlSurfaceContainer *b) |
Friends | |
| class | GuiMenuBar |
| GuiMenuItem::GuiMenuItem | ( | const SDL_Rect & | r, | |
| GuiMenuBar * | parent, | |||
| const char * | name, | |||
| bool | checkable = false, |
|||
| const char * | txt = 0, |
|||
| SdlSurfaceContainer * | b = 0, |
|||
| SdlAudio * | u = 0, |
|||
| SdlAudio * | d = 0 | |||
| ) |
Constructor.
| checkable | the kind of item this should be, checkable or clickable Other params see GuiDynamicButton::GuiDynamicButton() |
| GuiMenuItem::GuiMenuItem | ( | const SDL_Rect & | r, | |
| GuiMenuBar * | parent, | |||
| const char * | name, | |||
| GuiMenuBar * | submenu, | |||
| const char * | txt = NULL, |
|||
| SdlSurfaceContainer * | b = 0, |
|||
| SdlAudio * | u = 0, |
|||
| SdlAudio * | d = 0 | |||
| ) |
Constructor for submenu-items.
| submenu | a pointer to the submenu to be associated with this object or NULL if a new menu-bar should be created (that will be destroyed with this object). |
| virtual const char* GuiMenuItem::getClassName | ( | ) | [inline, virtual] |
This function should be overriden in every sub-class of BasicObject!
Reimplemented from GuiElement.
| void GuiMenuItem::setItemID | ( | int | id | ) | [inline] |
Sets the item's ID.
| id | the new ID |
| void GuiMenuItem::setSelectable | ( | bool | cansel | ) |
Sets whether or not the user can access the item. (The item will be invisible if not).
| cansel | the new value |
| GuiMenuBar* GuiMenuItem::getBar | ( | ) | [inline] |
| void GuiMenuItem::setButtonImages | ( | SdlSurfaceContainer * | b | ) |
Changes the image of the item's button.
| b | the new images for the different button-states |
1.5.1