Exemplo n.º 1
0
 public FormProperty<?>[] getAllProperties() {
   if (layoutDelegate instanceof AbstractLayoutSupport) {
     return ((AbstractLayoutSupport) layoutDelegate).getAllProperties();
   }
   java.util.List<FormProperty<?>> allPropsList = new ArrayList<>();
   for (Node.PropertySet propertySet : propertySets) {
     FormProperty<?>[] props = (FormProperty<?>[]) propertySet.getProperties();
     allPropsList.addAll(Arrays.asList(props));
   }
   FormProperty<?>[] allProperties = new FormProperty<?>[allPropsList.size()];
   allPropsList.toArray(allProperties);
   return allProperties;
 }
Exemplo n.º 2
0
  // properties and customizer
  public Node.PropertySet[] getPropertySets() {
    if (propertySets == null) {
      if (layoutDelegate == null) {
        return new Node.PropertySet[0]; // Issue 63916
      }
      propertySets = layoutDelegate.getPropertySets();

      for (Node.PropertySet propertySet : propertySets) {
        FormProperty<?>[] props = (FormProperty<?>[]) propertySet.getProperties();
        for (FormProperty<?> prop : props) {
          prop.addVetoableChangeListener(getLayoutListener());
          prop.addPropertyChangeListener(getLayoutListener());
        }
      }
    }
    return propertySets;
  }