In this picture, as you can see there are the red deletion buttons, how do I create a hover tooltip for these buttons? Is it the same as setShowHover(true)
?
Code:
HoverCustomizer customGroupTooltips = new HoverCustomizer()
{
@Override
public String hoverHTML(Object value, ListGridRecord record, int rowNum, int colNum) {
if (colNum == 1)
{
return "tooltip message";
}
else if (colNum == 2)
{
return "delete";
}
return null;
}
};
ListGridField name = new ListGridField(FIELD_NAME);
ListGridField exportField = new IconField(FIELD_EXPORT, ICON.jpg, EXPORT_CUSTOM);
exportField.setShowHover(true);
exportField.setHoverCustomizer(customGroupTooltips.hoverHTML()); //how do i make sure it is colNum 1 message here?
Yes you can do it by using
setHoverCustomizer()
method onListGridField
.Here is the code: