List of usage examples for com.vaadin.ui AbstractSplitPanel setMinSplitPosition
public void setMinSplitPosition(float pos, Unit unit)
From source file:org.lunifera.runtime.web.vaadin.databinding.component.internal.SplitPanelMinSplitPositionProperty.java
License:Open Source License
protected void doSetValue(Object source, Object value) { AbstractSplitPanel component = (AbstractSplitPanel) source; Unit unit = component.getMinSplitPositionUnit(); int pos = (Integer) value; if (unit != Unit.PIXELS && unit != Unit.PERCENTAGE) { if (pos <= 100) { unit = Unit.PERCENTAGE;//from ww w . ja v a2s.c o m } else { unit = Unit.PIXELS; } } component.setMinSplitPosition((Integer) value, unit); }
From source file:org.lunifera.runtime.web.vaadin.databinding.component.internal.SplitPanelMinSplitPositionUnitProperty.java
License:Open Source License
protected void doSetValue(Object source, Object value) { AbstractSplitPanel component = (AbstractSplitPanel) source; component.setMinSplitPosition(component.getMinSplitPosition(), (Unit) value); }