From fae7e7519afae5f42836eaaf5e317151ea9c4378 Mon Sep 17 00:00:00 2001 From: David Robillard Date: Mon, 8 Oct 2007 04:21:18 +0000 Subject: Fixed missing symbol in Raul. Made Raul::List interface and uses thereof less fugly. git-svn-id: http://svn.drobilla.net/lad/ingen@845 a436a847-0d15-0410-975c-d299462d15a1 --- src/libs/engine/events/ClearPatchEvent.cpp | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) (limited to 'src/libs/engine/events/ClearPatchEvent.cpp') diff --git a/src/libs/engine/events/ClearPatchEvent.cpp b/src/libs/engine/events/ClearPatchEvent.cpp index ad35d162..84731d0a 100644 --- a/src/libs/engine/events/ClearPatchEvent.cpp +++ b/src/libs/engine/events/ClearPatchEvent.cpp @@ -51,7 +51,7 @@ ClearPatchEvent::pre_process() _process = _patch->enabled(); - for (Raul::List::const_iterator i = _patch->nodes().begin(); i != _patch->nodes().end(); ++i) + for (List::const_iterator i = _patch->nodes().begin(); i != _patch->nodes().end(); ++i) (*i)->remove_from_store(); } #endif @@ -69,7 +69,7 @@ ClearPatchEvent::execute(ProcessContext& context) _patch->disable(); cerr << "FIXME: CLEAR PATCH\n"; - //for (Raul::List::const_iterator i = _patch->nodes().begin(); i != _patch->nodes().end(); ++i) + //for (List::const_iterator i = _patch->nodes().begin(); i != _patch->nodes().end(); ++i) // (*i)->remove_from_patch(); if (_patch->compiled_patch() != NULL) { @@ -85,15 +85,16 @@ ClearPatchEvent::post_process() { if (_patch != NULL) { // Delete all nodes - for (Raul::List::iterator i = _patch->nodes().begin(); i != _patch->nodes().end(); ++i) { + for (List::iterator i = _patch->nodes().begin(); i != _patch->nodes().end(); ++i) { (*i)->deactivate(); delete *i; } _patch->nodes().clear(); // Delete all connections - for (Raul::List::iterator i = _patch->connections().begin(); i != _patch->connections().end(); ++i) - delete *i; + for (List< SharedPtr >::iterator i = _patch->connections().begin(); i != _patch->connections().end(); ++i) + (*i).reset(); + _patch->connections().clear(); // Restore patch's run state -- cgit v1.2.1