diff options
author | Sampo Savolainen <v2@iki.fi> | 2009-03-07 11:17:06 +0000 |
---|---|---|
committer | Sampo Savolainen <v2@iki.fi> | 2009-03-07 11:17:06 +0000 |
commit | bcd217ec8e11abcb3bc829251b6dc503d606aaeb (patch) | |
tree | bdb5d54aa6c7b1b46835acee2c8697dabbf520d7 /gtk2_ardour/generic_pluginui.cc | |
parent | e09c51251f1742ac5c61966b5dd8c5f61c567f69 (diff) |
Improvements to the plugin eq gui:
- phase correction for analysis
- move gui elements to a more common location so that it's available for VSTs
(needs packing in each PluginUI derived class though)
git-svn-id: svn://localhost/ardour2/branches/3.0@4745 d708f5d6-7413-0410-9779-e7cbd77b26cf
Diffstat (limited to 'gtk2_ardour/generic_pluginui.cc')
-rw-r--r-- | gtk2_ardour/generic_pluginui.cc | 43 |
1 files changed, 1 insertions, 42 deletions
diff --git a/gtk2_ardour/generic_pluginui.cc b/gtk2_ardour/generic_pluginui.cc index 16dbba523f..d276b294ed 100644 --- a/gtk2_ardour/generic_pluginui.cc +++ b/gtk2_ardour/generic_pluginui.cc @@ -50,7 +50,6 @@ #include "utils.h" #include "gui_thread.h" #include "automation_controller.h" -#include "plugin_eq_gui.h" #include "i18n.h" @@ -65,7 +64,6 @@ GenericPluginUI::GenericPluginUI (boost::shared_ptr<PluginInsert> pi, bool scrol : PlugUIBase (pi), button_table (initial_button_rows, initial_button_cols), output_table (initial_output_rows, initial_output_cols), - eqgui_toggle(_("Freq Analysis")), hAdjustment(0.0, 0.0, 0.0), vAdjustment(0.0, 0.0, 0.0), scroller_view(hAdjustment, vAdjustment), @@ -99,6 +97,7 @@ GenericPluginUI::GenericPluginUI (boost::shared_ptr<PluginInsert> pi, bool scrol VBox* v1_box = manage (new VBox); VBox* v2_box = manage (new VBox); constraint_hbox->pack_start (eqgui_toggle, false, false); + add2(plugin_eq_bin); v1_box->pack_start (*smaller_hbox, false, true); v2_box->pack_start (focus_button, false, true); @@ -124,9 +123,6 @@ GenericPluginUI::GenericPluginUI (boost::shared_ptr<PluginInsert> pi, bool scrol main_contents.pack_start (hpacker, false, false); } - eqgui_toggle.set_active (false); - eqgui_toggle.signal_toggled().connect( mem_fun(*this, &GenericPluginUI::toggle_plugin_analysis)); - pi->ActiveChanged.connect (bind(mem_fun(*this, &GenericPluginUI::processor_active_changed), boost::weak_ptr<Processor>(pi))); @@ -836,41 +832,4 @@ GenericPluginUI::setup_scale_values(guint32 port_index, ControlUI* cui) } -void -GenericPluginUI::toggle_plugin_analysis() -{ - - - - if (eqgui_toggle.get_active() && !get_child2()) { - // Create the GUI - PluginEqGui *foo = new PluginEqGui(insert); - pack2( *foo ); - show_all(); - } - - Gtk::Widget *gui; - - if (!eqgui_toggle.get_active() && (gui = get_child2())) { - // Hide & remove - gui->hide(); - remove(*gui); - - delete gui; - - Gtk::Widget *toplevel = get_toplevel(); - if (!toplevel) { - std::cerr << "No toplevel widget?!?!" << std::endl; - return; - } - - Gtk::Container *cont = dynamic_cast<Gtk::Container *>(toplevel); - if (!cont) { - std::cerr << "Toplevel widget is not a container?!?" << std::endl; - return; - } - Gtk::Allocation alloc(0, 0, 50, 50); // Just make it small - toplevel->size_allocate(alloc); - } -} |