final ExampleGroup sg = getSelectedGroup ();
statusBar.addSpacing ();
final FeatureState fgs = sg.getFeatureGroupState ();
final WebLabel featureState = new WebLabel ();
TooltipManager.setTooltip ( featureState, fgs.getIcon (), fgs.getDescription () );
featureState.setIcon ( fgs.getIcon () );
featureState.addMouseListener ( new MouseAdapter ()
{
@Override
public void mousePressed ( final MouseEvent e )
{
showLegend ( featureState, getSelectedGroup ().getFeatureGroupState () );
}
} );
statusBar.add ( featureState );
statusBar.addSpacing ();
final WebLabel groupDescription = new WebLabel ();
groupDescription.setText ( sg.getGroupDescription () );
statusBar.add ( groupDescription );
exampleTabs.addChangeListener ( new ChangeListener ()
{
@Override
public void stateChanged ( final ChangeEvent e )
{
final ExampleGroup sg = getSelectedGroup ();
final FeatureState fgs = sg.getFeatureGroupState ();
TooltipManager.removeTooltips ( featureState );
TooltipManager.setTooltip ( featureState, fgs.getIcon (), fgs.getDescription () );
featureState.setIcon ( fgs.getIcon () );
groupDescription.setText ( sg.getGroupDescription () );
}
} );
// Update button
final WebButton update = WebButton.createIconWebButton ( getUpdateIcon () );