Switch back to setting nodes as leaves, but fix the drop zone code to

allow dropping on leaves.
This commit is contained in:
Bharat Mediratta
2011-01-06 11:46:15 -08:00
parent 9682b7ea6e
commit fc6907dcfe
2 changed files with 8 additions and 5 deletions

View File

@@ -345,6 +345,13 @@
return returnCls;
}
// Override Ext.tree.TreeDropZone.getDropPoint so that it allows dropping
// on any node. The standard function won't let you drop on leaves, but
// in our model we consider an album without sub-albums a leaf.
v.dropZone.getDropPoint = function(e, n, dd) {
return "append";
}
v.dropZone.onNodeDrop = function(target, dd, e, data) {
var nodes = data.nodes;
source_ids = [];