Search in sources :

Example 6 with Toggle

use of org.eclipse.draw2d.Toggle in project whole by wholeplatform.

the class FeatureRightPart method refreshVisuals.

@Override
protected void refreshVisuals() {
    Feature entity = getModelEntity();
    FeatureFigure f = (FeatureFigure) getFigure();
    Toggle toggle = f.getFoldingToggle(0);
    if (entity.getFeatures().wIsEmpty() && !toggle.isSelected())
        toggle.doClick();
}
Also used : Toggle(org.eclipse.draw2d.Toggle) FeatureFigure(org.whole.lang.features.ui.figures.FeatureFigure) Feature(org.whole.lang.frames.model.Feature)

Aggregations

Toggle (org.eclipse.draw2d.Toggle)6 FeatureFigure (org.whole.lang.features.ui.figures.FeatureFigure)2 Feature (org.whole.lang.frames.model.Feature)2 EntityToggle (org.whole.lang.ui.figures.EntityToggle)2 ActionListener (org.eclipse.draw2d.ActionListener)1 ChangeEvent (org.eclipse.draw2d.ChangeEvent)1 ChangeListener (org.eclipse.draw2d.ChangeListener)1 ToggleModel (org.eclipse.draw2d.ToggleModel)1 Point (org.eclipse.draw2d.geometry.Point)1 IFoldableFigure (org.whole.lang.ui.figures.IFoldableFigure)1