Hides the tooltip.
Namespace: MindFusion.Common.UI
File: Tooltip.js
Syntax
JavaScript
Copy Code
|
---|
function hide () |
Example
The following code handles the itemMouseEnter event of a TreeView and hides the tooltip if the node that triggered the event is the origin node:
JavaScript
Copy Code
|
---|
// This is the handler function of tree.itemMouseEnter event. // If the node, sending the event is a root node, set some node-dependent data and show the tooltip. function nodeEnter(sender, args) { var node = args.item; if (!node.parentNode) { tooltip.element.querySelector("#truckNo").innerText = node.title; tooltip.element.querySelector("#dest").innerText = node.flatItems.where(function (n) { return n.level == 1 }).count(); tooltip.element.querySelector("#del").innerText = node.flatItems.where(function (n) { return n.level == 2 }).count(); tooltip.show(new d.Point(tree.bounds.right() + 10, tree.bounds.y + node.bounds.y - tree.element.scrollTop)); } else tooltip.hide(); } |
See Also