diff options
author | Robin Gareus <robin@gareus.org> | 2016-04-17 14:01:57 +0200 |
---|---|---|
committer | Robin Gareus <robin@gareus.org> | 2016-04-17 14:01:57 +0200 |
commit | 8f14f422e053646a1b171a87f696d9d7f232e3bf (patch) | |
tree | 6146a4575e46b52e8cce8c77cb46dc26bdc0c7d1 /gtk2_ardour/mixer_strip.cc | |
parent | bb090c0012340b637508e0930376b3d5afba5f5c (diff) |
unhardcode "Program Name" string length
Diffstat (limited to 'gtk2_ardour/mixer_strip.cc')
-rw-r--r-- | gtk2_ardour/mixer_strip.cc | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/gtk2_ardour/mixer_strip.cc b/gtk2_ardour/mixer_strip.cc index 999208562f..db5d70bc85 100644 --- a/gtk2_ardour/mixer_strip.cc +++ b/gtk2_ardour/mixer_strip.cc @@ -1365,7 +1365,8 @@ MixerStrip::update_io_button (boost::shared_ptr<ARDOUR::Route> route, Width widt // "ardour:Master/" -> "Master" string::size_type slash = ardour_track_name.find("/"); if (slash != string::npos) { - label << ardour_track_name.substr(7, slash - 7); + const size_t ppps = RouteUI::program_port_prefix.size () + 1; // "ardour:" + label << ardour_track_name.substr (ppps, slash - ppps); have_label = true; } } |