当鼠标指针悬停在YUI上下文菜单项上时,如何显示工具提示
||
在我们的工作区中,有一个使用YUI库创建的上下文菜单。当用户将鼠标悬停在每个项目上时,我们希望触发工具提示。我在Google周围搜索,但找不到有用的信息。我们怎样才能做到这一点?
这是上下文菜单的创建方式:
// Add ContextMenu instance to the DataTable parent container
var contextMenu = new YAHOO.widget.ContextMenu(\"contextMenu\", {trigger: viewScriptsDataTable.getTbodyEl(), itemData: contextMenuItems, lazyload: true});
contextMenu.render(\"viewScriptsGrid\");
// Subscribe to events in format event, function, object to pass to function
contextMenu.beforeShowEvent.subscribe(CodesGrid.updateSelectionIfNecessary, viewScriptsDataTable);
contextMenu.subscribe(\"click\", CodesGrid.onContextMenuClick, viewScriptsDataTable);
没有找到相关结果
已邀请:
1 个回复
磐剩
或者,您可以从现有的html构建菜单,以便设置title属性: