public MaxBoundsForm() { setNumCols(4); setColWidths(125, 125, 75, 125); minX = new FloatItem(); minX.setTitle(MESSAGES.maxBoundsMinX()); minX.setWidth(125); minX.setRequired(true); minY = new FloatItem(); minY.setTitle(MESSAGES.maxBoundsMinY()); minY.setWidth(125); minY.setRequired(true); maxX = new FloatItem(); maxX.setTitle(MESSAGES.maxBoundsMaxX()); maxX.setWidth(125); maxX.setRequired(true); maxY = new FloatItem(); maxY.setTitle(MESSAGES.maxBoundsMaxY()); maxY.setWidth(125); maxY.setRequired(true); // ------------------------------------------------- setFields(minX, maxX, minY, maxY); }
propDateValue.setVisible(true); } else if (type == PropertyDataTypes.DECIMAL || type == PropertyDataTypes.DOUBLE) { propFloatValue.setTitle("Value ("+type.getTypeName()+")"); propFloatValue.setVisible(true); } else if (type == PropertyDataTypes.LONG) { propLongValue.setTitle("Value ("+type.getTypeName()+")");
public static FloatItem getOrCreateRef(JavaScriptObject jsObj) { if(jsObj == null) return null; RefDataClass obj = RefDataClass.getRef(jsObj); if(obj != null) { obj.setJsObj(jsObj); return (FloatItem) obj; } else { return new FloatItem(jsObj); } }
public void setData(DynamicLayerConfiguration layerConfig) { clearValues(); this.layerConfig = layerConfig; Bbox bounds = layerConfig.getServerLayerInfo().getMaxExtent(); if (bounds != null) { minX.setValue(bounds.getX()); minY.setValue(bounds.getY()); maxX.setValue(bounds.getMaxX()); maxY.setValue(bounds.getMaxY()); } }
public DynamicLayerConfiguration getData() { Bbox bounds = layerConfig.getServerLayerInfo().getMaxExtent(); if (bounds == null) { bounds = new Bbox(); layerConfig.getServerLayerInfo().setMaxExtent(bounds); layerConfig.getClientLayerInfo().setMaxExtent(bounds); } bounds.setX(minX.getValueAsFloat()); bounds.setY(minY.getValueAsFloat()); bounds.setMaxX(maxX.getValueAsFloat()); bounds.setMaxY(maxY.getValueAsFloat()); return layerConfig; } }
public FloatItem() { setType("float"); }
private void disableAllFields() { propDateValue.setVisible(false); propStringValue.setVisible(false); propLongValue.setVisible(false); propBooleanValue.setVisible(false); propFloatValue.setVisible(false); propGridCanvas.setVisible(false); } // TODO: Browse for reference
propDateValue.setValue(property.getDateValue()); } else if (type == PropertyDataTypes.DECIMAL) { propFloatValue.setValue(property.getDecimalValue().doubleValue()); } else if (type == PropertyDataTypes.DOUBLE) { propFloatValue.setValue(property.getDoubleValue()); } else if (type == PropertyDataTypes.LONG) { propLongValue.setValue(property.getLongValue());
property.setDateValue(propDateValue.getValueAsDate()); } else if (type == PropertyDataTypes.DECIMAL) { property.setDecimalValue(new BigDecimal(propFloatValue.getValueAsFloat().toString())); } else if (type == PropertyDataTypes.DOUBLE) { property.setDoubleValue(new Double(propFloatValue.getValueAsFloat())); } else if (type == PropertyDataTypes.LONG) { property.setLongValue(new Long(propLongValue.getValueAsInteger()));