summaryrefslogtreecommitdiff
path: root/gtk2_ardour/port_matrix_grid.cc
diff options
context:
space:
mode:
authorCarl Hetherington <carl@carlh.net>2009-11-16 22:32:58 +0000
committerCarl Hetherington <carl@carlh.net>2009-11-16 22:32:58 +0000
commit95e4f7558b6d9616ef2180682a8c203c2226261b (patch)
tree09d119eba3f136c446089c70bd8b428cdebfc380 /gtk2_ardour/port_matrix_grid.cc
parentce8bd8948e794377697fdc9e0f3674cf7593c725 (diff)
Allow ardour to manipulate connections between two JACK ports that don't belong to us.
git-svn-id: svn://localhost/ardour2/branches/3.0@6100 d708f5d6-7413-0410-9779-e7cbd77b26cf
Diffstat (limited to 'gtk2_ardour/port_matrix_grid.cc')
-rw-r--r--gtk2_ardour/port_matrix_grid.cc32
1 files changed, 3 insertions, 29 deletions
diff --git a/gtk2_ardour/port_matrix_grid.cc b/gtk2_ardour/port_matrix_grid.cc
index 543efa91ca..b6be4165a9 100644
--- a/gtk2_ardour/port_matrix_grid.cc
+++ b/gtk2_ardour/port_matrix_grid.cc
@@ -166,9 +166,6 @@ PortMatrixGrid::render_group_pair (cairo_t* cr, boost::shared_ptr<const PortGrou
ARDOUR::BundleChannel (j->bundle, 0)
));
switch (s) {
- case PortMatrixNode::UNKNOWN:
- draw_unknown_indicator (cr, bx, by);
- break;
case PortMatrixNode::ASSOCIATED:
draw_association_indicator (cr, bx, by);
break;
@@ -210,10 +207,6 @@ PortMatrixGrid::render_group_pair (cairo_t* cr, boost::shared_ptr<const PortGrou
draw_association_indicator (cr, tx, ty);
break;
- case PortMatrixNode::UNKNOWN:
- draw_unknown_indicator (cr, tx, ty);
- break;
-
case PortMatrixNode::NOT_ASSOCIATED:
break;
@@ -266,20 +259,6 @@ PortMatrixGrid::draw_empty_square (cairo_t* cr, uint32_t x, uint32_t y)
cairo_fill (cr);
}
-void
-PortMatrixGrid::draw_unknown_indicator (cairo_t* cr, uint32_t x, uint32_t y)
-{
- set_source_rgba (cr, unknown_colour(), 0.5);
- cairo_rectangle (
- cr,
- x + thick_grid_line_width(),
- y + thick_grid_line_width(),
- grid_spacing() - 2 * thick_grid_line_width(),
- grid_spacing() - 2 * thick_grid_line_width()
- );
- cairo_fill (cr);
-}
-
PortMatrixNode
PortMatrixGrid::position_to_node (uint32_t x, uint32_t y) const
{
@@ -340,10 +319,6 @@ PortMatrixGrid::get_association (PortMatrixNode node) const
}
break;
- case PortMatrixNode::UNKNOWN:
- have_unknown = true;
- break;
-
case PortMatrixNode::NOT_ASSOCIATED:
if (i == j) {
have_diagonal_not_association = true;
@@ -356,9 +331,7 @@ PortMatrixGrid::get_association (PortMatrixNode node) const
}
}
- if (have_unknown) {
- return PortMatrixNode::UNKNOWN;
- } else if (have_diagonal_association && !have_off_diagonal_association && !have_diagonal_not_association) {
+ if (have_diagonal_association && !have_off_diagonal_association && !have_diagonal_not_association) {
return PortMatrixNode::ASSOCIATED;
} else if (!have_diagonal_association && !have_off_diagonal_association) {
return PortMatrixNode::NOT_ASSOCIATED;
@@ -375,7 +348,8 @@ PortMatrixGrid::get_association (PortMatrixNode node) const
}
- return PortMatrixNode::UNKNOWN;
+ /* NOTREACHED */
+ return PortMatrixNode::NOT_ASSOCIATED;
}
void