item.setMenu(menu);
return item;
}
protected ToggleButton createToggleButton(AbstractImagePrototype icon, final String tt, String toolTipTitle) {
ToggleButton item = new ToggleButton() {
@Override
protected void afterRender() {
super.afterRender();
if (GXT.isAriaEnabled()) buttonEl.dom.setTitle(tt);
}
};
item.setTabIndex(-1);
ToolTipConfig cfg = new ToolTipConfig(toolTipTitle, tt);
item.setToolTip(cfg);
if (GXT.isAriaEnabled()) {
item.setData("gxt-menutext", toolTipTitle);
}
item.setIcon(icon);
item.addSelectionListener(btnListener);
return item;
}