[Summary] Just adding access to the named Gtk::EventBox-es, created with XML scripts.

This commit is contained in:
VKamyshniy 2014-06-26 17:40:20 +03:00
parent 57548ecb7c
commit 598feb7cdc
2 changed files with 12 additions and 0 deletions

View file

@ -480,6 +480,17 @@ WavesUI::get_adjustment(const char* id)
return *child;
}
Gtk::EventBox&
WavesUI::get_event_box (const char* id)
{
Gtk::EventBox* child = dynamic_cast<Gtk::EventBox*> (get_object(id));
if (child == NULL ) {
dbg_msg (std::string("Gtk::EventBox ") + id + " not found !");
throw std::exception();
}
return *child;
}
Gtk::Box&
WavesUI::get_box (const char* id)

View file

@ -42,6 +42,7 @@ class WavesUI : public std::map<std::string, Gtk::Object*> {
WavesUI (const std::string& layout_script_file, Gtk::Container& root);
Gtk::Adjustment& get_adjustment (const char* id);
Gtk::EventBox& get_event_box (const char* id);
Gtk::Box& get_box (const char* id);
Gtk::VBox& get_v_box (const char* id);
Gtk::HBox& get_h_box (const char* id);