|
Public Types |
enum | { MAX_ENTRY = 1024
} |
Public Member Functions |
| COptionMenu (const CRect &size, CControlListener *listener, long tag, CBitmap *background=0, CBitmap *bgWhenClick=0, const long style=0) |
virtual | ~COptionMenu () |
virtual void | setValue (float val) |
virtual bool | addEntry (COptionMenu *subMenu, char *txt) |
virtual bool | addEntry (char *txt, long index=-1) |
virtual long | getCurrent (char *txt=0, bool countSeparator=true) const |
virtual bool | setCurrent (long index, bool countSeparator=true) |
virtual bool | getEntry (long index, char *txt) const |
virtual bool | setEntry (long index, char *txt) |
virtual bool | removeEntry (long index) |
virtual bool | removeAllEntry () |
virtual long | getNbEntries () const |
virtual long | getIndex (char *txt) const |
virtual bool | checkEntry (long index, bool state) |
virtual bool | checkEntryAlone (long index) |
virtual bool | isCheckEntry (long index) const |
virtual void | draw (CDrawContext *pContext) |
| called if the view should draw itself
|
virtual void | mouse (CDrawContext *pContext, CPoint &where, long button=-1) |
| called if a mouse click event occurs
|
virtual void | takeFocus (CDrawContext *pContext=0) |
| called if view should take focus
|
virtual void | looseFocus (CDrawContext *pContext=0) |
| called if view should loose focus
|
virtual void | setNbItemsPerColumn (long val) |
virtual long | getNbItemsPerColumn () const |
long | getLastResult () const |
COptionMenu * | getLastItemMenu (long &idxInMenu) const |
void | setScheme (COptionMenuScheme *s) |
virtual COptionMenuScheme * | getScheme () const |
virtual void | setPrefixNumbers (long preCount) |
COptionMenu * | getSubMenu (long idx) const |
Protected Member Functions |
COptionMenu * | getItemMenu (long idx, long &idxInMenu, long &offsetIdx) |
void | removeItems () |
void * | appendItems (long &offsetIdx) |
bool | allocateMenu (long nb) |
bool | allocateSubMenu (long nb) |
Protected Attributes |
void * | platformControl |
char ** | entry |
COptionMenu ** | submenuEntry |
bool * | check |
long | nbEntries |
long | nbSubMenus |
long | currentIndex |
CBitmap * | bgWhenClick |
long | lastButton |
long | nbItemsPerColumn |
long | nbAllocated |
long | nbSubMenuAllocated |
long | lastResult |
long | prefixNumbers |
COptionMenu * | lastMenu |
COptionMenuScheme * | scheme |
Define a rectangle view where a text-value can be displayed with a given font and color. The text-value is centered in the given rect. A pixmap can be used as background, a second pixmap can be used when the option menu is popuped. There are 2 styles with or without a shadowed text. When a mouse click occurs, a popup menu is displayed.