How to programmatically invoke contextmenu action in jstree?

18 Views Asked by At

I have jstree and a button on a webpage. Jstree has contextmenu with an action "addnew". How can I trigger this action when a button is clicked?

var tree = $('#treeFolders').jstree(true);
var selectedNode = tree.get_selected(true)[0];

/* how to execute 'addnew' action against selectedNode? */

0

There are 0 best solutions below