From c553980105862c93537b671476163122b08640e1 Mon Sep 17 00:00:00 2001 From: Marcus Huderle Date: Thu, 8 Mar 2018 21:26:40 -0800 Subject: [PATCH] Properly remove connections --- editor.cpp | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/editor.cpp b/editor.cpp index 319c9a4c..eb67f471 100755 --- a/editor.cpp +++ b/editor.cpp @@ -166,6 +166,11 @@ void Editor::showCurrentConnectionMap(QString curDirection) { scene->removeItem(connection_item); delete connection_item; connection_item = NULL; + + if (map->connection_items.contains(curDirection)) { + delete map->connection_items.value(curDirection); + map->connection_items.remove(curDirection); + } } ui->comboBox_ConnectedMap->setCurrentText("");