- selected_port = 0;
-
- notebook.set_name ("IOSelectorNotebook");
- notebook.set_size_request (-1, 125);
-
- clear_connections_button.set_name ("IOSelectorButton");
- add_port_button.set_name ("IOSelectorButton");
- remove_port_button.set_name ("IOSelectorButton");
-
- selector_frame.set_name ("IOSelectorFrame");
- port_frame.set_name ("IOSelectorFrame");
-
- selector_frame.set_label (_("Available connections"));
-
- selector_button_box.set_spacing (5);
- selector_button_box.set_border_width (5);
-
- selector_box.set_spacing (5);
- selector_box.set_border_width (5);
- selector_box.pack_start (notebook);
- selector_box.pack_start (selector_button_box, false, false);
-
- selector_frame.add (selector_box);
-
- port_box.set_spacing (5);
- port_box.set_border_width (5);
-
- port_display_scroller.set_name ("IOSelectorNotebook");
- port_display_scroller.set_border_width (0);
- port_display_scroller.set_size_request (-1, 170);
- port_display_scroller.add (port_box);
- port_display_scroller.set_policy (POLICY_NEVER,
- POLICY_AUTOMATIC);
-
- port_button_box.set_spacing (5);
- port_button_box.set_border_width (5);
-
- port_button_box.pack_start (add_port_button, false, false);
-
- if (for_input) {
- if (io.input_maximum() < 0 || io.input_maximum() > (int) io.n_inputs()) {
- add_port_button.set_sensitive (true);
- } else {
- add_port_button.set_sensitive (false);
- }
-
- } else {
- if (io.output_maximum() < 0 || io.output_maximum() > (int) io.n_outputs()) {
- add_port_button.set_sensitive (true);
- } else {
- add_port_button.set_sensitive (false);