From 91cdc941af88e8ba6e19673eb17825233db2218c Mon Sep 17 00:00:00 2001 From: David Robillard Date: Thu, 9 Jun 2011 00:23:26 +0000 Subject: Fix support for multiple instances of alsa clients with the same name (never consider client name an ID). Remove Alsa specific crap from PatchagePort. Sane implementation of AlsaDriver::refresh. Fix refreshing. Remove useless Jack graph order callback. Fix double add/remove of ports to modules. git-svn-id: http://svn.drobilla.net/lad/trunk/patchage@3374 a436a847-0d15-0410-975c-d299462d15a1 --- src/PatchageCanvas.cpp | 16 +++++----------- 1 file changed, 5 insertions(+), 11 deletions(-) (limited to 'src/PatchageCanvas.cpp') diff --git a/src/PatchageCanvas.cpp b/src/PatchageCanvas.cpp index 69633c8..ebbfc39 100644 --- a/src/PatchageCanvas.cpp +++ b/src/PatchageCanvas.cpp @@ -98,22 +98,16 @@ PatchageCanvas::find_port(const PortID& id) return pp; } -PatchagePort* +void PatchageCanvas::remove_port(const PortID& id) { PatchagePort* const port = find_port(id); - if (!port) - return port; + if (!port) { + Raul::error << "Failed to find port " << id << " to remove" << std::endl; + } _port_index.erase(id); - - PatchageModule* module = dynamic_cast(port->module()); - if (!module) - return port; - - module->remove_port(port); - _app->enqueue_resize(module); - return port; + delete port; } void -- cgit v1.2.1