added new clear the buffer function

added new clear the buffer function
This commit is contained in:
AdaskoTheBeAsT
2014-10-04 15:02:16 +02:00
parent 4598e7d76b
commit 765d28e08d
2 changed files with 18 additions and 0 deletions

View File

@@ -75,6 +75,8 @@ a.search('test', false, true);
//test redraw node
a.redraw_node($('#node1'), false, false, false);
//test clear buffer
a.clear_buffer();
//tree with new unique plugin parameters
var treeWithUnique = $('#treeWithUnique').jstree({

16
jstree/jstree.d.ts vendored
View File

@@ -1059,6 +1059,13 @@ interface JSTree extends JQuery {
*/
paste: (obj: any, pos: any) => void;
/**
* clear the buffer of previously copied or cut nodes
* @name clear_buffer()
* @trigger clear_buffer.jstree
*/
clear_buffer: () => void;
/**
* put a node in edit mode (input field to rename the node)
* @name edit(obj [, default_text])
@@ -1223,7 +1230,16 @@ interface JSTree extends JQuery {
*/
is_undetermined: (obj: any) => boolean;
/**
* called when a node is selected by the user. Used internally.
* @private
* @name activate_node(obj, e)
* @param {mixed} obj the node
* @param {Object} e the related event
* @trigger activate_node.jstree, changed.jstree
*/
activate_node: (obj: any, e: any) => any;
/**
* check a node (only if tie_selection in checkbox settings is false, otherwise select_node will be called internally)
* @name check_node(obj)