cgv
|
derive from this class to provide a gui to the current viewer More...
#include <menu_provider.h>
Protected Member Functions | |
creation of menu entries | |
base::base_ptr | add_menu_separator (const std::string &menu_path) |
add a newly created decorator to the group | |
button_ptr | add_menu_button (const std::string &menu_path, const std::string &options="") |
use the current gui driver to append a new button in the menu, where menu path is a '/' separated path | |
data::ref_ptr< control< bool > > | add_menu_bool_control (const std::string &menu_path, bool &value, const std::string &options="") |
use this to add a new control to the gui with a given value type, gui type and init options | |
update menu | |
base::base_ptr | find_menu_element (const std::string &menu_path) const |
return the element of the given menu path | |
void | remove_menu_element (base::base_ptr) |
remove a single element from the gui | |
menu_provider () | |
default construction | |
~menu_provider () | |
ensure to remove posted recreation callbacks | |
virtual void | create_menu ()=0 |
you must overload this for menu creation | |
virtual void | destroy_menu ()=0 |
you must overload this for to remove all elements from the menu again | |
derive from this class to provide a gui to the current viewer
Definition at line 12 of file menu_provider.h.
cgv::gui::menu_provider::menu_provider | ( | ) |
default construction
Definition at line 44 of file menu_provider.cxx.
cgv::gui::menu_provider::~menu_provider | ( | ) |
ensure to remove posted recreation callbacks
Definition at line 48 of file menu_provider.cxx.
|
protected |
use this to add a new control to the gui with a given value type, gui type and init options
Definition at line 24 of file menu_provider.cxx.
References cgv::gui::get_gui_driver().
|
protected |
use the current gui driver to append a new button in the menu, where menu path is a '/' separated path
Definition at line 16 of file menu_provider.cxx.
References cgv::gui::get_gui_driver().
|
protected |
add a newly created decorator to the group
Definition at line 8 of file menu_provider.cxx.
References cgv::gui::get_gui_driver().
|
protected |
return the element of the given menu path
Definition at line 31 of file menu_provider.cxx.
References cgv::gui::get_gui_driver().
|
protected |
remove a single element from the gui
Definition at line 38 of file menu_provider.cxx.
References cgv::gui::get_gui_driver().