From 419f85be4edc1ec93bbd2aae8f2cd081ece689c3 Mon Sep 17 00:00:00 2001 From: Carl Hetherington Date: Wed, 9 Nov 2011 22:26:16 +0000 Subject: [PATCH] Be a little bit less complainy about setting state that already exists; useful when the port matrix is in show-only-bundles mode and it is to some extent guessing what connections to make. git-svn-id: svn://localhost/ardour2/branches/3.0@10517 d708f5d6-7413-0410-9779-e7cbd77b26cf --- gtk2_ardour/io_selector.cc | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/gtk2_ardour/io_selector.cc b/gtk2_ardour/io_selector.cc index fea21ced0f..f77123a684 100644 --- a/gtk2_ardour/io_selector.cc +++ b/gtk2_ardour/io_selector.cc @@ -145,9 +145,13 @@ IOSelector::set_state (ARDOUR::BundleChannel c[2], bool s) } if (s) { - _io->connect (f, *j, 0); + if (!f->connected_to (*j)) { + _io->connect (f, *j, 0); + } } else { - _io->disconnect (f, *j, 0); + if (f->connected_to (*j)) { + _io->disconnect (f, *j, 0); + } } } } -- 2.30.2