move_node copy_node fixed

move_node copy_node fixed
This commit is contained in:
AdaskoTheBeAsT
2014-10-11 14:56:31 +02:00
parent bba33bcb0b
commit 2773ff5fb8
2 changed files with 9 additions and 2 deletions
+5
View File
@@ -104,3 +104,8 @@ var treeWithNewCheckboxProperties = $('#treeWithNewCheckboxProperties').jstree({
}
});
var tree = $('a').jstree();
tree.move_node('a', 'b', 0, (node: any, new_par: any, pos: any) => { }, true, true);
tree.copy_node('a', 'b', 0, (node: any, new_par: any, pos: any) => { }, true, true);
+4 -2
View File
@@ -1004,9 +1004,10 @@ interface JSTree extends JQuery {
* @param {mixed} pos the position to insert at (besides integer values, "first" and "last" are supported, as well as "before" and "after"), defaults to integer `0`
* @param {function} callback a function to call once the move is completed, receives 3 arguments - the node, the new parent and the position
* @param {Boolean} internal parameter indicating if the parent node has been loaded
* @param {Boolean} internal parameter indicating if the tree should be redrawn
* @trigger move_node.jstree
*/
move_node: (obj: any, par: any, pos?: any, callback?: any, internal?: boolean) => void;
move_node: (obj: any, par: any, pos?: any, callback?: (node: any, new_par: any, pos: any) => void, is_loaded?: boolean, skip_redraw?: boolean) => void;
/**
* copy a node to a new parent
@@ -1016,9 +1017,10 @@ interface JSTree extends JQuery {
* @param {mixed} pos the position to insert at (besides integer values, "first" and "last" are supported, as well as "before" and "after"), defaults to integer `0`
* @param {function} callback a function to call once the move is completed, receives 3 arguments - the node, the new parent and the position
* @param {Boolean} internal parameter indicating if the parent node has been loaded
* @param {Boolean} internal parameter indicating if the tree should be redrawn
* @trigger model.jstree copy_node.jstree
*/
copy_node: (obj: any, par: any, pos?: any, callback?: any, internal?: boolean) => void;
copy_node: (obj: any, par: any, pos?: any, callback?: (node: any, new_par: any, pos: any) => void, is_loaded?: boolean, skip_redraw?: boolean) => void;
/**
* cut a node (a later call to `paste(obj)` would move the node)