LAYOUT.setBorder("1px solid #CCCCCC");
LAYOUT.setBackgroundColor("#FFFFFF");
for(final Operation operation : this){
if(operation.DESCRIPTION == null)
operation.DESCRIPTION = operation.NAME;
final Label label = new Label(operation.NAME);
label.setAutoFit(true);
label.setPadding(3);
if(operation.ICON!=null)
label.setIcon(operation.ICON);
label.setBackgroundColor("#FFFFFF");
label.addMouseOverHandler(new MouseOverHandler(){
/* (non-Javadoc)
* @see com.smartgwt.client.widgets.events.MouseOverHandler#onMouseOver(com.smartgwt.client.widgets.events.MouseOverEvent)
*/
public void onMouseOver(MouseOverEvent event){
label.setBackgroundColor("#EEEECC");
}
});
label.addMouseOutHandler(new MouseOutHandler(){
/* (non-Javadoc)
* @see com.smartgwt.client.widgets.events.MouseOutHandler#onMouseOut(com.smartgwt.client.widgets.events.MouseOutEvent)
*/
public void onMouseOut(MouseOutEvent event){
label.setBackgroundColor("#FFFFFF");
}
});
label.addClickHandler(new ClickHandler(){
/* (non-Javadoc)
* @see com.smartgwt.client.widgets.events.ClickHandler#onClick(com.smartgwt.client.widgets.events.ClickEvent)
*/
public void onClick(ClickEvent event){
com.smartgwt.client.widgets.Window window = new com.smartgwt.client.widgets.Window();