Commit 88fa6068b6dbfc0394deb21c602e59af68222448
1 parent
63ac7745
Exists in
master
and in
111 other branches
Fix a bug with drag&drop of a parameter defined in the plot tree
Showing
1 changed file
with
2 additions
and
2 deletions
Show diff stats
js/app/views/PlotComponents/PlotTree.js
... | ... | @@ -330,7 +330,7 @@ Ext.define('amdaPlotComp.PlotTree', { |
330 | 330 | |
331 | 331 | moveParam : function(record,targetNode,position) |
332 | 332 | { |
333 | - if (record.$className != 'amdaPlotObj.PlotParamTreeNode') | |
333 | + if ((record.$className != 'amdaPlotObj.PlotParamTreeNode') || (targetNode == null)) | |
334 | 334 | return false; |
335 | 335 | |
336 | 336 | var fromIndex = record.parentNode.indexOf(record); |
... | ... | @@ -558,7 +558,7 @@ Ext.define('amdaPlotComp.PlotTree', { |
558 | 558 | } |
559 | 559 | else |
560 | 560 | fromPanelObject = record.parentNode.object; |
561 | - if (fromPanelObject == null) | |
561 | + if ((fromPanelObject == null) || (targetNode == null)) | |
562 | 562 | return false; |
563 | 563 | |
564 | 564 | var toPanelObject = null; | ... | ... |