From d1033819bd09d8a46ec602a586ddba0e10f803d6 Mon Sep 17 00:00:00 2001 From: Paul Davis Date: Tue, 12 Jan 2016 14:09:24 -0500 Subject: change ownership of the AutomationControl used by Amp. It used to be owned by Amp. Now it is owned by Amp's owner --- libs/ardour/automatable.cc | 14 ++------------ 1 file changed, 2 insertions(+), 12 deletions(-) (limited to 'libs/ardour/automatable.cc') diff --git a/libs/ardour/automatable.cc b/libs/ardour/automatable.cc index 9670f68689..c9d8374db9 100644 --- a/libs/ardour/automatable.cc +++ b/libs/ardour/automatable.cc @@ -449,19 +449,9 @@ Automatable::control_factory(const Evoral::Parameter& param) warning << "PluginPropertyAutomation for non-Plugin" << endl; } } else if (param.type() == GainAutomation) { - Amp* amp = dynamic_cast(this); - if (amp) { - control = new Amp::GainControl(X_("gaincontrol"), _a_session, amp, param); - } else { - warning << "GainAutomation for non-Amp" << endl; - } + control = new Amp::GainControl(_a_session, param); } else if (param.type() == TrimAutomation) { - Amp* amp = dynamic_cast(this); - if (amp) { - control = new Amp::GainControl(X_("trimcontrol"), _a_session, amp, param); - } else { - warning << "TrimAutomation for non-Amp" << endl; - } + control = new Amp::GainControl(_a_session, param); } else if (param.type() == PanAzimuthAutomation || param.type() == PanWidthAutomation || param.type() == PanElevationAutomation) { Pannable* pannable = dynamic_cast(this); if (pannable) { -- cgit v1.2.3