cont'd work on Pin Dialog Display
[ardour.git] / gtk2_ardour / gain_meter.h
index 57215b48b5051fcbc2d6674dd2f5630ded35241c..7cf3410241b28556a338ee730392af1b0f0b013c 100644 (file)
@@ -49,6 +49,7 @@
 
 namespace ARDOUR {
        class IO;
+       class GainControl;
        class Session;
        class Route;
        class RouteGroup;
@@ -71,11 +72,14 @@ class GainMeterBase : virtual public sigc::trackable, ARDOUR::SessionHandlePtr
 
        virtual void set_controls (boost::shared_ptr<ARDOUR::Route> route,
                                   boost::shared_ptr<ARDOUR::PeakMeter> meter,
-                                  boost::shared_ptr<ARDOUR::Amp> amp);
+                                  boost::shared_ptr<ARDOUR::Amp> amp,
+                                  boost::shared_ptr<ARDOUR::GainControl> control);
 
        void update_gain_sensitive ();
        void update_meters ();
 
+       const ARDOUR::ChanCount meter_channels () const;
+
        void effective_gain_display ();
        void set_width (Width, int len=0);
        void set_meter_strip_name (const char * name);
@@ -102,6 +106,7 @@ class GainMeterBase : virtual public sigc::trackable, ARDOUR::SessionHandlePtr
        boost::shared_ptr<ARDOUR::Route> _route;
        boost::shared_ptr<ARDOUR::PeakMeter> _meter;
        boost::shared_ptr<ARDOUR::Amp> _amp;
+       boost::shared_ptr<ARDOUR::GainControl> _control;
        std::vector<sigc::connection> connections;
        PBD::ScopedConnectionList model_connections;
 
@@ -111,7 +116,8 @@ class GainMeterBase : virtual public sigc::trackable, ARDOUR::SessionHandlePtr
        Gtkmm2ext::SliderController *gain_slider;
        Gtk::Adjustment              gain_adjustment;
        Gtkmm2ext::FocusEntry        gain_display;
-       ArdourButton                 peak_display;
+       Gtkmm2ext::FocusEntry        peak_display;
+//     Gtk::Button                  peak_display;
        Gtk::DrawingArea             meter_metric_area;
        Gtk::DrawingArea             meter_ticks1_area;
        Gtk::DrawingArea             meter_ticks2_area;
@@ -203,7 +209,8 @@ class GainMeter : public GainMeterBase, public Gtk::VBox
 
        virtual void set_controls (boost::shared_ptr<ARDOUR::Route> route,
                                   boost::shared_ptr<ARDOUR::PeakMeter> meter,
-                                  boost::shared_ptr<ARDOUR::Amp> amp);
+                                  boost::shared_ptr<ARDOUR::Amp> amp,
+                                  boost::shared_ptr<ARDOUR::GainControl> control);
 
        int get_gm_width ();
        void setup_meters (int len=0);