List of usage examples for com.vaadin.server SizeWithUnit parseStringSize
public static SizeWithUnit parseStringSize(String s)
From source file:com.haulmont.cuba.web.toolkit.ui.CubaSuggestionField.java
License:Apache License
public void setPopupWidth(String popupWidth) { if (popupWidth == null || popupWidth.isEmpty()) { throw new IllegalArgumentException("Popup width cannot be empty"); }//from w w w. j av a2 s . c o m if (Objects.equals(getState(false).popupWidth, popupWidth)) return; if (isPredefinedPopupWidth(popupWidth)) { getState().popupWidth = popupWidth; return; } // try to parse to be sure that string is correct SizeWithUnit.parseStringSize(popupWidth); getState().popupWidth = popupWidth; }