Remove unnecessary/unused template parameter from canvas sysex flags.
[ardour.git] / gtk2_ardour / io_selector.h
index 57c6e6db86c3238804248af0571385860d527f22..9125a418caf45d88bbeb76243e454d8dff31893e 100644 (file)
 #include "ardour_dialog.h"
 #include "port_matrix.h"
 
-class IOSelector : public PortMatrix {
+namespace ARDOUR {
+       class PortInsert;
+}
+
+class IOSelector : public PortMatrix
+{
   public:
        IOSelector (ARDOUR::Session&, boost::shared_ptr<ARDOUR::IO>, bool);
 
-       void set_state (int, std::string const &, bool, uint32_t);
-       bool get_state (int, std::string const &) const;
-       uint32_t n_rows () const;
-       uint32_t maximum_rows () const;
-       uint32_t minimum_rows () const;
-       std::string row_name (int) const;
-       void add_row ();
-       void remove_row (int);
-       std::string row_descriptor () const;
-       boost::shared_ptr<ARDOUR::IO> const io() { return _io; }
+       void set_state (ARDOUR::BundleChannel c[2], bool);
+       State get_state (ARDOUR::BundleChannel c[2]) const;
+
+       void add_channel (boost::shared_ptr<ARDOUR::Bundle>);
+       bool can_remove_channels (int d) const {
+               return d == _ours;
+       }
+       void remove_channel (ARDOUR::BundleChannel);
+       bool can_rename_channels (int d) const {
+               return false;
+       }
+       
+       uint32_t n_io_ports () const;
+       uint32_t maximum_io_ports () const;
+       uint32_t minimum_io_ports () const;
+       boost::shared_ptr<ARDOUR::IO> const io () { return _io; }
+       void setup_ports (int);
+       bool list_is_global (int) const;
+
+       bool find_inputs_for_io_outputs () const {
+               return _find_inputs_for_io_outputs;
+       }
+
+       int ours () const {
+               return _ours;
+       }
+
+       int other () const {
+               return _other;
+       }
+
 
   private:
-       boost::shared_ptr<ARDOUR::IO> _io;
        
-       void ports_changed (ARDOUR::IOChange, void*);
+       int _other;
+       int _ours;
+       boost::shared_ptr<ARDOUR::IO> _io;
+       boost::shared_ptr<PortGroup> _port_group;
+       bool _find_inputs_for_io_outputs;
 };
 
 class IOSelectorWindow : public ArdourDialog
 {
   public:
        IOSelectorWindow (ARDOUR::Session&, boost::shared_ptr<ARDOUR::IO>, bool for_input, bool can_cancel = false);
-       ~IOSelectorWindow ();
 
        IOSelector& selector() { return _selector; }
 
@@ -66,17 +94,12 @@ class IOSelectorWindow : public ArdourDialog
        Gtk::Button cancel_button;
        Gtk::Button rescan_button;
 
-       Gtk::HBox  suggestion_box;
-       Gtk::Label suggestion;
-
-       void rescan ();
        void cancel ();
        void accept ();
-
-       void ports_changed (ARDOUR::IOChange change, void *src);
+       void rescan ();
+       
+       void ports_changed ();
        void io_name_changed (void *src);
-       bool enter_scroller (GdkEventCrossing*);
-       bool leave_scroller (GdkEventCrossing*);
 };
 
 
@@ -89,7 +112,6 @@ class PortInsertUI : public Gtk::VBox
        void finished (IOSelector::Result);
 
   private:
-       Gtk::HBox hbox;
        IOSelector input_selector;
        IOSelector output_selector;
 };
@@ -111,7 +133,6 @@ class PortInsertWindow : public ArdourDialog
        Gtk::Button rescan_button;
        Gtk::Frame button_frame;
        
-       void rescan ();
        void cancel ();
        void accept ();