@UiHandler({"code", "description"}) void onCodeValueChange(ValueChangeEvent<String> event) { if (editElement != null) { editElement.setCode(code.getText()); editElement.setDescription(description.getText()); } }
@Override public MapDrawingObject createDrawingObject(String elementName) { Element el = getModel().getXml().getOwnerDocument().createElement(elementName); getModel().getXml().appendChild(el); // ret.setAttribute("pid", "" + GpsReadNode.pointId++); MapDrawingObject mdo = new MapDrawingObject(el); mapDrawingObjects.add(mdo); mdo.getPid(); return mdo; }
@UiHandler({"zone", "easting", "northing"}) void onUTMValueChange(ValueChangeEvent<String> event) { if (editElement != null) { editElement.setZone(zone.getText()); editElement.setEasting(easting.getText()); editElement.setNorthing(northing.getText()); editElement.setLatLngFromUTM(); mapPanel.updateDrawingObject(editElement); } }
private void setWidgetValuesFromEditElement(MapDrawingObject element) { selectMsg.setVisible(false); editPanel.setVisible(true); editLabel.setText("Editing: " + element.getType()); code.setText(editElement.getCode()); description.setText(editElement.getDescription()); if (element.getType().equals("point")) { pointFields.setVisible(true); zone.setText(editElement.getZone()); easting.setText(editElement.getEasting()); northing.setText(editElement.getNorthing()); height.setText(editElement.getHeight()); latitude.setText(editElement.getLatitude()); longitude.setText(editElement.getLongitude()); } else { pointFields.setVisible(false); } }