PluginInfo::type added to copy constructor. But why is the copy constructor defined...
[ardour.git] / gtk2_ardour / route_ui.h
index 7415eddad6b58367eb13217da207e515c4e91a4e..f58c8f4fe94d8df7e91521b16f4f909521f2c73e 100644 (file)
@@ -15,7 +15,6 @@
     along with this program; if not, write to the Free Software
     Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
 
-    $Id$
 */
 
 #ifndef __ardour_route_ui__
@@ -45,19 +44,21 @@ class BindableToggleButton;
 class RouteUI : public virtual AxisView
 {
   public:
+       RouteUI(ARDOUR::Session&, const char*, const char*, const char*);
        RouteUI(boost::shared_ptr<ARDOUR::Route>, ARDOUR::Session&, const char*, const char*, const char*);
+
        virtual ~RouteUI();
 
+       virtual void set_route (boost::shared_ptr<ARDOUR::Route>);
+       void set_button_names (const char*, const char*, const char*);
+
        bool is_track() const;
        bool is_audio_track() const;
 
-       boost::shared_ptr<ARDOUR::Route> route() const { return _route; }
-       
-       // FIXME: make these return shared_ptr
-       ARDOUR::Track*      track() const;
-       ARDOUR::AudioTrack* audio_track() const;
-       
-       ARDOUR::Diskstream* get_diskstream() const;
+       boost::shared_ptr<ARDOUR::Route>      route() const { return _route; }
+       boost::shared_ptr<ARDOUR::Track>      track() const;
+       boost::shared_ptr<ARDOUR::AudioTrack> audio_track() const;
+       boost::shared_ptr<ARDOUR::Diskstream> get_diskstream() const;
 
        string name() const;
 
@@ -70,6 +71,8 @@ class RouteUI : public virtual AxisView
 
        bool ignore_toggle;
        bool wait_for_release;
+       bool multiple_mute_change;
+       bool multiple_solo_change;
 
        BindableToggleButton* mute_button;
        BindableToggleButton* solo_button;
@@ -86,14 +89,18 @@ class RouteUI : public virtual AxisView
        void ensure_xml_node ();
 
        XMLNode* get_child_xml_node (const string & childname);
+
+       void save_as_template ();
        
-       gint mute_press(GdkEventButton*);
-       gint mute_release(GdkEventButton*);
-       gint solo_press(GdkEventButton*);
-       gint solo_release(GdkEventButton*);
-       gint rec_enable_press(GdkEventButton*);
+       bool mute_press(GdkEventButton*);
+       bool mute_release(GdkEventButton*);
+       bool solo_press(GdkEventButton*);
+       bool solo_release(GdkEventButton*);
+       bool rec_enable_press(GdkEventButton*);
+       bool rec_enable_release(GdkEventButton*);
 
        void solo_changed(void*);
+       void solo_changed_so_update_mute ();
        void mute_changed(void*);
        virtual void redirects_changed (void *) {}
        void route_rec_enable_changed();
@@ -121,10 +128,6 @@ class RouteUI : public virtual AxisView
 
        int  set_color_from_route ();
 
-       sigc::connection blink_connection;
-
-       void rec_enable_button_blink (bool onoff, ARDOUR::AudioDiskstream *, Gtk::Widget *w);
-       
        void remove_this_route ();
        static gint idle_remove_this_route (RouteUI *);
 
@@ -141,18 +144,38 @@ class RouteUI : public virtual AxisView
        void toggle_polarity ();
        virtual void polarity_changed ();
 
+       Gtk::CheckMenuItem *denormal_menu_item;
+       void toggle_denormal_protection();
+       virtual void denormal_protection_changed ();
+
        void disconnect_input ();
        void disconnect_output ();
 
-       void update_rec_display ();
+       virtual void update_rec_display ();
        void update_mute_display ();
+
+       bool was_solo_safe;
        void update_solo_display ();
+
        virtual void map_frozen ();
 
        void set_remote_control_id (uint32_t id, Gtk::CheckMenuItem* item);
 
        void reversibly_apply_route_boolean (string name, void (ARDOUR::Route::*func)(bool, void*), bool, void *);
        void reversibly_apply_audio_track_boolean (string name, void (ARDOUR::AudioTrack::*func)(bool, void*), bool, void *);
+
+  protected:
+       std::vector<sigc::connection> connections;
+       std::string s_name;
+       std::string m_name;
+       std::string r_name;
+
+       bool self_destruct; 
+
+       void init ();
+       void reset ();
+
+       void save_template (const std::string&);
 };
 
 #endif /* __ardour_route_ui__ */