@Override public void setLast() { for(IInputComponentWrapper e: entries) { e.getDisplay().pseudoClassStateChanged(PseudoClass.getPseudoClass("last"), true); } layout.pseudoClassStateChanged(PseudoClass.getPseudoClass("last"), true); }
public void postProcess() { for (final IFieldset fieldset : fieldsets) { FormFieldset formFieldset = (FormFieldset) fieldset; for (final IInputComponentWrapper row : formFieldset.getRows()) { final String visibleIf = row.getConfiguration().getVisibleIf(); if (StringUtils.isNotEmpty(visibleIf)) { // means that visibility of this component depends on the // value of a component // VisibleIF format: componentId,value1,value2 ... valuen // VisibleIF format: componentId,value1 if (visibleIf.contains(",")) { final String attrId = visibleIf.split(",")[0]; final List<String> attrValue = Arrays.asList(visibleIf.split(",")); final AbstractInputComponent comp = (AbstractInputComponent) controller.getComponent(attrId); if (comp != null) { comp.addValueChangeListner((arg0, arg1, arg2) -> { String newValKey = (String) comp.getValueToValidate(); if (attrValue.contains(newValKey)) { row.getDisplay().setVisible(true); } else { row.getDisplay().setVisible(false); } }); } } } } } }
row.getDisplay().visibleProperty().set(true); row.getDisplay().visibleProperty().set(false); String newValKey = (String) comp.getValueToValidate(); if (attrValue.contains(newValKey)) { row.getDisplay().visibleProperty().set(true); } else { row.getDisplay().visibleProperty().set(false);
/** * @{inheritedDoc} */ @Override protected void process() { super.process(); row.endEdition(); for(IInputComponentWrapper r: row.getEntries()) { layout.getChildren().add(r.getDisplay()); } layout.getStyleClass().addAll("white-background", "shadowed-pane", "padding-16-32-16-32"); // shadow will not be visible without padding of this pane StackPane et = new StackPane(); et.setPrefHeight(-1); et.setStyle("-fx-padding:4;-fx-background-color:transparent;"); et.getChildren().add(layout); buildHeaderActions(); processedView(et); }