diff options
Diffstat (limited to 'src/libs/client/NodeModel.cpp')
-rw-r--r-- | src/libs/client/NodeModel.cpp | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/src/libs/client/NodeModel.cpp b/src/libs/client/NodeModel.cpp index 8c5892e7..2816c7fa 100644 --- a/src/libs/client/NodeModel.cpp +++ b/src/libs/client/NodeModel.cpp @@ -48,7 +48,13 @@ NodeModel::~NodeModel() void NodeModel::remove_port(SharedPtr<PortModel> port) { - _ports.remove(port); + // FIXME: slow + for (PortModelList::iterator i = _ports.begin(); i != _ports.end(); ++i) { + if ((*i) == port) { + _ports.erase(i); + break; + } + } signal_removed_port.emit(port); } @@ -56,6 +62,7 @@ NodeModel::remove_port(SharedPtr<PortModel> port) void NodeModel::remove_port(const Path& port_path) { + // FIXME: slow for (PortModelList::iterator i = _ports.begin(); i != _ports.end(); ++i) { if ((*i)->path() == port_path) { _ports.erase(i); |