diff options
Diffstat (limited to 'src/libs/engine/events/AddPortEvent.cpp')
-rw-r--r-- | src/libs/engine/events/AddPortEvent.cpp | 12 |
1 files changed, 5 insertions, 7 deletions
diff --git a/src/libs/engine/events/AddPortEvent.cpp b/src/libs/engine/events/AddPortEvent.cpp index 28273815..d31c2169 100644 --- a/src/libs/engine/events/AddPortEvent.cpp +++ b/src/libs/engine/events/AddPortEvent.cpp @@ -115,15 +115,13 @@ AddPortEvent::pre_process() if (!_patch->parent()) { if (_type == "ingen:audio") _driver_port = _engine.audio_driver()->create_port( - dynamic_cast<DuplexPort*>(_patch_port)); + dynamic_cast<DuplexPort*>(_patch_port)); else if (_type == "ingen:midi") _driver_port = _engine.midi_driver()->create_port( - dynamic_cast<DuplexPort*>(_patch_port)); - } - - if (_type == "ingen:osc" && _engine.osc_driver()) { - _driver_port = _engine.osc_driver()->create_port( - dynamic_cast<DuplexPort*>(_patch_port)); + dynamic_cast<DuplexPort*>(_patch_port)); + else if (_type == "ingen:osc" && _engine.osc_driver()) + _driver_port = _engine.osc_driver()->create_port( + dynamic_cast<DuplexPort*>(_patch_port)); } assert(_ports_array->size() == _patch->num_ports()); |