independent panning for external sends
[ardour.git] / gtk2_ardour / send_ui.cc
index 627fe531f68e0dbcf6fb21d2ca1ea0e41e3b2590..54663dbe0a0cabddae00c65bd2fd4db5e0fb3e94 100644 (file)
@@ -19,7 +19,6 @@
 
 #include <gtkmm2ext/doi.h>
 
-#include "ardour/amp.h"
 #include "ardour/io.h"
 #include "ardour/send.h"
 #include "ardour/rc_configuration.h"
@@ -47,16 +46,13 @@ SendUI::SendUI (Gtk::Window* parent, boost::shared_ptr<Send> s, Session* session
        _gpm.set_controls (boost::shared_ptr<Route>(), s->meter(), s->amp());
 
        _hbox.pack_start (_gpm, true, true);
-       set_name ("SendUIFrame");
+       set_name (X_("SendUIFrame"));
 
        _vbox.set_spacing (5);
        _vbox.set_border_width (5);
 
        _vbox.pack_start (_hbox, false, false, false);
-       // until sends have their own Pannable, don't show this
-       // because it controls the Route Pannable which confuses
-       // users (among others)
-       // _vbox.pack_start (_panners, false, false);
+       _vbox.pack_start (_panners, false, false);
 
        io = manage (new IOSelector (parent, session, s->output()));
 
@@ -72,13 +68,13 @@ SendUI::SendUI (Gtk::Window* parent, boost::shared_ptr<Send> s, Session* session
 
        _send->set_metering (true);
 
-       _send->output()->changed.connect (connections, invalidator (*this), ui_bind (&SendUI::outs_changed, this, _1, _2), gui_context());
+       _send->output()->changed.connect (connections, invalidator (*this), boost::bind (&SendUI::outs_changed, this, _1, _2), gui_context());
 
        _panners.set_width (Wide);
        _panners.setup_pan ();
 
        _gpm.setup_meters ();
-       _gpm.set_fader_name ("SendUIFrame");
+       _gpm.set_fader_name (X_("SendUIFader"));
 
        // screen_update_connection = ARDOUR_UI::instance()->RapidScreenUpdate.connect (
        //              sigc::mem_fun (*this, &SendUI::update));
@@ -114,6 +110,10 @@ SendUI::update ()
 void
 SendUI::fast_update ()
 {
+       if (!is_mapped()) {
+               return;
+       }
+
        if (Config->get_meter_falloff() > 0.0f) {
                _gpm.update_meters ();
        }
@@ -134,10 +134,6 @@ SendUIWindow::SendUIWindow (boost::shared_ptr<Send> s, Session* session)
        hpacker.show ();
 
        s->DropReferences.connect (going_away_connection, invalidator (*this), boost::bind (&SendUIWindow::send_going_away, this), gui_context());
-
-       signal_delete_event().connect (sigc::bind (
-                                              sigc::ptr_fun (just_hide_it),
-                                              reinterpret_cast<Window *> (this)));
 }
 
 SendUIWindow::~SendUIWindow ()