* MIDI control lanes: Set Interpolationtype according to Parameter
[ardour.git] / gtk2_ardour / automation_time_axis.h
index b708b6f58e755d38e7c269e3fa237230089c209f..d749a5fbf0944b78224ef98600ccb630c4f00d2e 100644 (file)
@@ -42,6 +42,7 @@ using std::string;
 namespace ARDOUR {
        class Session;
        class Route;
+       class AutomationControl;
 }
 
 class PublicEditor;
@@ -49,9 +50,10 @@ class TimeSelection;
 class RegionSelection;
 class PointSelection;
 class AutomationLine;
-class GhostRegion;
 class Selection;
 class Selectable;
+class AutomationStreamView;
+class AutomationController;
 
 
 class AutomationTimeAxisView : public TimeAxisView {
@@ -62,13 +64,14 @@ class AutomationTimeAxisView : public TimeAxisView {
                                boost::shared_ptr<ARDOUR::AutomationControl>,
                                PublicEditor&,
                                TimeAxisView& parent,
+                               bool show_regions,
                                ArdourCanvas::Canvas& canvas,
                                const string & name, /* translatable */
                                const string & plug_name = "");
 
        ~AutomationTimeAxisView();
        
-       void set_height (TimeAxisView::TrackHeight);
+       virtual void set_height (uint32_t);
        void set_samples_per_unit (double);
        std::string name() const { return _name; }
 
@@ -91,16 +94,16 @@ class AutomationTimeAxisView : public TimeAxisView {
        bool paste (nframes_t, float times, Selection&, size_t nth);
        void reset_objects (PointSelection&);
 
-       void add_ghost (GhostRegion*);
-       void remove_ghost (GhostRegion*);
-
-       void set_state (const XMLNode&);
+       int  set_state (const XMLNode&);
        
        guint32 show_at (double y, int& nth, Gtk::VBox *parent);
        void hide ();
        
        static const string state_node_name;
        XMLNode* get_state_node();
+       
+       boost::shared_ptr<ARDOUR::AutomationControl> control()    { return _control; }
+       boost::shared_ptr<AutomationController>      controller() { return _controller; }
 
   protected:
        boost::shared_ptr<ARDOUR::Route> _route; ///< Parent route
@@ -111,15 +114,14 @@ class AutomationTimeAxisView : public TimeAxisView {
        
        ArdourCanvas::SimpleRect* _base_rect;
        boost::shared_ptr<AutomationLine> _line;
+       AutomationStreamView*             _view;
        
        string _name;
-       bool    in_destructor;
        bool    ignore_toggle;
 
        bool    first_call_to_set_height;
 
        Gtk::Button        hide_button;
-       Gtk::Button        height_button;
        Gtk::Button        clear_button;
        Gtk::Button        auto_button; 
        Gtk::Menu*         automation_menu;
@@ -137,14 +139,11 @@ class AutomationTimeAxisView : public TimeAxisView {
        void add_line (boost::shared_ptr<AutomationLine>);
        
        void clear_clicked ();
-       void height_clicked ();
        void hide_clicked ();
        void auto_clicked ();
 
        void build_display_menu ();
 
-       list<GhostRegion*> ghosts;
-
        bool cut_copy_clear_one (AutomationLine&, Selection&, Editing::CutCopyOp);
        bool cut_copy_clear_objects_one (AutomationLine&, PointSelection&, Editing::CutCopyOp);
        bool paste_one (AutomationLine&, nframes_t, float times, Selection&, size_t nth);
@@ -165,7 +164,7 @@ class AutomationTimeAxisView : public TimeAxisView {
        void entered ();
        void exited ();
 
-       void set_colors ();
+       //void set_colors ();
        void color_handler ();
 
        static Pango::FontDescription* name_font;