diff --git a/telldus-gui/Plugins/SchedulerGUISimple/ActionPoint.qml b/telldus-gui/Plugins/SchedulerGUISimple/ActionPoint.qml index 8ac46670..a9ce33a3 100644 --- a/telldus-gui/Plugins/SchedulerGUISimple/ActionPoint.qml +++ b/telldus-gui/Plugins/SchedulerGUISimple/ActionPoint.qml @@ -420,7 +420,7 @@ Rectangle{ } function remove(keepDialogOpen, ignoreParent){ - if(ignoreParent == undefined && pointRect.parentPoint != undefined){ + if(keepDialogOpen == undefined && ignoreParent == undefined && pointRect.parentPoint != undefined){ //remove from parent instead pointRect.parentPoint.remove(); return; @@ -491,10 +491,12 @@ Rectangle{ else if(originalPoint.getChildPoint(index) == undefined){ print("CREATE NEW POINT"); originalPoint.addChildPoint(index, deviceRow.createChildPoint(index, pointRect, deviceRow.deviceId)); + pointRect.deviceRow.updateContinuingBars(); } else{ print("REMOVE A POINT"); originalPoint.removeChildPoint(index); + pointRect.deviceRow.updateContinuingBars(); } } diff --git a/telldus-gui/Plugins/SchedulerGUISimple/schedulerscripts.js b/telldus-gui/Plugins/SchedulerGUISimple/schedulerscripts.js index b86a53e8..9c0939d9 100644 --- a/telldus-gui/Plugins/SchedulerGUISimple/schedulerscripts.js +++ b/telldus-gui/Plugins/SchedulerGUISimple/schedulerscripts.js @@ -387,7 +387,7 @@ function addChildPoint(index, point){ function removeChildPoint(index){ print("INDEX BEFORE REMOVE: " + childPoints[index]); var toBeRemoved = childPoints[index]; - childPoints[index] = undefined; + delete childPoints[index]; // = undefined; toBeRemoved.remove("true"); print("INDEX AFTER REMOVE: " + childPoints[index]); }