summaryrefslogtreecommitdiff
path: root/gtk2_ardour/midi_time_axis.cc
diff options
context:
space:
mode:
Diffstat (limited to 'gtk2_ardour/midi_time_axis.cc')
-rw-r--r--gtk2_ardour/midi_time_axis.cc8
1 files changed, 1 insertions, 7 deletions
diff --git a/gtk2_ardour/midi_time_axis.cc b/gtk2_ardour/midi_time_axis.cc
index 18786fe54a..c8cd5fe464 100644
--- a/gtk2_ardour/midi_time_axis.cc
+++ b/gtk2_ardour/midi_time_axis.cc
@@ -506,13 +506,7 @@ MidiTimeAxisView::create_automation_child (const Evoral::Parameter& param, bool
if (existing != _automation_tracks.end())
return;
- boost::shared_ptr<AutomationControl> c
- = boost::dynamic_pointer_cast<AutomationControl>(_route->data().control(param));
-
- if (!c) {
- c = boost::dynamic_pointer_cast<AutomationControl>(_route->control_factory(param));
- _route->add_control(c);
- }
+ boost::shared_ptr<AutomationControl> c = _route->get_control (param);
assert(c);