@Override public String toString(Label object) { return object==null? "" : object.getText(); } @Override
private void swapLabelsColor(Label lbl1, Label lbl2) { Paint color = lbl1.getTextFill(); lbl1.setTextFill(lbl2.getTextFill()); lbl2.setTextFill(color); }
@Override public void requestLayout() { if (performingLayout) { return; } super.requestLayout(); }
@Override public Node createLabel() { final Label l = new Label(label); l.setTooltip( new Tooltip(tooltip) ); return l; }
@Override protected void layoutChildren() { super.layoutChildren(); if (itemChanged) { if (suggestionList.getItems().size() > 0) { suggestionList.getSelectionModel().select(0); suggestionList.scrollTo(0); } itemChanged = false; } } };
@Override public Label fromString(String string) { return new Label(string); } });
private Object validateComboBox(Object text) { if (control instanceof ComboBox && ((ComboBox) control).isEditable()) { final String editorText = ((ComboBox<?>) control).getEditor().getText(); text = editorText == null || editorText.isEmpty() ? null : text; } return text; }
public void setToast(String toast) { this.toast.setText(toast); }
public void setTypeId(PropertyTypeId typeId) { typeChoiceBox.getSelectionModel().select(typeId); }
/** * {@inheritDoc} */ @Override public void sort() { getSelectionModel().clearSelection(); super.sort(); if (itemWasSelected) { getSelectionModel().select(0); } }
private boolean showCloseButton() { return tab.isClosable() && (getSkinnable().getTabClosingPolicy().equals(TabPane.TabClosingPolicy.ALL_TABS)); // || // getSkinnable().getTabClosingPolicy().equals(TabPane.TabClosingPolicy.SELECTED_TAB) && tab.isSelected()); }
@Override public StyleableProperty<Boolean> getStyleableProperty(ColorPicker n) { final JFXColorPickerSkin skin = (JFXColorPickerSkin) n.getSkin(); return skin.colorLabelVisible; } };
@Override protected void layoutChildren(double contentX, double contentY, double contentWidth, double contentHeight) { scrollPane.resizeRelocate(contentX, contentY, contentWidth, contentHeight); }
@Override protected double computeMinHeight(double width) { return super.computePrefHeight(width); }
@Override protected Skin<?> createDefaultSkin() { return super.createDefaultSkin(); } }.createDefaultSkin();
@Override public String toString(Label object) { return object==null? "" : object.getText(); }
public String getToast() { return toast.getText(); }