EasyUI Forum
May 06, 2024, 02:37:35 AM *
Welcome, Guest. Please login or register.

Login with username, password and session length
News:
 
   Home   Help Search Login Register  
Pages: [1]
  Print  
Author Topic: Tree Mouseover  (Read 3238 times)
nasiayam
Newbie
*
Posts: 2


View Profile
« on: April 24, 2017, 08:01:58 AM »

Hi

Does easyui-tree supports mouse hover event ? If it does, how to do it ? My intention is to generate tooltip while mouse hovers through a tree control.

Thanks. 
Logged
jarry
Administrator
Hero Member
*****
Posts: 2262


View Profile Email
« Reply #1 on: April 24, 2017, 08:27:36 PM »

You can define the 'formatter' function to attach the 'title' attribute to the node. Please try this code:
Code:
$('#tt').tree({
formatter: function(node){
return '<span title="'+node.text+'">'+node.text+'</span>';
}
})
Logged
Pages: [1]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.18 | SMF © 2013, Simple Machines Valid XHTML 1.0! Valid CSS!