#include <menu.h>
Public Methods | |
| GlutMenu (int button=GLUT_LEFT_BUTTON) | |
| Constructor. | |
| ~GlutMenu () | |
| Destructor. | |
| void | addEntry (const std::string &name, int value=-1) |
| Add a menu entry with a menu event ID. | |
| GlutMenu & | subMenu () |
| Create a sub-menu. | |
| void | addEntry (const std::string &name, GlutMenu &menu) |
| Add a sub-menu. | |
| void | reset () |
| Clear the contents of the menu. | |
| void | attach () |
| Bind the menu to the mouse button. | |
| void | detach () |
| Dettach the menu from the mouse button. | |
Protected Methods | |
| void | resetList () |
| Free all resources. | |
Protected Attributes | |
| int | _button |
| Mouse button to attach/detach. | |
| int | _menuID |
| GLUT menu ID. | |
| std::list< GlutMenu * > | _subMenu |
| List of child menus. | |
Definition at line 51 of file menu.h.
|
|
Constructor.
Definition at line 11 of file menu.cpp. Referenced by subMenu(). |
|
|
Create a sub-menu.
Definition at line 22 of file menu.cpp. References _button, _subMenu, and GlutMenu(). |
1.2.18