diff --git a/gtk2_ardour/waves_ui.cc b/gtk2_ardour/waves_ui.cc index 25246e53d6..7e7b210662 100644 --- a/gtk2_ardour/waves_ui.cc +++ b/gtk2_ardour/waves_ui.cc @@ -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 (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) diff --git a/gtk2_ardour/waves_ui.h b/gtk2_ardour/waves_ui.h index 99edfd4b36..0975968851 100644 --- a/gtk2_ardour/waves_ui.h +++ b/gtk2_ardour/waves_ui.h @@ -42,6 +42,7 @@ class WavesUI : public std::map { 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);