Skip to content

preventTreeDefault doesn't seem to work as expected #21

@jeffaotal

Description

@jeffaotal

I would have expected the following code to have stopped the node from actually being dropped.

		tree.on("node.dragend", function(event) {
		    
			event.preventTreeDefault();
			
			alert("hi");
			
		});

But instead after I close the alert box the node is indeed dropped onto the target node.

Is there a way to intercept the drop and stop it from happening? What I'm trying to do is show a dialog which will describe the impact of making the drop and allowing the user to accept or cancel the drop.

Thanks,
Jeff

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions